@codingame/monaco-vscode-extensions-service-override
Advanced tools
Comparing version
@@ -19,3 +19,3 @@ | ||
import { IWorkbenchExtensionEnablementService, IWorkbenchExtensionManagementService, IWebExtensionsScannerService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensionManagement/common/extensionManagement.service'; | ||
import { ExtensionManifestPropertiesService } from '@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService'; | ||
import { ExtensionManifestPropertiesService } from '@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService'; | ||
import { IExtensionManifestPropertiesService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service'; | ||
@@ -22,0 +22,0 @@ import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service'; |
{ | ||
"name": "@codingame/monaco-vscode-extensions-service-override", | ||
"version": "17.2.1", | ||
"version": "18.0.0", | ||
"private": false, | ||
@@ -18,29 +18,31 @@ "description": "VSCode public API plugged on the monaco editor - extensions service-override", | ||
"dependencies": { | ||
"@codingame/monaco-vscode-0b087f42-a5a3-5eb9-9bfd-1eebc1bba163-common": "17.2.1", | ||
"@codingame/monaco-vscode-1cc4ea0a-c5b6-54ed-bb60-078a99119b55-common": "17.2.1", | ||
"@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "17.2.1", | ||
"@codingame/monaco-vscode-25a9b730-95ad-54d3-8807-71421ad9b891-common": "17.2.1", | ||
"@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common": "17.2.1", | ||
"@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common": "17.2.1", | ||
"@codingame/monaco-vscode-34a0ffd3-b9f5-5699-b43b-38af5732f38a-common": "17.2.1", | ||
"@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common": "17.2.1", | ||
"@codingame/monaco-vscode-4a3ac544-9a61-534c-88df-756262793ef7-common": "17.2.1", | ||
"@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "17.2.1", | ||
"@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "17.2.1", | ||
"@codingame/monaco-vscode-86d65fc6-30f9-5dca-9501-e249de688591-common": "17.2.1", | ||
"@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "17.2.1", | ||
"@codingame/monaco-vscode-9c72783f-914c-50be-b9ef-da16356d81a8-common": "17.2.1", | ||
"@codingame/monaco-vscode-api": "17.2.1", | ||
"@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common": "17.2.1", | ||
"@codingame/monaco-vscode-be8ddbb5-094a-5657-b1cc-fe106c94c632-common": "17.2.1", | ||
"@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "17.2.1", | ||
"@codingame/monaco-vscode-c3c61c00-c254-5856-9dc9-d7929c1f9062-common": "17.2.1", | ||
"@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common": "17.2.1", | ||
"@codingame/monaco-vscode-e67a0dae-5b2c-54e6-8d61-90102c78362d-common": "17.2.1", | ||
"@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "17.2.1", | ||
"@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "17.2.1", | ||
"@codingame/monaco-vscode-f22e7e55-aee8-5b52-a6bc-950efd9f5890-common": "17.2.1", | ||
"@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common": "17.2.1", | ||
"@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common": "17.2.1", | ||
"@codingame/monaco-vscode-files-service-override": "17.2.1" | ||
"@codingame/monaco-vscode-1cb11a73-359e-5a2f-9e95-6989cc9858ee-common": "18.0.0", | ||
"@codingame/monaco-vscode-1cc4ea0a-c5b6-54ed-bb60-078a99119b55-common": "18.0.0", | ||
"@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "18.0.0", | ||
"@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common": "18.0.0", | ||
"@codingame/monaco-vscode-34a0ffd3-b9f5-5699-b43b-38af5732f38a-common": "18.0.0", | ||
"@codingame/monaco-vscode-3a35f433-1297-5707-ab58-c261b8180e6d-common": "18.0.0", | ||
"@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common": "18.0.0", | ||
"@codingame/monaco-vscode-47472025-cc45-5680-86cd-09ceaba921a1-common": "18.0.0", | ||
"@codingame/monaco-vscode-4a3ac544-9a61-534c-88df-756262793ef7-common": "18.0.0", | ||
"@codingame/monaco-vscode-4ee27008-17b4-593f-9c09-19e8e3077f51-common": "18.0.0", | ||
"@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common": "18.0.0", | ||
"@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "18.0.0", | ||
"@codingame/monaco-vscode-7adbeffb-8051-54a9-8c9b-b62ce9e5836f-common": "18.0.0", | ||
"@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "18.0.0", | ||
"@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "18.0.0", | ||
"@codingame/monaco-vscode-924e8f00-6faf-5059-b518-e43427d29ab3-common": "18.0.0", | ||
"@codingame/monaco-vscode-9c72783f-914c-50be-b9ef-da16356d81a8-common": "18.0.0", | ||
"@codingame/monaco-vscode-a4683c2b-a0d2-5112-96ba-eedc605346d2-common": "18.0.0", | ||
"@codingame/monaco-vscode-a8d3bd74-e63e-5327-96e8-4f931661e329-common": "18.0.0", | ||
"@codingame/monaco-vscode-api": "18.0.0", | ||
"@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common": "18.0.0", | ||
"@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "18.0.0", | ||
"@codingame/monaco-vscode-c3c61c00-c254-5856-9dc9-d7929c1f9062-common": "18.0.0", | ||
"@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "18.0.0", | ||
"@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "18.0.0", | ||
"@codingame/monaco-vscode-f22e7e55-aee8-5b52-a6bc-950efd9f5890-common": "18.0.0", | ||
"@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common": "18.0.0", | ||
"@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common": "18.0.0", | ||
"@codingame/monaco-vscode-files-service-override": "18.0.0" | ||
}, | ||
@@ -47,0 +49,0 @@ "main": "index.js", |
@@ -15,3 +15,3 @@ import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
} | ||
export declare function isRemoteConsoleLog(obj: any): obj is IRemoteConsoleLog; | ||
export declare function isRemoteConsoleLog(obj: unknown): obj is IRemoteConsoleLog; | ||
export declare function parse(entry: IRemoteConsoleLog): { | ||
@@ -18,0 +18,0 @@ args: any[]; |
@@ -15,5 +15,5 @@ | ||
const notFound = (id) => ( localize(1787, "Extension '{0}' not found.", id)); | ||
const notFound = (id) => ( localize(1792, "Extension '{0}' not found.", id)); | ||
const useId = ( localize( | ||
1788, | ||
1793, | ||
"Make sure you use the full extension ID, including the publisher, e.g.: {0}", | ||
@@ -55,3 +55,3 @@ 'ms-dotnettools.csharp' | ||
if (this.location) { | ||
this.logger.info(( localize(1789, "Extensions installed on {0}:", this.location))); | ||
this.logger.info(( localize(1794, "Extensions installed on {0}:", this.location))); | ||
} | ||
@@ -71,3 +71,3 @@ extensions = extensions.sort((e1, e2) => e1.identifier.id.localeCompare(e2.identifier.id)); | ||
if (extensions.length) { | ||
this.logger.info(this.location ? ( localize(1790, "Installing extensions on {0}...", this.location)) : ( localize(1791, "Installing extensions..."))); | ||
this.logger.info(this.location ? ( localize(1795, "Installing extensions on {0}...", this.location)) : ( localize(1796, "Installing extensions..."))); | ||
} | ||
@@ -115,7 +115,7 @@ const installVSIXInfos = []; | ||
catch (error) { | ||
this.logger.error(( localize(1792, "Error while installing extensions: {0}", getErrorMessage(error)))); | ||
this.logger.error(( localize(1797, "Error while installing extensions: {0}", getErrorMessage(error)))); | ||
throw error; | ||
} | ||
if (failed.length) { | ||
throw ( new Error(( localize(1793, "Failed Installing Extensions: {0}", failed.join(', '))))); | ||
throw ( new Error(( localize(1798, "Failed Installing Extensions: {0}", failed.join(', '))))); | ||
} | ||
@@ -132,3 +132,3 @@ } | ||
this.logger.trace(( localize( | ||
1794, | ||
1799, | ||
"Fetching latest versions for {0} extensions", | ||
@@ -150,7 +150,7 @@ installedExtensionsQuery.length | ||
if (!extensionsToUpdate.length) { | ||
this.logger.info(( localize(1795, "No extension to update"))); | ||
this.logger.info(( localize(1800, "No extension to update"))); | ||
return; | ||
} | ||
this.logger.info(( localize( | ||
1796, | ||
1801, | ||
"Updating extensions: {0}", | ||
@@ -163,3 +163,3 @@ ( extensionsToUpdate.map(ext => ext.extension.identifier.id)).join(', ') | ||
this.logger.error(( localize( | ||
1797, | ||
1802, | ||
"Error while updating extension {0}: {1}", | ||
@@ -172,3 +172,3 @@ extensionResult.identifier.id, | ||
this.logger.info(( localize( | ||
1798, | ||
1803, | ||
"Extension '{0}' v{1} was successfully updated.", | ||
@@ -188,3 +188,3 @@ extensionResult.identifier.id, | ||
this.logger.info(( localize( | ||
1799, | ||
1804, | ||
"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'.", | ||
@@ -198,3 +198,3 @@ id, | ||
if (version && installedExtension.manifest.version === version) { | ||
this.logger.info(( localize(1800, "Extension '{0}' is already installed.", `${id}@${version}`))); | ||
this.logger.info(( localize(1805, "Extension '{0}' is already installed.", `${id}@${version}`))); | ||
return false; | ||
@@ -236,3 +236,3 @@ } | ||
this.logger.info(( localize( | ||
1800, | ||
1805, | ||
"Extension '{0}' is already installed.", | ||
@@ -244,3 +244,3 @@ version ? `${id}@${version}` : id | ||
this.logger.info(( localize( | ||
1801, | ||
1806, | ||
"Updating the extension '{0}' to the version {1}", | ||
@@ -252,6 +252,6 @@ id, | ||
if (installOptions.isBuiltin) { | ||
this.logger.info(version ? ( localize(1802, "Installing builtin extension '{0}' v{1}...", id, version)) : ( localize(1803, "Installing builtin extension '{0}'...", id))); | ||
this.logger.info(version ? ( localize(1807, "Installing builtin extension '{0}' v{1}...", id, version)) : ( localize(1808, "Installing builtin extension '{0}'...", id))); | ||
} | ||
else { | ||
this.logger.info(version ? ( localize(1804, "Installing extension '{0}' v{1}...", id, version)) : ( localize(1805, "Installing extension '{0}'...", id))); | ||
this.logger.info(version ? ( localize(1809, "Installing extension '{0}' v{1}...", id, version)) : ( localize(1810, "Installing extension '{0}'...", id))); | ||
} | ||
@@ -268,3 +268,3 @@ extensionsToInstall.push({ | ||
this.logger.error(( localize( | ||
1806, | ||
1811, | ||
"Error while installing extension {0}: {1}", | ||
@@ -278,3 +278,3 @@ extensionResult.identifier.id, | ||
this.logger.info(( localize( | ||
1807, | ||
1812, | ||
"Extension '{0}' v{1} was successfully installed.", | ||
@@ -298,7 +298,7 @@ extensionResult.identifier.id, | ||
await this.extensionManagementService.install(vsix, { ...installOptions, installGivenVersion: true }); | ||
this.logger.info(( localize(1808, "Extension '{0}' was successfully installed.", basename(vsix)))); | ||
this.logger.info(( localize(1813, "Extension '{0}' was successfully installed.", basename(vsix)))); | ||
} | ||
catch (error) { | ||
if (isCancellationError(error)) { | ||
this.logger.info(( localize(1809, "Cancelled installing extension '{0}'.", basename(vsix)))); | ||
this.logger.info(( localize(1814, "Cancelled installing extension '{0}'.", basename(vsix)))); | ||
} | ||
@@ -338,3 +338,3 @@ else { | ||
this.logger.info(( localize( | ||
1810, | ||
1815, | ||
"A newer version of extension '{0}' v{1} is already installed. Use '--force' option to downgrade to older version.", | ||
@@ -367,3 +367,3 @@ newer.identifier.id, | ||
this.logger.info(( localize( | ||
1811, | ||
1816, | ||
"Extension '{0}' is a Built-in extension and cannot be uninstalled", | ||
@@ -376,3 +376,3 @@ id | ||
this.logger.info(( localize( | ||
1812, | ||
1817, | ||
"Extension '{0}' is marked as a Built-in extension by user. Please use '--force' option to uninstall it.", | ||
@@ -383,3 +383,3 @@ id | ||
} | ||
this.logger.info(( localize(1813, "Uninstalling {0}...", id))); | ||
this.logger.info(( localize(1818, "Uninstalling {0}...", id))); | ||
for (const extensionToUninstall of extensionsToUninstall) { | ||
@@ -390,3 +390,3 @@ await this.extensionManagementService.uninstall(extensionToUninstall, { profileLocation }); | ||
this.logger.info(( localize( | ||
1814, | ||
1819, | ||
"Extension '{0}' was successfully uninstalled from {1}!", | ||
@@ -398,3 +398,3 @@ id, | ||
else { | ||
this.logger.info(( localize(1815, "Extension '{0}' was successfully uninstalled!", id))); | ||
this.logger.info(( localize(1820, "Extension '{0}' was successfully uninstalled!", id))); | ||
} | ||
@@ -417,3 +417,3 @@ } | ||
notInstalled(id) { | ||
return this.location ? ( localize(1816, "Extension '{0}' is not installed on {1}.", id, this.location)) : ( localize(1817, "Extension '{0}' is not installed.", id)); | ||
return this.location ? ( localize(1821, "Extension '{0}' is not installed on {1}.", id, this.location)) : ( localize(1822, "Extension '{0}' is not installed.", id)); | ||
} | ||
@@ -420,0 +420,0 @@ }; |
@@ -8,3 +8,3 @@ import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service"; | ||
import { AbstractExtensionResourceLoaderService } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/platform/extensionResourceLoader/common/extensionResourceLoader"; | ||
import { AbstractExtensionResourceLoaderService } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/platform/extensionResourceLoader/common/extensionResourceLoader"; | ||
import { IExtensionGalleryManifestService } from "@codingame/monaco-vscode-api/vscode/vs/platform/extensionManagement/common/extensionGalleryManifest.service"; | ||
@@ -11,0 +11,0 @@ export declare class ExtensionResourceLoaderService extends AbstractExtensionResourceLoaderService { |
@@ -11,3 +11,3 @@ | ||
import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service'; | ||
import { AbstractExtensionResourceLoaderService } from '@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/platform/extensionResourceLoader/common/extensionResourceLoader'; | ||
import { AbstractExtensionResourceLoaderService } from '@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/platform/extensionResourceLoader/common/extensionResourceLoader'; | ||
import '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation'; | ||
@@ -14,0 +14,0 @@ import { IExtensionGalleryManifestService } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensionManagement/common/extensionGalleryManifest.service'; |
@@ -14,5 +14,9 @@ import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; | ||
import { IAuthenticationUsageService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationUsageService.service"; | ||
import { UriComponents } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
import { URI, UriComponents } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
import { IOpenerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service"; | ||
import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service"; | ||
import { IURLService } from "@codingame/monaco-vscode-api/vscode/vs/platform/url/common/url.service"; | ||
import { IAuthorizationTokenResponse } from "@codingame/monaco-vscode-api/vscode/vs/base/common/oauth"; | ||
import { IDynamicAuthenticationProviderStorageService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/dynamicAuthenticationProviderStorage.service"; | ||
import { IClipboardService } from "@codingame/monaco-vscode-api/vscode/vs/platform/clipboard/common/clipboardService.service"; | ||
export interface AuthenticationInteractiveOptions { | ||
@@ -29,2 +33,3 @@ detail?: string; | ||
account?: AuthenticationSessionAccount; | ||
authorizationServer?: UriComponents; | ||
} | ||
@@ -36,5 +41,6 @@ export declare class MainThreadAuthenticationProvider extends Disposable implements IAuthenticationProvider { | ||
readonly supportsMultipleAccounts: boolean; | ||
readonly authorizationServers: ReadonlyArray<URI>; | ||
private readonly notificationService; | ||
readonly onDidChangeSessions: Event<AuthenticationSessionsChangeEvent>; | ||
constructor(_proxy: ExtHostAuthenticationShape, id: string, label: string, supportsMultipleAccounts: boolean, notificationService: INotificationService, onDidChangeSessionsEmitter: Emitter<AuthenticationSessionsChangeEvent>); | ||
constructor(_proxy: ExtHostAuthenticationShape, id: string, label: string, supportsMultipleAccounts: boolean, authorizationServers: ReadonlyArray<URI>, notificationService: INotificationService, onDidChangeSessionsEmitter: Emitter<AuthenticationSessionsChangeEvent>); | ||
getSessions(scopes: string[] | undefined, options: IAuthenticationProviderSessionOptions): Promise<readonly AuthenticationSession[]>; | ||
@@ -55,11 +61,20 @@ createSession(scopes: string[], options: IAuthenticationCreateSessionOptions): Promise<AuthenticationSession>; | ||
private readonly logService; | ||
private readonly urlService; | ||
private readonly dynamicAuthProviderStorageService; | ||
private readonly clipboardService; | ||
private readonly _proxy; | ||
private readonly _registrations; | ||
private _sentProviderUsageEvents; | ||
constructor(extHostContext: IExtHostContext, authenticationService: IAuthenticationService, authenticationExtensionsService: IAuthenticationExtensionsService, authenticationAccessService: IAuthenticationAccessService, authenticationUsageService: IAuthenticationUsageService, dialogService: IDialogService, notificationService: INotificationService, extensionService: IExtensionService, telemetryService: ITelemetryService, openerService: IOpenerService, logService: ILogService); | ||
$registerAuthenticationProvider(id: string, label: string, supportsMultipleAccounts: boolean): Promise<void>; | ||
$unregisterAuthenticationProvider(id: string): void; | ||
constructor(extHostContext: IExtHostContext, authenticationService: IAuthenticationService, authenticationExtensionsService: IAuthenticationExtensionsService, authenticationAccessService: IAuthenticationAccessService, authenticationUsageService: IAuthenticationUsageService, dialogService: IDialogService, notificationService: INotificationService, extensionService: IExtensionService, telemetryService: ITelemetryService, openerService: IOpenerService, logService: ILogService, urlService: IURLService, dynamicAuthProviderStorageService: IDynamicAuthenticationProviderStorageService, clipboardService: IClipboardService); | ||
$registerAuthenticationProvider(id: string, label: string, supportsMultipleAccounts: boolean, supportedAuthorizationServer?: UriComponents[]): Promise<void>; | ||
$unregisterAuthenticationProvider(id: string): Promise<void>; | ||
$ensureProvider(id: string): Promise<void>; | ||
$sendDidChangeSessions(providerId: string, event: AuthenticationSessionsChangeEvent): void; | ||
$sendDidChangeSessions(providerId: string, event: AuthenticationSessionsChangeEvent): Promise<void>; | ||
$removeSession(providerId: string, sessionId: string): Promise<void>; | ||
$waitForUriHandler(expectedUri: UriComponents): Promise<UriComponents>; | ||
$showContinueNotification(message: string): Promise<boolean>; | ||
$registerDynamicAuthenticationProvider(id: string, label: string, authorizationServer: UriComponents, clientId: string): Promise<void>; | ||
$setSessionsForDynamicAuthProvider(authProviderId: string, clientId: string, sessions: (IAuthorizationTokenResponse & { | ||
created_at: number; | ||
})[]): Promise<void>; | ||
private loginPrompt; | ||
@@ -76,2 +91,3 @@ private continueWithIncorrectAccountPrompt; | ||
private _removeAccountPreference; | ||
$showDeviceCodeModal(userCode: string, verificationUri: string): Promise<boolean>; | ||
} |
@@ -23,5 +23,10 @@ | ||
import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service'; | ||
import { ExtensionHostKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionHostKind'; | ||
import { IURLService } from '@codingame/monaco-vscode-api/vscode/vs/platform/url/common/url.service'; | ||
import { DeferredPromise, raceTimeout } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async'; | ||
import { IDynamicAuthenticationProviderStorageService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/dynamicAuthenticationProviderStorage.service'; | ||
import { IClipboardService } from '@codingame/monaco-vscode-api/vscode/vs/platform/clipboard/common/clipboardService.service'; | ||
class MainThreadAuthenticationProvider extends Disposable { | ||
constructor(_proxy, id, label, supportsMultipleAccounts, notificationService, onDidChangeSessionsEmitter) { | ||
constructor(_proxy, id, label, supportsMultipleAccounts, authorizationServers, notificationService, onDidChangeSessionsEmitter) { | ||
super(); | ||
@@ -32,2 +37,3 @@ this._proxy = _proxy; | ||
this.supportsMultipleAccounts = supportsMultipleAccounts; | ||
this.authorizationServers = authorizationServers; | ||
this.notificationService = notificationService; | ||
@@ -44,7 +50,7 @@ this.onDidChangeSessions = onDidChangeSessionsEmitter.event; | ||
await this._proxy.$removeSession(this.id, sessionId); | ||
this.notificationService.info(( localize(2381, "Successfully signed out."))); | ||
this.notificationService.info(( localize(2387, "Successfully signed out."))); | ||
} | ||
} | ||
let MainThreadAuthentication = class MainThreadAuthentication extends Disposable { | ||
constructor(extHostContext, authenticationService, authenticationExtensionsService, authenticationAccessService, authenticationUsageService, dialogService, notificationService, extensionService, telemetryService, openerService, logService) { | ||
constructor(extHostContext, authenticationService, authenticationExtensionsService, authenticationAccessService, authenticationUsageService, dialogService, notificationService, extensionService, telemetryService, openerService, logService, urlService, dynamicAuthProviderStorageService, clipboardService) { | ||
super(); | ||
@@ -61,2 +67,5 @@ this.authenticationService = authenticationService; | ||
this.logService = logService; | ||
this.urlService = urlService; | ||
this.dynamicAuthProviderStorageService = dynamicAuthProviderStorageService; | ||
this.clipboardService = clipboardService; | ||
this._registrations = this._register(( new DisposableMap())); | ||
@@ -66,5 +75,4 @@ this._sentProviderUsageEvents = ( new Set()); | ||
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostAuthentication)); | ||
this._register(this.authenticationService.onDidChangeSessions(e => { | ||
this._proxy.$onDidChangeAuthenticationSessions(e.providerId, e.label); | ||
})); | ||
this._register(this.authenticationService.onDidChangeSessions(e => this._proxy.$onDidChangeAuthenticationSessions(e.providerId, e.label))); | ||
this._register(this.authenticationService.onDidUnregisterAuthenticationProvider(e => this._proxy.$onDidUnregisterAuthenticationProvider(e.id))); | ||
this._register(this.authenticationExtensionsService.onDidChangeAccountPreference(e => { | ||
@@ -74,4 +82,19 @@ const providerInfo = this.authenticationService.getProvider(e.providerId); | ||
})); | ||
this._register(this.dynamicAuthProviderStorageService.onDidChangeTokens(e => { | ||
this._proxy.$onDidChangeDynamicAuthProviderTokens(e.authProviderId, e.clientId, e.tokens); | ||
})); | ||
this._register(authenticationService.registerAuthenticationProviderHostDelegate({ | ||
priority: extHostContext.extensionHostKind === ExtensionHostKind.LocalWebWorker ? 0 : 1, | ||
create: async (authorizationServer, serverMetadata, resource) => { | ||
const authProviderId = ( authorizationServer.toString(true)); | ||
const clientId = this.dynamicAuthProviderStorageService.getClientId(authProviderId); | ||
let initialTokens = undefined; | ||
if (clientId) { | ||
initialTokens = await this.dynamicAuthProviderStorageService.getSessionsForDynamicAuthProvider(authProviderId, clientId); | ||
} | ||
return await this._proxy.$registerDynamicAuthProvider(authorizationServer, serverMetadata, resource, clientId, initialTokens); | ||
} | ||
})); | ||
} | ||
async $registerAuthenticationProvider(id, label, supportsMultipleAccounts) { | ||
async $registerAuthenticationProvider(id, label, supportsMultipleAccounts, supportedAuthorizationServer = []) { | ||
if (!this.authenticationService.declaredProviders.find(p => p.id === id)) { | ||
@@ -83,2 +106,3 @@ this.logService.warn(`Authentication provider ${id} was not declared in the Extension Manifest.`); | ||
this._registrations.set(id, emitter); | ||
const supportedAuthorizationServerUris = ( supportedAuthorizationServer.map(i => URI.revive(i))); | ||
const provider = ( new MainThreadAuthenticationProvider( | ||
@@ -89,2 +113,3 @@ this._proxy, | ||
supportsMultipleAccounts, | ||
supportedAuthorizationServerUris, | ||
this.notificationService, | ||
@@ -95,3 +120,3 @@ emitter | ||
} | ||
$unregisterAuthenticationProvider(id) { | ||
async $unregisterAuthenticationProvider(id) { | ||
this._registrations.deleteAndDispose(id); | ||
@@ -105,3 +130,3 @@ this.authenticationService.unregisterAuthenticationProvider(id); | ||
} | ||
$sendDidChangeSessions(providerId, event) { | ||
async $sendDidChangeSessions(providerId, event) { | ||
const obj = this._registrations.get(providerId); | ||
@@ -115,2 +140,45 @@ if (obj instanceof Emitter) { | ||
} | ||
async $waitForUriHandler(expectedUri) { | ||
const deferredPromise = ( new DeferredPromise()); | ||
const disposable = this.urlService.registerHandler({ | ||
handleURL: async (uri) => { | ||
if (uri.scheme !== expectedUri.scheme || uri.authority !== expectedUri.authority || uri.path !== expectedUri.path) { | ||
return false; | ||
} | ||
deferredPromise.complete(uri); | ||
disposable.dispose(); | ||
return true; | ||
} | ||
}); | ||
const result = await raceTimeout(deferredPromise.p, 5 * 60 * 1000); | ||
if (!result) { | ||
throw ( new Error('Timed out waiting for URI handler')); | ||
} | ||
return await deferredPromise.p; | ||
} | ||
$showContinueNotification(message) { | ||
const yes = ( localize(2388, "Yes")); | ||
const no = ( localize(2389, "No")); | ||
const deferredPromise = ( new DeferredPromise()); | ||
let result = false; | ||
const handle = this.notificationService.prompt(Severity.Warning, message, [{ | ||
label: yes, | ||
run: () => result = true | ||
}, { | ||
label: no, | ||
run: () => result = false | ||
}]); | ||
const disposable = handle.onDidClose(() => { | ||
deferredPromise.complete(result); | ||
disposable.dispose(); | ||
}); | ||
return deferredPromise.p; | ||
} | ||
async $registerDynamicAuthenticationProvider(id, label, authorizationServer, clientId) { | ||
await this.$registerAuthenticationProvider(id, label, false, [authorizationServer]); | ||
this.dynamicAuthProviderStorageService.storeClientId(id, ( URI.revive(authorizationServer).toString(true)), clientId, label); | ||
} | ||
async $setSessionsForDynamicAuthProvider(authProviderId, clientId, sessions) { | ||
await this.dynamicAuthProviderStorageService.setSessionsForDynamicAuthProvider(authProviderId, clientId, sessions); | ||
} | ||
async loginPrompt(provider, extensionName, recreatingSession, options) { | ||
@@ -120,3 +188,3 @@ let message; | ||
message = ( localize( | ||
2382, | ||
2390, | ||
"The extension '{0}' wants to access the language models provided by {1}.", | ||
@@ -130,3 +198,3 @@ extensionName, | ||
? ( localize( | ||
2383, | ||
2391, | ||
"The extension '{0}' wants you to sign in again using {1}.", | ||
@@ -137,3 +205,3 @@ extensionName, | ||
: ( localize( | ||
2384, | ||
2392, | ||
"The extension '{0}' wants to sign in using {1}.", | ||
@@ -146,3 +214,3 @@ extensionName, | ||
{ | ||
label: ( localize(2385, "&&Allow")), | ||
label: ( localize(2393, "&&Allow")), | ||
run() { | ||
@@ -155,3 +223,3 @@ return true; | ||
buttons.push({ | ||
label: ( localize(2386, "Learn more")), | ||
label: ( localize(2394, "Learn more")), | ||
run: async () => { | ||
@@ -175,5 +243,5 @@ const result = this.loginPrompt(provider, extensionName, recreatingSession, options); | ||
const result = await this.dialogService.prompt({ | ||
message: ( localize(2387, "Incorrect account detected")), | ||
message: ( localize(2395, "Incorrect account detected")), | ||
detail: ( localize( | ||
2388, | ||
2396, | ||
"The chosen account, {0}, does not match the requested account, {1}.", | ||
@@ -187,7 +255,7 @@ chosenAccountLabel, | ||
{ | ||
label: ( localize(2389, 'Keep {0}', chosenAccountLabel)), | ||
label: ( localize(2397, 'Keep {0}', chosenAccountLabel)), | ||
run: () => chosenAccountLabel | ||
}, | ||
{ | ||
label: ( localize(2390, 'Login with {0}', requestedAccountLabel)), | ||
label: ( localize(2398, 'Login with {0}', requestedAccountLabel)), | ||
run: () => requestedAccountLabel | ||
@@ -203,3 +271,4 @@ } | ||
async doGetSession(providerId, scopes, extensionId, extensionName, options) { | ||
const sessions = await this.authenticationService.getSessions(providerId, scopes, options.account, true); | ||
const authorizationServer = URI.revive(options.authorizationServer); | ||
const sessions = await this.authenticationService.getSessions(providerId, scopes, { account: options.account, authorizationServer }, true); | ||
const provider = this.authenticationService.getProvider(providerId); | ||
@@ -258,3 +327,7 @@ if (options.forceNewSession && options.createIfNone) { | ||
do { | ||
session = await this.authenticationService.createSession(providerId, scopes, { activateImmediate: true, account: accountToCreate }); | ||
session = await this.authenticationService.createSession(providerId, scopes, { | ||
activateImmediate: true, | ||
account: accountToCreate, | ||
authorizationServer | ||
}); | ||
} while (accountToCreate | ||
@@ -340,2 +413,31 @@ && accountToCreate.label !== session.account.label | ||
} | ||
async $showDeviceCodeModal(userCode, verificationUri) { | ||
const { result } = await this.dialogService.prompt({ | ||
type: Severity.Info, | ||
message: ( localize(2399, "Device Code Authentication")), | ||
detail: ( localize( | ||
2400, | ||
"Your code: {0}\n\nTo complete authentication, navigate to {1} and enter the code above.", | ||
userCode, | ||
verificationUri | ||
)), | ||
buttons: [ | ||
{ | ||
label: ( localize(2401, "Copy & Continue")), | ||
run: () => true | ||
} | ||
], | ||
cancelButton: true | ||
}); | ||
if (result) { | ||
try { | ||
await this.clipboardService.writeText(userCode); | ||
return await this.openerService.open(( URI.parse(verificationUri))); | ||
} | ||
catch (error) { | ||
this.notificationService.error(( localize(2402, "Failed to open {0}", verificationUri))); | ||
} | ||
} | ||
return false; | ||
} | ||
}; | ||
@@ -353,5 +455,8 @@ MainThreadAuthentication = __decorate([ | ||
( __param(9, IOpenerService)), | ||
( __param(10, ILogService)) | ||
( __param(10, ILogService)), | ||
( __param(11, IURLService)), | ||
( __param(12, IDynamicAuthenticationProviderStorageService)), | ||
( __param(13, IClipboardService)) | ||
], MainThreadAuthentication); | ||
export { MainThreadAuthentication, MainThreadAuthenticationProvider }; |
@@ -10,3 +10,3 @@ | ||
import { MainContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol'; | ||
import { ResourceNotebookCellEdit } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/bulkEdit/browser/bulkCellEdits'; | ||
import { ResourceNotebookCellEdit } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/bulkEdit/browser/bulkCellEdits'; | ||
import { CellEditType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookCommon'; | ||
@@ -13,0 +13,0 @@ import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js'; |
@@ -15,3 +15,3 @@ import { DeferredPromise } from "@codingame/monaco-vscode-api/vscode/vs/base/common/async"; | ||
import { IChatEditingService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatEditingService.service"; | ||
import { IChatContentInlineReference, IChatContentReference, IChatTask, IChatWarningMessage } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService"; | ||
import { IChatContentInlineReference, IChatContentReference, IChatTask, IChatTaskSerialized, IChatWarningMessage } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService"; | ||
import { IChatService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService.service"; | ||
@@ -34,2 +34,3 @@ import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js"; | ||
add(progress: IChatWarningMessage | IChatContentReference): void; | ||
toJSON(): IChatTaskSerialized; | ||
} | ||
@@ -53,3 +54,2 @@ export declare class MainThreadChatAgents2 extends Disposable implements MainThreadChatAgentsShape2 { | ||
private readonly _proxy; | ||
private _responsePartHandlePool; | ||
private readonly _activeTasks; | ||
@@ -62,3 +62,6 @@ private readonly _unresolvedAnchors; | ||
$updateAgent(handle: number, metadataUpdate: IExtensionChatAgentMetadata): Promise<void>; | ||
$handleProgressChunk(requestId: string, progress: IChatProgressDto, responsePartHandle?: number): Promise<number | void>; | ||
$handleProgressChunk(requestId: string, chunks: (IChatProgressDto | [ | ||
IChatProgressDto, | ||
number | ||
])[]): Promise<void>; | ||
$handleAnchorResolve(requestId: string, handle: string, resolveAnchor: Dto<IChatContentInlineReference> | undefined): void; | ||
@@ -65,0 +68,0 @@ $registerAgentCompletionsProvider(handle: number, id: string, triggerCharacters: string[]): void; |
@@ -54,2 +54,9 @@ | ||
} | ||
toJSON() { | ||
return { | ||
kind: 'progressTaskSerialized', | ||
content: this.content, | ||
progress: this.progress | ||
}; | ||
} | ||
} | ||
@@ -74,3 +81,2 @@ let MainThreadChatAgents2 = class MainThreadChatAgents2 extends Disposable { | ||
this._pendingProgress = ( new Map()); | ||
this._responsePartHandlePool = 0; | ||
this._activeTasks = ( new Map()); | ||
@@ -146,5 +152,2 @@ this._unresolvedAnchors = ( new Map()); | ||
}, | ||
provideSampleQuestions: (location, token) => { | ||
return this._proxy.$provideSampleQuestions(handle, location, token); | ||
} | ||
}; | ||
@@ -190,45 +193,52 @@ let disposable; | ||
} | ||
async $handleProgressChunk(requestId, progress, responsePartHandle) { | ||
const revivedProgress = progress.kind === 'notebookEdit' | ||
? ChatNotebookEdit.fromChatEdit(revive(progress)) | ||
: revive(progress); | ||
if (revivedProgress.kind === 'notebookEdit' | ||
|| revivedProgress.kind === 'textEdit' | ||
|| revivedProgress.kind === 'codeblockUri') { | ||
revivedProgress.uri = this._uriIdentityService.asCanonicalUri(revivedProgress.uri); | ||
} | ||
if (revivedProgress.kind === 'progressTask') { | ||
const handle = ++this._responsePartHandlePool; | ||
const responsePartId = `${requestId}_${handle}`; | ||
const task = ( new MainThreadChatTask(revivedProgress.content)); | ||
this._activeTasks.set(responsePartId, task); | ||
this._pendingProgress.get(requestId)?.(task); | ||
return handle; | ||
} | ||
else if (responsePartHandle !== undefined) { | ||
const responsePartId = `${requestId}_${responsePartHandle}`; | ||
const task = this._activeTasks.get(responsePartId); | ||
switch (revivedProgress.kind) { | ||
case 'progressTaskResult': | ||
if (task && revivedProgress.content) { | ||
task.complete(revivedProgress.content.value); | ||
this._activeTasks.delete(responsePartId); | ||
async $handleProgressChunk(requestId, chunks) { | ||
const chatProgressParts = []; | ||
chunks.forEach(item => { | ||
const [progress, responsePartHandle] = Array.isArray(item) ? item : [item]; | ||
const revivedProgress = progress.kind === 'notebookEdit' | ||
? ChatNotebookEdit.fromChatEdit(revive(progress)) | ||
: revive(progress); | ||
if (revivedProgress.kind === 'notebookEdit' | ||
|| revivedProgress.kind === 'textEdit' | ||
|| revivedProgress.kind === 'codeblockUri') { | ||
revivedProgress.uri = this._uriIdentityService.asCanonicalUri(revivedProgress.uri); | ||
} | ||
if (responsePartHandle !== undefined) { | ||
if (revivedProgress.kind === 'progressTask') { | ||
const handle = responsePartHandle; | ||
const responsePartId = `${requestId}_${handle}`; | ||
const task = ( new MainThreadChatTask(revivedProgress.content)); | ||
this._activeTasks.set(responsePartId, task); | ||
chatProgressParts.push(task); | ||
return; | ||
} | ||
else if (responsePartHandle !== undefined) { | ||
const responsePartId = `${requestId}_${responsePartHandle}`; | ||
const task = this._activeTasks.get(responsePartId); | ||
switch (revivedProgress.kind) { | ||
case 'progressTaskResult': | ||
if (task && revivedProgress.content) { | ||
task.complete(revivedProgress.content.value); | ||
this._activeTasks.delete(responsePartId); | ||
} | ||
else { | ||
task?.complete(undefined); | ||
} | ||
return; | ||
case 'warning': | ||
case 'reference': | ||
task?.add(revivedProgress); | ||
return; | ||
} | ||
else { | ||
task?.complete(undefined); | ||
} | ||
return responsePartHandle; | ||
case 'warning': | ||
case 'reference': | ||
task?.add(revivedProgress); | ||
return; | ||
} | ||
} | ||
} | ||
if (revivedProgress.kind === 'inlineReference' && revivedProgress.resolveId) { | ||
if (!( this._unresolvedAnchors.has(requestId))) { | ||
this._unresolvedAnchors.set(requestId, ( new Map())); | ||
if (revivedProgress.kind === 'inlineReference' && revivedProgress.resolveId) { | ||
if (!( this._unresolvedAnchors.has(requestId))) { | ||
this._unresolvedAnchors.set(requestId, ( new Map())); | ||
} | ||
this._unresolvedAnchors.get(requestId)?.set(revivedProgress.resolveId, revivedProgress); | ||
} | ||
this._unresolvedAnchors.get(requestId)?.set(revivedProgress.resolveId, revivedProgress); | ||
} | ||
this._pendingProgress.get(requestId)?.(revivedProgress); | ||
chatProgressParts.push(revivedProgress); | ||
}); | ||
this._pendingProgress.get(requestId)?.(chatProgressParts); | ||
} | ||
@@ -235,0 +245,0 @@ $handleAnchorResolve(requestId, handle, resolveAnchor) { |
@@ -95,3 +95,3 @@ | ||
this.logger.info(( localize( | ||
2391, | ||
2403, | ||
"Cannot install the '{0}' extension because it is declared to not run in this setup.", | ||
@@ -98,0 +98,0 @@ getExtensionId(manifest.publisher, manifest.name) |
@@ -13,3 +13,3 @@ import { CancellationToken } from "@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation"; | ||
import { IViewDescriptorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/views.service"; | ||
import { ICellRange } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookRange"; | ||
import { ICellRange } from "@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/common/notebookRange"; | ||
import { IViewsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/views/common/viewsService.service"; | ||
@@ -83,3 +83,3 @@ import { MarshalledCommentThread } from "../../common/comments.js"; | ||
} | ||
export declare class MainThreadCommentController implements ICommentController { | ||
export declare class MainThreadCommentController extends Disposable implements ICommentController { | ||
private readonly _proxy; | ||
@@ -86,0 +86,0 @@ private readonly _commentService; |
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6'; | ||
import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event'; | ||
import { DisposableStore, DisposableMap, Disposable, MutableDisposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle'; | ||
import { DisposableStore, Disposable, DisposableMap, MutableDisposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle'; | ||
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri'; | ||
@@ -17,3 +17,3 @@ import { Range } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/range'; | ||
import { SyncDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors'; | ||
import { ViewPaneContainer } from '@codingame/monaco-vscode-e67a0dae-5b2c-54e6-8d61-90102c78362d-common/vscode/vs/workbench/browser/parts/views/viewPaneContainer'; | ||
import { ViewPaneContainer } from '@codingame/monaco-vscode-a8d3bd74-e63e-5327-96e8-4f931661e329-common/vscode/vs/workbench/browser/parts/views/viewPaneContainer'; | ||
import { Codicon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/codicons'; | ||
@@ -205,3 +205,3 @@ import { registerIcon } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/iconRegistry'; | ||
} | ||
class MainThreadCommentController { | ||
class MainThreadCommentController extends Disposable { | ||
get handle() { | ||
@@ -238,2 +238,3 @@ return this._handle; | ||
constructor(_proxy, _commentService, _handle, _uniqueId, _id, _label, _features) { | ||
super(); | ||
this._proxy = _proxy; | ||
@@ -246,3 +247,3 @@ this._commentService = _commentService; | ||
this._features = _features; | ||
this._threads = ( new DisposableMap()); | ||
this._threads = this._register(( new DisposableMap())); | ||
} | ||
@@ -430,3 +431,3 @@ get activeComment() { | ||
} | ||
const commentsViewIcon = registerIcon('comments-view-icon', Codicon.commentDiscussion, ( localize(2392, 'View icon of the comments view.'))); | ||
const commentsViewIcon = registerIcon('comments-view-icon', Codicon.commentDiscussion, ( localize(2404, 'View icon of the comments view.'))); | ||
let MainThreadComments = class MainThreadComments extends Disposable { | ||
@@ -476,2 +477,3 @@ constructor(extHostContext, _commentService, _viewsService, _viewDescriptorService, _uriIdentityService, _editorService) { | ||
this._handlers.delete(handle); | ||
this._commentControllers.get(handle)?.dispose(); | ||
this._commentControllers.delete(handle); | ||
@@ -478,0 +480,0 @@ if (typeof providerId !== 'string') { |
@@ -28,3 +28,3 @@ | ||
import { CustomTextEditorModel } from '../../contrib/customEditor/common/customTextEditorModel.js'; | ||
import { ExtensionKeyedWebviewOriginStore } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webview/browser/webview'; | ||
import { ExtensionKeyedWebviewOriginStore } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webview/browser/webview'; | ||
import { IWebviewWorkbenchService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/webviewPanel/browser/webviewWorkbenchService.service'; | ||
@@ -38,3 +38,3 @@ import { editorGroupToColumn } from '@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common/vscode/vs/workbench/services/editor/common/editorGroupColumn'; | ||
import { ResourceWorkingCopy } from '@codingame/monaco-vscode-bba55be6-41a2-50cd-a3cc-8bafa35bfa89-common/vscode/vs/workbench/services/workingCopy/common/resourceWorkingCopy'; | ||
import { NO_TYPE_ID, WorkingCopyCapabilities } from '@codingame/monaco-vscode-86d65fc6-30f9-5dca-9501-e249de688591-common/vscode/vs/workbench/services/workingCopy/common/workingCopy'; | ||
import { NO_TYPE_ID, WorkingCopyCapabilities } from '@codingame/monaco-vscode-a4683c2b-a0d2-5112-96ba-eedc605346d2-common/vscode/vs/workbench/services/workingCopy/common/workingCopy'; | ||
import { IWorkingCopyFileService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/workingCopy/common/workingCopyFileService.service'; | ||
@@ -307,3 +307,3 @@ import { IWorkingCopyService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/workingCopy/common/workingCopyService.service'; | ||
e.veto(true, ( localize( | ||
2393, | ||
2405, | ||
"An extension provided editor for '{0}' is still open that would close otherwise.", | ||
@@ -376,3 +376,3 @@ this.name | ||
resource: this._editorResource, | ||
label: label ?? ( localize(2394, "Edit")), | ||
label: label ?? ( localize(2406, "Edit")), | ||
code: 'undoredo.customEditorEdit', | ||
@@ -379,0 +379,0 @@ undo: () => this.undo(), |
@@ -10,2 +10,4 @@ | ||
import { CancellationToken } from '@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation'; | ||
import { DeferredPromise } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async'; | ||
import { CancellationError } from '@codingame/monaco-vscode-api/vscode/vs/base/common/errors'; | ||
@@ -22,15 +24,15 @@ class DecorationRequestsQueue { | ||
const id = ++this._idPool; | ||
const result = ( new Promise(resolve => { | ||
this._requests.set(id, { id, uri }); | ||
this._resolver.set(id, resolve); | ||
this._processQueue(); | ||
})); | ||
const defer = ( new DeferredPromise()); | ||
this._requests.set(id, { id, uri }); | ||
this._resolver.set(id, defer); | ||
this._processQueue(); | ||
const sub = token.onCancellationRequested(() => { | ||
this._requests.delete(id); | ||
this._resolver.delete(id); | ||
defer.error(( new CancellationError())); | ||
}); | ||
return result.finally(() => sub.dispose()); | ||
return defer.p.finally(() => sub.dispose()); | ||
} | ||
_processQueue() { | ||
if (typeof this._timer === 'number') { | ||
if (this._timer !== undefined) { | ||
return; | ||
@@ -42,4 +44,4 @@ } | ||
this._proxy.$provideDecorations(this._handle, [...( requests.values())], CancellationToken.None).then(data => { | ||
for (const [id, resolve] of resolver) { | ||
resolve(data[id]); | ||
for (const [id, defer] of resolver) { | ||
defer.complete(data[id]); | ||
} | ||
@@ -46,0 +48,0 @@ }); |
@@ -24,5 +24,6 @@ | ||
import { Event } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event'; | ||
import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/autorun'; | ||
import { constObservable, observableFromEvent } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/utils'; | ||
import { derived, derivedOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/derived'; | ||
import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun'; | ||
import { constObservable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/constObservable'; | ||
import { observableFromEvent } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableFromEvent'; | ||
import { derived, derivedOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/derived'; | ||
@@ -29,0 +30,0 @@ var MainThreadTextEditors_1; |
@@ -14,4 +14,4 @@ | ||
import { SideBySideEditorInput } from '@codingame/monaco-vscode-9c72783f-914c-50be-b9ef-da16356d81a8-common/vscode/vs/workbench/common/editor/sideBySideEditorInput'; | ||
import { AbstractTextResourceEditorInput } from '@codingame/monaco-vscode-86d65fc6-30f9-5dca-9501-e249de688591-common/vscode/vs/workbench/common/editor/textResourceEditorInput'; | ||
import { ChatEditorInput } from '@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common/vscode/vs/workbench/contrib/chat/browser/chatEditorInput'; | ||
import { AbstractTextResourceEditorInput } from '@codingame/monaco-vscode-4ee27008-17b4-593f-9c09-19e8e3077f51-common/vscode/vs/workbench/common/editor/textResourceEditorInput'; | ||
import { ChatEditorInput } from '@codingame/monaco-vscode-3a35f433-1297-5707-ab58-c261b8180e6d-common/vscode/vs/workbench/contrib/chat/browser/chatEditorInput'; | ||
import { CustomEditorInput } from '@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common/vscode/vs/workbench/contrib/customEditor/browser/customEditorInput'; | ||
@@ -21,5 +21,5 @@ import { InteractiveEditorInput } from '@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common/vscode/vs/workbench/contrib/interactive/browser/interactiveEditorInput'; | ||
import { MultiDiffEditorInput } from '@codingame/monaco-vscode-1cc4ea0a-c5b6-54ed-bb60-078a99119b55-common/vscode/vs/workbench/contrib/multiDiffEditor/browser/multiDiffEditorInput'; | ||
import { NotebookEditorInput } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookEditorInput'; | ||
import { TerminalEditorInput } from '@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common/vscode/vs/workbench/contrib/terminal/browser/terminalEditorInput'; | ||
import { WebviewInput } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput'; | ||
import { NotebookEditorInput } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/common/notebookEditorInput'; | ||
import { TerminalEditorInput } from '@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/contrib/terminal/browser/terminalEditorInput'; | ||
import { WebviewInput } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput'; | ||
import { editorGroupToColumn, columnToEditorGroup } from '@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common/vscode/vs/workbench/services/editor/common/editorGroupColumn'; | ||
@@ -26,0 +26,0 @@ import { GroupDirection, preferredSideBySideGroupDirection } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorGroupsService'; |
@@ -17,3 +17,3 @@ | ||
const p = ( new Promise((resolve, reject) => { | ||
setTimeout(() => reject(( new Error(( localize(2395, "Aborted onWillCreateEditSessionIdentity-event after 10000ms"))))), this.timeout); | ||
setTimeout(() => reject(( new Error(( localize(2407, "Aborted onWillCreateEditSessionIdentity-event after 10000ms"))))), this.timeout); | ||
this._proxy.$onWillCreateEditSessionIdentity(workspaceFolder.uri, token, this.timeout).then(resolve, reject); | ||
@@ -20,0 +20,0 @@ })); |
@@ -92,3 +92,3 @@ | ||
message: ( localize( | ||
2396, | ||
2408, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension, which is not loaded. Would you like to reload the window to load the extension?", | ||
@@ -99,3 +99,3 @@ extName, | ||
actions: { | ||
primary: [( new Action('reload', ( localize(2397, "Reload Window")), '', true, () => this._hostService.reload()))] | ||
primary: [( new Action('reload', ( localize(2409, "Reload Window")), '', true, () => this._hostService.reload()))] | ||
} | ||
@@ -110,3 +110,3 @@ }); | ||
message: ( localize( | ||
2398, | ||
2410, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is not supported in the current workspace", | ||
@@ -122,3 +122,3 @@ extName, | ||
message: ( localize( | ||
2399, | ||
2411, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is not supported in Restricted Mode", | ||
@@ -129,3 +129,3 @@ extName, | ||
actions: { | ||
primary: [( new Action('manageWorkspaceTrust', ( localize(2400, "Manage Workspace Trust")), '', true, () => this._commandService.executeCommand('workbench.trust.manage')))] | ||
primary: [( new Action('manageWorkspaceTrust', ( localize(2412, "Manage Workspace Trust")), '', true, () => this._commandService.executeCommand('workbench.trust.manage')))] | ||
} | ||
@@ -138,3 +138,3 @@ }); | ||
message: ( localize( | ||
2401, | ||
2413, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is disabled. Would you like to enable the extension and reload the window?", | ||
@@ -145,3 +145,3 @@ extName, | ||
actions: { | ||
primary: [( new Action('enable', ( localize(2402, "Enable and Reload")), '', true, () => this._extensionEnablementService.setEnablement([missingInstalledDependency], enablementState === EnablementState.DisabledGlobally ? EnablementState.EnabledGlobally : EnablementState.EnabledWorkspace) | ||
primary: [( new Action('enable', ( localize(2414, "Enable and Reload")), '', true, () => this._extensionEnablementService.setEnablement([missingInstalledDependency], enablementState === EnablementState.DisabledGlobally ? EnablementState.EnabledGlobally : EnablementState.EnabledWorkspace) | ||
.then(() => this._hostService.reload(), e => this._notificationService.error(e))))] | ||
@@ -155,3 +155,3 @@ } | ||
message: ( localize( | ||
2403, | ||
2415, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension which is disabled.", | ||
@@ -177,3 +177,3 @@ extName, | ||
message: ( localize( | ||
2404, | ||
2416, | ||
"Cannot activate the '{0}' extension because it depends on the '{1}' extension from '{2}', which is not installed. Would you like to install the extension and reload the window?", | ||
@@ -185,3 +185,3 @@ extName, | ||
actions: { | ||
primary: [( new Action('install', ( localize(2405, "Install and Reload")), '', true, () => this._extensionsWorkbenchService.install(dependencyExtension) | ||
primary: [( new Action('install', ( localize(2417, "Install and Reload")), '', true, () => this._extensionsWorkbenchService.install(dependencyExtension) | ||
.then(() => this._hostService.reload(), e => this._notificationService.error(e))))] | ||
@@ -193,3 +193,3 @@ } | ||
this._notificationService.error(( localize( | ||
2406, | ||
2418, | ||
"Cannot activate the '{0}' extension because it depends on an unknown '{1}' extension.", | ||
@@ -196,0 +196,0 @@ extName, |
@@ -78,3 +78,3 @@ | ||
message = ( localize( | ||
2407, | ||
2419, | ||
"Extension '{0}' wants to make refactoring changes with this file creation", | ||
@@ -86,3 +86,3 @@ data.extensionNames[0] | ||
message = ( localize( | ||
2408, | ||
2420, | ||
"Extension '{0}' wants to make refactoring changes with this file copy", | ||
@@ -94,3 +94,3 @@ data.extensionNames[0] | ||
message = ( localize( | ||
2409, | ||
2421, | ||
"Extension '{0}' wants to make refactoring changes with this file move", | ||
@@ -102,3 +102,3 @@ data.extensionNames[0] | ||
message = ( localize( | ||
2410, | ||
2422, | ||
"Extension '{0}' wants to make refactoring changes with this file deletion", | ||
@@ -112,3 +112,3 @@ data.extensionNames[0] | ||
message = ( localize( | ||
2411, | ||
2423, | ||
"{0} extensions want to make refactoring changes with this file creation", | ||
@@ -120,3 +120,3 @@ data.extensionNames.length | ||
message = ( localize( | ||
2412, | ||
2424, | ||
"{0} extensions want to make refactoring changes with this file copy", | ||
@@ -128,3 +128,3 @@ data.extensionNames.length | ||
message = ( localize( | ||
2413, | ||
2425, | ||
"{0} extensions want to make refactoring changes with this file move", | ||
@@ -136,3 +136,3 @@ data.extensionNames.length | ||
message = ( localize( | ||
2414, | ||
2426, | ||
"{0} extensions want to make refactoring changes with this file deletion", | ||
@@ -147,4 +147,4 @@ data.extensionNames.length | ||
message, | ||
primaryButton: ( localize(2415, "Show &&Preview")), | ||
cancelButton: ( localize(2416, "Skip Changes")) | ||
primaryButton: ( localize(2427, "Show &&Preview")), | ||
cancelButton: ( localize(2428, "Skip Changes")) | ||
}); | ||
@@ -168,7 +168,7 @@ showPreview = true; | ||
{ | ||
label: ( localize(2417, "&&OK")), | ||
label: ( localize(2429, "&&OK")), | ||
run: () => Choice.OK | ||
}, | ||
{ | ||
label: ( localize(2415, "Show &&Preview")), | ||
label: ( localize(2427, "Show &&Preview")), | ||
run: () => Choice.Preview | ||
@@ -178,6 +178,6 @@ } | ||
cancelButton: { | ||
label: ( localize(2416, "Skip Changes")), | ||
label: ( localize(2428, "Skip Changes")), | ||
run: () => Choice.Cancel | ||
}, | ||
checkbox: { label: ( localize(2418, "Do not ask me again")) } | ||
checkbox: { label: ( localize(2430, "Do not ask me again")) } | ||
}); | ||
@@ -199,11 +199,11 @@ if (result === Choice.Cancel) { | ||
case FileOperation.CREATE: | ||
return localize(2419, "Running 'File Create' participants..."); | ||
return localize(2431, "Running 'File Create' participants..."); | ||
case FileOperation.MOVE: | ||
return localize(2420, "Running 'File Rename' participants..."); | ||
return localize(2432, "Running 'File Rename' participants..."); | ||
case FileOperation.COPY: | ||
return localize(2421, "Running 'File Copy' participants..."); | ||
return localize(2433, "Running 'File Copy' participants..."); | ||
case FileOperation.DELETE: | ||
return localize(2422, "Running 'File Delete' participants..."); | ||
return localize(2434, "Running 'File Delete' participants..."); | ||
case FileOperation.WRITE: | ||
return localize(2423, "Running 'File Write' participants..."); | ||
return localize(2435, "Running 'File Write' participants..."); | ||
} | ||
@@ -279,3 +279,3 @@ } | ||
title: { | ||
value: ( localize(2424, "Reset choice for 'File operation needs preview'")), | ||
value: ( localize(2436, "Reset choice for 'File operation needs preview'")), | ||
original: `Reset choice for 'File operation needs preview'` | ||
@@ -282,0 +282,0 @@ }, |
@@ -22,3 +22,3 @@ | ||
import { CallHierarchyProviderRegistry } from '@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common/vscode/vs/workbench/contrib/callHierarchy/common/callHierarchy'; | ||
import { WorkspaceSymbolProviderRegistry } from '@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common/vscode/vs/workbench/contrib/search/common/search'; | ||
import { WorkspaceSymbolProviderRegistry } from '@codingame/monaco-vscode-47472025-cc45-5680-86cd-09ceaba921a1-common/vscode/vs/workbench/contrib/search/common/search'; | ||
import { TypeHierarchyProviderRegistry } from '@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common/vscode/vs/workbench/contrib/typeHierarchy/common/typeHierarchy'; | ||
@@ -25,0 +25,0 @@ import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js'; |
@@ -32,3 +32,3 @@ import { CancellationToken } from "@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation"; | ||
$registerLanguageModelProvider(handle: number, identifier: string, metadata: ILanguageModelChatMetadata): void; | ||
$reportResponsePart(requestId: number, chunk: IChatResponseFragment): Promise<void>; | ||
$reportResponsePart(requestId: number, chunk: IChatResponseFragment | IChatResponseFragment[]): Promise<void>; | ||
$reportResponseDone(requestId: number, err: SerializedError | undefined): Promise<void>; | ||
@@ -35,0 +35,0 @@ $unregisterProvider(handle: number): void; |
@@ -12,3 +12,3 @@ | ||
import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service'; | ||
import { resizeImage } from '@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common/vscode/vs/workbench/contrib/chat/browser/imageUtils'; | ||
import { resizeImage } from '@codingame/monaco-vscode-1cb11a73-359e-5a2f-9e95-6989cc9858ee-common/vscode/vs/workbench/contrib/chat/browser/imageUtils'; | ||
import { ILanguageModelIgnoredFilesService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/ignoredFiles.service'; | ||
@@ -156,3 +156,3 @@ import { ILanguageModelStatsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModelStats.service'; | ||
} | ||
const accountLabel = auth.accountLabel ?? ( localize(2425, 'Language Models')); | ||
const accountLabel = auth.accountLabel ?? ( localize(2437, 'Language Models')); | ||
const disposables = ( new DisposableStore()); | ||
@@ -159,0 +159,0 @@ this._authenticationService.registerAuthenticationProvider(authProviderId, ( new LanguageModelAccessAuthProvider(authProviderId, auth.providerLabel, accountLabel))); |
import { CancellationToken } from "@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation"; | ||
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; | ||
import { IToolData, IToolInvocation, IToolResult, IToolProgressStep } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModelToolsService"; | ||
import { IToolInvocation, IToolProgressStep, IToolResult } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModelToolsService"; | ||
import { ILanguageModelToolsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModelToolsService.service"; | ||
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js"; | ||
import { Dto, SerializableObjectWithBuffers } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/proxyIdentifier"; | ||
import { MainThreadLanguageModelToolsShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import { IToolDataDto, MainThreadLanguageModelToolsShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
export declare class MainThreadLanguageModelTools extends Disposable implements MainThreadLanguageModelToolsShape { | ||
@@ -14,3 +14,4 @@ private readonly _languageModelToolsService; | ||
constructor(extHostContext: IExtHostContext, _languageModelToolsService: ILanguageModelToolsService); | ||
$getTools(): Promise<IToolData[]>; | ||
private getToolDtos; | ||
$getTools(): Promise<IToolDataDto[]>; | ||
$invokeTool(dto: IToolInvocation, token?: CancellationToken): Promise<Dto<IToolResult> | SerializableObjectWithBuffers<Dto<IToolResult>>>; | ||
@@ -17,0 +18,0 @@ $acceptToolProgress(callId: string, progress: IToolProgressStep): void; |
@@ -19,6 +19,18 @@ | ||
this._proxy = ( extHostContext.getProxy(ExtHostContext.ExtHostLanguageModelTools)); | ||
this._register(this._languageModelToolsService.onDidChangeTools(e => this._proxy.$onDidChangeTools([...this._languageModelToolsService.getTools()]))); | ||
this._register(this._languageModelToolsService.onDidChangeTools(e => this._proxy.$onDidChangeTools(this.getToolDtos()))); | ||
} | ||
getToolDtos() { | ||
return ( Array.from(this._languageModelToolsService.getTools()) | ||
.map(tool => ({ | ||
id: tool.id, | ||
displayName: tool.displayName, | ||
toolReferenceName: tool.toolReferenceName, | ||
tags: tool.tags, | ||
userDescription: tool.userDescription, | ||
modelDescription: tool.modelDescription, | ||
inputSchema: tool.inputSchema, | ||
}))); | ||
} | ||
async $getTools() { | ||
return Array.from(this._languageModelToolsService.getTools()); | ||
return this.getToolDtos(); | ||
} | ||
@@ -25,0 +37,0 @@ async $invokeTool(dto, token) { |
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; | ||
import { UriComponents } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
import { IDialogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service"; | ||
import { LogLevel } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log"; | ||
import { IMcpRegistry } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/mcp/common/mcpRegistryTypes.service"; | ||
import { McpCollectionDefinition, McpConnectionState, McpServerDefinition } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/mcp/common/mcpTypes"; | ||
import { IAuthenticationMcpAccessService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpAccessService.service"; | ||
import { IAuthenticationMcpService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpService.service"; | ||
import { IAuthenticationMcpUsageService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpUsageService.service"; | ||
import { IAuthenticationService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service"; | ||
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js"; | ||
import { MainThreadMcpShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import { IAuthorizationProtectedResourceMetadata, IAuthorizationServerMetadata } from "@codingame/monaco-vscode-api/vscode/vs/base/common/oauth"; | ||
export declare class MainThreadMcp extends Disposable implements MainThreadMcpShape { | ||
private readonly _extHostContext; | ||
private readonly _mcpRegistry; | ||
private readonly dialogService; | ||
private readonly _authenticationService; | ||
private readonly authenticationMcpServersService; | ||
private readonly authenticationMCPServerAccessService; | ||
private readonly authenticationMCPServerUsageService; | ||
private _serverIdCounter; | ||
private readonly _servers; | ||
private readonly _serverDefinitions; | ||
private readonly _proxy; | ||
private readonly _collectionDefinitions; | ||
constructor(_extHostContext: IExtHostContext, _mcpRegistry: IMcpRegistry); | ||
constructor(_extHostContext: IExtHostContext, _mcpRegistry: IMcpRegistry, dialogService: IDialogService, _authenticationService: IAuthenticationService, authenticationMcpServersService: IAuthenticationMcpService, authenticationMCPServerAccessService: IAuthenticationMcpAccessService, authenticationMCPServerUsageService: IAuthenticationMcpUsageService); | ||
$upsertMcpCollection(collection: McpCollectionDefinition.FromExtHost, serversDto: McpServerDefinition.Serialized[]): void; | ||
@@ -20,3 +33,6 @@ $deleteMcpCollection(collectionId: string): void; | ||
$onDidReceiveMessage(id: number, message: string): void; | ||
$getTokenFromServerMetadata(id: number, authServerComponents: UriComponents, serverMetadata: IAuthorizationServerMetadata, resourceMetadata: IAuthorizationProtectedResourceMetadata | undefined): Promise<string | undefined>; | ||
private continueWithIncorrectAccountPrompt; | ||
private loginPrompt; | ||
dispose(): void; | ||
} |
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6'; | ||
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls'; | ||
import { disposableTimeout } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async'; | ||
@@ -7,17 +8,31 @@ import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event'; | ||
import '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/index'; | ||
import Severity from '@codingame/monaco-vscode-api/vscode/vs/base/common/severity'; | ||
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri'; | ||
import { IDialogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service'; | ||
import { LogLevel } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log'; | ||
import { IMcpRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/mcp/common/mcpRegistryTypes.service'; | ||
import { McpServerTransportType, McpServerDefinition, McpServerLaunch, McpConnectionState } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/mcp/common/mcpTypes'; | ||
import { IAuthenticationMcpAccessService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpAccessService.service'; | ||
import { IAuthenticationMcpService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpService.service'; | ||
import { IAuthenticationMcpUsageService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/browser/authenticationMcpUsageService.service'; | ||
import { IAuthenticationService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/authentication/common/authentication.service'; | ||
import { ExtensionHostKind, extensionHostKindToString } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionHostKind'; | ||
import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js'; | ||
import { ExtHostContext, MainContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol'; | ||
import { observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/base'; | ||
import { CancellationError } from '@codingame/monaco-vscode-api/vscode/vs/base/common/errors'; | ||
import { observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableValue'; | ||
let MainThreadMcp = class MainThreadMcp extends Disposable { | ||
constructor(_extHostContext, _mcpRegistry) { | ||
constructor(_extHostContext, _mcpRegistry, dialogService, _authenticationService, authenticationMcpServersService, authenticationMCPServerAccessService, authenticationMCPServerUsageService) { | ||
super(); | ||
this._extHostContext = _extHostContext; | ||
this._mcpRegistry = _mcpRegistry; | ||
this.dialogService = dialogService; | ||
this._authenticationService = _authenticationService; | ||
this.authenticationMcpServersService = authenticationMcpServersService; | ||
this.authenticationMCPServerAccessService = authenticationMCPServerAccessService; | ||
this.authenticationMCPServerUsageService = authenticationMCPServerUsageService; | ||
this._serverIdCounter = 0; | ||
this._servers = ( new Map()); | ||
this._serverDefinitions = ( new Map()); | ||
this._collectionDefinitions = this._register(( new DisposableMap())); | ||
@@ -39,3 +54,3 @@ const proxy = this._proxy = ( _extHostContext.getProxy(ExtHostContext.ExtHostMcp)); | ||
}, | ||
start: (collection, _serverDefiniton, resolveLaunch) => { | ||
start: (_collection, serverDefiniton, resolveLaunch) => { | ||
const id = ++this._serverIdCounter; | ||
@@ -48,2 +63,3 @@ const launch = ( new ExtHostMcpServerLaunch( | ||
this._servers.set(id, launch); | ||
this._serverDefinitions.set(id, serverDefiniton); | ||
proxy.$startMcp(id, resolveLaunch); | ||
@@ -90,2 +106,3 @@ return launch; | ||
this._servers.delete(id); | ||
this._serverDefinitions.delete(id); | ||
} | ||
@@ -103,2 +120,116 @@ } | ||
} | ||
async $getTokenFromServerMetadata(id, authServerComponents, serverMetadata, resourceMetadata) { | ||
const server = this._serverDefinitions.get(id); | ||
if (!server) { | ||
return undefined; | ||
} | ||
const authorizationServer = URI.revive(authServerComponents); | ||
const scopesSupported = resourceMetadata?.scopes_supported || serverMetadata.scopes_supported || []; | ||
let providerId = await this._authenticationService.getOrActivateProviderIdForServer(authorizationServer); | ||
if (!providerId) { | ||
const provider = await this._authenticationService.createDynamicAuthenticationProvider(authorizationServer, serverMetadata, resourceMetadata); | ||
if (!provider) { | ||
return undefined; | ||
} | ||
providerId = provider.id; | ||
} | ||
const sessions = await this._authenticationService.getSessions(providerId, scopesSupported, { authorizationServer: authorizationServer }, true); | ||
const accountNamePreference = this.authenticationMcpServersService.getAccountPreference(server.id, providerId); | ||
let matchingAccountPreferenceSession; | ||
if (accountNamePreference) { | ||
matchingAccountPreferenceSession = sessions.find(session => session.account.label === accountNamePreference); | ||
} | ||
const provider = this._authenticationService.getProvider(providerId); | ||
let session; | ||
if (sessions.length) { | ||
if (matchingAccountPreferenceSession && this.authenticationMCPServerAccessService.isAccessAllowed(providerId, matchingAccountPreferenceSession.account.label, server.id)) { | ||
return matchingAccountPreferenceSession.accessToken; | ||
} | ||
if (!provider.supportsMultipleAccounts && this.authenticationMCPServerAccessService.isAccessAllowed(providerId, sessions[0].account.label, server.id)) { | ||
return sessions[0].accessToken; | ||
} | ||
} | ||
const isAllowed = await this.loginPrompt(server.label, provider.label, false); | ||
if (!isAllowed) { | ||
throw ( new Error('User did not consent to login.')); | ||
} | ||
if (sessions.length) { | ||
session = provider.supportsMultipleAccounts | ||
? await this.authenticationMcpServersService.selectSession(providerId, server.id, server.label, scopesSupported, sessions) | ||
: sessions[0]; | ||
} | ||
else { | ||
const accountToCreate = matchingAccountPreferenceSession?.account; | ||
do { | ||
session = await this._authenticationService.createSession(providerId, scopesSupported, { | ||
activateImmediate: true, | ||
account: accountToCreate, | ||
authorizationServer | ||
}); | ||
} while (accountToCreate | ||
&& accountToCreate.label !== session.account.label | ||
&& !(await this.continueWithIncorrectAccountPrompt(session.account.label, accountToCreate.label))); | ||
} | ||
this.authenticationMCPServerAccessService.updateAllowedMcpServers(providerId, session.account.label, [{ id: server.id, name: server.label, allowed: true }]); | ||
this.authenticationMcpServersService.updateAccountPreference(server.id, providerId, session.account); | ||
this.authenticationMCPServerUsageService.addAccountUsage(providerId, session.account.label, scopesSupported, server.id, server.label); | ||
return session.accessToken; | ||
} | ||
async continueWithIncorrectAccountPrompt(chosenAccountLabel, requestedAccountLabel) { | ||
const result = await this.dialogService.prompt({ | ||
message: ( localize(2438, "Incorrect account detected")), | ||
detail: ( localize( | ||
2439, | ||
"The chosen account, {0}, does not match the requested account, {1}.", | ||
chosenAccountLabel, | ||
requestedAccountLabel | ||
)), | ||
type: Severity.Warning, | ||
cancelButton: true, | ||
buttons: [ | ||
{ | ||
label: ( localize(2440, 'Keep {0}', chosenAccountLabel)), | ||
run: () => chosenAccountLabel | ||
}, | ||
{ | ||
label: ( localize(2441, 'Login with {0}', requestedAccountLabel)), | ||
run: () => requestedAccountLabel | ||
} | ||
], | ||
}); | ||
if (!result.result) { | ||
throw ( new CancellationError()); | ||
} | ||
return result.result === chosenAccountLabel; | ||
} | ||
async loginPrompt(mcpLabel, providerLabel, recreatingSession) { | ||
const message = recreatingSession | ||
? ( localize( | ||
2442, | ||
"The MCP Server Definition '{0}' wants you to authenticate to {1}.", | ||
mcpLabel, | ||
providerLabel | ||
)) | ||
: ( localize( | ||
2443, | ||
"The MCP Server Definition '{0}' wants to authenticate to {1}.", | ||
mcpLabel, | ||
providerLabel | ||
)); | ||
const buttons = [ | ||
{ | ||
label: ( localize(2444, "&&Allow")), | ||
run() { | ||
return true; | ||
}, | ||
} | ||
]; | ||
const { result } = await this.dialogService.prompt({ | ||
type: Severity.Info, | ||
message, | ||
buttons, | ||
cancelButton: true, | ||
}); | ||
return result ?? false; | ||
} | ||
dispose() { | ||
@@ -109,2 +240,3 @@ for (const server of ( this._servers.values())) { | ||
this._servers.clear(); | ||
this._serverDefinitions.clear(); | ||
super.dispose(); | ||
@@ -115,3 +247,8 @@ } | ||
extHostNamedCustomer(MainContext.MainThreadMcp), | ||
( __param(1, IMcpRegistry)) | ||
( __param(1, IMcpRegistry)), | ||
( __param(2, IDialogService)), | ||
( __param(3, IAuthenticationService)), | ||
( __param(4, IAuthenticationMcpService)), | ||
( __param(5, IAuthenticationMcpAccessService)), | ||
( __param(6, IAuthenticationMcpUsageService)) | ||
], MainThreadMcp); | ||
@@ -118,0 +255,0 @@ class ExtHostMcpServerLaunch extends Disposable { |
@@ -54,3 +54,3 @@ | ||
if (!source) { | ||
source = ( localize(2426, "Extension")); | ||
source = ( localize(2445, "Extension")); | ||
} | ||
@@ -61,3 +61,3 @@ const secondaryActions = []; | ||
id: options.source.identifier.value, | ||
label: ( localize(2427, "Manage Extension")), | ||
label: ( localize(2446, "Manage Extension")), | ||
run: () => { | ||
@@ -97,3 +97,3 @@ return this._commandService.executeCommand('_extensions.manage', options.source.identifier.value); | ||
cancelButton = { | ||
label: ( localize(2428, "Cancel")), | ||
label: ( localize(2447, "Cancel")), | ||
run: () => undefined | ||
@@ -104,3 +104,3 @@ }; | ||
cancelButton = { | ||
label: ( localize(2429, "&&OK")), | ||
label: ( localize(2448, "&&OK")), | ||
run: () => undefined | ||
@@ -107,0 +107,0 @@ }; |
@@ -14,3 +14,3 @@ | ||
import { INotebookCellStatusBarService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookCellStatusBarService.service'; | ||
import { SimpleNotebookProviderInfo } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookService'; | ||
import { SimpleNotebookProviderInfo } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/common/notebookService'; | ||
import { INotebookService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookService.service'; | ||
@@ -17,0 +17,0 @@ import { extHostNamedCustomer } from '../../services/extensions/common/extHostCustomers.js'; |
@@ -12,3 +12,3 @@ | ||
import { editorGroupToColumn } from '@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common/vscode/vs/workbench/services/editor/common/editorGroupColumn'; | ||
import { getNotebookEditorFromEditorPane } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser'; | ||
import { getNotebookEditorFromEditorPane } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser'; | ||
import { INotebookEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/services/notebookEditorService.service'; | ||
@@ -15,0 +15,0 @@ import { INotebookService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookService.service'; |
import * as extHostProtocol from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import * as notebookCommon from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookCommon"; | ||
import { ICellExecuteUpdate, ICellExecutionComplete } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookExecutionStateService"; | ||
import { ICellExecuteUpdate, ICellExecutionComplete } from "@codingame/monaco-vscode-e28ac690-06d5-5ee9-92d1-02df70296354-common/vscode/vs/workbench/contrib/notebook/common/notebookExecutionStateService"; | ||
export declare namespace NotebookDto { | ||
@@ -5,0 +5,0 @@ function toNotebookOutputItemDto(item: notebookCommon.IOutputItemDto): extHostProtocol.NotebookOutputItemDto; |
import { UriComponents } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri"; | ||
import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service"; | ||
import { INotebookEditor } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser"; | ||
import { INotebookEditor } from "@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser"; | ||
import { INotebookEditorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/services/notebookEditorService.service"; | ||
import { ICellRange } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookRange"; | ||
import { ICellRange } from "@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/common/notebookRange"; | ||
import { IEditorGroupsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorGroupsService.service"; | ||
@@ -7,0 +7,0 @@ import { IEditorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service"; |
@@ -8,3 +8,3 @@ | ||
import { EditorActivation } from '@codingame/monaco-vscode-api/vscode/vs/platform/editor/common/editor'; | ||
import { getNotebookEditorFromEditorPane } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser'; | ||
import { getNotebookEditorFromEditorPane } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser'; | ||
import { INotebookEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/services/notebookEditorService.service'; | ||
@@ -11,0 +11,0 @@ import { editorGroupToColumn, columnToEditorGroup } from '@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common/vscode/vs/workbench/services/editor/common/editorGroupColumn'; |
@@ -13,3 +13,2 @@ | ||
import { INotebookEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/services/notebookEditorService.service'; | ||
import { NotebookExecutionType } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/notebook/common/notebookExecutionStateService'; | ||
import { INotebookExecutionStateService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookExecutionStateService.service'; | ||
@@ -109,7 +108,2 @@ import { INotebookKernelService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/common/notebookKernelService.service'; | ||
})); | ||
this._disposables.add(this._notebookExecutionStateService.onDidChangeExecution(e => { | ||
if (e.type === NotebookExecutionType.cell) { | ||
this._proxy.$cellExecutionChanged(e.notebook, e.cellHandle, e.changed?.state); | ||
} | ||
})); | ||
this._disposables.add(this._notebookKernelService.onDidChangeSelectedNotebooks(e => { | ||
@@ -116,0 +110,0 @@ for (const [handle, [kernel,]] of this._kernels) { |
@@ -21,3 +21,3 @@ | ||
const p = ( new Promise((resolve, reject) => { | ||
_warningTimeout = setTimeout(() => reject(( new Error(( localize(2430, "Aborted onWillSaveNotebookDocument-event after 1750ms"))))), 1750); | ||
_warningTimeout = setTimeout(() => reject(( new Error(( localize(2449, "Aborted onWillSaveNotebookDocument-event after 1750ms"))))), 1750); | ||
this._proxy.$participateInSave(workingCopy.resource, context.reason, token).then(_ => { | ||
@@ -24,0 +24,0 @@ clearTimeout(_warningTimeout); |
@@ -72,7 +72,7 @@ | ||
const statusProperties = { | ||
name: ( localize(2431, "Show Output")), | ||
name: ( localize(2450, "Show Output")), | ||
text: '$(output)', | ||
ariaLabel: ( localize(2432, "Show {0} Output Channel", channel.label)), | ||
ariaLabel: ( localize(2451, "Show {0} Output Channel", channel.label)), | ||
command: `workbench.action.output.show.${channel.id}`, | ||
tooltip: ( localize(2433, "Show {0} Output Channel", channel.label)), | ||
tooltip: ( localize(2452, "Show {0} Output Channel", channel.label)), | ||
kind: 'prominent' | ||
@@ -79,0 +79,0 @@ }; |
@@ -31,3 +31,3 @@ | ||
id: extensionId, | ||
label: ( localize(2434, "Manage Extension")), | ||
label: ( localize(2453, "Manage Extension")), | ||
run: () => this._commandService.executeCommand('_extensions.manage', extensionId) | ||
@@ -34,0 +34,0 @@ })] |
@@ -20,3 +20,3 @@ | ||
const p = ( new Promise((resolve, reject) => { | ||
setTimeout(() => reject(( new Error(( localize(2435, "Aborted onWillSaveTextDocument-event after 1750ms"))))), 1750); | ||
setTimeout(() => reject(( new Error(( localize(2454, "Aborted onWillSaveTextDocument-event after 1750ms"))))), 1750); | ||
this._proxy.$participateInSave(editorModel.resource, context.reason).then(values => { | ||
@@ -23,0 +23,0 @@ if (!values.every(success => success)) { |
@@ -15,3 +15,3 @@ | ||
import { IQuickDiffService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/scm/common/quickDiff.service'; | ||
import { ResourceTree } from '@codingame/monaco-vscode-be8ddbb5-094a-5657-b1cc-fe106c94c632-common/vscode/vs/base/common/resourceTree'; | ||
import { ResourceTree } from '@codingame/monaco-vscode-7adbeffb-8051-54a9-8c9b-b62ce9e5836f-common/vscode/vs/base/common/resourceTree'; | ||
import { IUriIdentityService } from '@codingame/monaco-vscode-api/vscode/vs/platform/uriIdentity/common/uriIdentity.service'; | ||
@@ -25,5 +25,6 @@ import { IWorkspaceContextService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service'; | ||
import { structuralEquals } from '@codingame/monaco-vscode-api/vscode/vs/base/common/equals'; | ||
import { historyItemRefColor, historyItemRemoteRefColor, historyItemBaseRefColor } from '@codingame/monaco-vscode-be8ddbb5-094a-5657-b1cc-fe106c94c632-common/vscode/vs/workbench/contrib/scm/browser/scmHistory'; | ||
import { observableValue, transaction } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/base'; | ||
import { observableValueOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/api'; | ||
import { historyItemRefColor, historyItemRemoteRefColor, historyItemBaseRefColor } from '@codingame/monaco-vscode-7adbeffb-8051-54a9-8c9b-b62ce9e5836f-common/vscode/vs/workbench/contrib/scm/browser/scmHistory'; | ||
import { observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableValue'; | ||
import { observableValueOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableValueOpts'; | ||
import { transaction } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/transaction'; | ||
@@ -167,15 +168,18 @@ function getIconFromIconDto(iconDto) { | ||
} | ||
async resolveHistoryItemRefsCommonAncestor(historyItemRefs) { | ||
return this.proxy.$resolveHistoryItemRefsCommonAncestor(this.handle, historyItemRefs, CancellationToken.None); | ||
async resolveHistoryItemChatContext(historyItemId, token) { | ||
return this.proxy.$resolveHistoryItemChatContext(this.handle, historyItemId, token ?? CancellationToken.None); | ||
} | ||
async provideHistoryItemRefs(historyItemsRefs) { | ||
const historyItemRefs = await this.proxy.$provideHistoryItemRefs(this.handle, historyItemsRefs, CancellationToken.None); | ||
async resolveHistoryItemRefsCommonAncestor(historyItemRefs, token) { | ||
return this.proxy.$resolveHistoryItemRefsCommonAncestor(this.handle, historyItemRefs, token ?? CancellationToken.None); | ||
} | ||
async provideHistoryItemRefs(historyItemsRefs, token) { | ||
const historyItemRefs = await this.proxy.$provideHistoryItemRefs(this.handle, historyItemsRefs, token ?? CancellationToken.None); | ||
return historyItemRefs?.map(ref => ({ ...ref, icon: getIconFromIconDto(ref.icon) })); | ||
} | ||
async provideHistoryItems(options) { | ||
const historyItems = await this.proxy.$provideHistoryItems(this.handle, options, CancellationToken.None); | ||
async provideHistoryItems(options, token) { | ||
const historyItems = await this.proxy.$provideHistoryItems(this.handle, options, token ?? CancellationToken.None); | ||
return historyItems?.map(historyItem => toISCMHistoryItem(historyItem)); | ||
} | ||
async provideHistoryItemChanges(historyItemId, historyItemParentId) { | ||
const changes = await this.proxy.$provideHistoryItemChanges(this.handle, historyItemId, historyItemParentId, CancellationToken.None); | ||
async provideHistoryItemChanges(historyItemId, historyItemParentId, token) { | ||
const changes = await this.proxy.$provideHistoryItemChanges(this.handle, historyItemId, historyItemParentId, token ?? CancellationToken.None); | ||
return changes?.map(change => ({ | ||
@@ -182,0 +186,0 @@ uri: URI.revive(change.uri), |
@@ -13,3 +13,3 @@ | ||
import { revive } from '@codingame/monaco-vscode-api/vscode/vs/base/common/marshalling'; | ||
import { SearchContext } from '@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common/vscode/vs/workbench/contrib/search/common/constants'; | ||
import { SearchContext } from '@codingame/monaco-vscode-47472025-cc45-5680-86cd-09ceaba921a1-common/vscode/vs/workbench/contrib/search/common/constants'; | ||
import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service'; | ||
@@ -104,2 +104,3 @@ | ||
this.keywords.push(result); | ||
this.progress?.(result); | ||
} | ||
@@ -172,3 +173,3 @@ } | ||
} | ||
_provideSearchResults(query, session, token, onKeywordResult) { | ||
_provideSearchResults(query, session, token) { | ||
switch (query.type) { | ||
@@ -175,0 +176,0 @@ case QueryType.File: |
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service"; | ||
import { MainThreadStorageShape } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js"; | ||
import { IExtensionIdWithVersion } from "@codingame/monaco-vscode-a2719803-af40-5ae9-a29f-8a2231c33056-common/vscode/vs/platform/extensionManagement/common/extensionStorage"; | ||
import { IExtensionIdWithVersion } from "@codingame/monaco-vscode-cecd476b-6f89-54b7-b016-fe6fdaa6675e-common/vscode/vs/platform/extensionManagement/common/extensionStorage"; | ||
import { IExtensionStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/extensionManagement/common/extensionStorage.service"; | ||
@@ -6,0 +6,0 @@ import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation"; |
@@ -408,3 +408,3 @@ | ||
const source = TaskSourceDTO.to(task.source, workspace); | ||
const label = ( localize(2436, '{0}: {1}', source.label, task.name)); | ||
const label = ( localize(2455, '{0}: {1}', source.label, task.name)); | ||
const definition = TaskDefinitionDTO.to(task.definition, executeOnly); | ||
@@ -411,0 +411,0 @@ const id = (CustomExecutionDTO.is(task.execution) && task._id) ? task._id : `${task.source.extensionId}.${definition._key}`; |
@@ -17,4 +17,4 @@ import { MainThreadTerminalServiceShape, TerminalLaunchConfig, ExtHostTerminalIdentifier } from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import { ITerminalCompletionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminalContrib/suggest/browser/terminalCompletionService.service"; | ||
import { IWorkbenchEnvironmentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service"; | ||
export declare class MainThreadTerminalService implements MainThreadTerminalServiceShape { | ||
private readonly _extHostContext; | ||
private readonly _terminalService; | ||
@@ -31,2 +31,3 @@ private readonly _terminalLinkProviderService; | ||
private readonly _terminalCompletionService; | ||
private readonly _environmentService; | ||
private readonly _store; | ||
@@ -43,3 +44,3 @@ private readonly _proxy; | ||
private _os; | ||
constructor(_extHostContext: IExtHostContext, _terminalService: ITerminalService, _terminalLinkProviderService: ITerminalLinkProviderService, _terminalQuickFixService: ITerminalQuickFixService, _instantiationService: IInstantiationService, _environmentVariableService: IEnvironmentVariableService, _logService: ILogService, _terminalProfileResolverService: ITerminalProfileResolverService, remoteAgentService: IRemoteAgentService, _terminalGroupService: ITerminalGroupService, _terminalEditorService: ITerminalEditorService, _terminalProfileService: ITerminalProfileService, _terminalCompletionService: ITerminalCompletionService); | ||
constructor(_extHostContext: IExtHostContext, _terminalService: ITerminalService, _terminalLinkProviderService: ITerminalLinkProviderService, _terminalQuickFixService: ITerminalQuickFixService, _instantiationService: IInstantiationService, _environmentVariableService: IEnvironmentVariableService, _logService: ILogService, _terminalProfileResolverService: ITerminalProfileResolverService, remoteAgentService: IRemoteAgentService, _terminalGroupService: ITerminalGroupService, _terminalEditorService: ITerminalEditorService, _terminalProfileService: ITerminalProfileService, _terminalCompletionService: ITerminalCompletionService, _environmentService: IWorkbenchEnvironmentService); | ||
dispose(): void; | ||
@@ -46,0 +47,0 @@ private _updateDefaultProfile; |
@@ -20,10 +20,10 @@ | ||
import { ITerminalLinkProviderService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminalContrib/links/browser/links.service'; | ||
import { TerminalQuickFixType } from '@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common/vscode/vs/workbench/contrib/terminalContrib/quickFix/browser/quickFix'; | ||
import { TerminalQuickFixType } from '@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/contrib/terminalContrib/quickFix/browser/quickFix'; | ||
import { ITerminalQuickFixService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminalContrib/quickFix/browser/quickFix.service'; | ||
import { TerminalCapability } from '@codingame/monaco-vscode-0b087f42-a5a3-5eb9-9bfd-1eebc1bba163-common/vscode/vs/platform/terminal/common/capabilities/capabilities'; | ||
import { TerminalCapability } from '@codingame/monaco-vscode-47472025-cc45-5680-86cd-09ceaba921a1-common/vscode/vs/platform/terminal/common/capabilities/capabilities'; | ||
import { ITerminalCompletionService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminalContrib/suggest/browser/terminalCompletionService.service'; | ||
import { IWorkbenchEnvironmentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service'; | ||
let MainThreadTerminalService = class MainThreadTerminalService { | ||
constructor(_extHostContext, _terminalService, _terminalLinkProviderService, _terminalQuickFixService, _instantiationService, _environmentVariableService, _logService, _terminalProfileResolverService, remoteAgentService, _terminalGroupService, _terminalEditorService, _terminalProfileService, _terminalCompletionService) { | ||
this._extHostContext = _extHostContext; | ||
constructor(_extHostContext, _terminalService, _terminalLinkProviderService, _terminalQuickFixService, _instantiationService, _environmentVariableService, _logService, _terminalProfileResolverService, remoteAgentService, _terminalGroupService, _terminalEditorService, _terminalProfileService, _terminalCompletionService, _environmentService) { | ||
this._terminalService = _terminalService; | ||
@@ -40,2 +40,3 @@ this._terminalLinkProviderService = _terminalLinkProviderService; | ||
this._terminalCompletionService = _terminalCompletionService; | ||
this._environmentService = _environmentService; | ||
this._store = ( new DisposableStore()); | ||
@@ -100,3 +101,3 @@ this._extHostTerminals = ( new Map()); | ||
async _updateDefaultProfile() { | ||
const remoteAuthority = this._extHostContext.remoteAuthority ?? undefined; | ||
const remoteAuthority = this._environmentService.remoteAuthority; | ||
const defaultProfile = this._terminalProfileResolverService.getDefaultProfile({ remoteAuthority, os: this._os }); | ||
@@ -393,3 +394,4 @@ const defaultAutomationProfile = this._terminalProfileResolverService.getDefaultProfile({ remoteAuthority, os: this._os, allowAutomationShell: true }); | ||
( __param(11, ITerminalProfileService)), | ||
( __param(12, ITerminalCompletionService)) | ||
( __param(12, ITerminalCompletionService)), | ||
( __param(13, IWorkbenchEnvironmentService)) | ||
], MainThreadTerminalService); | ||
@@ -396,0 +398,0 @@ let TerminalDataEventTracker = class TerminalDataEventTracker extends Disposable { |
@@ -6,3 +6,3 @@ | ||
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri'; | ||
import { TerminalCapability } from '@codingame/monaco-vscode-0b087f42-a5a3-5eb9-9bfd-1eebc1bba163-common/vscode/vs/platform/terminal/common/capabilities/capabilities'; | ||
import { TerminalCapability } from '@codingame/monaco-vscode-47472025-cc45-5680-86cd-09ceaba921a1-common/vscode/vs/platform/terminal/common/capabilities/capabilities'; | ||
import { ExtHostContext, MainContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol'; | ||
@@ -9,0 +9,0 @@ import { ITerminalService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminal/browser/terminal.service'; |
@@ -19,3 +19,4 @@ | ||
import { ExtHostContext, MainContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol'; | ||
import { transaction, observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/base'; | ||
import { transaction } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/transaction'; | ||
import { observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableValue'; | ||
@@ -22,0 +23,0 @@ let MainThreadTesting = class MainThreadTesting extends Disposable { |
@@ -115,3 +115,3 @@ | ||
return this.notificationService.prompt(Severity.Info, ( localize( | ||
2437, | ||
2456, | ||
"The extension {0} has forwarded port {1}. You'll need to run as superuser to use port {2} locally.", | ||
@@ -122,3 +122,3 @@ source, | ||
)), [{ | ||
label: ( localize(2438, "Use Port {0} as Sudo...", tunnel.tunnelRemotePort)), | ||
label: ( localize(2457, "Use Port {0} as Sudo...", tunnel.tunnelRemotePort)), | ||
run: async () => { | ||
@@ -125,0 +125,0 @@ this.elevateionRetry = true; |
@@ -55,3 +55,3 @@ | ||
if (!isCancellationError(e)) { | ||
const openDefaultAction = ( new Action('default', ( localize(2439, "Open using default opener")), undefined, undefined, async () => { | ||
const openDefaultAction = ( new Action('default', ( localize(2458, "Open using default opener")), undefined, undefined, async () => { | ||
await this.openerService.open(uri, { | ||
@@ -65,3 +65,3 @@ allowTunneling: false, | ||
severity: Severity.Error, | ||
message: ( localize(2440, 'Could not open uri with \'{0}\': {1}', id, (e.toString()))), | ||
message: ( localize(2459, 'Could not open uri with \'{0}\': {1}', id, (e.toString()))), | ||
actions: { | ||
@@ -68,0 +68,0 @@ primary: [ |
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; | ||
import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service"; | ||
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service"; | ||
import { WebviewInput } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput"; | ||
import { WebviewInput } from "@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput"; | ||
import { IWebviewWorkbenchService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/webviewPanel/browser/webviewWorkbenchService.service"; | ||
@@ -6,0 +6,0 @@ import { IEditorGroupsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorGroupsService.service"; |
@@ -11,4 +11,4 @@ | ||
import { DiffEditorInput } from '@codingame/monaco-vscode-9c72783f-914c-50be-b9ef-da16356d81a8-common/vscode/vs/workbench/common/editor/diffEditorInput'; | ||
import { ExtensionKeyedWebviewOriginStore } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webview/browser/webview'; | ||
import { WebviewInput } from '@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput'; | ||
import { ExtensionKeyedWebviewOriginStore } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webview/browser/webview'; | ||
import { WebviewInput } from '@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webviewPanel/browser/webviewEditorInput'; | ||
import { IWebviewWorkbenchService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/webviewPanel/browser/webviewWorkbenchService.service'; | ||
@@ -15,0 +15,0 @@ import { editorGroupToColumn } from '@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common/vscode/vs/workbench/services/editor/common/editorGroupColumn'; |
@@ -6,3 +6,3 @@ import { VSBuffer } from "@codingame/monaco-vscode-api/vscode/vs/base/common/buffer"; | ||
import * as extHostProtocol from "@codingame/monaco-vscode-api/vscode/vs/workbench/api/common/extHost.protocol"; | ||
import { IOverlayWebview, WebviewContentOptions, WebviewExtensionDescription } from "@codingame/monaco-vscode-324f9a6e-6231-5bfc-af17-e147abd2dfd2-common/vscode/vs/workbench/contrib/webview/browser/webview"; | ||
import { IOverlayWebview, WebviewContentOptions, WebviewExtensionDescription } from "@codingame/monaco-vscode-4372ad43-a220-5e78-83e6-95a9cfd64384-common/vscode/vs/workbench/contrib/webview/browser/webview"; | ||
import { IExtHostContext } from "../../services/extensions/common/extHostCustomers.js"; | ||
@@ -9,0 +9,0 @@ export declare class MainThreadWebviews extends Disposable implements extHostProtocol.MainThreadWebviewsShape { |
@@ -107,3 +107,3 @@ | ||
</head> | ||
<body>${( localize(2441, "An error occurred while loading view: {0}", escape(viewType)))}</body> | ||
<body>${( localize(2460, "An error occurred while loading view: {0}", escape(viewType)))}</body> | ||
</html>`; | ||
@@ -110,0 +110,0 @@ } |
@@ -82,7 +82,7 @@ | ||
if (addCount === 1) { | ||
message = ( localize(2442, "Extension '{0}' added 1 folder to the workspace", extensionName)); | ||
message = ( localize(2461, "Extension '{0}' added 1 folder to the workspace", extensionName)); | ||
} | ||
else { | ||
message = ( localize( | ||
2443, | ||
2462, | ||
"Extension '{0}' added {1} folders to the workspace", | ||
@@ -96,7 +96,7 @@ extensionName, | ||
if (removeCount === 1) { | ||
message = ( localize(2444, "Extension '{0}' removed 1 folder from the workspace", extensionName)); | ||
message = ( localize(2463, "Extension '{0}' removed 1 folder from the workspace", extensionName)); | ||
} | ||
else { | ||
message = ( localize( | ||
2445, | ||
2464, | ||
"Extension '{0}' removed {1} folders from the workspace", | ||
@@ -109,3 +109,3 @@ extensionName, | ||
else { | ||
message = ( localize(2446, "Extension '{0}' changed folders of the workspace", extensionName)); | ||
message = ( localize(2465, "Extension '{0}' changed folders of the workspace", extensionName)); | ||
} | ||
@@ -112,0 +112,0 @@ return message; |
@@ -52,3 +52,3 @@ | ||
e.veto(true, ( localize( | ||
5404, | ||
5524, | ||
"An extension provided text editor for '{0}' is still open that would close otherwise.", | ||
@@ -55,0 +55,0 @@ this.name |
@@ -6,3 +6,3 @@ | ||
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service'; | ||
import { Memento } from '@codingame/monaco-vscode-25a9b730-95ad-54d3-8807-71421ad9b891-common/vscode/vs/workbench/common/memento'; | ||
import { Memento } from '@codingame/monaco-vscode-924e8f00-6faf-5059-b518-e43427d29ab3-common/vscode/vs/workbench/common/memento'; | ||
import { updateContributedOpeners } from '@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/contrib/externalUriOpener/common/configuration'; | ||
@@ -9,0 +9,0 @@ import { IExtensionService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service'; |
@@ -143,7 +143,7 @@ | ||
const goodPrompt = { | ||
label: ( localize(12192, "I can't reproduce")), | ||
label: ( localize(12471, "I can't reproduce")), | ||
run: () => this._commandService.executeCommand('extension.bisect.next', false) | ||
}; | ||
const badPrompt = { | ||
label: ( localize(12193, "I can reproduce")), | ||
label: ( localize(12472, "I can reproduce")), | ||
run: () => this._commandService.executeCommand('extension.bisect.next', true) | ||
@@ -157,7 +157,7 @@ }; | ||
? ( localize( | ||
12194, | ||
12473, | ||
"Extension Bisect is active and has disabled 1 extension. Check if you can still reproduce the problem and proceed by selecting from these options." | ||
)) | ||
: ( localize( | ||
12195, | ||
12474, | ||
"Extension Bisect is active and has disabled {0} extensions. Check if you can still reproduce the problem and proceed by selecting from these options.", | ||
@@ -180,3 +180,3 @@ this._extensionBisectService.disabledCount | ||
id: 'extension.bisect.start', | ||
title: ( localize2(12196, 'Start Extension Bisect')), | ||
title: ( localize2(12475, 'Start Extension Bisect')), | ||
category: Categories.Help, | ||
@@ -201,9 +201,9 @@ f1: true, | ||
const res = await dialogService.confirm({ | ||
message: ( localize(12197, "Extension Bisect")), | ||
message: ( localize(12476, "Extension Bisect")), | ||
detail: ( localize( | ||
12198, | ||
12477, | ||
"Extension Bisect will use binary search to find an extension that causes a problem. During the process the window reloads repeatedly (~{0} times). Each time you must confirm if you are still seeing problems.", | ||
2 + Math.log2(extensions.length) | 0 | ||
)), | ||
primaryButton: ( localize(12199, "&&Start Extension Bisect")) | ||
primaryButton: ( localize(12478, "&&Start Extension Bisect")) | ||
}); | ||
@@ -220,3 +220,3 @@ if (res.confirmed) { | ||
id: 'extension.bisect.next', | ||
title: ( localize2(12200, 'Continue Extension Bisect')), | ||
title: ( localize2(12479, 'Continue Extension Bisect')), | ||
category: Categories.Help, | ||
@@ -255,4 +255,4 @@ f1: true, | ||
if (done.bad) { | ||
await dialogService.info(( localize(12201, "Extension Bisect")), ( localize( | ||
12202, | ||
await dialogService.info(( localize(12480, "Extension Bisect")), ( localize( | ||
12481, | ||
"Extension Bisect is done but no extension has been identified. This might be a problem with {0}.", | ||
@@ -265,11 +265,11 @@ productService.nameShort | ||
type: Severity.Info, | ||
message: ( localize(12201, "Extension Bisect")), | ||
primaryButton: ( localize(12203, "&&Report Issue & Continue")), | ||
cancelButton: ( localize(12204, "Continue")), | ||
message: ( localize(12480, "Extension Bisect")), | ||
primaryButton: ( localize(12482, "&&Report Issue & Continue")), | ||
cancelButton: ( localize(12483, "Continue")), | ||
detail: ( localize( | ||
12205, | ||
12484, | ||
"Extension Bisect is done and has identified {0} as the extension causing the problem.", | ||
done.id | ||
)), | ||
checkbox: { label: ( localize(12206, "Keep this extension disabled")), checked: true } | ||
checkbox: { label: ( localize(12485, "Keep this extension disabled")), checked: true } | ||
}); | ||
@@ -289,5 +289,5 @@ if (res.checkboxChecked) { | ||
type: Severity.Info, | ||
message: ( localize(12207, "Extension Bisect")), | ||
message: ( localize(12486, "Extension Bisect")), | ||
detail: ( localize( | ||
12208, | ||
12487, | ||
"Extension Bisect is active and has disabled {0} extensions. Check if you can still reproduce the problem and proceed by selecting from these options.", | ||
@@ -298,11 +298,11 @@ bisectService.disabledCount | ||
{ | ||
label: ( localize(12209, "I ca&&n't reproduce")), | ||
label: ( localize(12488, "I ca&&n't reproduce")), | ||
run: () => false | ||
}, | ||
{ | ||
label: ( localize(12210, "I can &&reproduce")), | ||
label: ( localize(12489, "I can &&reproduce")), | ||
run: () => true | ||
}, | ||
{ | ||
label: ( localize(12211, "&&Stop Bisect")), | ||
label: ( localize(12490, "&&Stop Bisect")), | ||
run: () => undefined | ||
@@ -312,3 +312,3 @@ } | ||
cancelButton: { | ||
label: ( localize(12212, "&&Cancel Bisect")), | ||
label: ( localize(12491, "&&Cancel Bisect")), | ||
run: () => null | ||
@@ -324,3 +324,3 @@ } | ||
id: 'extension.bisect.stop', | ||
title: ( localize2(12213, 'Stop Extension Bisect')), | ||
title: ( localize2(12492, 'Stop Extension Bisect')), | ||
category: Categories.Help, | ||
@@ -327,0 +327,0 @@ f1: true, |
@@ -25,3 +25,3 @@ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service"; | ||
import { IExtensionManifestPropertiesService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocationTracker } from "../common/extensionRunningLocationTracker.js"; | ||
@@ -28,0 +28,0 @@ import { IExtensionHost } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; |
@@ -14,3 +14,3 @@ import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event"; | ||
import { IBrowserWorkbenchEnvironmentService } from "@codingame/monaco-vscode-34a0ffd3-b9f5-5699-b43b-38af5732f38a-common/vscode/vs/workbench/services/environment/browser/environmentService.service"; | ||
import { LocalWebWorkerRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { LocalWebWorkerRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionHostExtensions, ExtensionHostStartup, IExtensionHost } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; | ||
@@ -17,0 +17,0 @@ export interface IWebWorkerExtensionHostInitData { |
@@ -116,3 +116,3 @@ | ||
let barrierHasError = false; | ||
let startTimeout = null; | ||
let startTimeout = undefined; | ||
const rejectBarrier = (exitCode, error) => { | ||
@@ -119,0 +119,0 @@ barrierError = error; |
@@ -22,3 +22,3 @@ import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle"; | ||
import { IExtensionManifestPropertiesService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocationTracker } from "./extensionRunningLocationTracker.js"; | ||
@@ -25,0 +25,0 @@ import { ActivationKind, ActivationTimes, ExtensionActivationReason, ExtensionPointContribution, IExtensionHost, IExtensionsStatus, IMessage, IResponsiveStateChangeEvent, IWillActivateEvent, WillStopExtensionHostsEvent } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; |
@@ -42,3 +42,3 @@ | ||
import { IExtensionManifestPropertiesService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service'; | ||
import { RemoteRunningLocation, LocalProcessRunningLocation, LocalWebWorkerRunningLocation } from '@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation'; | ||
import { RemoteRunningLocation, LocalProcessRunningLocation, LocalWebWorkerRunningLocation } from '@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation'; | ||
import { ExtensionRunningLocationTracker, filterExtensionIdentifiers } from './extensionRunningLocationTracker.js'; | ||
@@ -185,3 +185,3 @@ import { toExtensionDescription, ExtensionHostStartup, ActivationKind, ExtensionPointContribution, ActivationTimes, toExtension } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions'; | ||
id: 'join.disconnectRemote', | ||
label: ( localize(12294, "Disconnect Remote Agent")), | ||
label: ( localize(12574, "Disconnect Remote Agent")), | ||
order: WillShutdownJoinerOrder.Last | ||
@@ -193,3 +193,3 @@ }); | ||
id: 'join.stopExtensionHosts', | ||
label: ( localize(12295, "Stopping Extension Hosts")), | ||
label: ( localize(12575, "Stopping Extension Hosts")), | ||
}); | ||
@@ -265,3 +265,3 @@ } | ||
message: ( localize( | ||
12296, | ||
12576, | ||
"The following extensions contain dependency loops and have been disabled: {0}", | ||
@@ -447,3 +447,3 @@ ( result.removedDueToLooping.map(e => `'${e.identifier.value}'`)).join(', ') | ||
message: ( localize( | ||
12296, | ||
12576, | ||
"The following extensions contain dependency loops and have been disabled: {0}", | ||
@@ -463,3 +463,3 @@ ( result.removedDueToLooping.map(e => `'${e.identifier.value}'`)).join(', ') | ||
const msg = ( localize( | ||
12297, | ||
12577, | ||
"No extension host found that can launch the test runner at {0}.", | ||
@@ -634,3 +634,3 @@ (this._environmentService.extensionTestsLocationURI.toString()) | ||
}).catch(error => { | ||
vetoReasons.add(( localize(12298, "{0} (Error: {1})", reason, toErrorMessage(error)))); | ||
vetoReasons.add(( localize(12578, "{0} (Error: {1})", reason, toErrorMessage(error)))); | ||
}); | ||
@@ -650,7 +650,7 @@ } | ||
type: Severity.Warning, | ||
message: ( localize(12299, "Please confirm restart of extensions.")), | ||
message: ( localize(12579, "Please confirm restart of extensions.")), | ||
detail: vetoReasonsArray.length === 1 ? | ||
vetoReasonsArray[0] : | ||
vetoReasonsArray.join('\n -'), | ||
primaryButton: ( localize(12300, "Restart Anyway")) | ||
primaryButton: ( localize(12580, "Restart Anyway")) | ||
}); | ||
@@ -752,3 +752,3 @@ if (confirmed) { | ||
this._logService.info(`Automatically restarting the remote extension host.`); | ||
this._notificationService.status(( localize(12301, "The remote extension host terminated unexpectedly. Restarting...")), { hideAfter: 5000 }); | ||
this._notificationService.status(( localize(12581, "The remote extension host terminated unexpectedly. Restarting...")), { hideAfter: 5000 }); | ||
this._startExtensionHostsIfNecessary(false, Array.from(( this._allRequestedActivateEvents.keys()))); | ||
@@ -758,6 +758,6 @@ } | ||
this._notificationService.prompt(Severity.Error, ( localize( | ||
12302, | ||
12582, | ||
"Remote Extension host terminated unexpectedly 3 times within the last 5 minutes." | ||
)), [{ | ||
label: ( localize(12303, "Restart Remote Extension Host")), | ||
label: ( localize(12583, "Restart Remote Extension Host")), | ||
run: () => { | ||
@@ -1253,3 +1253,3 @@ this._startExtensionHostsIfNecessary(false, Array.from(( this._allRequestedActivateEvents.keys()))); | ||
id: 'activationEvents', | ||
label: ( localize(12304, "Activation Events")), | ||
label: ( localize(12584, "Activation Events")), | ||
access: { | ||
@@ -1256,0 +1256,0 @@ canToggle: false |
@@ -13,3 +13,3 @@ import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event"; | ||
import { IResolveAuthorityResult } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionHostProxy"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ActivationKind, ExtensionActivationReason, ExtensionHostStartup, IExtensionHost, IInternalExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; | ||
@@ -16,0 +16,0 @@ import { ResponsiveState } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/rpcProtocol"; |
@@ -482,3 +482,3 @@ | ||
id: 'editor.action.measureExtHostLatency', | ||
title: ( localize2(12305, "Measure Extension Host Latency")), | ||
title: ( localize2(12585, "Measure Extension Host Latency")), | ||
category: Categories.Developer, | ||
@@ -485,0 +485,0 @@ f1: true |
@@ -7,3 +7,3 @@ import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event"; | ||
import { IResolveAuthorityResult } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionHostProxy"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ActivationKind, ExtensionActivationReason, ExtensionHostStartup } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; | ||
@@ -10,0 +10,0 @@ import { ResponsiveState } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/rpcProtocol"; |
@@ -10,3 +10,3 @@ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service"; | ||
import { IExtensionManifestPropertiesService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
export declare class ExtensionRunningLocationTracker { | ||
@@ -13,0 +13,0 @@ private readonly _registry; |
@@ -10,3 +10,3 @@ | ||
import { IExtensionManifestPropertiesService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionManifestPropertiesService.service'; | ||
import { RemoteRunningLocation, LocalProcessRunningLocation, LocalWebWorkerRunningLocation } from '@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation'; | ||
import { RemoteRunningLocation, LocalProcessRunningLocation, LocalWebWorkerRunningLocation } from '@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation'; | ||
@@ -13,0 +13,0 @@ let ExtensionRunningLocationTracker = class ExtensionRunningLocationTracker { |
@@ -109,3 +109,3 @@ | ||
id: 'enabledApiProposals', | ||
label: ( localize(12306, "API Proposals")), | ||
label: ( localize(12586, "API Proposals")), | ||
access: { | ||
@@ -112,0 +112,0 @@ canToggle: false |
@@ -12,3 +12,3 @@ | ||
logService.warn(( localize( | ||
12391, | ||
12671, | ||
"Overwriting extension {0} with {1}.", | ||
@@ -33,3 +33,3 @@ extension.extensionLocation.fsPath, | ||
logService.warn(( localize( | ||
12391, | ||
12671, | ||
"Overwriting extension {0} with {1}.", | ||
@@ -51,3 +51,3 @@ extension.extensionLocation.fsPath, | ||
logService.warn(( localize( | ||
12392, | ||
12672, | ||
"Overwriting {0} with Workspace Extension {1}.", | ||
@@ -62,3 +62,3 @@ extension.extensionLocation.fsPath, | ||
logService.info(( localize( | ||
12393, | ||
12673, | ||
"Loading development extension at {0}", | ||
@@ -65,0 +65,0 @@ developedExtension.extensionLocation.fsPath |
@@ -11,3 +11,3 @@ import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event"; | ||
import { IResolveAuthorityResult } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionHostProxy"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ActivationKind, ExtensionActivationReason, ExtensionHostStartup, IExtensionHost, IInternalExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; | ||
@@ -14,0 +14,0 @@ import { ResponsiveState } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/rpcProtocol"; |
@@ -17,3 +17,3 @@ import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event"; | ||
import { IWorkbenchEnvironmentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service"; | ||
import { RemoteRunningLocation } from "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { RemoteRunningLocation } from "@codingame/monaco-vscode-571c8352-7953-5038-9f09-e03bb6219a0e-common/vscode/vs/workbench/services/extensions/common/extensionRunningLocation"; | ||
import { ExtensionHostExtensions, ExtensionHostStartup, IExtensionHost } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions"; | ||
@@ -20,0 +20,0 @@ export interface IRemoteExtensionHostInitData { |
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
1242467
1.53%23099
1.36%29
7.41%+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated