@codingame/monaco-vscode-user-data-profile-service-override 28.4.1 → 29.1.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 +2 -2
- package/vscode/src/vs/workbench/contrib/userDataProfile/browser/userDataProfile.js +26 -27
- package/vscode/src/vs/workbench/contrib/userDataProfile/browser/userDataProfileActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/userDataProfile/browser/userDataProfilesEditor.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/userDataProfile/browser/userDataProfilesEditor.js +83 -79
- package/vscode/src/vs/workbench/contrib/userDataProfile/browser/userDataProfilesEditorModel.js +26 -26
- package/vscode/src/vs/workbench/services/userDataProfile/browser/extensionsResource.js +5 -5
- package/vscode/src/vs/workbench/services/userDataProfile/browser/globalStateResource.js +1 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/keybindingsResource.js +1 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/mcpProfileResource.js +1 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/settingsResource.js +1 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/snippetsResource.js +2 -2
- package/vscode/src/vs/workbench/services/userDataProfile/browser/tasksResource.js +1 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/userDataProfileImportExportService.js +41 -40
- package/vscode/src/vs/workbench/services/userDataProfile/browser/userDataProfileInit.js +2 -1
- package/vscode/src/vs/workbench/services/userDataProfile/browser/userDataProfileManagement.js +10 -9
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-user-data-profile-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "29.1.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - user-data-profile service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-api": "
|
|
18
|
+
"@codingame/monaco-vscode-api": "29.1.0"
|
|
19
19
|
},
|
|
20
20
|
"main": "index.js",
|
|
21
21
|
"module": "index.js",
|
|
@@ -24,7 +24,6 @@ import { EditorPaneDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/wor
|
|
|
24
24
|
import { EditorExtensions } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/editor';
|
|
25
25
|
import { UserDataProfilesEditorInput, UserDataProfilesEditor, UserDataProfilesEditorInputSerializer } from './userDataProfilesEditor.js';
|
|
26
26
|
import { SyncDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors';
|
|
27
|
-
import { MODAL_GROUP } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService';
|
|
28
27
|
import { IEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
29
28
|
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
30
29
|
import { IHostService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/host/browser/host.service';
|
|
@@ -104,12 +103,12 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
104
103
|
return false;
|
|
105
104
|
}
|
|
106
105
|
async openProfilesEditor() {
|
|
107
|
-
const editor = await this.editorService.openEditor(( new UserDataProfilesEditorInput(this.instantiationService))
|
|
106
|
+
const editor = await this.editorService.openEditor(( new UserDataProfilesEditorInput(this.instantiationService)));
|
|
108
107
|
return editor;
|
|
109
108
|
}
|
|
110
109
|
registerEditor() {
|
|
111
110
|
( Registry.as(EditorExtensions.EditorPane)).registerEditorPane(
|
|
112
|
-
EditorPaneDescriptor.create(UserDataProfilesEditor, UserDataProfilesEditor.ID, ( localize(
|
|
111
|
+
EditorPaneDescriptor.create(UserDataProfilesEditor, UserDataProfilesEditor.ID, ( localize(14864, "Profiles Editor"))),
|
|
113
112
|
[( new SyncDescriptor(UserDataProfilesEditorInput))]
|
|
114
113
|
);
|
|
115
114
|
( Registry.as(EditorExtensions.EditorFactory)).registerEditorSerializer(UserDataProfilesEditorInput.ID, UserDataProfilesEditorInputSerializer);
|
|
@@ -127,7 +126,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
127
126
|
if (uriIdentityService.extUri.extname(resource) === `.${PROFILE_EXTENSION}`) {
|
|
128
127
|
const template = await userDataProfileImportExportService.resolveProfileTemplate(resource);
|
|
129
128
|
if (!template) {
|
|
130
|
-
notificationService.warn(( localize(
|
|
129
|
+
notificationService.warn(( localize(14865, "The dropped profile is invalid.")));
|
|
131
130
|
editorService.openEditor(textEditorService.createTextEditor({
|
|
132
131
|
resource
|
|
133
132
|
}));
|
|
@@ -165,7 +164,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
165
164
|
}
|
|
166
165
|
registerProfileSubMenu() {
|
|
167
166
|
const getProfilesTitle = () => {
|
|
168
|
-
return localize(
|
|
167
|
+
return localize(14866, "Profile ({0})", this.userDataProfileService.currentProfile.name);
|
|
169
168
|
};
|
|
170
169
|
MenuRegistry.appendMenuItem(MenuId.GlobalActivity, {
|
|
171
170
|
get title() {
|
|
@@ -188,7 +187,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
188
187
|
}
|
|
189
188
|
registerOpenProfileSubMenu() {
|
|
190
189
|
MenuRegistry.appendMenuItem(MenuId.MenubarFileMenu, {
|
|
191
|
-
title: ( localize(
|
|
190
|
+
title: ( localize(14867, "New Window with Profile")),
|
|
192
191
|
submenu: OpenProfileMenu,
|
|
193
192
|
group: "1_new",
|
|
194
193
|
order: 4
|
|
@@ -211,7 +210,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
211
210
|
id: `workbench.profiles.actions.profileEntry.${profile.id}`,
|
|
212
211
|
title: profile.name,
|
|
213
212
|
metadata: {
|
|
214
|
-
description: ( localize2(
|
|
213
|
+
description: ( localize2(14868, "Switch to {0} profile", profile.name))
|
|
215
214
|
},
|
|
216
215
|
toggled: ( ContextKeyExpr.equals(CURRENT_PROFILE_CONTEXT.key, profile.id)),
|
|
217
216
|
menu: [{
|
|
@@ -232,7 +231,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
232
231
|
constructor() {
|
|
233
232
|
super({
|
|
234
233
|
id: `workbench.profiles.actions.newWindowWithProfile`,
|
|
235
|
-
title: ( localize2(
|
|
234
|
+
title: ( localize2(14869, "New Window with Profile...")),
|
|
236
235
|
category: PROFILES_CATEGORY,
|
|
237
236
|
precondition: HAS_PROFILES_CONTEXT,
|
|
238
237
|
f1: true
|
|
@@ -246,8 +245,8 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
246
245
|
label: profile.name,
|
|
247
246
|
profile
|
|
248
247
|
}))), {
|
|
249
|
-
title: ( localize(
|
|
250
|
-
placeHolder: ( localize(
|
|
248
|
+
title: ( localize(14870, "New Window with Profile")),
|
|
249
|
+
placeHolder: ( localize(14871, "Select Profile")),
|
|
251
250
|
canPickMany: false
|
|
252
251
|
});
|
|
253
252
|
if (pick) {
|
|
@@ -267,9 +266,9 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
267
266
|
constructor() {
|
|
268
267
|
super({
|
|
269
268
|
id,
|
|
270
|
-
title: ( localize2(
|
|
269
|
+
title: ( localize2(14872, "{0}", profile.name)),
|
|
271
270
|
metadata: {
|
|
272
|
-
description: ( localize2(
|
|
271
|
+
description: ( localize2(14873, "Open New Window with {0} Profile", profile.name))
|
|
273
272
|
},
|
|
274
273
|
menu: {
|
|
275
274
|
id: OpenProfileMenu,
|
|
@@ -290,7 +289,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
290
289
|
command: {
|
|
291
290
|
id,
|
|
292
291
|
category: PROFILES_CATEGORY,
|
|
293
|
-
title: ( localize2(
|
|
292
|
+
title: ( localize2(14874, "Open {0} Profile", profile.name)),
|
|
294
293
|
precondition
|
|
295
294
|
}
|
|
296
295
|
}));
|
|
@@ -302,7 +301,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
302
301
|
constructor() {
|
|
303
302
|
super({
|
|
304
303
|
id: `workbench.profiles.actions.switchProfile`,
|
|
305
|
-
title: ( localize2(
|
|
304
|
+
title: ( localize2(14875, "Switch Profile...")),
|
|
306
305
|
category: PROFILES_CATEGORY,
|
|
307
306
|
f1: true
|
|
308
307
|
});
|
|
@@ -318,7 +317,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
318
317
|
});
|
|
319
318
|
}
|
|
320
319
|
const result = await quickInputService.pick(items.sort((a, b) => a.profile.name.localeCompare(b.profile.name)), {
|
|
321
|
-
placeHolder: ( localize(
|
|
320
|
+
placeHolder: ( localize(14876, "Select Profile"))
|
|
322
321
|
});
|
|
323
322
|
if (result) {
|
|
324
323
|
await that.userDataProfileManagementService.switchProfile(result.profile);
|
|
@@ -333,8 +332,8 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
333
332
|
super({
|
|
334
333
|
id: `workbench.profiles.actions.manageProfiles`,
|
|
335
334
|
title: {
|
|
336
|
-
...( localize2(
|
|
337
|
-
mnemonicTitle: ( localize(
|
|
335
|
+
...( localize2(14877, "Profiles")),
|
|
336
|
+
mnemonicTitle: ( localize(14878, "&&Profiles"))
|
|
338
337
|
},
|
|
339
338
|
menu: [{
|
|
340
339
|
id: MenuId.GlobalActivity,
|
|
@@ -356,14 +355,14 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
356
355
|
run(accessor) {
|
|
357
356
|
const editorService = accessor.get(IEditorService);
|
|
358
357
|
const instantiationService = accessor.get(IInstantiationService);
|
|
359
|
-
return editorService.openEditor(( new UserDataProfilesEditorInput(instantiationService))
|
|
358
|
+
return editorService.openEditor(( new UserDataProfilesEditorInput(instantiationService)));
|
|
360
359
|
}
|
|
361
360
|
}));
|
|
362
361
|
disposables.add(MenuRegistry.appendMenuItem(MenuId.CommandPalette, {
|
|
363
362
|
command: {
|
|
364
363
|
id: "workbench.profiles.actions.manageProfiles",
|
|
365
364
|
category: Categories.Preferences,
|
|
366
|
-
title: ( localize2(
|
|
365
|
+
title: ( localize2(14879, "Open Profiles (UI)"))
|
|
367
366
|
}
|
|
368
367
|
}));
|
|
369
368
|
return disposables;
|
|
@@ -376,7 +375,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
376
375
|
constructor() {
|
|
377
376
|
super({
|
|
378
377
|
id,
|
|
379
|
-
title: ( localize2(
|
|
378
|
+
title: ( localize2(14880, "Export Profile...")),
|
|
380
379
|
category: PROFILES_CATEGORY,
|
|
381
380
|
f1: true
|
|
382
381
|
});
|
|
@@ -390,7 +389,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
390
389
|
command: {
|
|
391
390
|
id,
|
|
392
391
|
title: ( localize2(
|
|
393
|
-
|
|
392
|
+
14881,
|
|
394
393
|
"Export Profile ({0})...",
|
|
395
394
|
that.userDataProfileService.currentProfile.name
|
|
396
395
|
))
|
|
@@ -404,7 +403,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
404
403
|
constructor() {
|
|
405
404
|
super({
|
|
406
405
|
id: "workbench.profiles.actions.createFromCurrentProfile",
|
|
407
|
-
title: ( localize2(
|
|
406
|
+
title: ( localize2(14882, "Save Current Profile As...")),
|
|
408
407
|
category: PROFILES_CATEGORY,
|
|
409
408
|
f1: true
|
|
410
409
|
});
|
|
@@ -421,7 +420,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
421
420
|
constructor() {
|
|
422
421
|
super({
|
|
423
422
|
id: "workbench.profiles.actions.createProfile",
|
|
424
|
-
title: ( localize2(
|
|
423
|
+
title: ( localize2(14883, "New Profile...")),
|
|
425
424
|
category: PROFILES_CATEGORY,
|
|
426
425
|
f1: true,
|
|
427
426
|
menu: [{
|
|
@@ -442,7 +441,7 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
442
441
|
constructor() {
|
|
443
442
|
super({
|
|
444
443
|
id: "workbench.profiles.actions.deleteProfile",
|
|
445
|
-
title: ( localize2(
|
|
444
|
+
title: ( localize2(14884, "Delete Profile...")),
|
|
446
445
|
category: PROFILES_CATEGORY,
|
|
447
446
|
f1: true,
|
|
448
447
|
precondition: HAS_PROFILES_CONTEXT
|
|
@@ -458,11 +457,11 @@ let UserDataProfilesWorkbenchContribution = class UserDataProfilesWorkbenchContr
|
|
|
458
457
|
if (profiles.length) {
|
|
459
458
|
const picks = await quickInputService.pick(( profiles.map(profile => ({
|
|
460
459
|
label: profile.name,
|
|
461
|
-
description: profile.id === userDataProfileService.currentProfile.id ? ( localize(
|
|
460
|
+
description: profile.id === userDataProfileService.currentProfile.id ? ( localize(14885, "Current")) : undefined,
|
|
462
461
|
profile
|
|
463
462
|
}))), {
|
|
464
|
-
title: ( localize(
|
|
465
|
-
placeHolder: ( localize(
|
|
463
|
+
title: ( localize(14886, "Delete Profile...")),
|
|
464
|
+
placeHolder: ( localize(14887, "Select Profiles to Delete")),
|
|
466
465
|
canPickMany: true
|
|
467
466
|
});
|
|
468
467
|
if (picks) {
|
|
@@ -11,7 +11,7 @@ class CreateTransientProfileAction extends Action2 {
|
|
|
11
11
|
this.ID = "workbench.profiles.actions.createTemporaryProfile";
|
|
12
12
|
}
|
|
13
13
|
static {
|
|
14
|
-
this.TITLE = ( localize2(
|
|
14
|
+
this.TITLE = ( localize2(14888, "New Window with Temporary Profile"));
|
|
15
15
|
}
|
|
16
16
|
constructor() {
|
|
17
17
|
super({
|
|
@@ -32,7 +32,7 @@ registerAction2(class CleanupProfilesAction extends Action2 {
|
|
|
32
32
|
constructor() {
|
|
33
33
|
super({
|
|
34
34
|
id: "workbench.profiles.actions.cleanupProfiles",
|
|
35
|
-
title: ( localize2(
|
|
35
|
+
title: ( localize2(14889, "Cleanup Profiles")),
|
|
36
36
|
category: Categories.Developer,
|
|
37
37
|
f1: true
|
|
38
38
|
});
|
|
@@ -45,7 +45,7 @@ registerAction2(class ResetWorkspacesAction extends Action2 {
|
|
|
45
45
|
constructor() {
|
|
46
46
|
super({
|
|
47
47
|
id: "workbench.profiles.actions.resetWorkspaces",
|
|
48
|
-
title: ( localize2(
|
|
48
|
+
title: ( localize2(14890, "Reset Workspace Profiles Associations")),
|
|
49
49
|
category: Categories.Developer,
|
|
50
50
|
f1: true
|
|
51
51
|
});
|
|
@@ -7,7 +7,7 @@ import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platfo
|
|
|
7
7
|
import { IThemeService } from "@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service";
|
|
8
8
|
import { IUserDataProfile } from "@codingame/monaco-vscode-api/vscode/vs/platform/userDataProfile/common/userDataProfile";
|
|
9
9
|
import { EditorPane } from "@codingame/monaco-vscode-api/vscode/vs/workbench/browser/parts/editor/editorPane";
|
|
10
|
-
import { IEditorOpenContext, IEditorSerializer, IUntypedEditorInput } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/editor";
|
|
10
|
+
import { EditorInputCapabilities, IEditorOpenContext, IEditorSerializer, IUntypedEditorInput } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/editor";
|
|
11
11
|
import { EditorInput } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/editor/editorInput";
|
|
12
12
|
import { IUserDataProfilesEditor } from "../common/userDataProfile.js";
|
|
13
13
|
import { IEditorGroup } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorGroupsService";
|
|
@@ -55,6 +55,7 @@ export declare class UserDataProfilesEditorInput extends EditorInput {
|
|
|
55
55
|
private _dirty;
|
|
56
56
|
get dirty(): boolean;
|
|
57
57
|
set dirty(dirty: boolean);
|
|
58
|
+
get capabilities(): EditorInputCapabilities;
|
|
58
59
|
constructor(instantiationService: IInstantiationService);
|
|
59
60
|
get typeId(): string;
|
|
60
61
|
getName(): string;
|