@codingame/monaco-vscode-extensions-service-override 14.0.0 → 14.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,7 +4,7 @@
4
4
  <meta http-equiv="Content-Security-Policy" content="
5
5
  default-src 'none';
6
6
  child-src 'self' data: blob:;
7
- script-src 'self' 'unsafe-eval' 'sha256-xM2KVDKIoeb8vVxk4ezEUsxdTZh5wFnKO3YmFhy9tkk=' data: extension-file: https: http://localhost:* blob:;
7
+ script-src 'self' 'unsafe-eval' 'sha256-O8NK++6jfjVooqQN8mkcEKUM19Yc4nx5RZXws6U2sao=' data: extension-file: https: http://localhost:* blob:;
8
8
  connect-src 'self' data: extension-file: https: wss: http://localhost:* http://127.0.0.1:* ws://localhost:* ws://127.0.0.1:*;"/>
9
9
  </head>
10
10
  <body>
@@ -78,7 +78,7 @@
78
78
  return;
79
79
  }
80
80
  const { data } = event.data;
81
- createWorker(data.workerUrl, data.fileRoot, data.nls.messages, data.nls.language);
81
+ createWorker(data.workerUrl, data.workerOptions, data.fileRoot, data.nls.messages, data.nls.language);
82
82
  };
83
83
 
84
84
  window.parent.postMessage({
@@ -87,7 +87,7 @@
87
87
  }, '*');
88
88
  }
89
89
 
