@codingame/monaco-vscode-extensions-service-override 36.1.1 → 36.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-extensions-service-override",
|
|
3
|
-
"version": "36.
|
|
3
|
+
"version": "36.2.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - extensions service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-api": "36.
|
|
19
|
-
"@codingame/monaco-vscode-files-service-override": "36.
|
|
18
|
+
"@codingame/monaco-vscode-api": "36.2.0",
|
|
19
|
+
"@codingame/monaco-vscode-files-service-override": "36.2.0"
|
|
20
20
|
},
|
|
21
21
|
"main": "index.js",
|
|
22
22
|
"module": "index.js",
|
|
@@ -89,19 +89,23 @@ let WebWorkerExtensionHost = class WebWorkerExtensionHost extends Disposable {
|
|
|
89
89
|
const webEndpointUrlTemplate = this._productService.webEndpointUrlTemplate;
|
|
90
90
|
const commit = this._productService.commit;
|
|
91
91
|
const quality = this._productService.quality;
|
|
92
|
+
const key = "webWorkerExtensionHostIframeStableOriginUUID";
|
|
93
|
+
let stableOriginUUID = this._storageService.get(key, StorageScope.WORKSPACE);
|
|
94
|
+
if (typeof stableOriginUUID === "undefined") {
|
|
95
|
+
stableOriginUUID = generateUuid();
|
|
96
|
+
this._storageService.store(key, stableOriginUUID, StorageScope.WORKSPACE, StorageTarget.MACHINE);
|
|
97
|
+
}
|
|
98
|
+
const hash = await parentOriginHash(mainWindow.origin, stableOriginUUID);
|
|
99
|
+
const uuid = `v--${hash}`;
|
|
92
100
|
if (webEndpointUrlTemplate && commit && quality) {
|
|
93
|
-
const key = "webWorkerExtensionHostIframeStableOriginUUID";
|
|
94
|
-
let stableOriginUUID = this._storageService.get(key, StorageScope.WORKSPACE);
|
|
95
|
-
if (typeof stableOriginUUID === "undefined") {
|
|
96
|
-
stableOriginUUID = generateUuid();
|
|
97
|
-
this._storageService.store(key, stableOriginUUID, StorageScope.WORKSPACE, StorageTarget.MACHINE);
|
|
98
|
-
}
|
|
99
|
-
const hash = await parentOriginHash(mainWindow.origin, stableOriginUUID);
|
|
100
101
|
const baseUrl = (
|
|
101
|
-
webEndpointUrlTemplate.replace("{{uuid}}",
|
|
102
|
+
webEndpointUrlTemplate.replace("{{uuid}}", uuid).replace("{{commit}}", commit).replace("{{quality}}", quality));
|
|
102
103
|
const res = ( new URL(`${baseUrl}/out/${iframeModulePath}${suffix}`));
|
|
103
104
|
res.searchParams.set("salt", stableOriginUUID);
|
|
104
105
|
return ( res.toString());
|
|
106
|
+
} else {
|
|
107
|
+
const relativeExtensionHostIframeSrc = ( ( FileAccess.asBrowserUri(iframeModulePath)).toString(true));
|
|
108
|
+
return `${relativeExtensionHostIframeSrc.replace("{{uuid}}", uuid)}${suffix}`;
|
|
105
109
|
}
|
|
106
110
|
}
|
|
107
111
|
const relativeExtensionHostIframeSrc = this._webWorkerService.getWorkerUrl(( new WebWorkerDescriptor({
|