@codingame/monaco-vscode-base-service-override 13.1.7 → 14.0.1
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 +9 -10
- package/vscode/src/vs/workbench/services/configuration/common/jsonEditingService.js +2 -2
- package/vscode/src/vs/workbench/services/decorations/browser/decorationsService.js +1 -1
- package/vscode/src/vs/workbench/services/label/common/labelService.d.ts +2 -1
- package/vscode/src/vs/workbench/services/label/common/labelService.js +20 -17
- package/vscode/src/vs/workbench/services/path/common/pathService.js +1 -1
- package/vscode/src/vs/workbench/services/request/browser/requestService.d.ts +2 -2
- package/vscode/src/vs/workbench/services/request/browser/requestService.js +11 -4
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopySaveParticipant.js +2 -2
- package/vscode/src/vs/workbench/services/workingCopy/common/workingCopyFileService.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-base-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - base service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,15 +15,14 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-039b5553-0838-562a-97c2-30d6e54a7b42-common": "
|
|
19
|
-
"@codingame/monaco-vscode-
|
|
20
|
-
"@codingame/monaco-vscode-
|
|
21
|
-
"@codingame/monaco-vscode-
|
|
22
|
-
"@codingame/monaco-vscode-
|
|
23
|
-
"@codingame/monaco-vscode-
|
|
24
|
-
"@codingame/monaco-vscode-api": "
|
|
25
|
-
"@codingame/monaco-vscode-
|
|
26
|
-
"@codingame/monaco-vscode-d987325e-3e05-53aa-b9ff-6f97476f64db-common": "13.1.7"
|
|
18
|
+
"@codingame/monaco-vscode-039b5553-0838-562a-97c2-30d6e54a7b42-common": "14.0.1",
|
|
19
|
+
"@codingame/monaco-vscode-2cbab29e-9393-5de6-b701-9a9555360b6b-common": "14.0.1",
|
|
20
|
+
"@codingame/monaco-vscode-407531d3-fdae-5387-8c41-49ba0e9574b5-common": "14.0.1",
|
|
21
|
+
"@codingame/monaco-vscode-411e0589-fa79-504b-b32c-80a88847b23a-common": "14.0.1",
|
|
22
|
+
"@codingame/monaco-vscode-91789cdf-e3cb-5a04-aaeb-6f7df7d3d231-common": "14.0.1",
|
|
23
|
+
"@codingame/monaco-vscode-9a1a5840-af83-5d07-a156-ba32a36c5c4b-common": "14.0.1",
|
|
24
|
+
"@codingame/monaco-vscode-api": "14.0.1",
|
|
25
|
+
"@codingame/monaco-vscode-d987325e-3e05-53aa-b9ff-6f97476f64db-common": "14.0.1"
|
|
27
26
|
},
|
|
28
27
|
"main": "index.js",
|
|
29
28
|
"module": "index.js",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
3
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
4
4
|
import { parse } from '@codingame/monaco-vscode-api/vscode/vs/base/common/json';
|
|
5
|
-
import { setProperty } from '@codingame/monaco-vscode-
|
|
5
|
+
import { setProperty } from '@codingame/monaco-vscode-407531d3-fdae-5387-8c41-49ba0e9574b5-common/vscode/vs/base/common/jsonEdit';
|
|
6
6
|
import { Queue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async';
|
|
7
7
|
import { EditOperation } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/editOperation';
|
|
8
8
|
import { Range } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/range';
|
|
@@ -108,7 +108,7 @@ let JSONEditingService = class JSONEditingService {
|
|
|
108
108
|
switch (error) {
|
|
109
109
|
case JSONEditingErrorCode.ERROR_INVALID_FILE: {
|
|
110
110
|
return localize(
|
|
111
|
-
|
|
111
|
+
11516,
|
|
112
112
|
"Unable to write into the file. Please open the file to correct errors/warnings in the file and try again."
|
|
113
113
|
);
|
|
114
114
|
}
|
|
@@ -161,7 +161,7 @@ class DecorationStyles {
|
|
|
161
161
|
const strikethrough = ( data.some(d => d.strikethrough));
|
|
162
162
|
if (onlyChildren) {
|
|
163
163
|
badgeClassName = rule.bubbleBadgeClassName;
|
|
164
|
-
tooltip = ( localize(
|
|
164
|
+
tooltip = ( localize(11555, "Contains emphasized items"));
|
|
165
165
|
}
|
|
166
166
|
return {
|
|
167
167
|
labelClassName,
|
|
@@ -3,7 +3,7 @@ import { IDisposable, Disposable } from "@codingame/monaco-vscode-api/vscode/vs/
|
|
|
3
3
|
import { IWorkbenchEnvironmentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service";
|
|
4
4
|
import { IWorkspace, ISingleFolderWorkspaceIdentifier, IWorkspaceIdentifier } from "@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace";
|
|
5
5
|
import { IWorkspaceContextService } from "@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service";
|
|
6
|
-
import { ResourceLabelFormatter, ResourceLabelFormatting, IFormatterChangeEvent, Verbosity } from "@codingame/monaco-vscode-
|
|
6
|
+
import { ResourceLabelFormatter, ResourceLabelFormatting, IFormatterChangeEvent, Verbosity } from "@codingame/monaco-vscode-2cbab29e-9393-5de6-b701-9a9555360b6b-common/vscode/vs/platform/label/common/label";
|
|
7
7
|
import { ILabelService } from "@codingame/monaco-vscode-api/vscode/vs/platform/label/common/label.service";
|
|
8
8
|
import { ILifecycleService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/lifecycle/common/lifecycle.service";
|
|
9
9
|
import { IPathService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/path/common/pathService.service";
|
|
@@ -29,6 +29,7 @@ export declare class LabelService extends Disposable implements ILabelService {
|
|
|
29
29
|
relative?: boolean;
|
|
30
30
|
noPrefix?: boolean;
|
|
31
31
|
separator?: "/" | "\\";
|
|
32
|
+
appendWorkspaceSuffix?: boolean;
|
|
32
33
|
}): string;
|
|
33
34
|
private doGetUriLabel;
|
|
34
35
|
getUriBasenameLabel(resource: URI): string;
|
|
@@ -12,7 +12,7 @@ import { isWorkspace, toWorkspaceIdentifier, isSingleFolderWorkspaceIdentifier,
|
|
|
12
12
|
import { IWorkspaceContextService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service';
|
|
13
13
|
import { basenameOrAuthority, basename, joinPath, dirname } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
|
|
14
14
|
import { getPathLabel, tildify } from '@codingame/monaco-vscode-api/vscode/vs/base/common/labels';
|
|
15
|
-
import { Verbosity } from '@codingame/monaco-vscode-
|
|
15
|
+
import { Verbosity } from '@codingame/monaco-vscode-2cbab29e-9393-5de6-b701-9a9555360b6b-common/vscode/vs/platform/label/common/label';
|
|
16
16
|
import { ILabelService } from '@codingame/monaco-vscode-api/vscode/vs/platform/label/common/label.service';
|
|
17
17
|
import { ExtensionsRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionsRegistry';
|
|
18
18
|
import { match } from '@codingame/monaco-vscode-api/vscode/vs/base/common/glob';
|
|
@@ -26,12 +26,12 @@ import { IRemoteAgentService } from '@codingame/monaco-vscode-api/vscode/vs/work
|
|
|
26
26
|
import { Schemas } from '@codingame/monaco-vscode-api/vscode/vs/base/common/network';
|
|
27
27
|
import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage';
|
|
28
28
|
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
|
|
29
|
-
import { Memento } from '@codingame/monaco-vscode-
|
|
29
|
+
import { Memento } from '@codingame/monaco-vscode-91789cdf-e3cb-5a04-aaeb-6f7df7d3d231-common/vscode/vs/workbench/common/memento';
|
|
30
30
|
|
|
31
31
|
const resourceLabelFormattersExtPoint = ExtensionsRegistry.registerExtensionPoint({
|
|
32
32
|
extensionPoint: 'resourceLabelFormatters',
|
|
33
33
|
jsonSchema: {
|
|
34
|
-
description: ( localize(
|
|
34
|
+
description: ( localize(11848, 'Contributes resource label formatting rules.')),
|
|
35
35
|
type: 'array',
|
|
36
36
|
items: {
|
|
37
37
|
type: 'object',
|
|
@@ -40,52 +40,52 @@ const resourceLabelFormattersExtPoint = ExtensionsRegistry.registerExtensionPoin
|
|
|
40
40
|
scheme: {
|
|
41
41
|
type: 'string',
|
|
42
42
|
description: ( localize(
|
|
43
|
-
|
|
43
|
+
11849,
|
|
44
44
|
'URI scheme on which to match the formatter on. For example "file". Simple glob patterns are supported.'
|
|
45
45
|
)),
|
|
46
46
|
},
|
|
47
47
|
authority: {
|
|
48
48
|
type: 'string',
|
|
49
49
|
description: ( localize(
|
|
50
|
-
|
|
50
|
+
11850,
|
|
51
51
|
'URI authority on which to match the formatter on. Simple glob patterns are supported.'
|
|
52
52
|
)),
|
|
53
53
|
},
|
|
54
54
|
formatting: {
|
|
55
|
-
description: ( localize(
|
|
55
|
+
description: ( localize(11851, "Rules for formatting uri resource labels.")),
|
|
56
56
|
type: 'object',
|
|
57
57
|
properties: {
|
|
58
58
|
label: {
|
|
59
59
|
type: 'string',
|
|
60
60
|
description: ( localize(
|
|
61
|
-
|
|
61
|
+
11852,
|
|
62
62
|
"Label rules to display. For example: myLabel:/${path}. ${path}, ${scheme}, ${authority} and ${authoritySuffix} are supported as variables."
|
|
63
63
|
))
|
|
64
64
|
},
|
|
65
65
|
separator: {
|
|
66
66
|
type: 'string',
|
|
67
67
|
description: ( localize(
|
|
68
|
-
|
|
68
|
+
11853,
|
|
69
69
|
"Separator to be used in the uri label display. '/' or '\' as an example."
|
|
70
70
|
))
|
|
71
71
|
},
|
|
72
72
|
stripPathStartingSeparator: {
|
|
73
73
|
type: 'boolean',
|
|
74
74
|
description: ( localize(
|
|
75
|
-
|
|
75
|
+
11854,
|
|
76
76
|
"Controls whether `${path}` substitutions should have starting separator characters stripped."
|
|
77
77
|
))
|
|
78
78
|
},
|
|
79
79
|
tildify: {
|
|
80
80
|
type: 'boolean',
|
|
81
81
|
description: ( localize(
|
|
82
|
-
|
|
82
|
+
11855,
|
|
83
83
|
"Controls if the start of the uri label should be tildified when possible."
|
|
84
84
|
))
|
|
85
85
|
},
|
|
86
86
|
workspaceSuffix: {
|
|
87
87
|
type: 'string',
|
|
88
|
-
description: ( localize(
|
|
88
|
+
description: ( localize(11856, "Suffix appended to the workspace label."))
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
}
|
|
@@ -178,9 +178,12 @@ let LabelService = class LabelService extends Disposable {
|
|
|
178
178
|
if (formatting && options.separator) {
|
|
179
179
|
formatting = { ...formatting, separator: options.separator };
|
|
180
180
|
}
|
|
181
|
-
|
|
181
|
+
let label = this.doGetUriLabel(resource, formatting, options);
|
|
182
182
|
if (!formatting && options.separator) {
|
|
183
|
-
|
|
183
|
+
label = label.replace(sepRegexp, options.separator);
|
|
184
|
+
}
|
|
185
|
+
if (options.appendWorkspaceSuffix && formatting?.workspaceSuffix) {
|
|
186
|
+
label = this.appendWorkspaceSuffix(label, resource);
|
|
184
187
|
}
|
|
185
188
|
return label;
|
|
186
189
|
}
|
|
@@ -264,10 +267,10 @@ let LabelService = class LabelService extends Disposable {
|
|
|
264
267
|
}
|
|
265
268
|
doGetWorkspaceLabel(workspaceUri, options) {
|
|
266
269
|
if (isUntitledWorkspace(workspaceUri, this.environmentService)) {
|
|
267
|
-
return localize(
|
|
270
|
+
return localize(11857, "Untitled (Workspace)");
|
|
268
271
|
}
|
|
269
272
|
if (isTemporaryWorkspace(workspaceUri)) {
|
|
270
|
-
return localize(
|
|
273
|
+
return localize(11858, "Workspace");
|
|
271
274
|
}
|
|
272
275
|
let filename = basename(workspaceUri);
|
|
273
276
|
if (filename.endsWith(WORKSPACE_EXTENSION)) {
|
|
@@ -280,14 +283,14 @@ let LabelService = class LabelService extends Disposable {
|
|
|
280
283
|
break;
|
|
281
284
|
case Verbosity.LONG:
|
|
282
285
|
label = ( localize(
|
|
283
|
-
|
|
286
|
+
11859,
|
|
284
287
|
"{0} (Workspace)",
|
|
285
288
|
this.getUriLabel(joinPath(dirname(workspaceUri), filename))
|
|
286
289
|
));
|
|
287
290
|
break;
|
|
288
291
|
case Verbosity.MEDIUM:
|
|
289
292
|
default:
|
|
290
|
-
label = ( localize(
|
|
293
|
+
label = ( localize(11860, "{0} (Workspace)", filename));
|
|
291
294
|
break;
|
|
292
295
|
}
|
|
293
296
|
if (options?.verbose === Verbosity.SHORT) {
|
|
@@ -6,7 +6,7 @@ import { win32, posix } from '@codingame/monaco-vscode-api/vscode/vs/base/common
|
|
|
6
6
|
import { OS, OperatingSystem } from '@codingame/monaco-vscode-api/vscode/vs/base/common/platform';
|
|
7
7
|
import { basename } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
|
|
8
8
|
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri';
|
|
9
|
-
import { getVirtualWorkspaceScheme } from '@codingame/monaco-vscode-
|
|
9
|
+
import { getVirtualWorkspaceScheme } from '@codingame/monaco-vscode-2cbab29e-9393-5de6-b701-9a9555360b6b-common/vscode/vs/platform/workspace/common/virtualWorkspace';
|
|
10
10
|
import { IWorkspaceContextService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service';
|
|
11
11
|
import { IWorkbenchEnvironmentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service';
|
|
12
12
|
import { IRemoteAgentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/remote/common/remoteAgentService.service';
|
|
@@ -4,12 +4,12 @@ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/pl
|
|
|
4
4
|
import { IRemoteAgentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/remote/common/remoteAgentService.service";
|
|
5
5
|
import { AbstractRequestService, AuthInfo, Credentials } from "@codingame/monaco-vscode-api/vscode/vs/platform/request/common/request";
|
|
6
6
|
import { IRequestService } from "@codingame/monaco-vscode-api/vscode/vs/platform/request/common/request.service";
|
|
7
|
-
import {
|
|
7
|
+
import { ILoggerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
|
|
8
8
|
export declare class BrowserRequestService extends AbstractRequestService implements IRequestService {
|
|
9
9
|
private readonly remoteAgentService;
|
|
10
10
|
private readonly configurationService;
|
|
11
11
|
readonly _serviceBrand: undefined;
|
|
12
|
-
constructor(remoteAgentService: IRemoteAgentService, configurationService: IConfigurationService,
|
|
12
|
+
constructor(remoteAgentService: IRemoteAgentService, configurationService: IConfigurationService, loggerService: ILoggerService);
|
|
13
13
|
request(options: IRequestOptions, token: CancellationToken): Promise<IRequestContext>;
|
|
14
14
|
resolveProxy(url: string): Promise<string | undefined>;
|
|
15
15
|
lookupAuthorization(authInfo: AuthInfo): Promise<Credentials | undefined>;
|
|
@@ -6,18 +6,25 @@ import { IRemoteAgentService } from '@codingame/monaco-vscode-api/vscode/vs/work
|
|
|
6
6
|
import { CommandsRegistry } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands';
|
|
7
7
|
import { AbstractRequestService } from '@codingame/monaco-vscode-api/vscode/vs/platform/request/common/request';
|
|
8
8
|
import { request } from '../../../../base/parts/request/common/requestImpl.js';
|
|
9
|
-
import {
|
|
9
|
+
import { ILoggerService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service';
|
|
10
|
+
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
11
|
+
import { LogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/logService';
|
|
12
|
+
import { windowLogGroup } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/log/common/logConstants';
|
|
10
13
|
|
|
11
14
|
let BrowserRequestService = class BrowserRequestService extends AbstractRequestService {
|
|
12
|
-
constructor(remoteAgentService, configurationService,
|
|
15
|
+
constructor(remoteAgentService, configurationService, loggerService) {
|
|
16
|
+
const logger = loggerService.createLogger(`network`, { name: ( localize(11964, "Network")), group: windowLogGroup });
|
|
17
|
+
const logService = ( new LogService(logger));
|
|
13
18
|
super(logService);
|
|
14
19
|
this.remoteAgentService = remoteAgentService;
|
|
15
20
|
this.configurationService = configurationService;
|
|
21
|
+
this._register(logger);
|
|
22
|
+
this._register(logService);
|
|
16
23
|
}
|
|
17
24
|
async request(options, token) {
|
|
18
25
|
try {
|
|
19
26
|
if (!options.proxyAuthorization) {
|
|
20
|
-
options.proxyAuthorization = this.configurationService.
|
|
27
|
+
options.proxyAuthorization = this.configurationService.inspect('http.proxyAuthorization').userLocalValue;
|
|
21
28
|
}
|
|
22
29
|
const context = await this.logAndRequest(options, () => request(options, token, () => navigator.onLine));
|
|
23
30
|
const connection = this.remoteAgentService.getConnection();
|
|
@@ -53,7 +60,7 @@ let BrowserRequestService = class BrowserRequestService extends AbstractRequestS
|
|
|
53
60
|
BrowserRequestService = ( __decorate([
|
|
54
61
|
( __param(0, IRemoteAgentService)),
|
|
55
62
|
( __param(1, IConfigurationService)),
|
|
56
|
-
( __param(2,
|
|
63
|
+
( __param(2, ILoggerService))
|
|
57
64
|
], BrowserRequestService));
|
|
58
65
|
CommandsRegistry.registerCommand('_workbench.fetchJSON', async function (accessor, url, method) {
|
|
59
66
|
const result = await fetch(url, { method, headers: { Accept: 'application/json' } });
|
package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopySaveParticipant.js
CHANGED
|
@@ -27,13 +27,13 @@ let StoredFileWorkingCopySaveParticipant = class StoredFileWorkingCopySavePartic
|
|
|
27
27
|
const cts = ( new CancellationTokenSource(token));
|
|
28
28
|
workingCopy.model?.pushStackElement();
|
|
29
29
|
progress.report({
|
|
30
|
-
message: ( localize(
|
|
30
|
+
message: ( localize(12346, "Running Code Actions and Formatters..."))
|
|
31
31
|
});
|
|
32
32
|
let bubbleCancel = false;
|
|
33
33
|
await this.progressService.withProgress({
|
|
34
34
|
priority: NotificationPriority.URGENT,
|
|
35
35
|
location: ProgressLocation.Notification,
|
|
36
|
-
cancellable: ( localize(
|
|
36
|
+
cancellable: ( localize(12347, "Skip")),
|
|
37
37
|
delay: workingCopy.isDirty() ? 5000 : 3000
|
|
38
38
|
}, async (progress) => {
|
|
39
39
|
for (const saveParticipant of this.saveParticipants) {
|
|
@@ -6,7 +6,7 @@ import { FileOperation, IFileStatWithMetadata } from "@codingame/monaco-vscode-a
|
|
|
6
6
|
import { IFileService } from "@codingame/monaco-vscode-api/vscode/vs/platform/files/common/files.service";
|
|
7
7
|
import { CancellationToken } from "@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation";
|
|
8
8
|
import { IWorkingCopyService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/workingCopy/common/workingCopyService.service";
|
|
9
|
-
import { IWorkingCopy } from "@codingame/monaco-vscode-
|
|
9
|
+
import { IWorkingCopy } from "@codingame/monaco-vscode-ce8c4b18-4e75-55dd-9656-517347af9de7-common/vscode/vs/workbench/services/workingCopy/common/workingCopy";
|
|
10
10
|
import { IUriIdentityService } from "@codingame/monaco-vscode-api/vscode/vs/platform/uriIdentity/common/uriIdentity.service";
|
|
11
11
|
import { VSBuffer, VSBufferReadable, VSBufferReadableStream } from "@codingame/monaco-vscode-api/vscode/vs/base/common/buffer";
|
|
12
12
|
import { SaveReason } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/editor";
|