@codingame/monaco-vscode-api 1.83.1 → 1.83.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.
- package/monaco-editor-treemending.patch +555 -555
- package/package.json +1 -1
- package/vscode/src/vs/platform/extensionManagement/common/extensionNls.js +1 -1
- package/vscode/src/vs/platform/workspaces/common/workspaces.js +15 -15
- package/vscode/src/vs/workbench/api/browser/mainThreadCustomEditors.js +49 -51
- package/vscode/src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.js +58 -69
- package/vscode/src/vs/workbench/api/browser/mainThreadFileSystem.js +23 -23
- package/vscode/src/vs/workbench/api/browser/mainThreadWebviews.js +16 -16
- package/vscode/src/vs/workbench/api/common/extHostCommands.js +59 -65
- package/vscode/src/vs/workbench/api/common/extHostConsoleForwarder.js +8 -8
- package/vscode/src/vs/workbench/api/common/extHostLanguageFeatures.js +151 -215
- package/vscode/src/vs/workbench/api/common/extHostSCM.js +54 -58
- package/vscode/src/vs/workbench/api/common/extHostTreeViews.js +53 -55
- package/vscode/src/vs/workbench/api/common/extHostTunnelService.js +28 -28
- package/vscode/src/vs/workbench/api/common/extHostTypeConverters.js +265 -277
- package/vscode/src/vs/workbench/api/common/extensionHostMain.js +17 -19
- package/vscode/src/vs/workbench/api/worker/extHostExtensionService.js +5 -5
- package/vscode/src/vs/workbench/browser/parts/editor/sideBySideEditor.js +26 -32
- package/vscode/src/vs/workbench/browser/parts/editor/textDiffEditor.js +20 -26
- package/vscode/src/vs/workbench/contrib/bulkEdit/browser/bulkFileEdits.js +58 -74
- package/vscode/src/vs/workbench/contrib/comments/browser/commentThreadZoneWidget.js +19 -19
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsTreeViewer.js +32 -36
- package/vscode/src/vs/workbench/contrib/debug/browser/debugColors.js +19 -19
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/model/mapping.js +73 -126
- package/vscode/src/vs/workbench/contrib/snippets/browser/snippetsService.js +66 -74
- package/vscode/src/vs/workbench/contrib/tasks/common/tasks.js +82 -92
- package/vscode/src/vs/workbench/services/extensions/browser/webWorkerExtensionHost.js +27 -29
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.js +122 -124
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManager.js +35 -39
- package/vscode/src/vs/workbench/services/extensions/common/extensionRunningLocationTracker.js +25 -25
- package/vscode/src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.js +30 -32
- package/vscode/src/vs/workbench/services/remote/common/tunnelModel.js +82 -92
- package/vscode/src/vs/workbench/services/textfile/common/textFileEditorModel.js +31 -31
- package/vscode/src/vs/workbench/services/untitled/common/untitledTextEditorService.js +16 -16
- package/vscode/src/vs/workbench/services/workingCopy/common/workingCopyBackupService.js +32 -42
|
@@ -13,7 +13,7 @@ import { Disposable as Disposable$1 } from './extHostTypes.js';
|
|
|
13
13
|
class ExtensionTunnel extends DisposableTunnel {
|
|
14
14
|
}
|
|
15
15
|
var TunnelDtoConverter;
|
|
16
|
-
( (
|
|
16
|
+
( (function(TunnelDtoConverter) {
|
|
17
17
|
function fromApiTunnel(tunnel) {
|
|
18
18
|
return {
|
|
19
19
|
remoteAddress: tunnel.remoteAddress,
|
|
@@ -37,27 +37,27 @@ var TunnelDtoConverter;
|
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
39
|
TunnelDtoConverter.fromServiceTunnel = fromServiceTunnel;
|
|
40
|
-
})(TunnelDtoConverter || (TunnelDtoConverter = {})))
|
|
41
|
-
const IExtHostTunnelService = (
|
|
40
|
+
})(TunnelDtoConverter || (TunnelDtoConverter = {})));
|
|
41
|
+
const IExtHostTunnelService = ( createDecorator('IExtHostTunnelService'));
|
|
42
42
|
let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
43
43
|
constructor(extHostRpc, initData, logService) {
|
|
44
44
|
super();
|
|
45
45
|
this.logService = logService;
|
|
46
46
|
this._showCandidatePort = () => { return Promise.resolve(true); };
|
|
47
|
-
this._extensionTunnels = (
|
|
48
|
-
this._onDidChangeTunnels = (
|
|
47
|
+
this._extensionTunnels = ( new Map());
|
|
48
|
+
this._onDidChangeTunnels = ( new Emitter());
|
|
49
49
|
this.onDidChangeTunnels = this._onDidChangeTunnels.event;
|
|
50
50
|
this._providerHandleCounter = 0;
|
|
51
|
-
this._portAttributesProviders = (
|
|
52
|
-
this._proxy = (
|
|
51
|
+
this._portAttributesProviders = ( new Map());
|
|
52
|
+
this._proxy = ( extHostRpc.getProxy(MainContext.MainThreadTunnelService));
|
|
53
53
|
}
|
|
54
54
|
async openTunnel(extension, forward) {
|
|
55
55
|
this.logService.trace(`ForwardedPorts: (ExtHostTunnelService) ${extension.identifier.value} called openTunnel API for ${forward.remoteAddress.host}:${forward.remoteAddress.port}.`);
|
|
56
56
|
const tunnel = await this._proxy.$openTunnel(forward, extension.displayName);
|
|
57
57
|
if (tunnel) {
|
|
58
|
-
const disposableTunnel = (
|
|
58
|
+
const disposableTunnel = ( new ExtensionTunnel(tunnel.remoteAddress, tunnel.localAddress, () => {
|
|
59
59
|
return this._proxy.$closeTunnel(tunnel.remoteAddress);
|
|
60
|
-
}))
|
|
60
|
+
}));
|
|
61
61
|
this._register(disposableTunnel);
|
|
62
62
|
return disposableTunnel;
|
|
63
63
|
}
|
|
@@ -85,7 +85,7 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
85
85
|
if (!provider) {
|
|
86
86
|
return [];
|
|
87
87
|
}
|
|
88
|
-
providedAttributes.push(...(await Promise.all((
|
|
88
|
+
providedAttributes.push(...(await Promise.all(( ports.map(async (port) => {
|
|
89
89
|
let providedAttributes;
|
|
90
90
|
try {
|
|
91
91
|
providedAttributes = await provider.provider.providePortAttributes({ port, pid, commandLine }, cancellationToken);
|
|
@@ -94,15 +94,15 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
94
94
|
providedAttributes = await provider.provider.providePortAttributes(port, pid, commandLine, cancellationToken);
|
|
95
95
|
}
|
|
96
96
|
return { providedAttributes, port };
|
|
97
|
-
})))))
|
|
97
|
+
})))));
|
|
98
98
|
}
|
|
99
99
|
const allAttributes = providedAttributes.filter(attribute => !!attribute.providedAttributes);
|
|
100
|
-
return (allAttributes.length > 0) ? (
|
|
100
|
+
return (allAttributes.length > 0) ? ( allAttributes.map(attributes => {
|
|
101
101
|
return {
|
|
102
102
|
autoForwardAction: attributes.providedAttributes.autoForwardAction,
|
|
103
103
|
port: attributes.port
|
|
104
104
|
};
|
|
105
|
-
}))
|
|
105
|
+
})) : [];
|
|
106
106
|
}
|
|
107
107
|
async $registerCandidateFinder(_enable) { }
|
|
108
108
|
registerTunnelProvider(provider, information) {
|
|
@@ -110,7 +110,7 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
110
110
|
throw new Error('A tunnel provider has already been registered. Only the first tunnel provider to be registered will be used.');
|
|
111
111
|
}
|
|
112
112
|
this._forwardPortProvider = async (tunnelOptions, tunnelCreationOptions) => {
|
|
113
|
-
const result = await provider.provideTunnel(tunnelOptions, tunnelCreationOptions, (
|
|
113
|
+
const result = await provider.provideTunnel(tunnelOptions, tunnelCreationOptions, ( new CancellationTokenSource()).token);
|
|
114
114
|
return result ?? undefined;
|
|
115
115
|
};
|
|
116
116
|
const tunnelFeatures = information.tunnelFeatures ? {
|
|
@@ -140,12 +140,12 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
140
140
|
privacyOptions = [
|
|
141
141
|
{
|
|
142
142
|
id: 'private',
|
|
143
|
-
label: (
|
|
143
|
+
label: ( nls.localize('tunnelPrivacy.private', "Private")),
|
|
144
144
|
themeIcon: 'lock'
|
|
145
145
|
},
|
|
146
146
|
{
|
|
147
147
|
id: 'public',
|
|
148
|
-
label: (
|
|
148
|
+
label: ( nls.localize('tunnelPrivacy.public', "Public")),
|
|
149
149
|
themeIcon: 'eye'
|
|
150
150
|
}
|
|
151
151
|
];
|
|
@@ -169,9 +169,9 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
169
169
|
return undefined;
|
|
170
170
|
}
|
|
171
171
|
async $closeTunnel(remote, silent) {
|
|
172
|
-
if ((
|
|
172
|
+
if (( this._extensionTunnels.has(remote.host))) {
|
|
173
173
|
const hostMap = this._extensionTunnels.get(remote.host);
|
|
174
|
-
if ((
|
|
174
|
+
if (( hostMap.has(remote.port))) {
|
|
175
175
|
if (silent) {
|
|
176
176
|
hostMap.get(remote.port).disposeListener.dispose();
|
|
177
177
|
}
|
|
@@ -196,8 +196,8 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
196
196
|
this.logService.error('ForwardedPorts: (ExtHostTunnelService) Resolved tunnel is undefined');
|
|
197
197
|
return undefined;
|
|
198
198
|
}
|
|
199
|
-
if (!(
|
|
200
|
-
this._extensionTunnels.set(tunnelOptions.remoteAddress.host, (
|
|
199
|
+
if (!( this._extensionTunnels.has(tunnelOptions.remoteAddress.host))) {
|
|
200
|
+
this._extensionTunnels.set(tunnelOptions.remoteAddress.host, ( new Map()));
|
|
201
201
|
}
|
|
202
202
|
const disposeListener = this._register(tunnel.onDidDispose(() => {
|
|
203
203
|
this.logService.trace('ForwardedPorts: (ExtHostTunnelService) Extension fired tunnel\'s onDidDispose.');
|
|
@@ -220,17 +220,17 @@ let ExtHostTunnelService = class ExtHostTunnelService extends Disposable {
|
|
|
220
220
|
return undefined;
|
|
221
221
|
}
|
|
222
222
|
async $applyCandidateFilter(candidates) {
|
|
223
|
-
const filter = await Promise.all((
|
|
223
|
+
const filter = await Promise.all(( candidates.map(
|
|
224
224
|
candidate => this._showCandidatePort(candidate.host, candidate.port, candidate.detail ?? '')
|
|
225
|
-
)))
|
|
225
|
+
)));
|
|
226
226
|
const result = candidates.filter((candidate, index) => filter[index]);
|
|
227
|
-
this.logService.trace(`ForwardedPorts: (ExtHostTunnelService) filtered from ${(
|
|
227
|
+
this.logService.trace(`ForwardedPorts: (ExtHostTunnelService) filtered from ${( candidates.map(port => port.port)).join(', ')} to ${( result.map(port => port.port)).join(', ')}`);
|
|
228
228
|
return result;
|
|
229
229
|
}
|
|
230
230
|
};
|
|
231
|
-
ExtHostTunnelService = (
|
|
232
|
-
(
|
|
233
|
-
(
|
|
234
|
-
(
|
|
235
|
-
], ExtHostTunnelService))
|
|
231
|
+
ExtHostTunnelService = ( __decorate([
|
|
232
|
+
( __param(0, IExtHostRpcService)),
|
|
233
|
+
( __param(1, IExtHostInitDataService)),
|
|
234
|
+
( __param(2, ILogService))
|
|
235
|
+
], ExtHostTunnelService));
|
|
236
236
|
export { ExtHostTunnelService, IExtHostTunnelService, TunnelDtoConverter };
|