@codingame/monaco-vscode-keybindings-service-override 15.0.3 → 16.0.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 +12 -9
- package/vscode/src/vs/platform/keyboardLayout/common/keyboardConfig.js +3 -3
- package/vscode/src/vs/workbench/browser/contextkeys.js +1 -1
- package/vscode/src/vs/workbench/contrib/commands/common/commands.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/keybindings/browser/keybindings.contribution.js +1 -1
- package/vscode/src/vs/workbench/contrib/preferences/browser/keybindingsEditorContribution.js +4 -4
- package/vscode/src/vs/workbench/services/actions/common/menusExtensionPoint.js +142 -135
- package/vscode/src/vs/workbench/services/keybinding/browser/keybindingService.js +24 -24
- package/vscode/src/vs/workbench/services/keybinding/browser/keyboardLayoutService.js +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-keybindings-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "16.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - keybindings service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,14 +15,14 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-2a22c7b4-b906-5914-8cd1-3ed912fb738f-common": "
|
|
19
|
-
"@codingame/monaco-vscode-
|
|
20
|
-
"@codingame/monaco-vscode-
|
|
21
|
-
"@codingame/monaco-vscode-7559b0be-bfa5-5fe6-b731-1973fe9fffa1-common": "
|
|
22
|
-
"@codingame/monaco-vscode-
|
|
23
|
-
"@codingame/monaco-vscode-
|
|
24
|
-
"@codingame/monaco-vscode-d609a7d3-bf87-551a-884f-550a8b327ec5-common": "
|
|
25
|
-
"@codingame/monaco-vscode-files-service-override": "
|
|
18
|
+
"@codingame/monaco-vscode-2a22c7b4-b906-5914-8cd1-3ed912fb738f-common": "16.0.0",
|
|
19
|
+
"@codingame/monaco-vscode-2b1a9082-790f-527f-b013-d1b29d6265a3-common": "16.0.0",
|
|
20
|
+
"@codingame/monaco-vscode-40cada32-7e9c-528a-81fc-766e4da54147-common": "16.0.0",
|
|
21
|
+
"@codingame/monaco-vscode-7559b0be-bfa5-5fe6-b731-1973fe9fffa1-common": "16.0.0",
|
|
22
|
+
"@codingame/monaco-vscode-api": "16.0.0",
|
|
23
|
+
"@codingame/monaco-vscode-b1110435-a331-5549-ab1e-aa3d763c3a1f-common": "16.0.0",
|
|
24
|
+
"@codingame/monaco-vscode-d609a7d3-bf87-551a-884f-550a8b327ec5-common": "16.0.0",
|
|
25
|
+
"@codingame/monaco-vscode-files-service-override": "16.0.0"
|
|
26
26
|
},
|
|
27
27
|
"main": "index.js",
|
|
28
28
|
"module": "index.js",
|
|
@@ -31,6 +31,9 @@
|
|
|
31
31
|
".": {
|
|
32
32
|
"default": "./index.js"
|
|
33
33
|
},
|
|
34
|
+
"./vscode/*.css": {
|
|
35
|
+
"default": "./vscode/src/*.css"
|
|
36
|
+
},
|
|
34
37
|
"./vscode/*": {
|
|
35
38
|
"types": "./vscode/src/*.d.ts",
|
|
36
39
|
"default": "./vscode/src/*.js"
|
|
@@ -20,7 +20,7 @@ const keyboardConfiguration = {
|
|
|
20
20
|
'id': 'keyboard',
|
|
21
21
|
'order': 15,
|
|
22
22
|
'type': 'object',
|
|
23
|
-
'title': ( localize(
|
|
23
|
+
'title': ( localize(1873, "Keyboard")),
|
|
24
24
|
'properties': {
|
|
25
25
|
'keyboard.dispatch': {
|
|
26
26
|
scope: ConfigurationScope.APPLICATION,
|
|
@@ -28,7 +28,7 @@ const keyboardConfiguration = {
|
|
|
28
28
|
enum: ['code', 'keyCode'],
|
|
29
29
|
default: 'code',
|
|
30
30
|
markdownDescription: ( localize(
|
|
31
|
-
|
|
31
|
+
1874,
|
|
32
32
|
"Controls the dispatching logic for key presses to use either `code` (recommended) or `keyCode`."
|
|
33
33
|
)),
|
|
34
34
|
included: OS === OperatingSystem.Macintosh || OS === OperatingSystem.Linux
|
|
@@ -37,7 +37,7 @@ const keyboardConfiguration = {
|
|
|
37
37
|
scope: ConfigurationScope.APPLICATION,
|
|
38
38
|
type: 'boolean',
|
|
39
39
|
default: false,
|
|
40
|
-
markdownDescription: ( localize(
|
|
40
|
+
markdownDescription: ( localize(1875, "Controls if the AltGraph+ modifier should be treated as Ctrl+Alt+.")),
|
|
41
41
|
included: OS === OperatingSystem.Windows
|
|
42
42
|
}
|
|
43
43
|
}
|
|
@@ -13,7 +13,7 @@ import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/pl
|
|
|
13
13
|
import { IWorkbenchEnvironmentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/environment/common/environmentService.service';
|
|
14
14
|
import { WorkbenchState, isTemporaryWorkspace } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace';
|
|
15
15
|
import { IWorkspaceContextService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service';
|
|
16
|
-
import { positionToString, Parts } from '@codingame/monaco-vscode-
|
|
16
|
+
import { positionToString, Parts } from '@codingame/monaco-vscode-b1110435-a331-5549-ab1e-aa3d763c3a1f-common/vscode/vs/workbench/services/layout/browser/layoutService';
|
|
17
17
|
import { IWorkbenchLayoutService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
18
18
|
import { getRemoteName } from '@codingame/monaco-vscode-api/vscode/vs/platform/remote/common/remoteHosts';
|
|
19
19
|
import { getVirtualWorkspaceScheme } from '@codingame/monaco-vscode-7559b0be-bfa5-5fe6-b731-1973fe9fffa1-common/vscode/vs/platform/workspace/common/virtualWorkspace';
|
|
@@ -10,10 +10,10 @@ class RunCommands extends Action2 {
|
|
|
10
10
|
constructor() {
|
|
11
11
|
super({
|
|
12
12
|
id: 'runCommands',
|
|
13
|
-
title: ( localize2(
|
|
13
|
+
title: ( localize2(5169, "Run Commands")),
|
|
14
14
|
f1: false,
|
|
15
15
|
metadata: {
|
|
16
|
-
description: ( localize(
|
|
16
|
+
description: ( localize(5170, "Run several commands")),
|
|
17
17
|
args: [
|
|
18
18
|
{
|
|
19
19
|
name: 'args',
|
|
@@ -23,7 +23,7 @@ class RunCommands extends Action2 {
|
|
|
23
23
|
properties: {
|
|
24
24
|
commands: {
|
|
25
25
|
type: 'array',
|
|
26
|
-
description: ( localize(
|
|
26
|
+
description: ( localize(5171, "Commands to run")),
|
|
27
27
|
items: {
|
|
28
28
|
anyOf: [
|
|
29
29
|
{
|
|
@@ -63,14 +63,14 @@ class RunCommands extends Action2 {
|
|
|
63
63
|
const notificationService = accessor.get(INotificationService);
|
|
64
64
|
if (!this._isCommandArgs(args)) {
|
|
65
65
|
notificationService.error(( localize(
|
|
66
|
-
|
|
66
|
+
5172,
|
|
67
67
|
"'runCommands' has received an argument with incorrect type. Please, review the argument passed to the command."
|
|
68
68
|
)));
|
|
69
69
|
return;
|
|
70
70
|
}
|
|
71
71
|
if (args.commands.length === 0) {
|
|
72
72
|
notificationService.warn(( localize(
|
|
73
|
-
|
|
73
|
+
5173,
|
|
74
74
|
"'runCommands' has not received commands to run. Did you forget to pass commands in the 'runCommands' argument?"
|
|
75
75
|
)));
|
|
76
76
|
return;
|
|
@@ -16,7 +16,7 @@ class ToggleKeybindingsLogAction extends Action2 {
|
|
|
16
16
|
constructor() {
|
|
17
17
|
super({
|
|
18
18
|
id: 'workbench.action.toggleKeybindingsLog',
|
|
19
|
-
title: ( localize2(
|
|
19
|
+
title: ( localize2(7339, "Toggle Keyboard Shortcuts Troubleshooting")),
|
|
20
20
|
category: Categories.Developer,
|
|
21
21
|
f1: true
|
|
22
22
|
});
|
package/vscode/src/vs/workbench/contrib/preferences/browser/keybindingsEditorContribution.js
CHANGED
|
@@ -20,11 +20,11 @@ import { KeybindingParser } from '@codingame/monaco-vscode-2a22c7b4-b906-5914-8c
|
|
|
20
20
|
import { assertIsDefined } from '@codingame/monaco-vscode-api/vscode/vs/base/common/types';
|
|
21
21
|
import { isEqual } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
|
|
22
22
|
import { IUserDataProfileService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/userDataProfile/common/userDataProfile.service';
|
|
23
|
-
import { DEFINE_KEYBINDING_EDITOR_CONTRIB_ID } from '@codingame/monaco-vscode-
|
|
23
|
+
import { DEFINE_KEYBINDING_EDITOR_CONTRIB_ID } from '@codingame/monaco-vscode-2b1a9082-790f-527f-b013-d1b29d6265a3-common/vscode/vs/workbench/services/preferences/common/preferences';
|
|
24
24
|
|
|
25
25
|
var KeybindingEditorDecorationsRenderer_1;
|
|
26
26
|
const NLS_KB_LAYOUT_ERROR_MESSAGE = ( localize(
|
|
27
|
-
|
|
27
|
+
8473,
|
|
28
28
|
"You won't be able to produce this key combination under your current keyboard layout."
|
|
29
29
|
));
|
|
30
30
|
let DefineKeybindingEditorContribution = class DefineKeybindingEditorContribution extends Disposable {
|
|
@@ -182,14 +182,14 @@ let KeybindingEditorDecorationsRenderer = KeybindingEditorDecorationsRenderer_1
|
|
|
182
182
|
else {
|
|
183
183
|
if (usLabel && uiLabel !== usLabel) {
|
|
184
184
|
msg = ( new MarkdownString(( localize(
|
|
185
|
-
|
|
185
|
+
8474,
|
|
186
186
|
"**{0}** for your current keyboard layout (**{1}** for US standard).",
|
|
187
187
|
uiLabel,
|
|
188
188
|
usLabel
|
|
189
189
|
))));
|
|
190
190
|
}
|
|
191
191
|
else {
|
|
192
|
-
msg = ( new MarkdownString(( localize(
|
|
192
|
+
msg = ( new MarkdownString(( localize(8475, "**{0}** for your current keyboard layout.", uiLabel))));
|
|
193
193
|
}
|
|
194
194
|
className = 'keybindingInfo';
|
|
195
195
|
overviewRulerColor = themeColorFromId(overviewRulerInfo);
|
|
@@ -21,215 +21,215 @@ const apiMenus = [
|
|
|
21
21
|
{
|
|
22
22
|
key: 'commandPalette',
|
|
23
23
|
id: MenuId.CommandPalette,
|
|
24
|
-
description: ( localize(
|
|
24
|
+
description: ( localize(11785, "The Command Palette")),
|
|
25
25
|
supportsSubmenus: false
|
|
26
26
|
},
|
|
27
27
|
{
|
|
28
28
|
key: 'touchBar',
|
|
29
29
|
id: MenuId.TouchBarContext,
|
|
30
|
-
description: ( localize(
|
|
30
|
+
description: ( localize(11786, "The touch bar (macOS only)")),
|
|
31
31
|
supportsSubmenus: false
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
34
|
key: 'editor/title',
|
|
35
35
|
id: MenuId.EditorTitle,
|
|
36
|
-
description: ( localize(
|
|
36
|
+
description: ( localize(11787, "The editor title menu"))
|
|
37
37
|
},
|
|
38
38
|
{
|
|
39
39
|
key: 'editor/title/run',
|
|
40
40
|
id: MenuId.EditorTitleRun,
|
|
41
|
-
description: ( localize(
|
|
41
|
+
description: ( localize(11788, "Run submenu inside the editor title menu"))
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
key: 'editor/context',
|
|
45
45
|
id: MenuId.EditorContext,
|
|
46
|
-
description: ( localize(
|
|
46
|
+
description: ( localize(11789, "The editor context menu"))
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
49
|
key: 'editor/context/copy',
|
|
50
50
|
id: MenuId.EditorContextCopy,
|
|
51
|
-
description: ( localize(
|
|
51
|
+
description: ( localize(11790, "'Copy as' submenu in the editor context menu"))
|
|
52
52
|
},
|
|
53
53
|
{
|
|
54
54
|
key: 'editor/context/share',
|
|
55
55
|
id: MenuId.EditorContextShare,
|
|
56
|
-
description: ( localize(
|
|
56
|
+
description: ( localize(11791, "'Share' submenu in the editor context menu")),
|
|
57
57
|
proposed: 'contribShareMenu'
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
key: 'explorer/context',
|
|
61
61
|
id: MenuId.ExplorerContext,
|
|
62
|
-
description: ( localize(
|
|
62
|
+
description: ( localize(11792, "The file explorer context menu"))
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
key: 'explorer/context/share',
|
|
66
66
|
id: MenuId.ExplorerContextShare,
|
|
67
|
-
description: ( localize(
|
|
67
|
+
description: ( localize(11793, "'Share' submenu in the file explorer context menu")),
|
|
68
68
|
proposed: 'contribShareMenu'
|
|
69
69
|
},
|
|
70
70
|
{
|
|
71
71
|
key: 'editor/title/context',
|
|
72
72
|
id: MenuId.EditorTitleContext,
|
|
73
|
-
description: ( localize(
|
|
73
|
+
description: ( localize(11794, "The editor tabs context menu"))
|
|
74
74
|
},
|
|
75
75
|
{
|
|
76
76
|
key: 'editor/title/context/share',
|
|
77
77
|
id: MenuId.EditorTitleContextShare,
|
|
78
|
-
description: ( localize(
|
|
78
|
+
description: ( localize(11795, "'Share' submenu inside the editor title context menu")),
|
|
79
79
|
proposed: 'contribShareMenu'
|
|
80
80
|
},
|
|
81
81
|
{
|
|
82
82
|
key: 'debug/callstack/context',
|
|
83
83
|
id: MenuId.DebugCallStackContext,
|
|
84
|
-
description: ( localize(
|
|
84
|
+
description: ( localize(11796, "The debug callstack view context menu"))
|
|
85
85
|
},
|
|
86
86
|
{
|
|
87
87
|
key: 'debug/variables/context',
|
|
88
88
|
id: MenuId.DebugVariablesContext,
|
|
89
|
-
description: ( localize(
|
|
89
|
+
description: ( localize(11797, "The debug variables view context menu"))
|
|
90
90
|
},
|
|
91
91
|
{
|
|
92
92
|
key: 'debug/toolBar',
|
|
93
93
|
id: MenuId.DebugToolBar,
|
|
94
|
-
description: ( localize(
|
|
94
|
+
description: ( localize(11798, "The debug toolbar menu"))
|
|
95
95
|
},
|
|
96
96
|
{
|
|
97
97
|
key: 'debug/createConfiguration',
|
|
98
98
|
id: MenuId.DebugCreateConfiguration,
|
|
99
99
|
proposed: 'contribDebugCreateConfiguration',
|
|
100
|
-
description: ( localize(
|
|
100
|
+
description: ( localize(11799, "The debug create configuration menu"))
|
|
101
101
|
},
|
|
102
102
|
{
|
|
103
103
|
key: 'notebook/variables/context',
|
|
104
104
|
id: MenuId.NotebookVariablesContext,
|
|
105
|
-
description: ( localize(
|
|
105
|
+
description: ( localize(11800, "The notebook variables view context menu"))
|
|
106
106
|
},
|
|
107
107
|
{
|
|
108
108
|
key: 'menuBar/home',
|
|
109
109
|
id: MenuId.MenubarHomeMenu,
|
|
110
|
-
description: ( localize(
|
|
110
|
+
description: ( localize(11801, "The home indicator context menu (web only)")),
|
|
111
111
|
proposed: 'contribMenuBarHome',
|
|
112
112
|
supportsSubmenus: false
|
|
113
113
|
},
|
|
114
114
|
{
|
|
115
115
|
key: 'menuBar/edit/copy',
|
|
116
116
|
id: MenuId.MenubarCopy,
|
|
117
|
-
description: ( localize(
|
|
117
|
+
description: ( localize(11802, "'Copy as' submenu in the top level Edit menu"))
|
|
118
118
|
},
|
|
119
119
|
{
|
|
120
120
|
key: 'scm/title',
|
|
121
121
|
id: MenuId.SCMTitle,
|
|
122
|
-
description: ( localize(
|
|
122
|
+
description: ( localize(11803, "The Source Control title menu"))
|
|
123
123
|
},
|
|
124
124
|
{
|
|
125
125
|
key: 'scm/sourceControl',
|
|
126
126
|
id: MenuId.SCMSourceControl,
|
|
127
|
-
description: ( localize(
|
|
127
|
+
description: ( localize(11804, "The Source Control menu"))
|
|
128
128
|
},
|
|
129
129
|
{
|
|
130
130
|
key: 'scm/sourceControl/title',
|
|
131
131
|
id: MenuId.SCMSourceControlTitle,
|
|
132
|
-
description: ( localize(
|
|
132
|
+
description: ( localize(11805, "The Source Control title menu")),
|
|
133
133
|
proposed: 'contribSourceControlTitleMenu'
|
|
134
134
|
},
|
|
135
135
|
{
|
|
136
136
|
key: 'scm/resourceState/context',
|
|
137
137
|
id: MenuId.SCMResourceContext,
|
|
138
|
-
description: ( localize(
|
|
138
|
+
description: ( localize(11806, "The Source Control resource state context menu"))
|
|
139
139
|
},
|
|
140
140
|
{
|
|
141
141
|
key: 'scm/resourceFolder/context',
|
|
142
142
|
id: MenuId.SCMResourceFolderContext,
|
|
143
|
-
description: ( localize(
|
|
143
|
+
description: ( localize(11807, "The Source Control resource folder context menu"))
|
|
144
144
|
},
|
|
145
145
|
{
|
|
146
146
|
key: 'scm/resourceGroup/context',
|
|
147
147
|
id: MenuId.SCMResourceGroupContext,
|
|
148
|
-
description: ( localize(
|
|
148
|
+
description: ( localize(11808, "The Source Control resource group context menu"))
|
|
149
149
|
},
|
|
150
150
|
{
|
|
151
151
|
key: 'scm/change/title',
|
|
152
152
|
id: MenuId.SCMChangeContext,
|
|
153
|
-
description: ( localize(
|
|
153
|
+
description: ( localize(11809, "The Source Control inline change menu"))
|
|
154
154
|
},
|
|
155
155
|
{
|
|
156
156
|
key: 'scm/inputBox',
|
|
157
157
|
id: MenuId.SCMInputBox,
|
|
158
|
-
description: ( localize(
|
|
158
|
+
description: ( localize(11810, "The Source Control input box menu")),
|
|
159
159
|
proposed: 'contribSourceControlInputBoxMenu'
|
|
160
160
|
},
|
|
161
161
|
{
|
|
162
162
|
key: 'scm/history/title',
|
|
163
163
|
id: MenuId.SCMHistoryTitle,
|
|
164
|
-
description: ( localize(
|
|
164
|
+
description: ( localize(11811, "The Source Control History title menu")),
|
|
165
165
|
proposed: 'contribSourceControlHistoryTitleMenu'
|
|
166
166
|
},
|
|
167
167
|
{
|
|
168
168
|
key: 'scm/historyItem/context',
|
|
169
169
|
id: MenuId.SCMHistoryItemContext,
|
|
170
|
-
description: ( localize(
|
|
170
|
+
description: ( localize(11812, "The Source Control history item context menu")),
|
|
171
171
|
proposed: 'contribSourceControlHistoryItemMenu'
|
|
172
172
|
},
|
|
173
173
|
{
|
|
174
174
|
key: 'scm/historyItem/hover',
|
|
175
175
|
id: MenuId.SCMHistoryItemHover,
|
|
176
|
-
description: ( localize(
|
|
176
|
+
description: ( localize(11813, "The Source Control history item hover menu")),
|
|
177
177
|
proposed: 'contribSourceControlHistoryItemMenu'
|
|
178
178
|
},
|
|
179
179
|
{
|
|
180
180
|
key: 'scm/historyItemRef/context',
|
|
181
181
|
id: MenuId.SCMHistoryItemRefContext,
|
|
182
|
-
description: ( localize(
|
|
182
|
+
description: ( localize(11814, "The Source Control history item reference context menu")),
|
|
183
183
|
proposed: 'contribSourceControlHistoryItemMenu'
|
|
184
184
|
},
|
|
185
185
|
{
|
|
186
186
|
key: 'statusBar/remoteIndicator',
|
|
187
187
|
id: MenuId.StatusBarRemoteIndicatorMenu,
|
|
188
|
-
description: ( localize(
|
|
188
|
+
description: ( localize(11815, "The remote indicator menu in the status bar")),
|
|
189
189
|
supportsSubmenus: false
|
|
190
190
|
},
|
|
191
191
|
{
|
|
192
192
|
key: 'terminal/context',
|
|
193
193
|
id: MenuId.TerminalInstanceContext,
|
|
194
|
-
description: ( localize(
|
|
194
|
+
description: ( localize(11816, "The terminal context menu"))
|
|
195
195
|
},
|
|
196
196
|
{
|
|
197
197
|
key: 'terminal/title/context',
|
|
198
198
|
id: MenuId.TerminalTabContext,
|
|
199
|
-
description: ( localize(
|
|
199
|
+
description: ( localize(11817, "The terminal tabs context menu"))
|
|
200
200
|
},
|
|
201
201
|
{
|
|
202
202
|
key: 'view/title',
|
|
203
203
|
id: MenuId.ViewTitle,
|
|
204
|
-
description: ( localize(
|
|
204
|
+
description: ( localize(11818, "The contributed view title menu"))
|
|
205
205
|
},
|
|
206
206
|
{
|
|
207
207
|
key: 'viewContainer/title',
|
|
208
208
|
id: MenuId.ViewContainerTitle,
|
|
209
|
-
description: ( localize(
|
|
209
|
+
description: ( localize(11819, "The contributed view container title menu")),
|
|
210
210
|
proposed: 'contribViewContainerTitle'
|
|
211
211
|
},
|
|
212
212
|
{
|
|
213
213
|
key: 'view/item/context',
|
|
214
214
|
id: MenuId.ViewItemContext,
|
|
215
|
-
description: ( localize(
|
|
215
|
+
description: ( localize(11820, "The contributed view item context menu"))
|
|
216
216
|
},
|
|
217
217
|
{
|
|
218
218
|
key: 'comments/comment/editorActions',
|
|
219
219
|
id: MenuId.CommentEditorActions,
|
|
220
|
-
description: ( localize(
|
|
220
|
+
description: ( localize(11821, "The contributed comment editor actions")),
|
|
221
221
|
proposed: 'contribCommentEditorActionsMenu'
|
|
222
222
|
},
|
|
223
223
|
{
|
|
224
224
|
key: 'comments/commentThread/title',
|
|
225
225
|
id: MenuId.CommentThreadTitle,
|
|
226
|
-
description: ( localize(
|
|
226
|
+
description: ( localize(11822, "The contributed comment thread title menu"))
|
|
227
227
|
},
|
|
228
228
|
{
|
|
229
229
|
key: 'comments/commentThread/context',
|
|
230
230
|
id: MenuId.CommentThreadActions,
|
|
231
231
|
description: ( localize(
|
|
232
|
-
|
|
232
|
+
11823,
|
|
233
233
|
"The contributed comment thread context menu, rendered as buttons below the comment editor"
|
|
234
234
|
)),
|
|
235
235
|
supportsSubmenus: false
|
|
@@ -238,7 +238,7 @@ const apiMenus = [
|
|
|
238
238
|
key: 'comments/commentThread/additionalActions',
|
|
239
239
|
id: MenuId.CommentThreadAdditionalActions,
|
|
240
240
|
description: ( localize(
|
|
241
|
-
|
|
241
|
+
11823,
|
|
242
242
|
"The contributed comment thread context menu, rendered as buttons below the comment editor"
|
|
243
243
|
)),
|
|
244
244
|
supportsSubmenus: true,
|
|
@@ -248,7 +248,7 @@ const apiMenus = [
|
|
|
248
248
|
key: 'comments/commentThread/title/context',
|
|
249
249
|
id: MenuId.CommentThreadTitleContext,
|
|
250
250
|
description: ( localize(
|
|
251
|
-
|
|
251
|
+
11824,
|
|
252
252
|
"The contributed comment thread title's peek context menu, rendered as a right click menu on the comment thread's peek title."
|
|
253
253
|
)),
|
|
254
254
|
proposed: 'contribCommentPeekContext'
|
|
@@ -256,13 +256,13 @@ const apiMenus = [
|
|
|
256
256
|
{
|
|
257
257
|
key: 'comments/comment/title',
|
|
258
258
|
id: MenuId.CommentTitle,
|
|
259
|
-
description: ( localize(
|
|
259
|
+
description: ( localize(11825, "The contributed comment title menu"))
|
|
260
260
|
},
|
|
261
261
|
{
|
|
262
262
|
key: 'comments/comment/context',
|
|
263
263
|
id: MenuId.CommentActions,
|
|
264
264
|
description: ( localize(
|
|
265
|
-
|
|
265
|
+
11826,
|
|
266
266
|
"The contributed comment context menu, rendered as buttons below the comment editor"
|
|
267
267
|
)),
|
|
268
268
|
supportsSubmenus: false
|
|
@@ -271,7 +271,7 @@ const apiMenus = [
|
|
|
271
271
|
key: 'comments/commentThread/comment/context',
|
|
272
272
|
id: MenuId.CommentThreadCommentContext,
|
|
273
273
|
description: ( localize(
|
|
274
|
-
|
|
274
|
+
11827,
|
|
275
275
|
"The contributed comment context menu, rendered as a right click menu on the an individual comment in the comment thread's peek view."
|
|
276
276
|
)),
|
|
277
277
|
proposed: 'contribCommentPeekContext'
|
|
@@ -279,113 +279,113 @@ const apiMenus = [
|
|
|
279
279
|
{
|
|
280
280
|
key: 'commentsView/commentThread/context',
|
|
281
281
|
id: MenuId.CommentsViewThreadActions,
|
|
282
|
-
description: ( localize(
|
|
282
|
+
description: ( localize(11828, "The contributed comment thread context menu in the comments view")),
|
|
283
283
|
proposed: 'contribCommentsViewThreadMenus'
|
|
284
284
|
},
|
|
285
285
|
{
|
|
286
286
|
key: 'notebook/toolbar',
|
|
287
287
|
id: MenuId.NotebookToolbar,
|
|
288
|
-
description: ( localize(
|
|
288
|
+
description: ( localize(11829, "The contributed notebook toolbar menu"))
|
|
289
289
|
},
|
|
290
290
|
{
|
|
291
291
|
key: 'notebook/kernelSource',
|
|
292
292
|
id: MenuId.NotebookKernelSource,
|
|
293
|
-
description: ( localize(
|
|
293
|
+
description: ( localize(11830, "The contributed notebook kernel sources menu")),
|
|
294
294
|
proposed: 'notebookKernelSource'
|
|
295
295
|
},
|
|
296
296
|
{
|
|
297
297
|
key: 'notebook/cell/title',
|
|
298
298
|
id: MenuId.NotebookCellTitle,
|
|
299
|
-
description: ( localize(
|
|
299
|
+
description: ( localize(11831, "The contributed notebook cell title menu"))
|
|
300
300
|
},
|
|
301
301
|
{
|
|
302
302
|
key: 'notebook/cell/execute',
|
|
303
303
|
id: MenuId.NotebookCellExecute,
|
|
304
|
-
description: ( localize(
|
|
304
|
+
description: ( localize(11832, "The contributed notebook cell execution menu"))
|
|
305
305
|
},
|
|
306
306
|
{
|
|
307
307
|
key: 'interactive/toolbar',
|
|
308
308
|
id: MenuId.InteractiveToolbar,
|
|
309
|
-
description: ( localize(
|
|
309
|
+
description: ( localize(11833, "The contributed interactive toolbar menu")),
|
|
310
310
|
},
|
|
311
311
|
{
|
|
312
312
|
key: 'interactive/cell/title',
|
|
313
313
|
id: MenuId.InteractiveCellTitle,
|
|
314
|
-
description: ( localize(
|
|
314
|
+
description: ( localize(11834, "The contributed interactive cell title menu")),
|
|
315
315
|
},
|
|
316
316
|
{
|
|
317
317
|
key: 'issue/reporter',
|
|
318
318
|
id: MenuId.IssueReporter,
|
|
319
|
-
description: ( localize(
|
|
319
|
+
description: ( localize(11835, "The contributed issue reporter menu"))
|
|
320
320
|
},
|
|
321
321
|
{
|
|
322
322
|
key: 'testing/item/context',
|
|
323
323
|
id: MenuId.TestItem,
|
|
324
|
-
description: ( localize(
|
|
324
|
+
description: ( localize(11836, "The contributed test item menu")),
|
|
325
325
|
},
|
|
326
326
|
{
|
|
327
327
|
key: 'testing/item/gutter',
|
|
328
328
|
id: MenuId.TestItemGutter,
|
|
329
|
-
description: ( localize(
|
|
329
|
+
description: ( localize(11837, "The menu for a gutter decoration for a test item")),
|
|
330
330
|
},
|
|
331
331
|
{
|
|
332
332
|
key: 'testing/profiles/context',
|
|
333
333
|
id: MenuId.TestProfilesContext,
|
|
334
|
-
description: ( localize(
|
|
334
|
+
description: ( localize(11838, "The menu for configuring testing profiles.")),
|
|
335
335
|
},
|
|
336
336
|
{
|
|
337
337
|
key: 'testing/item/result',
|
|
338
338
|
id: MenuId.TestPeekElement,
|
|
339
|
-
description: ( localize(
|
|
339
|
+
description: ( localize(11839, "The menu for an item in the Test Results view or peek.")),
|
|
340
340
|
},
|
|
341
341
|
{
|
|
342
342
|
key: 'testing/message/context',
|
|
343
343
|
id: MenuId.TestMessageContext,
|
|
344
344
|
description: ( localize(
|
|
345
|
-
|
|
345
|
+
11840,
|
|
346
346
|
"A prominent button overlaying editor content where the message is displayed"
|
|
347
347
|
)),
|
|
348
348
|
},
|
|
349
349
|
{
|
|
350
350
|
key: 'testing/message/content',
|
|
351
351
|
id: MenuId.TestMessageContent,
|
|
352
|
-
description: ( localize(
|
|
352
|
+
description: ( localize(11841, "Context menu for the message in the results tree")),
|
|
353
353
|
},
|
|
354
354
|
{
|
|
355
355
|
key: 'extension/context',
|
|
356
356
|
id: MenuId.ExtensionContext,
|
|
357
|
-
description: ( localize(
|
|
357
|
+
description: ( localize(11842, "The extension context menu"))
|
|
358
358
|
},
|
|
359
359
|
{
|
|
360
360
|
key: 'timeline/title',
|
|
361
361
|
id: MenuId.TimelineTitle,
|
|
362
|
-
description: ( localize(
|
|
362
|
+
description: ( localize(11843, "The Timeline view title menu"))
|
|
363
363
|
},
|
|
364
364
|
{
|
|
365
365
|
key: 'timeline/item/context',
|
|
366
366
|
id: MenuId.TimelineItemContext,
|
|
367
|
-
description: ( localize(
|
|
367
|
+
description: ( localize(11844, "The Timeline view item context menu"))
|
|
368
368
|
},
|
|
369
369
|
{
|
|
370
370
|
key: 'ports/item/context',
|
|
371
371
|
id: MenuId.TunnelContext,
|
|
372
|
-
description: ( localize(
|
|
372
|
+
description: ( localize(11845, "The Ports view item context menu"))
|
|
373
373
|
},
|
|
374
374
|
{
|
|
375
375
|
key: 'ports/item/origin/inline',
|
|
376
376
|
id: MenuId.TunnelOriginInline,
|
|
377
|
-
description: ( localize(
|
|
377
|
+
description: ( localize(11846, "The Ports view item origin inline menu"))
|
|
378
378
|
},
|
|
379
379
|
{
|
|
380
380
|
key: 'ports/item/port/inline',
|
|
381
381
|
id: MenuId.TunnelPortInline,
|
|
382
|
-
description: ( localize(
|
|
382
|
+
description: ( localize(11847, "The Ports view item port inline menu"))
|
|
383
383
|
},
|
|
384
384
|
{
|
|
385
385
|
key: 'file/newFile',
|
|
386
386
|
id: MenuId.NewFile,
|
|
387
387
|
description: ( localize(
|
|
388
|
-
|
|
388
|
+
11848,
|
|
389
389
|
"The 'New File...' quick pick, shown on welcome page and File menu."
|
|
390
390
|
)),
|
|
391
391
|
supportsSubmenus: false,
|
|
@@ -393,63 +393,70 @@ const apiMenus = [
|
|
|
393
393
|
{
|
|
394
394
|
key: 'webview/context',
|
|
395
395
|
id: MenuId.WebviewContext,
|
|
396
|
-
description: ( localize(
|
|
396
|
+
description: ( localize(11849, "The webview context menu"))
|
|
397
397
|
},
|
|
398
398
|
{
|
|
399
399
|
key: 'file/share',
|
|
400
400
|
id: MenuId.MenubarShare,
|
|
401
|
-
description: ( localize(
|
|
401
|
+
description: ( localize(11850, "Share submenu shown in the top level File menu.")),
|
|
402
402
|
proposed: 'contribShareMenu'
|
|
403
403
|
},
|
|
404
404
|
{
|
|
405
405
|
key: 'editor/inlineCompletions/actions',
|
|
406
406
|
id: MenuId.InlineCompletionsActions,
|
|
407
|
-
description: ( localize(
|
|
407
|
+
description: ( localize(11851, "The actions shown when hovering on an inline completion")),
|
|
408
408
|
supportsSubmenus: false,
|
|
409
409
|
proposed: 'inlineCompletionsAdditions'
|
|
410
410
|
},
|
|
411
411
|
{
|
|
412
412
|
key: 'editor/content',
|
|
413
413
|
id: MenuId.EditorContent,
|
|
414
|
-
description: ( localize(
|
|
414
|
+
description: ( localize(11852, "The prominent button in an editor, overlays its content")),
|
|
415
415
|
proposed: 'contribEditorContentMenu'
|
|
416
416
|
},
|
|
417
417
|
{
|
|
418
418
|
key: 'editor/lineNumber/context',
|
|
419
419
|
id: MenuId.EditorLineNumberContext,
|
|
420
|
-
description: ( localize(
|
|
420
|
+
description: ( localize(11853, "The contributed editor line number context menu"))
|
|
421
421
|
},
|
|
422
422
|
{
|
|
423
423
|
key: 'mergeEditor/result/title',
|
|
424
424
|
id: MenuId.MergeInputResultToolbar,
|
|
425
|
-
description: ( localize(
|
|
425
|
+
description: ( localize(11854, "The result toolbar of the merge editor")),
|
|
426
426
|
proposed: 'contribMergeEditorMenus'
|
|
427
427
|
},
|
|
428
428
|
{
|
|
429
429
|
key: 'multiDiffEditor/resource/title',
|
|
430
430
|
id: MenuId.MultiDiffEditorFileToolbar,
|
|
431
|
-
description: ( localize(
|
|
431
|
+
description: ( localize(11855, "The resource toolbar in the multi diff editor")),
|
|
432
432
|
proposed: 'contribMultiDiffEditorMenus'
|
|
433
433
|
},
|
|
434
434
|
{
|
|
435
435
|
key: 'diffEditor/gutter/hunk',
|
|
436
436
|
id: MenuId.DiffEditorHunkToolbar,
|
|
437
|
-
description: ( localize(
|
|
437
|
+
description: ( localize(11856, "The gutter toolbar in the diff editor")),
|
|
438
438
|
proposed: 'contribDiffEditorGutterToolBarMenus'
|
|
439
439
|
},
|
|
440
440
|
{
|
|
441
441
|
key: 'diffEditor/gutter/selection',
|
|
442
442
|
id: MenuId.DiffEditorSelectionToolbar,
|
|
443
|
-
description: ( localize(
|
|
443
|
+
description: ( localize(11856, "The gutter toolbar in the diff editor")),
|
|
444
444
|
proposed: 'contribDiffEditorGutterToolBarMenus'
|
|
445
445
|
},
|
|
446
446
|
{
|
|
447
447
|
key: 'searchPanel/aiResults/commands',
|
|
448
448
|
id: MenuId.SearchActionMenu,
|
|
449
449
|
description: ( localize(
|
|
450
|
-
|
|
450
|
+
11857,
|
|
451
451
|
"The commands that will contribute to the menu rendered as buttons next to the AI search title"
|
|
452
452
|
)),
|
|
453
|
+
},
|
|
454
|
+
{
|
|
455
|
+
key: 'chat/modelPicker',
|
|
456
|
+
id: MenuId.ChatModelPicker,
|
|
457
|
+
description: ( localize(11858, "The chat model picker dropdown menu")),
|
|
458
|
+
supportsSubmenus: false,
|
|
459
|
+
proposed: 'chatParticipantPrivate'
|
|
453
460
|
}
|
|
454
461
|
];
|
|
455
462
|
var schema;
|
|
@@ -461,23 +468,23 @@ var schema;
|
|
|
461
468
|
function isValidMenuItem(item, collector) {
|
|
462
469
|
if (typeof item.command !== 'string') {
|
|
463
470
|
collector.error(( localize(
|
|
464
|
-
|
|
471
|
+
11859,
|
|
465
472
|
"property `{0}` is mandatory and must be of type `string`",
|
|
466
473
|
'command'
|
|
467
474
|
)));
|
|
468
475
|
return false;
|
|
469
476
|
}
|
|
470
477
|
if (item.alt && typeof item.alt !== 'string') {
|
|
471
|
-
collector.error(( localize(
|
|
478
|
+
collector.error(( localize(11860, "property `{0}` can be omitted or must be of type `string`", 'alt')));
|
|
472
479
|
return false;
|
|
473
480
|
}
|
|
474
481
|
if (item.when && typeof item.when !== 'string') {
|
|
475
|
-
collector.error(( localize(
|
|
482
|
+
collector.error(( localize(11860, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
476
483
|
return false;
|
|
477
484
|
}
|
|
478
485
|
if (item.group && typeof item.group !== 'string') {
|
|
479
486
|
collector.error(( localize(
|
|
480
|
-
|
|
487
|
+
11860,
|
|
481
488
|
"property `{0}` can be omitted or must be of type `string`",
|
|
482
489
|
'group'
|
|
483
490
|
)));
|
|
@@ -489,19 +496,19 @@ var schema;
|
|
|
489
496
|
function isValidSubmenuItem(item, collector) {
|
|
490
497
|
if (typeof item.submenu !== 'string') {
|
|
491
498
|
collector.error(( localize(
|
|
492
|
-
|
|
499
|
+
11859,
|
|
493
500
|
"property `{0}` is mandatory and must be of type `string`",
|
|
494
501
|
'submenu'
|
|
495
502
|
)));
|
|
496
503
|
return false;
|
|
497
504
|
}
|
|
498
505
|
if (item.when && typeof item.when !== 'string') {
|
|
499
|
-
collector.error(( localize(
|
|
506
|
+
collector.error(( localize(11860, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
500
507
|
return false;
|
|
501
508
|
}
|
|
502
509
|
if (item.group && typeof item.group !== 'string') {
|
|
503
510
|
collector.error(( localize(
|
|
504
|
-
|
|
511
|
+
11860,
|
|
505
512
|
"property `{0}` can be omitted or must be of type `string`",
|
|
506
513
|
'group'
|
|
507
514
|
)));
|
|
@@ -512,7 +519,7 @@ var schema;
|
|
|
512
519
|
schema.isValidSubmenuItem = isValidSubmenuItem;
|
|
513
520
|
function isValidItems(items, collector) {
|
|
514
521
|
if (!Array.isArray(items)) {
|
|
515
|
-
collector.error(( localize(
|
|
522
|
+
collector.error(( localize(11861, "submenu items must be an array")));
|
|
516
523
|
return false;
|
|
517
524
|
}
|
|
518
525
|
for (const item of items) {
|
|
@@ -532,15 +539,15 @@ var schema;
|
|
|
532
539
|
schema.isValidItems = isValidItems;
|
|
533
540
|
function isValidSubmenu(submenu, collector) {
|
|
534
541
|
if (typeof submenu !== 'object') {
|
|
535
|
-
collector.error(( localize(
|
|
542
|
+
collector.error(( localize(11862, "submenu items must be an object")));
|
|
536
543
|
return false;
|
|
537
544
|
}
|
|
538
545
|
if (typeof submenu.id !== 'string') {
|
|
539
|
-
collector.error(( localize(
|
|
546
|
+
collector.error(( localize(11859, "property `{0}` is mandatory and must be of type `string`", 'id')));
|
|
540
547
|
return false;
|
|
541
548
|
}
|
|
542
549
|
if (typeof submenu.label !== 'string') {
|
|
543
|
-
collector.error(( localize(
|
|
550
|
+
collector.error(( localize(11859, "property `{0}` is mandatory and must be of type `string`", 'label')));
|
|
544
551
|
return false;
|
|
545
552
|
}
|
|
546
553
|
return true;
|
|
@@ -552,24 +559,24 @@ var schema;
|
|
|
552
559
|
properties: {
|
|
553
560
|
command: {
|
|
554
561
|
description: ( localize(
|
|
555
|
-
|
|
562
|
+
11863,
|
|
556
563
|
'Identifier of the command to execute. The command must be declared in the \'commands\'-section'
|
|
557
564
|
)),
|
|
558
565
|
type: 'string'
|
|
559
566
|
},
|
|
560
567
|
alt: {
|
|
561
568
|
description: ( localize(
|
|
562
|
-
|
|
569
|
+
11864,
|
|
563
570
|
'Identifier of an alternative command to execute. The command must be declared in the \'commands\'-section'
|
|
564
571
|
)),
|
|
565
572
|
type: 'string'
|
|
566
573
|
},
|
|
567
574
|
when: {
|
|
568
|
-
description: ( localize(
|
|
575
|
+
description: ( localize(11865, 'Condition which must be true to show this item')),
|
|
569
576
|
type: 'string'
|
|
570
577
|
},
|
|
571
578
|
group: {
|
|
572
|
-
description: ( localize(
|
|
579
|
+
description: ( localize(11866, 'Group into which this item belongs')),
|
|
573
580
|
type: 'string'
|
|
574
581
|
}
|
|
575
582
|
}
|
|
@@ -579,15 +586,15 @@ var schema;
|
|
|
579
586
|
required: ['submenu'],
|
|
580
587
|
properties: {
|
|
581
588
|
submenu: {
|
|
582
|
-
description: ( localize(
|
|
589
|
+
description: ( localize(11867, 'Identifier of the submenu to display in this item.')),
|
|
583
590
|
type: 'string'
|
|
584
591
|
},
|
|
585
592
|
when: {
|
|
586
|
-
description: ( localize(
|
|
593
|
+
description: ( localize(11865, 'Condition which must be true to show this item')),
|
|
587
594
|
type: 'string'
|
|
588
595
|
},
|
|
589
596
|
group: {
|
|
590
|
-
description: ( localize(
|
|
597
|
+
description: ( localize(11866, 'Group into which this item belongs')),
|
|
591
598
|
type: 'string'
|
|
592
599
|
}
|
|
593
600
|
}
|
|
@@ -597,16 +604,16 @@ var schema;
|
|
|
597
604
|
required: ['id', 'label'],
|
|
598
605
|
properties: {
|
|
599
606
|
id: {
|
|
600
|
-
description: ( localize(
|
|
607
|
+
description: ( localize(11868, 'Identifier of the menu to display as a submenu.')),
|
|
601
608
|
type: 'string'
|
|
602
609
|
},
|
|
603
610
|
label: {
|
|
604
|
-
description: ( localize(
|
|
611
|
+
description: ( localize(11869, 'The label of the menu item which leads to this submenu.')),
|
|
605
612
|
type: 'string'
|
|
606
613
|
},
|
|
607
614
|
icon: {
|
|
608
615
|
description: ( localize(
|
|
609
|
-
|
|
616
|
+
11870,
|
|
610
617
|
'(Optional) Icon which is used to represent the submenu in the UI. Either a file path, an object with file paths for dark and light themes, or a theme icon references, like `\\$(zap)`'
|
|
611
618
|
)),
|
|
612
619
|
anyOf: [{
|
|
@@ -616,11 +623,11 @@ var schema;
|
|
|
616
623
|
type: 'object',
|
|
617
624
|
properties: {
|
|
618
625
|
light: {
|
|
619
|
-
description: ( localize(
|
|
626
|
+
description: ( localize(11871, 'Icon path when a light theme is used')),
|
|
620
627
|
type: 'string'
|
|
621
628
|
},
|
|
622
629
|
dark: {
|
|
623
|
-
description: ( localize(
|
|
630
|
+
description: ( localize(11872, 'Icon path when a dark theme is used')),
|
|
624
631
|
type: 'string'
|
|
625
632
|
}
|
|
626
633
|
}
|
|
@@ -629,11 +636,11 @@ var schema;
|
|
|
629
636
|
}
|
|
630
637
|
};
|
|
631
638
|
schema.menusContribution = {
|
|
632
|
-
description: ( localize(
|
|
639
|
+
description: ( localize(11873, "Contributes menu items to the editor")),
|
|
633
640
|
type: 'object',
|
|
634
641
|
properties: index(apiMenus, menu => menu.key, menu => ({
|
|
635
642
|
markdownDescription: menu.proposed ? ( localize(
|
|
636
|
-
|
|
643
|
+
11874,
|
|
637
644
|
"Proposed API, requires `enabledApiProposal: [\"{0}\"]` - {1}",
|
|
638
645
|
menu.proposed,
|
|
639
646
|
menu.description
|
|
@@ -648,18 +655,18 @@ var schema;
|
|
|
648
655
|
}
|
|
649
656
|
};
|
|
650
657
|
schema.submenusContribution = {
|
|
651
|
-
description: ( localize(
|
|
658
|
+
description: ( localize(11875, "Contributes submenu items to the editor")),
|
|
652
659
|
type: 'array',
|
|
653
660
|
items: submenu
|
|
654
661
|
};
|
|
655
662
|
function isValidCommand(command, collector) {
|
|
656
663
|
if (!command) {
|
|
657
|
-
collector.error(( localize(
|
|
664
|
+
collector.error(( localize(11876, "expected non-empty value.")));
|
|
658
665
|
return false;
|
|
659
666
|
}
|
|
660
667
|
if (isFalsyOrWhitespace(command.command)) {
|
|
661
668
|
collector.error(( localize(
|
|
662
|
-
|
|
669
|
+
11859,
|
|
663
670
|
"property `{0}` is mandatory and must be of type `string`",
|
|
664
671
|
'command'
|
|
665
672
|
)));
|
|
@@ -673,7 +680,7 @@ var schema;
|
|
|
673
680
|
}
|
|
674
681
|
if (command.enablement && typeof command.enablement !== 'string') {
|
|
675
682
|
collector.error(( localize(
|
|
676
|
-
|
|
683
|
+
11860,
|
|
677
684
|
"property `{0}` can be omitted or must be of type `string`",
|
|
678
685
|
'precondition'
|
|
679
686
|
)));
|
|
@@ -699,7 +706,7 @@ var schema;
|
|
|
699
706
|
return true;
|
|
700
707
|
}
|
|
701
708
|
collector.error(( localize(
|
|
702
|
-
|
|
709
|
+
11877,
|
|
703
710
|
"property `icon` can be omitted or must be either a string or a literal like `{dark, light}`"
|
|
704
711
|
)));
|
|
705
712
|
return false;
|
|
@@ -707,7 +714,7 @@ var schema;
|
|
|
707
714
|
function isValidLocalizedString(localized, collector, propertyName) {
|
|
708
715
|
if (typeof localized === 'undefined') {
|
|
709
716
|
collector.error(( localize(
|
|
710
|
-
|
|
717
|
+
11878,
|
|
711
718
|
"property `{0}` is mandatory and must be of type `string` or `object`",
|
|
712
719
|
propertyName
|
|
713
720
|
)));
|
|
@@ -715,7 +722,7 @@ var schema;
|
|
|
715
722
|
}
|
|
716
723
|
else if (typeof localized === 'string' && isFalsyOrWhitespace(localized)) {
|
|
717
724
|
collector.error(( localize(
|
|
718
|
-
|
|
725
|
+
11859,
|
|
719
726
|
"property `{0}` is mandatory and must be of type `string`",
|
|
720
727
|
propertyName
|
|
721
728
|
)));
|
|
@@ -723,7 +730,7 @@ var schema;
|
|
|
723
730
|
}
|
|
724
731
|
else if (typeof localized !== 'string' && (isFalsyOrWhitespace(localized.original) || isFalsyOrWhitespace(localized.value))) {
|
|
725
732
|
collector.error(( localize(
|
|
726
|
-
|
|
733
|
+
11879,
|
|
727
734
|
"properties `{0}` and `{1}` are mandatory and must be of type `string`",
|
|
728
735
|
`${propertyName}.value`,
|
|
729
736
|
`${propertyName}.original`
|
|
@@ -737,37 +744,37 @@ var schema;
|
|
|
737
744
|
required: ['command', 'title'],
|
|
738
745
|
properties: {
|
|
739
746
|
command: {
|
|
740
|
-
description: ( localize(
|
|
747
|
+
description: ( localize(11880, 'Identifier of the command to execute')),
|
|
741
748
|
type: 'string'
|
|
742
749
|
},
|
|
743
750
|
title: {
|
|
744
|
-
description: ( localize(
|
|
751
|
+
description: ( localize(11881, 'Title by which the command is represented in the UI')),
|
|
745
752
|
type: 'string'
|
|
746
753
|
},
|
|
747
754
|
shortTitle: {
|
|
748
755
|
markdownDescription: ( localize(
|
|
749
|
-
|
|
756
|
+
11882,
|
|
750
757
|
'(Optional) Short title by which the command is represented in the UI. Menus pick either `title` or `shortTitle` depending on the context in which they show commands.'
|
|
751
758
|
)),
|
|
752
759
|
type: 'string'
|
|
753
760
|
},
|
|
754
761
|
category: {
|
|
755
762
|
description: ( localize(
|
|
756
|
-
|
|
763
|
+
11883,
|
|
757
764
|
'(Optional) Category string by which the command is grouped in the UI'
|
|
758
765
|
)),
|
|
759
766
|
type: 'string'
|
|
760
767
|
},
|
|
761
768
|
enablement: {
|
|
762
769
|
description: ( localize(
|
|
763
|
-
|
|
770
|
+
11884,
|
|
764
771
|
'(Optional) Condition which must be true to enable the command in the UI (menu and keybindings). Does not prevent executing the command by other means, like the `executeCommand`-api.'
|
|
765
772
|
)),
|
|
766
773
|
type: 'string'
|
|
767
774
|
},
|
|
768
775
|
icon: {
|
|
769
776
|
description: ( localize(
|
|
770
|
-
|
|
777
|
+
11885,
|
|
771
778
|
'(Optional) Icon which is used to represent the command in the UI. Either a file path, an object with file paths for dark and light themes, or a theme icon references, like `\\$(zap)`'
|
|
772
779
|
)),
|
|
773
780
|
anyOf: [{
|
|
@@ -777,11 +784,11 @@ var schema;
|
|
|
777
784
|
type: 'object',
|
|
778
785
|
properties: {
|
|
779
786
|
light: {
|
|
780
|
-
description: ( localize(
|
|
787
|
+
description: ( localize(11886, 'Icon path when a light theme is used')),
|
|
781
788
|
type: 'string'
|
|
782
789
|
},
|
|
783
790
|
dark: {
|
|
784
|
-
description: ( localize(
|
|
791
|
+
description: ( localize(11887, 'Icon path when a dark theme is used')),
|
|
785
792
|
type: 'string'
|
|
786
793
|
}
|
|
787
794
|
}
|
|
@@ -790,7 +797,7 @@ var schema;
|
|
|
790
797
|
}
|
|
791
798
|
};
|
|
792
799
|
schema.commandsContribution = {
|
|
793
|
-
description: ( localize(
|
|
800
|
+
description: ( localize(11888, "Contributes commands to the command palette.")),
|
|
794
801
|
oneOf: [
|
|
795
802
|
commandType,
|
|
796
803
|
{
|
|
@@ -834,7 +841,7 @@ commandsExtensionPoint.setHandler(extensions => {
|
|
|
834
841
|
if (existingCmd) {
|
|
835
842
|
if (existingCmd.source) {
|
|
836
843
|
extension.collector.info(( localize(
|
|
837
|
-
|
|
844
|
+
11889,
|
|
838
845
|
"Command `{0}` already registered by {1} ({2})",
|
|
839
846
|
userFriendlyCommand.command,
|
|
840
847
|
existingCmd.source.title,
|
|
@@ -842,7 +849,7 @@ commandsExtensionPoint.setHandler(extensions => {
|
|
|
842
849
|
)));
|
|
843
850
|
}
|
|
844
851
|
else {
|
|
845
|
-
extension.collector.info(( localize(
|
|
852
|
+
extension.collector.info(( localize(11890, "Command `{0}` already registered", userFriendlyCommand.command)));
|
|
846
853
|
}
|
|
847
854
|
}
|
|
848
855
|
_commandRegistrations.add(MenuRegistry.addCommand({
|
|
@@ -883,19 +890,19 @@ submenusExtensionPoint.setHandler(extensions => {
|
|
|
883
890
|
continue;
|
|
884
891
|
}
|
|
885
892
|
if (!submenuInfo.id) {
|
|
886
|
-
collector.warn(( localize(
|
|
893
|
+
collector.warn(( localize(11891, "`{0}` is not a valid submenu identifier", submenuInfo.id)));
|
|
887
894
|
continue;
|
|
888
895
|
}
|
|
889
896
|
if (( _submenus.has(submenuInfo.id))) {
|
|
890
897
|
collector.info(( localize(
|
|
891
|
-
|
|
898
|
+
11892,
|
|
892
899
|
"The `{0}` submenu was already previously registered.",
|
|
893
900
|
submenuInfo.id
|
|
894
901
|
)));
|
|
895
902
|
continue;
|
|
896
903
|
}
|
|
897
904
|
if (!submenuInfo.label) {
|
|
898
|
-
collector.warn(( localize(
|
|
905
|
+
collector.warn(( localize(11893, "`{0}` is not a valid submenu label", submenuInfo.label)));
|
|
899
906
|
continue;
|
|
900
907
|
}
|
|
901
908
|
let absoluteIcon;
|
|
@@ -952,7 +959,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
952
959
|
}
|
|
953
960
|
if (menu.proposed && !isProposedApiEnabled(extension.description, menu.proposed)) {
|
|
954
961
|
collector.error(( localize(
|
|
955
|
-
|
|
962
|
+
11894,
|
|
956
963
|
"{0} is a proposed menu identifier. It requires 'package.json#enabledApiProposals: [\"{1}\"]' and is only available when running out of dev or with the following command line switch: --enable-proposed-api {2}",
|
|
957
964
|
entry[0],
|
|
958
965
|
menu.proposed,
|
|
@@ -967,7 +974,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
967
974
|
const alt = menuItem.alt && MenuRegistry.getCommand(menuItem.alt) || undefined;
|
|
968
975
|
if (!command) {
|
|
969
976
|
collector.error(( localize(
|
|
970
|
-
|
|
977
|
+
11895,
|
|
971
978
|
"Menu item references a command `{0}` which is not defined in the 'commands' section.",
|
|
972
979
|
menuItem.command
|
|
973
980
|
)));
|
|
@@ -975,20 +982,20 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
975
982
|
}
|
|
976
983
|
if (menuItem.alt && !alt) {
|
|
977
984
|
collector.warn(( localize(
|
|
978
|
-
|
|
985
|
+
11896,
|
|
979
986
|
"Menu item references an alt-command `{0}` which is not defined in the 'commands' section.",
|
|
980
987
|
menuItem.alt
|
|
981
988
|
)));
|
|
982
989
|
}
|
|
983
990
|
if (menuItem.command === menuItem.alt) {
|
|
984
|
-
collector.info(( localize(
|
|
991
|
+
collector.info(( localize(11897, "Menu item references the same command as default and alt-command")));
|
|
985
992
|
}
|
|
986
993
|
item = { command, alt, group: undefined, order: undefined, when: undefined };
|
|
987
994
|
}
|
|
988
995
|
else {
|
|
989
996
|
if (menu.supportsSubmenus === false) {
|
|
990
997
|
collector.error(( localize(
|
|
991
|
-
|
|
998
|
+
11898,
|
|
992
999
|
"Menu item references a submenu for a menu which doesn't have submenu support."
|
|
993
1000
|
)));
|
|
994
1001
|
continue;
|
|
@@ -996,7 +1003,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
996
1003
|
const submenu = _submenus.get(menuItem.submenu);
|
|
997
1004
|
if (!submenu) {
|
|
998
1005
|
collector.error(( localize(
|
|
999
|
-
|
|
1006
|
+
11899,
|
|
1000
1007
|
"Menu item references a submenu `{0}` which is not defined in the 'submenus' section.",
|
|
1001
1008
|
menuItem.submenu
|
|
1002
1009
|
)));
|
|
@@ -1009,7 +1016,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
1009
1016
|
}
|
|
1010
1017
|
if (( submenuRegistrations.has(submenu.id.id))) {
|
|
1011
1018
|
collector.warn(( localize(
|
|
1012
|
-
|
|
1019
|
+
11900,
|
|
1013
1020
|
"The `{0}` submenu was already contributed to the `{1}` menu.",
|
|
1014
1021
|
menuItem.submenu,
|
|
1015
1022
|
entry[0]
|
|
@@ -1031,7 +1038,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
1031
1038
|
}
|
|
1032
1039
|
if (menu.id === MenuId.ViewContainerTitle && !menuItem.when?.includes('viewContainer == workbench.view.debug')) {
|
|
1033
1040
|
collector.error(( localize(
|
|
1034
|
-
|
|
1041
|
+
11901,
|
|
1035
1042
|
"The {0} menu contribution must check {1} in its {2} clause.",
|
|
1036
1043
|
'`viewContainer/title`',
|
|
1037
1044
|
'`viewContainer == workbench.view.debug`',
|
|
@@ -1118,10 +1125,10 @@ let CommandsTableRenderer = class CommandsTableRenderer extends Disposable {
|
|
|
1118
1125
|
return { data: { headers: [], rows: [] }, dispose: () => { } };
|
|
1119
1126
|
}
|
|
1120
1127
|
const headers = [
|
|
1121
|
-
( localize(
|
|
1122
|
-
( localize(
|
|
1123
|
-
( localize(
|
|
1124
|
-
( localize(
|
|
1128
|
+
( localize(11902, "ID")),
|
|
1129
|
+
( localize(11903, "Title")),
|
|
1130
|
+
( localize(11904, "Keyboard Shortcuts")),
|
|
1131
|
+
( localize(11905, "Menu Contexts"))
|
|
1125
1132
|
];
|
|
1126
1133
|
const rows = ( commands.sort((a, b) => a.id.localeCompare(b.id))
|
|
1127
1134
|
.map(command => {
|
|
@@ -1161,7 +1168,7 @@ CommandsTableRenderer = ( __decorate([
|
|
|
1161
1168
|
], CommandsTableRenderer));
|
|
1162
1169
|
( Registry.as(Extensions.ExtensionFeaturesRegistry)).registerExtensionFeature({
|
|
1163
1170
|
id: 'commands',
|
|
1164
|
-
label: ( localize(
|
|
1171
|
+
label: ( localize(11906, "Commands")),
|
|
1165
1172
|
access: {
|
|
1166
1173
|
canToggle: false,
|
|
1167
1174
|
},
|
|
@@ -49,39 +49,39 @@ import { IUserDataProfileService } from '@codingame/monaco-vscode-api/vscode/vs/
|
|
|
49
49
|
var WorkbenchKeybindingService_1;
|
|
50
50
|
function isValidContributedKeyBinding(keyBinding, rejects) {
|
|
51
51
|
if (!keyBinding) {
|
|
52
|
-
rejects.push(( localize(
|
|
52
|
+
rejects.push(( localize(12281, "expected non-empty value.")));
|
|
53
53
|
return false;
|
|
54
54
|
}
|
|
55
55
|
if (typeof keyBinding.command !== 'string') {
|
|
56
56
|
rejects.push(( localize(
|
|
57
|
-
|
|
57
|
+
12282,
|
|
58
58
|
"property `{0}` is mandatory and must be of type `string`",
|
|
59
59
|
'command'
|
|
60
60
|
)));
|
|
61
61
|
return false;
|
|
62
62
|
}
|
|
63
63
|
if (keyBinding.key && typeof keyBinding.key !== 'string') {
|
|
64
|
-
rejects.push(( localize(
|
|
64
|
+
rejects.push(( localize(12283, "property `{0}` can be omitted or must be of type `string`", 'key')));
|
|
65
65
|
return false;
|
|
66
66
|
}
|
|
67
67
|
if (keyBinding.when && typeof keyBinding.when !== 'string') {
|
|
68
|
-
rejects.push(( localize(
|
|
68
|
+
rejects.push(( localize(12283, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
69
69
|
return false;
|
|
70
70
|
}
|
|
71
71
|
if (keyBinding.mac && typeof keyBinding.mac !== 'string') {
|
|
72
|
-
rejects.push(( localize(
|
|
72
|
+
rejects.push(( localize(12283, "property `{0}` can be omitted or must be of type `string`", 'mac')));
|
|
73
73
|
return false;
|
|
74
74
|
}
|
|
75
75
|
if (keyBinding.linux && typeof keyBinding.linux !== 'string') {
|
|
76
76
|
rejects.push(( localize(
|
|
77
|
-
|
|
77
|
+
12283,
|
|
78
78
|
"property `{0}` can be omitted or must be of type `string`",
|
|
79
79
|
'linux'
|
|
80
80
|
)));
|
|
81
81
|
return false;
|
|
82
82
|
}
|
|
83
83
|
if (keyBinding.win && typeof keyBinding.win !== 'string') {
|
|
84
|
-
rejects.push(( localize(
|
|
84
|
+
rejects.push(( localize(12283, "property `{0}` can be omitted or must be of type `string`", 'win')));
|
|
85
85
|
return false;
|
|
86
86
|
}
|
|
87
87
|
return true;
|
|
@@ -91,33 +91,33 @@ const keybindingType = {
|
|
|
91
91
|
default: { command: '', key: '' },
|
|
92
92
|
properties: {
|
|
93
93
|
command: {
|
|
94
|
-
description: ( localize(
|
|
94
|
+
description: ( localize(12284, 'Identifier of the command to run when keybinding is triggered.')),
|
|
95
95
|
type: 'string'
|
|
96
96
|
},
|
|
97
97
|
args: {
|
|
98
|
-
description: ( localize(
|
|
98
|
+
description: ( localize(12285, "Arguments to pass to the command to execute."))
|
|
99
99
|
},
|
|
100
100
|
key: {
|
|
101
101
|
description: ( localize(
|
|
102
|
-
|
|
102
|
+
12286,
|
|
103
103
|
'Key or key sequence (separate keys with plus-sign and sequences with space, e.g. Ctrl+O and Ctrl+L L for a chord).'
|
|
104
104
|
)),
|
|
105
105
|
type: 'string'
|
|
106
106
|
},
|
|
107
107
|
mac: {
|
|
108
|
-
description: ( localize(
|
|
108
|
+
description: ( localize(12287, 'Mac specific key or key sequence.')),
|
|
109
109
|
type: 'string'
|
|
110
110
|
},
|
|
111
111
|
linux: {
|
|
112
|
-
description: ( localize(
|
|
112
|
+
description: ( localize(12288, 'Linux specific key or key sequence.')),
|
|
113
113
|
type: 'string'
|
|
114
114
|
},
|
|
115
115
|
win: {
|
|
116
|
-
description: ( localize(
|
|
116
|
+
description: ( localize(12289, 'Windows specific key or key sequence.')),
|
|
117
117
|
type: 'string'
|
|
118
118
|
},
|
|
119
119
|
when: {
|
|
120
|
-
description: ( localize(
|
|
120
|
+
description: ( localize(12290, 'Condition when the key is active.')),
|
|
121
121
|
type: 'string'
|
|
122
122
|
},
|
|
123
123
|
}
|
|
@@ -126,7 +126,7 @@ const keybindingsExtPoint = ExtensionsRegistry.registerExtensionPoint({
|
|
|
126
126
|
extensionPoint: 'keybindings',
|
|
127
127
|
deps: [commandsExtensionPoint],
|
|
128
128
|
jsonSchema: {
|
|
129
|
-
description: ( localize(
|
|
129
|
+
description: ( localize(12291, "Contributes keybindings.")),
|
|
130
130
|
oneOf: [
|
|
131
131
|
keybindingType,
|
|
132
132
|
{
|
|
@@ -505,7 +505,7 @@ let WorkbenchKeybindingService = WorkbenchKeybindingService_1 = class WorkbenchK
|
|
|
505
505
|
}
|
|
506
506
|
if (rejects.length > 0) {
|
|
507
507
|
collector.error(( localize(
|
|
508
|
-
|
|
508
|
+
12292,
|
|
509
509
|
"Invalid `contributes.{0}`: {1}",
|
|
510
510
|
keybindingsExtPoint.name,
|
|
511
511
|
rejects.join('\n')
|
|
@@ -593,7 +593,7 @@ let WorkbenchKeybindingService = WorkbenchKeybindingService_1 = class WorkbenchK
|
|
|
593
593
|
static _getAllCommandsAsComment(boundCommands) {
|
|
594
594
|
const unboundCommands = getAllUnboundCommands(boundCommands);
|
|
595
595
|
const pretty = unboundCommands.sort().join('\n// - ');
|
|
596
|
-
return '// ' + ( localize(
|
|
596
|
+
return '// ' + ( localize(12293, "Here are other available commands: ")) + '\n// - ' + pretty;
|
|
597
597
|
}
|
|
598
598
|
mightProducePrintableCharacter(event) {
|
|
599
599
|
if (event.ctrlKey || event.metaKey || event.altKey) {
|
|
@@ -718,7 +718,7 @@ class KeybindingsJsonSchema {
|
|
|
718
718
|
this.schema = {
|
|
719
719
|
id: KeybindingsJsonSchema.schemaId,
|
|
720
720
|
type: 'array',
|
|
721
|
-
title: ( localize(
|
|
721
|
+
title: ( localize(12294, "Keybindings configuration")),
|
|
722
722
|
allowTrailingCommas: true,
|
|
723
723
|
allowComments: true,
|
|
724
724
|
definitions: {
|
|
@@ -742,7 +742,7 @@ class KeybindingsJsonSchema {
|
|
|
742
742
|
'type': 'string',
|
|
743
743
|
'enum': this.commandsEnum,
|
|
744
744
|
'enumDescriptions': this.commandsEnumDescriptions,
|
|
745
|
-
'description': ( localize(
|
|
745
|
+
'description': ( localize(12295, "Name of the command to execute")),
|
|
746
746
|
},
|
|
747
747
|
'commandType': {
|
|
748
748
|
'anyOf': [
|
|
@@ -753,7 +753,7 @@ class KeybindingsJsonSchema {
|
|
|
753
753
|
'type': 'string',
|
|
754
754
|
'enum': this.removalCommandsEnum,
|
|
755
755
|
'enumDescriptions': this.commandsEnumDescriptions,
|
|
756
|
-
'description': ( localize(
|
|
756
|
+
'description': ( localize(12296, "Name of the command to remove keyboard shortcut for")),
|
|
757
757
|
},
|
|
758
758
|
{
|
|
759
759
|
'type': 'string'
|
|
@@ -771,7 +771,7 @@ class KeybindingsJsonSchema {
|
|
|
771
771
|
'properties': {
|
|
772
772
|
'key': {
|
|
773
773
|
'type': 'string',
|
|
774
|
-
'description': ( localize(
|
|
774
|
+
'description': ( localize(12297, "Key or key sequence (separated by space)")),
|
|
775
775
|
},
|
|
776
776
|
'command': {
|
|
777
777
|
'anyOf': [
|
|
@@ -784,7 +784,7 @@ class KeybindingsJsonSchema {
|
|
|
784
784
|
'type': 'array'
|
|
785
785
|
},
|
|
786
786
|
'errorMessage': ( localize(
|
|
787
|
-
|
|
787
|
+
12298,
|
|
788
788
|
"Incorrect type. Expected \"{0}\". The field 'command' does not support running multiple commands. Use command 'runCommands' to pass it multiple commands to run.",
|
|
789
789
|
'string'
|
|
790
790
|
))
|
|
@@ -800,10 +800,10 @@ class KeybindingsJsonSchema {
|
|
|
800
800
|
},
|
|
801
801
|
'when': {
|
|
802
802
|
'type': 'string',
|
|
803
|
-
'description': ( localize(
|
|
803
|
+
'description': ( localize(12299, "Condition when the key is active."))
|
|
804
804
|
},
|
|
805
805
|
'args': {
|
|
806
|
-
'description': ( localize(
|
|
806
|
+
'description': ( localize(12300, "Arguments to pass to the command to execute."))
|
|
807
807
|
}
|
|
808
808
|
},
|
|
809
809
|
'$ref': '#/definitions/commandsSchemas'
|
|
@@ -483,12 +483,12 @@ const keyboardConfiguration = {
|
|
|
483
483
|
'id': 'keyboard',
|
|
484
484
|
'order': 15,
|
|
485
485
|
'type': 'object',
|
|
486
|
-
'title': ( localize(
|
|
486
|
+
'title': ( localize(12301, "Keyboard")),
|
|
487
487
|
'properties': {
|
|
488
488
|
'keyboard.layout': {
|
|
489
489
|
'type': 'string',
|
|
490
490
|
'default': 'autodetect',
|
|
491
|
-
'description': ( localize(
|
|
491
|
+
'description': ( localize(12302, "Control the keyboard layout used in web."))
|
|
492
492
|
}
|
|
493
493
|
}
|
|
494
494
|
};
|