90
- function createWorker(workerUrl, fileRoot, nlsMessages, nlsLanguage) {
90
+ function createWorker(workerUrl, workerOptions, fileRoot, nlsMessages, nlsLanguage) {
91
91
  try {
92
92
  if (globalThis.crossOriginIsolated) {
93
93
  workerUrl += '?vscode-coi=2'; // COEP
@@ -102,11 +102,11 @@
102
102
  `globalThis._VSCODE_NLS_MESSAGES = ${JSON.stringify(nlsMessages)};`,
103
103
  `globalThis._VSCODE_NLS_LANGUAGE = ${JSON.stringify(nlsLanguage)};`,
104
104
  `globalThis._VSCODE_FILE_ROOT = ${JSON.stringify(fileRoot)};`,
105
- `await import(${JSON.stringify(workerUrl)});`,
105
+ (workerOptions.type === 'module') ? `await import('${workerUrl}');` : `importScripts('${workerUrl}');`,
106
106
  `/*extensionHostWorker*/`
107
107
  ].join('')], { type: 'application/javascript' });
108
108
 
109
- const worker = new Worker(URL.createObjectURL(blob), { name, type: 'module' });
109
+ const worker = new Worker(URL.createObjectURL(blob), { name, ...workerOptions });
110
110
  const nestedWorkers = new Map();
111
111
 
112
112
  worker.onmessage = (event) => {
package/index.d.ts CHANGED
@@ -33,8 +33,8 @@ export interface IExtensionWithExtHostKind extends IExtension {
33
33
  extHostKind?: ExtensionHostKind;
34
34
  }
35
35
  export declare class ExtensionServiceOverride extends ExtensionService implements IExtensionService {
36
- constructor(workerExtHostEnabled: boolean, instantiationService: IInstantiationService, notificationService: INotificationService, browserEnvironmentService: IBrowserWorkbenchEnvironmentService, telemetryService: ITelemetryService, extensionEnablementService: IWorkbenchExtensionEnablementService, fileService: IFileService, productService: IProductService, extensionManagementService: IWorkbenchExtensionManagementService, contextService: IWorkspaceContextService, configurationService: IConfigurationService, extensionManifestPropertiesService: IExtensionManifestPropertiesService, webExtensionsScannerService: IWebExtensionsScannerService, logService: ILogService, remoteAgentService: IRemoteAgentService, remoteExtensionsScannerService: IRemoteExtensionsScannerService, lifecycleService: ILifecycleService, remoteAuthorityResolverService: IRemoteAuthorityResolverService, userDataInitializationService: IUserDataInitializationService, userDataProfileService: IUserDataProfileService, workspaceTrustManagementService: IWorkspaceTrustManagementService, remoteExplorerService: IRemoteExplorerService, dialogService: IDialogService);
36
+ constructor(workerConfig: WorkerConfig, instantiationService: IInstantiationService, notificationService: INotificationService, browserEnvironmentService: IBrowserWorkbenchEnvironmentService, telemetryService: ITelemetryService, extensionEnablementService: IWorkbenchExtensionEnablementService, fileService: IFileService, productService: IProductService, extensionManagementService: IWorkbenchExtensionManagementService, contextService: IWorkspaceContextService, configurationService: IConfigurationService, extensionManifestPropertiesService: IExtensionManifestPropertiesService, webExtensionsScannerService: IWebExtensionsScannerService, logService: ILogService, remoteAgentService: IRemoteAgentService, remoteExtensionsScannerService: IRemoteExtensionsScannerService, lifecycleService: ILifecycleService, remoteAuthorityResolverService: IRemoteAuthorityResolverService, userDataInitializationService: IUserDataInitializationService, userDataProfileService: IUserDataProfileService, workspaceTrustManagementService: IWorkspaceTrustManagementService, remoteExplorerService: IRemoteExplorerService, dialogService: IDialogService);
37
37
  deltaExtensions(toAdd: IExtensionWithExtHostKind[], toRemove: IExtension[]): Promise<void>;
38
38
  }
39
- export default function getServiceOverride(workerConfig?: WorkerConfig, _iframeAlternateDomains?: string): IEditorOverrideServices;
39
+ export default function getServiceOverride(workerConfig?: WorkerConfig, _iframeAlternateDomain?: string): IEditorOverrideServices;
40
40
  export { ExtensionHostKind, setLocalExtensionHost };
package/index.js CHANGED
@@ -134,9 +134,9 @@ function setLocalExtensionHost(_localExtensionHost) {
134
134
  localExtensionHost = _localExtensionHost;
135
135
  }
136
136
  let BrowserExtensionHostFactoryOverride = class BrowserExtensionHostFactoryOverride extends BrowserExtensionHostFactory {
137
- constructor(workerExtHostEnabled, _extensionsProposedApi, _scanWebExtensions, _getExtensionRegistrySnapshotWhenReady, _instantiationService, _remoteAgentService, _remoteAuthorityResolverService, _extensionEnablementService, _logService) {
137
+ constructor(workerConfig, _extensionsProposedApi, _scanWebExtensions, _getExtensionRegistrySnapshotWhenReady, _instantiationService, _remoteAgentService, _remoteAuthorityResolverService, _extensionEnablementService, _logService) {
138
138
  super(_extensionsProposedApi, _scanWebExtensions, _getExtensionRegistrySnapshotWhenReady, _instantiationService, _remoteAgentService, _remoteAuthorityResolverService, _extensionEnablementService, _logService);
139
- this.workerExtHostEnabled = workerExtHostEnabled;
139
+ this.workerConfig = workerConfig;
140
140
  }
141
141
  createExtensionHost(runningLocations, runningLocation, isInitialStart) {
142
142
  switch (runningLocation.kind) {
@@ -147,13 +147,13 @@ let BrowserExtensionHostFactoryOverride = class BrowserExtensionHostFactoryOverr
147
147
  return this._instantiationService.createInstance(localExtensionHost, runningLocation, ExtensionHostStartup.EagerAutoStart, this._createLocalExtensionHostDataProvider(runningLocations, runningLocation, isInitialStart));
148
148
  }
149
149
  case ExtensionHostKind.LocalWebWorker: {
150
- if (!this.workerExtHostEnabled) {
150
+ if (this.workerConfig == null) {
151
151
  return null;
152
152
  }
153
153
  const startup = isInitialStart
154
154
  ? ExtensionHostStartup.EagerManualStart
155
155
  : ExtensionHostStartup.EagerAutoStart;
156
- return this._instantiationService.createInstance(WebWorkerExtensionHost, runningLocation, startup, this._createLocalExtensionHostDataProvider(runningLocations, runningLocation, isInitialStart));
156
+ return this._instantiationService.createInstance(WebWorkerExtensionHost, runningLocation, startup, this._createLocalExtensionHostDataProvider(runningLocations, runningLocation, isInitialStart), this.workerConfig.url, this.workerConfig.options);
157
157
  }
158
158
  case ExtensionHostKind.Remote: {
159
159
  return super.createExtensionHost(runningLocations, runningLocation, isInitialStart);
@@ -189,10 +189,10 @@ LocalBrowserExtensionHostKindPicker = __decorate([
189
189
  __param(1, ILogService)
190
190
  ], LocalBrowserExtensionHostKindPicker);
191
191
  let ExtensionServiceOverride = class ExtensionServiceOverride extends ExtensionService {
192
- constructor(workerExtHostEnabled, instantiationService, notificationService, browserEnvironmentService, telemetryService, extensionEnablementService, fileService, productService, extensionManagementService, contextService, configurationService, extensionManifestPropertiesService, webExtensionsScannerService, logService, remoteAgentService, remoteExtensionsScannerService, lifecycleService, remoteAuthorityResolverService, userDataInitializationService, userDataProfileService, workspaceTrustManagementService, remoteExplorerService, dialogService) {
192
+ constructor(workerConfig, instantiationService, notificationService, browserEnvironmentService, telemetryService, extensionEnablementService, fileService, productService, extensionManagementService, contextService, configurationService, extensionManifestPropertiesService, webExtensionsScannerService, logService, remoteAgentService, remoteExtensionsScannerService, lifecycleService, remoteAuthorityResolverService, userDataInitializationService, userDataProfileService, workspaceTrustManagementService, remoteExplorerService, dialogService) {
193
193
  const extensionsProposedApi = instantiationService.createInstance(ExtensionsProposedApi);
194
- const extensionHostFactory = new BrowserExtensionHostFactoryOverride(workerExtHostEnabled, extensionsProposedApi, async () => await this._scanWebExtensions(), () => this._getExtensionRegistrySnapshotWhenReady(), instantiationService, remoteAgentService, remoteAuthorityResolverService, extensionEnablementService, logService);
195
- super(extensionsProposedApi, extensionHostFactory, new LocalBrowserExtensionHostKindPicker(workerExtHostEnabled
194
+ const extensionHostFactory = new BrowserExtensionHostFactoryOverride(workerConfig, extensionsProposedApi, async () => await this._scanWebExtensions(), () => this._getExtensionRegistrySnapshotWhenReady(), instantiationService, remoteAgentService, remoteAuthorityResolverService, extensionEnablementService, logService);
195
+ super(extensionsProposedApi, extensionHostFactory, new LocalBrowserExtensionHostKindPicker(workerConfig != null
196
196
  ? [
197
197
  ExtensionHostKind.LocalWebWorker,
198
198
  ExtensionHostKind.LocalProcess,
@@ -237,25 +237,20 @@ class ExtensionResourceLoaderServiceOverride extends ExtensionResourceLoaderServ
237
237
  return await super.readExtensionResource(uri);
238
238
  }
239
239
  }
240
- let iframeAlternateDomains;
240
+ let iframeAlternateDomain;
241
241
  registerAssets({
242
- 'vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html': () => changeUrlDomain(new URL('./assets/webWorkerExtensionHostIframe.html', import.meta.url).href, iframeAlternateDomains)
242
+ 'vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html': () => changeUrlDomain(new URL('./assets/webWorkerExtensionHostIframe.html', import.meta.url).href, iframeAlternateDomain)
243
243
  });
244
- function getServiceOverride(workerConfig, _iframeAlternateDomains) {
245
- if (_iframeAlternateDomains != null) {
246
- iframeAlternateDomains = _iframeAlternateDomains;
244
+ function getServiceOverride(workerConfig, _iframeAlternateDomain) {
245
+ if (_iframeAlternateDomain != null) {
246
+ iframeAlternateDomain = _iframeAlternateDomain;
247
247
  }
248
248
  const _workerConfig = workerConfig != null
249
249
  ? {
250
250
  ...workerConfig,
251
- url: changeUrlDomain(workerConfig.url, iframeAlternateDomains)
251
+ url: changeUrlDomain(workerConfig.url, iframeAlternateDomain ?? globalThis.location?.href ?? import.meta.url)
252
252
  }
253
253
  : undefined;
254
- if (workerConfig != null) {
255
- registerAssets({
256
- 'vs/workbench/api/worker/extensionHostWorkerMain.js': () => workerConfig.url
257
- });
258
- }
259
254
  return {
260
255
  [IExtensionService.toString()]: new SyncDescriptor(ExtensionServiceOverride, [_workerConfig], false),
261
256
  [IExtensionManifestPropertiesService.toString()]: new SyncDescriptor(ExtensionManifestPropertiesService, [], true),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-extensions-service-override",
3
- "version": "14.0.0",
3
+ "version": "14.0.2",
4
4
  "private": false,
5
5
  "description": "VSCode public API plugged on the monaco editor - extensions service-override",
6
6
  "keywords": [],
@@ -15,33 +15,33 @@
15
15
  },
16
16
  "type": "module",
17
17
  "dependencies": {
18
- "@codingame/monaco-vscode-0b087f42-a5a3-5eb9-9bfd-1eebc1bba163-common": "14.0.0",
19
- "@codingame/monaco-vscode-168b98e5-dc20-5807-b1f9-798f1f92b37f-common": "14.0.0",
20
- "@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "14.0.0",
21
- "@codingame/monaco-vscode-3607c442-ae7a-594b-b840-038378c24fef-common": "14.0.0",
22
- "@codingame/monaco-vscode-411e0589-fa79-504b-b32c-80a88847b23a-common": "14.0.0",
23
- "@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common": "14.0.0",
24
- "@codingame/monaco-vscode-4a28f637-7c3c-5e48-a77c-1b7538b38850-common": "14.0.0",
25
- "@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "14.0.0",
26
- "@codingame/monaco-vscode-771c2e6d-0284-5ac1-be73-7176085eedc5-common": "14.0.0",
27
- "@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "14.0.0",
28
- "@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "14.0.0",
29
- "@codingame/monaco-vscode-91789cdf-e3cb-5a04-aaeb-6f7df7d3d231-common": "14.0.0",
30
- "@codingame/monaco-vscode-99f24462-c56d-5407-83fb-2ea9dd33cc8c-common": "14.0.0",
31
- "@codingame/monaco-vscode-a17f5129-e16c-5dac-857e-dcd91bfeffa2-common": "14.0.0",
32
- "@codingame/monaco-vscode-af5ccfda-af82-504b-b365-92b4e654e5c5-common": "14.0.0",
33
- "@codingame/monaco-vscode-api": "14.0.0",
34
- "@codingame/monaco-vscode-bd6ad8b7-9db3-51a8-9895-0046508c029d-common": "14.0.0",
35
- "@codingame/monaco-vscode-be8ddbb5-094a-5657-b1cc-fe106c94c632-common": "14.0.0",
36
- "@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "14.0.0",
37
- "@codingame/monaco-vscode-c3c61c00-c254-5856-9dc9-d7929c1f9062-common": "14.0.0",
38
- "@codingame/monaco-vscode-ce8c4b18-4e75-55dd-9656-517347af9de7-common": "14.0.0",
39
- "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common": "14.0.0",
40
- "@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "14.0.0",
41
- "@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "14.0.0",
42
- "@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common": "14.0.0",
43
- "@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common": "14.0.0",
44
- "@codingame/monaco-vscode-files-service-override": "14.0.0"
18
+ "@codingame/monaco-vscode-0b087f42-a5a3-5eb9-9bfd-1eebc1bba163-common": "14.0.2",
19
+ "@codingame/monaco-vscode-168b98e5-dc20-5807-b1f9-798f1f92b37f-common": "14.0.2",
20
+ "@codingame/monaco-vscode-256d5b78-0649-50e9-8354-2807f95f68f4-common": "14.0.2",
21
+ "@codingame/monaco-vscode-3607c442-ae7a-594b-b840-038378c24fef-common": "14.0.2",
22
+ "@codingame/monaco-vscode-411e0589-fa79-504b-b32c-80a88847b23a-common": "14.0.2",
23
+ "@codingame/monaco-vscode-42931eb9-e564-530c-bafc-fa23ab43a070-common": "14.0.2",
24
+ "@codingame/monaco-vscode-4a28f637-7c3c-5e48-a77c-1b7538b38850-common": "14.0.2",
25
+ "@codingame/monaco-vscode-6845754f-e617-5ed9-8aaa-6ca3653a9532-common": "14.0.2",
26
+ "@codingame/monaco-vscode-771c2e6d-0284-5ac1-be73-7176085eedc5-common": "14.0.2",
27
+ "@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common": "14.0.2",
28
+ "@codingame/monaco-vscode-8ccb7637-50ea-5359-97bf-00015d7fe567-common": "14.0.2",
29
+ "@codingame/monaco-vscode-91789cdf-e3cb-5a04-aaeb-6f7df7d3d231-common": "14.0.2",
30
+ "@codingame/monaco-vscode-99f24462-c56d-5407-83fb-2ea9dd33cc8c-common": "14.0.2",
31
+ "@codingame/monaco-vscode-a17f5129-e16c-5dac-857e-dcd91bfeffa2-common": "14.0.2",
32
+ "@codingame/monaco-vscode-af5ccfda-af82-504b-b365-92b4e654e5c5-common": "14.0.2",
33
+ "@codingame/monaco-vscode-api": "14.0.2",
34
+ "@codingame/monaco-vscode-bd6ad8b7-9db3-51a8-9895-0046508c029d-common": "14.0.2",
35
+ "@codingame/monaco-vscode-be8ddbb5-094a-5657-b1cc-fe106c94c632-common": "14.0.2",
36
+ "@codingame/monaco-vscode-bf94ddb5-e436-506a-9763-5ab86b642508-common": "14.0.2",
37
+ "@codingame/monaco-vscode-c3c61c00-c254-5856-9dc9-d7929c1f9062-common": "14.0.2",
38
+ "@codingame/monaco-vscode-ce8c4b18-4e75-55dd-9656-517347af9de7-common": "14.0.2",
39
+ "@codingame/monaco-vscode-d7f659f5-da33-5ea8-a3b8-9b94f2cf5f33-common": "14.0.2",
40
+ "@codingame/monaco-vscode-eb7d5efd-2e60-59f8-9ba4-9a8ae8cb2957-common": "14.0.2",
41
+ "@codingame/monaco-vscode-eba0b9b3-174c-5dae-9867-a37810ca1808-common": "14.0.2",
42
+ "@codingame/monaco-vscode-f48982c4-9e82-55e2-b800-20e6d1e6096f-common": "14.0.2",
43
+ "@codingame/monaco-vscode-fab30422-b487-5f4e-8d30-8b4d266e3fcd-common": "14.0.2",
44
+ "@codingame/monaco-vscode-files-service-override": "14.0.2"
45
45
  },
46
46
  "main": "index.js",
47
47
  "module": "index.js",
@@ -1,7 +1,7 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
3
  import { mainWindow } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/window';
4
- import { Schemas } from '@codingame/monaco-vscode-api/vscode/vs/base/common/network';
4
+ import { Schemas, FileAccess } from '@codingame/monaco-vscode-api/vscode/vs/base/common/network';
5
5
  import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service';
6
6
  import { IDialogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service';
7
7
  import { IFileService } from '@codingame/monaco-vscode-api/vscode/vs/platform/files/common/files.service';
@@ -181,7 +181,7 @@ let BrowserExtensionHostFactory = class BrowserExtensionHostFactory {
181
181
  const startup = (isInitialStart
182
182
  ? ExtensionHostStartup.EagerManualStart
183
183
  : ExtensionHostStartup.EagerAutoStart);
184
- return this._instantiationService.createInstance(WebWorkerExtensionHost, runningLocation, startup, this._createLocalExtensionHostDataProvider(runningLocations, runningLocation, isInitialStart));
184
+ return this._instantiationService.createInstance(WebWorkerExtensionHost, runningLocation, startup, this._createLocalExtensionHostDataProvider(runningLocations, runningLocation, isInitialStart), ( ( FileAccess.asBrowserUri('vs/workbench/api/worker/extensionHostWorkerMain.js')).toString(true)), { type: 'module' });
185
185
  }
186
186
  case ExtensionHostKind.Remote: {
187
187
  const remoteAgentConnection = this._remoteAgentService.getConnection();
@@ -23,6 +23,8 @@ export declare class WebWorkerExtensionHost extends Disposable implements IExten
23
23
  readonly runningLocation: LocalWebWorkerRunningLocation;
24
24
  readonly startup: ExtensionHostStartup;
25
25
  private readonly _initDataProvider;
26
+ private readonly workerUrl;
27
+ private readonly workerOptions;
26
28
  private readonly _telemetryService;
27
29
  private readonly _contextService;
28
30
  private readonly _labelService;
@@ -45,7 +47,7 @@ export declare class WebWorkerExtensionHost extends Disposable implements IExten
45
47
  private _protocolPromise;
46
48
  private _protocol;
47
49
  private readonly _extensionHostLogsLocation;
48
- constructor(runningLocation: LocalWebWorkerRunningLocation, startup: ExtensionHostStartup, _initDataProvider: IWebWorkerExtensionHostDataProvider, _telemetryService: ITelemetryService, _contextService: IWorkspaceContextService, _labelService: ILabelService, _logService: ILogService, _loggerService: ILoggerService, _environmentService: IBrowserWorkbenchEnvironmentService, _userDataProfilesService: IUserDataProfilesService, _productService: IProductService, _layoutService: ILayoutService, _storageService: IStorageService);
50
+ constructor(runningLocation: LocalWebWorkerRunningLocation, startup: ExtensionHostStartup, _initDataProvider: IWebWorkerExtensionHostDataProvider, workerUrl: string, workerOptions: WorkerOptions | undefined, _telemetryService: ITelemetryService, _contextService: IWorkspaceContextService, _labelService: ILabelService, _logService: ILogService, _loggerService: ILoggerService, _environmentService: IBrowserWorkbenchEnvironmentService, _userDataProfilesService: IUserDataProfilesService, _productService: IProductService, _layoutService: ILayoutService, _storageService: IStorageService);
49
51
  protected _getWebWorkerExtensionHostIframeSrc(): Promise<string>;
50
52
  start(): Promise<IMessagePassingProtocol>;
51
53
  private _startInsideIframe;
@@ -31,11 +31,13 @@ import { ExtensionHostStartup } from '@codingame/monaco-vscode-api/vscode/vs/wor
31
31
  import { getNLSLanguage, getNLSMessages } from '@codingame/monaco-vscode-api/vscode/vs/nls.messages';
32
32
 
33
33
  let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
34
- constructor(runningLocation, startup, _initDataProvider, _telemetryService, _contextService, _labelService, _logService, _loggerService, _environmentService, _userDataProfilesService, _productService, _layoutService, _storageService) {
34
+ constructor(runningLocation, startup, _initDataProvider, workerUrl, workerOptions, _telemetryService, _contextService, _labelService, _logService, _loggerService, _environmentService, _userDataProfilesService, _productService, _layoutService, _storageService) {
35
35
  super();
36
36
  this.runningLocation = runningLocation;
37
37
  this.startup = startup;
38
38
  this._initDataProvider = _initDataProvider;
39
+ this.workerUrl = workerUrl;
40
+ this.workerOptions = workerOptions;
39
41
  this._telemetryService = _telemetryService;
40
42
  this._contextService = _contextService;
41
43
  this._labelService = _labelService;
@@ -62,6 +64,7 @@ let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
62
64
  suffixSearchParams.set('debugged', '1');
63
65
  }
64
66
  COI.addSearchParam(suffixSearchParams, true, true);
67
+ suffixSearchParams.set('parentOrigin', mainWindow.origin);
65
68
  const suffix = `?${( suffixSearchParams.toString())}`;
66
69
  const iframeModulePath = `vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html`;
67
70
  if (isWeb) {
@@ -81,7 +84,6 @@ let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
81
84
  .replace('{{commit}}', commit)
82
85
  .replace('{{quality}}', quality));
83
86
  const res = ( new URL(`${baseUrl}/out/${iframeModulePath}${suffix}`));
84
- res.searchParams.set('parentOrigin', mainWindow.origin);
85
87
  res.searchParams.set('salt', stableOriginUUID);
86
88
  return ( res.toString());
87
89
  }
@@ -147,7 +149,8 @@ let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
147
149
  iframe.contentWindow.postMessage({
148
150
  type: event.data.type,
149
151
  data: {
150
- workerUrl: ( ( FileAccess.asBrowserUri('vs/workbench/api/worker/extensionHostWorkerMain.js')).toString(true)),
152
+ workerUrl: this.workerUrl,
153
+ workerOptions: this.workerOptions,
151
154
  fileRoot: globalThis._VSCODE_FILE_ROOT,
152
155
  nls: {
153
156
  messages: getNLSMessages(),
@@ -282,16 +285,16 @@ let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
282
285
  }
283
286
  };
284
287
  WebWorkerExtensionHost = ( __decorate([
285
- ( __param(3, ITelemetryService)),
286
- ( __param(4, IWorkspaceContextService)),
287
- ( __param(5, ILabelService)),
288
- ( __param(6, ILogService)),
289
- ( __param(7, ILoggerService)),
290
- ( __param(8, IBrowserWorkbenchEnvironmentService)),
291
- ( __param(9, IUserDataProfilesService)),
292
- ( __param(10, IProductService)),
293
- ( __param(11, ILayoutService)),
294
- ( __param(12, IStorageService))
288
+ ( __param(5, ITelemetryService)),
289
+ ( __param(6, IWorkspaceContextService)),
290
+ ( __param(7, ILabelService)),
291
+ ( __param(8, ILogService)),
292
+ ( __param(9, ILoggerService)),
293
+ ( __param(10, IBrowserWorkbenchEnvironmentService)),
294
+ ( __param(11, IUserDataProfilesService)),
295
+ ( __param(12, IProductService)),
296
+ ( __param(13, ILayoutService)),
297
+ ( __param(14, IStorageService))
295
298
  ], WebWorkerExtensionHost));
296
299
 
297
300
  export { WebWorkerExtensionHost };