@codingame/monaco-vscode-keybindings-service-override 11.1.0 → 11.1.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 +3 -3
- package/vscode/src/vs/platform/keyboardLayout/common/keyboardConfig.js +3 -3
- 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 +3 -3
- package/vscode/src/vs/workbench/services/actions/common/menusExtensionPoint.js +132 -132
- 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": "11.1.
|
|
3
|
+
"version": "11.1.1",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "CodinGame",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
}
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"vscode": "npm:@codingame/monaco-vscode-api@11.1.
|
|
30
|
-
"@codingame/monaco-vscode-files-service-override": "11.1.
|
|
29
|
+
"vscode": "npm:@codingame/monaco-vscode-api@11.1.1",
|
|
30
|
+
"@codingame/monaco-vscode-files-service-override": "11.1.1"
|
|
31
31
|
}
|
|
32
32
|
}
|
|
@@ -14,7 +14,7 @@ const keyboardConfiguration = {
|
|
|
14
14
|
'id': 'keyboard',
|
|
15
15
|
'order': 15,
|
|
16
16
|
'type': 'object',
|
|
17
|
-
'title': ( localize(
|
|
17
|
+
'title': ( localize(8835, "Keyboard")),
|
|
18
18
|
'properties': {
|
|
19
19
|
'keyboard.dispatch': {
|
|
20
20
|
scope: 1 ,
|
|
@@ -22,7 +22,7 @@ const keyboardConfiguration = {
|
|
|
22
22
|
enum: ['code', 'keyCode'],
|
|
23
23
|
default: 'code',
|
|
24
24
|
markdownDescription: ( localize(
|
|
25
|
-
|
|
25
|
+
8836,
|
|
26
26
|
"Controls the dispatching logic for key presses to use either `code` (recommended) or `keyCode`."
|
|
27
27
|
)),
|
|
28
28
|
included: OS === 2 || OS === 3
|
|
@@ -31,7 +31,7 @@ const keyboardConfiguration = {
|
|
|
31
31
|
scope: 1 ,
|
|
32
32
|
type: 'boolean',
|
|
33
33
|
default: false,
|
|
34
|
-
markdownDescription: ( localize(
|
|
34
|
+
markdownDescription: ( localize(8837, "Controls if the AltGraph+ modifier should be treated as Ctrl+Alt+.")),
|
|
35
35
|
included: OS === 1
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -9,10 +9,10 @@ class RunCommands extends Action2 {
|
|
|
9
9
|
constructor() {
|
|
10
10
|
super({
|
|
11
11
|
id: 'runCommands',
|
|
12
|
-
title: ( localize2(
|
|
12
|
+
title: ( localize2(3080, "Run Commands")),
|
|
13
13
|
f1: false,
|
|
14
14
|
metadata: {
|
|
15
|
-
description: ( localize(
|
|
15
|
+
description: ( localize(3081, "Run several commands")),
|
|
16
16
|
args: [
|
|
17
17
|
{
|
|
18
18
|
name: 'args',
|
|
@@ -22,7 +22,7 @@ class RunCommands extends Action2 {
|
|
|
22
22
|
properties: {
|
|
23
23
|
commands: {
|
|
24
24
|
type: 'array',
|
|
25
|
-
description: ( localize(
|
|
25
|
+
description: ( localize(3082, "Commands to run")),
|
|
26
26
|
items: {
|
|
27
27
|
anyOf: [
|
|
28
28
|
{
|
|
@@ -62,14 +62,14 @@ class RunCommands extends Action2 {
|
|
|
62
62
|
const notificationService = accessor.get(INotificationService);
|
|
63
63
|
if (!this._isCommandArgs(args)) {
|
|
64
64
|
notificationService.error(( localize(
|
|
65
|
-
|
|
65
|
+
3083,
|
|
66
66
|
"'runCommands' has received an argument with incorrect type. Please, review the argument passed to the command."
|
|
67
67
|
)));
|
|
68
68
|
return;
|
|
69
69
|
}
|
|
70
70
|
if (args.commands.length === 0) {
|
|
71
71
|
notificationService.warn(( localize(
|
|
72
|
-
|
|
72
|
+
3084,
|
|
73
73
|
"'runCommands' has not received commands to run. Did you forget to pass commands in the 'runCommands' argument?"
|
|
74
74
|
)));
|
|
75
75
|
return;
|
|
@@ -9,7 +9,7 @@ class ToggleKeybindingsLogAction extends Action2 {
|
|
|
9
9
|
constructor() {
|
|
10
10
|
super({
|
|
11
11
|
id: 'workbench.action.toggleKeybindingsLog',
|
|
12
|
-
title: ( localize2(
|
|
12
|
+
title: ( localize2(3076, "Toggle Keyboard Shortcuts Troubleshooting")),
|
|
13
13
|
category: Categories.Developer,
|
|
14
14
|
f1: true
|
|
15
15
|
});
|
package/vscode/src/vs/workbench/contrib/preferences/browser/keybindingsEditorContribution.js
CHANGED
|
@@ -23,7 +23,7 @@ import { DEFINE_KEYBINDING_EDITOR_CONTRIB_ID } from 'vscode/vscode/vs/workbench/
|
|
|
23
23
|
|
|
24
24
|
var KeybindingEditorDecorationsRenderer_1;
|
|
25
25
|
const NLS_KB_LAYOUT_ERROR_MESSAGE = ( localize(
|
|
26
|
-
|
|
26
|
+
3077,
|
|
27
27
|
"You won't be able to produce this key combination under your current keyboard layout."
|
|
28
28
|
));
|
|
29
29
|
let DefineKeybindingEditorContribution = class DefineKeybindingEditorContribution extends Disposable {
|
|
@@ -181,14 +181,14 @@ let KeybindingEditorDecorationsRenderer = KeybindingEditorDecorationsRenderer_1
|
|
|
181
181
|
else {
|
|
182
182
|
if (usLabel && uiLabel !== usLabel) {
|
|
183
183
|
msg = ( (new MarkdownString(( localize(
|
|
184
|
-
|
|
184
|
+
3078,
|
|
185
185
|
"**{0}** for your current keyboard layout (**{1}** for US standard).",
|
|
186
186
|
uiLabel,
|
|
187
187
|
usLabel
|
|
188
188
|
)))));
|
|
189
189
|
}
|
|
190
190
|
else {
|
|
191
|
-
msg = ( (new MarkdownString(( localize(
|
|
191
|
+
msg = ( (new MarkdownString(( localize(3079, "**{0}** for your current keyboard layout.", uiLabel)))));
|
|
192
192
|
}
|
|
193
193
|
className = 'keybindingInfo';
|
|
194
194
|
overviewRulerColor = themeColorFromId(overviewRulerInfo);
|
|
@@ -20,203 +20,203 @@ const apiMenus = [
|
|
|
20
20
|
{
|
|
21
21
|
key: 'commandPalette',
|
|
22
22
|
id: MenuId.CommandPalette,
|
|
23
|
-
description: ( localize(
|
|
23
|
+
description: ( localize(8717, "The Command Palette")),
|
|
24
24
|
supportsSubmenus: false
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
key: 'touchBar',
|
|
28
28
|
id: MenuId.TouchBarContext,
|
|
29
|
-
description: ( localize(
|
|
29
|
+
description: ( localize(8718, "The touch bar (macOS only)")),
|
|
30
30
|
supportsSubmenus: false
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
33
|
key: 'editor/title',
|
|
34
34
|
id: MenuId.EditorTitle,
|
|
35
|
-
description: ( localize(
|
|
35
|
+
description: ( localize(8719, "The editor title menu"))
|
|
36
36
|
},
|
|
37
37
|
{
|
|
38
38
|
key: 'editor/title/run',
|
|
39
39
|
id: MenuId.EditorTitleRun,
|
|
40
|
-
description: ( localize(
|
|
40
|
+
description: ( localize(8720, "Run submenu inside the editor title menu"))
|
|
41
41
|
},
|
|
42
42
|
{
|
|
43
43
|
key: 'editor/context',
|
|
44
44
|
id: MenuId.EditorContext,
|
|
45
|
-
description: ( localize(
|
|
45
|
+
description: ( localize(8721, "The editor context menu"))
|
|
46
46
|
},
|
|
47
47
|
{
|
|
48
48
|
key: 'editor/context/copy',
|
|
49
49
|
id: MenuId.EditorContextCopy,
|
|
50
|
-
description: ( localize(
|
|
50
|
+
description: ( localize(8722, "'Copy as' submenu in the editor context menu"))
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
53
|
key: 'editor/context/share',
|
|
54
54
|
id: MenuId.EditorContextShare,
|
|
55
|
-
description: ( localize(
|
|
55
|
+
description: ( localize(8723, "'Share' submenu in the editor context menu")),
|
|
56
56
|
proposed: 'contribShareMenu'
|
|
57
57
|
},
|
|
58
58
|
{
|
|
59
59
|
key: 'explorer/context',
|
|
60
60
|
id: MenuId.ExplorerContext,
|
|
61
|
-
description: ( localize(
|
|
61
|
+
description: ( localize(8724, "The file explorer context menu"))
|
|
62
62
|
},
|
|
63
63
|
{
|
|
64
64
|
key: 'explorer/context/share',
|
|
65
65
|
id: MenuId.ExplorerContextShare,
|
|
66
|
-
description: ( localize(
|
|
66
|
+
description: ( localize(8725, "'Share' submenu in the file explorer context menu")),
|
|
67
67
|
proposed: 'contribShareMenu'
|
|
68
68
|
},
|
|
69
69
|
{
|
|
70
70
|
key: 'editor/title/context',
|
|
71
71
|
id: MenuId.EditorTitleContext,
|
|
72
|
-
description: ( localize(
|
|
72
|
+
description: ( localize(8726, "The editor tabs context menu"))
|
|
73
73
|
},
|
|
74
74
|
{
|
|
75
75
|
key: 'editor/title/context/share',
|
|
76
76
|
id: MenuId.EditorTitleContextShare,
|
|
77
|
-
description: ( localize(
|
|
77
|
+
description: ( localize(8727, "'Share' submenu inside the editor title context menu")),
|
|
78
78
|
proposed: 'contribShareMenu'
|
|
79
79
|
},
|
|
80
80
|
{
|
|
81
81
|
key: 'debug/callstack/context',
|
|
82
82
|
id: MenuId.DebugCallStackContext,
|
|
83
|
-
description: ( localize(
|
|
83
|
+
description: ( localize(8728, "The debug callstack view context menu"))
|
|
84
84
|
},
|
|
85
85
|
{
|
|
86
86
|
key: 'debug/variables/context',
|
|
87
87
|
id: MenuId.DebugVariablesContext,
|
|
88
|
-
description: ( localize(
|
|
88
|
+
description: ( localize(8729, "The debug variables view context menu"))
|
|
89
89
|
},
|
|
90
90
|
{
|
|
91
91
|
key: 'debug/toolBar',
|
|
92
92
|
id: MenuId.DebugToolBar,
|
|
93
|
-
description: ( localize(
|
|
93
|
+
description: ( localize(8730, "The debug toolbar menu"))
|
|
94
94
|
},
|
|
95
95
|
{
|
|
96
96
|
key: 'debug/createConfiguration',
|
|
97
97
|
id: MenuId.DebugCreateConfiguration,
|
|
98
98
|
proposed: 'contribDebugCreateConfiguration',
|
|
99
|
-
description: ( localize(
|
|
99
|
+
description: ( localize(8731, "The debug create configuration menu"))
|
|
100
100
|
},
|
|
101
101
|
{
|
|
102
102
|
key: 'notebook/variables/context',
|
|
103
103
|
id: MenuId.NotebookVariablesContext,
|
|
104
|
-
description: ( localize(
|
|
104
|
+
description: ( localize(8732, "The notebook variables view context menu"))
|
|
105
105
|
},
|
|
106
106
|
{
|
|
107
107
|
key: 'menuBar/home',
|
|
108
108
|
id: MenuId.MenubarHomeMenu,
|
|
109
|
-
description: ( localize(
|
|
109
|
+
description: ( localize(8733, "The home indicator context menu (web only)")),
|
|
110
110
|
proposed: 'contribMenuBarHome',
|
|
111
111
|
supportsSubmenus: false
|
|
112
112
|
},
|
|
113
113
|
{
|
|
114
114
|
key: 'menuBar/edit/copy',
|
|
115
115
|
id: MenuId.MenubarCopy,
|
|
116
|
-
description: ( localize(
|
|
116
|
+
description: ( localize(8734, "'Copy as' submenu in the top level Edit menu"))
|
|
117
117
|
},
|
|
118
118
|
{
|
|
119
119
|
key: 'scm/title',
|
|
120
120
|
id: MenuId.SCMTitle,
|
|
121
|
-
description: ( localize(
|
|
121
|
+
description: ( localize(8735, "The Source Control title menu"))
|
|
122
122
|
},
|
|
123
123
|
{
|
|
124
124
|
key: 'scm/sourceControl',
|
|
125
125
|
id: MenuId.SCMSourceControl,
|
|
126
|
-
description: ( localize(
|
|
126
|
+
description: ( localize(8736, "The Source Control menu"))
|
|
127
127
|
},
|
|
128
128
|
{
|
|
129
129
|
key: 'scm/sourceControl/title',
|
|
130
130
|
id: MenuId.SCMSourceControlTitle,
|
|
131
|
-
description: ( localize(
|
|
131
|
+
description: ( localize(8737, "The Source Control title menu")),
|
|
132
132
|
proposed: 'contribSourceControlTitleMenu'
|
|
133
133
|
},
|
|
134
134
|
{
|
|
135
135
|
key: 'scm/resourceState/context',
|
|
136
136
|
id: MenuId.SCMResourceContext,
|
|
137
|
-
description: ( localize(
|
|
137
|
+
description: ( localize(8738, "The Source Control resource state context menu"))
|
|
138
138
|
},
|
|
139
139
|
{
|
|
140
140
|
key: 'scm/resourceFolder/context',
|
|
141
141
|
id: MenuId.SCMResourceFolderContext,
|
|
142
|
-
description: ( localize(
|
|
142
|
+
description: ( localize(8739, "The Source Control resource folder context menu"))
|
|
143
143
|
},
|
|
144
144
|
{
|
|
145
145
|
key: 'scm/resourceGroup/context',
|
|
146
146
|
id: MenuId.SCMResourceGroupContext,
|
|
147
|
-
description: ( localize(
|
|
147
|
+
description: ( localize(8740, "The Source Control resource group context menu"))
|
|
148
148
|
},
|
|
149
149
|
{
|
|
150
150
|
key: 'scm/change/title',
|
|
151
151
|
id: MenuId.SCMChangeContext,
|
|
152
|
-
description: ( localize(
|
|
152
|
+
description: ( localize(8741, "The Source Control inline change menu"))
|
|
153
153
|
},
|
|
154
154
|
{
|
|
155
155
|
key: 'scm/inputBox',
|
|
156
156
|
id: MenuId.SCMInputBox,
|
|
157
|
-
description: ( localize(
|
|
157
|
+
description: ( localize(8742, "The Source Control input box menu")),
|
|
158
158
|
proposed: 'contribSourceControlInputBoxMenu'
|
|
159
159
|
},
|
|
160
160
|
{
|
|
161
161
|
key: 'scm/history/title',
|
|
162
162
|
id: MenuId.SCMHistoryTitle,
|
|
163
|
-
description: ( localize(
|
|
163
|
+
description: ( localize(8743, "The Source Control History title menu")),
|
|
164
164
|
proposed: 'contribSourceControlHistoryTitleMenu'
|
|
165
165
|
},
|
|
166
166
|
{
|
|
167
167
|
key: 'scm/historyItem/context',
|
|
168
168
|
id: MenuId.SCMChangesContext,
|
|
169
|
-
description: ( localize(
|
|
169
|
+
description: ( localize(8744, "The Source Control history item context menu")),
|
|
170
170
|
proposed: 'contribSourceControlHistoryItemMenu'
|
|
171
171
|
},
|
|
172
172
|
{
|
|
173
173
|
key: 'statusBar/remoteIndicator',
|
|
174
174
|
id: MenuId.StatusBarRemoteIndicatorMenu,
|
|
175
|
-
description: ( localize(
|
|
175
|
+
description: ( localize(8745, "The remote indicator menu in the status bar")),
|
|
176
176
|
supportsSubmenus: false
|
|
177
177
|
},
|
|
178
178
|
{
|
|
179
179
|
key: 'terminal/context',
|
|
180
180
|
id: MenuId.TerminalInstanceContext,
|
|
181
|
-
description: ( localize(
|
|
181
|
+
description: ( localize(8746, "The terminal context menu"))
|
|
182
182
|
},
|
|
183
183
|
{
|
|
184
184
|
key: 'terminal/title/context',
|
|
185
185
|
id: MenuId.TerminalTabContext,
|
|
186
|
-
description: ( localize(
|
|
186
|
+
description: ( localize(8747, "The terminal tabs context menu"))
|
|
187
187
|
},
|
|
188
188
|
{
|
|
189
189
|
key: 'view/title',
|
|
190
190
|
id: MenuId.ViewTitle,
|
|
191
|
-
description: ( localize(
|
|
191
|
+
description: ( localize(8748, "The contributed view title menu"))
|
|
192
192
|
},
|
|
193
193
|
{
|
|
194
194
|
key: 'viewContainer/title',
|
|
195
195
|
id: MenuId.ViewContainerTitle,
|
|
196
|
-
description: ( localize(
|
|
196
|
+
description: ( localize(8749, "The contributed view container title menu")),
|
|
197
197
|
proposed: 'contribViewContainerTitle'
|
|
198
198
|
},
|
|
199
199
|
{
|
|
200
200
|
key: 'view/item/context',
|
|
201
201
|
id: MenuId.ViewItemContext,
|
|
202
|
-
description: ( localize(
|
|
202
|
+
description: ( localize(8750, "The contributed view item context menu"))
|
|
203
203
|
},
|
|
204
204
|
{
|
|
205
205
|
key: 'comments/comment/editorActions',
|
|
206
206
|
id: MenuId.CommentEditorActions,
|
|
207
|
-
description: ( localize(
|
|
207
|
+
description: ( localize(8751, "The contributed comment editor actions")),
|
|
208
208
|
proposed: 'contribCommentEditorActionsMenu'
|
|
209
209
|
},
|
|
210
210
|
{
|
|
211
211
|
key: 'comments/commentThread/title',
|
|
212
212
|
id: MenuId.CommentThreadTitle,
|
|
213
|
-
description: ( localize(
|
|
213
|
+
description: ( localize(8752, "The contributed comment thread title menu"))
|
|
214
214
|
},
|
|
215
215
|
{
|
|
216
216
|
key: 'comments/commentThread/context',
|
|
217
217
|
id: MenuId.CommentThreadActions,
|
|
218
218
|
description: ( localize(
|
|
219
|
-
|
|
219
|
+
8753,
|
|
220
220
|
"The contributed comment thread context menu, rendered as buttons below the comment editor"
|
|
221
221
|
)),
|
|
222
222
|
supportsSubmenus: false
|
|
@@ -225,7 +225,7 @@ const apiMenus = [
|
|
|
225
225
|
key: 'comments/commentThread/additionalActions',
|
|
226
226
|
id: MenuId.CommentThreadAdditionalActions,
|
|
227
227
|
description: ( localize(
|
|
228
|
-
|
|
228
|
+
8753,
|
|
229
229
|
"The contributed comment thread context menu, rendered as buttons below the comment editor"
|
|
230
230
|
)),
|
|
231
231
|
supportsSubmenus: true,
|
|
@@ -235,7 +235,7 @@ const apiMenus = [
|
|
|
235
235
|
key: 'comments/commentThread/title/context',
|
|
236
236
|
id: MenuId.CommentThreadTitleContext,
|
|
237
237
|
description: ( localize(
|
|
238
|
-
|
|
238
|
+
8754,
|
|
239
239
|
"The contributed comment thread title's peek context menu, rendered as a right click menu on the comment thread's peek title."
|
|
240
240
|
)),
|
|
241
241
|
proposed: 'contribCommentPeekContext'
|
|
@@ -243,13 +243,13 @@ const apiMenus = [
|
|
|
243
243
|
{
|
|
244
244
|
key: 'comments/comment/title',
|
|
245
245
|
id: MenuId.CommentTitle,
|
|
246
|
-
description: ( localize(
|
|
246
|
+
description: ( localize(8755, "The contributed comment title menu"))
|
|
247
247
|
},
|
|
248
248
|
{
|
|
249
249
|
key: 'comments/comment/context',
|
|
250
250
|
id: MenuId.CommentActions,
|
|
251
251
|
description: ( localize(
|
|
252
|
-
|
|
252
|
+
8756,
|
|
253
253
|
"The contributed comment context menu, rendered as buttons below the comment editor"
|
|
254
254
|
)),
|
|
255
255
|
supportsSubmenus: false
|
|
@@ -258,7 +258,7 @@ const apiMenus = [
|
|
|
258
258
|
key: 'comments/commentThread/comment/context',
|
|
259
259
|
id: MenuId.CommentThreadCommentContext,
|
|
260
260
|
description: ( localize(
|
|
261
|
-
|
|
261
|
+
8757,
|
|
262
262
|
"The contributed comment context menu, rendered as a right click menu on the an individual comment in the comment thread's peek view."
|
|
263
263
|
)),
|
|
264
264
|
proposed: 'contribCommentPeekContext'
|
|
@@ -266,166 +266,166 @@ const apiMenus = [
|
|
|
266
266
|
{
|
|
267
267
|
key: 'commentsView/commentThread/context',
|
|
268
268
|
id: MenuId.CommentsViewThreadActions,
|
|
269
|
-
description: ( localize(
|
|
269
|
+
description: ( localize(8758, "The contributed comment thread context menu in the comments view")),
|
|
270
270
|
proposed: 'contribCommentsViewThreadMenus'
|
|
271
271
|
},
|
|
272
272
|
{
|
|
273
273
|
key: 'notebook/toolbar',
|
|
274
274
|
id: MenuId.NotebookToolbar,
|
|
275
|
-
description: ( localize(
|
|
275
|
+
description: ( localize(8759, "The contributed notebook toolbar menu"))
|
|
276
276
|
},
|
|
277
277
|
{
|
|
278
278
|
key: 'notebook/kernelSource',
|
|
279
279
|
id: MenuId.NotebookKernelSource,
|
|
280
|
-
description: ( localize(
|
|
280
|
+
description: ( localize(8760, "The contributed notebook kernel sources menu")),
|
|
281
281
|
proposed: 'notebookKernelSource'
|
|
282
282
|
},
|
|
283
283
|
{
|
|
284
284
|
key: 'notebook/cell/title',
|
|
285
285
|
id: MenuId.NotebookCellTitle,
|
|
286
|
-
description: ( localize(
|
|
286
|
+
description: ( localize(8761, "The contributed notebook cell title menu"))
|
|
287
287
|
},
|
|
288
288
|
{
|
|
289
289
|
key: 'notebook/cell/execute',
|
|
290
290
|
id: MenuId.NotebookCellExecute,
|
|
291
|
-
description: ( localize(
|
|
291
|
+
description: ( localize(8762, "The contributed notebook cell execution menu"))
|
|
292
292
|
},
|
|
293
293
|
{
|
|
294
294
|
key: 'interactive/toolbar',
|
|
295
295
|
id: MenuId.InteractiveToolbar,
|
|
296
|
-
description: ( localize(
|
|
296
|
+
description: ( localize(8763, "The contributed interactive toolbar menu")),
|
|
297
297
|
},
|
|
298
298
|
{
|
|
299
299
|
key: 'interactive/cell/title',
|
|
300
300
|
id: MenuId.InteractiveCellTitle,
|
|
301
|
-
description: ( localize(
|
|
301
|
+
description: ( localize(8764, "The contributed interactive cell title menu")),
|
|
302
302
|
},
|
|
303
303
|
{
|
|
304
304
|
key: 'issue/reporter',
|
|
305
305
|
id: MenuId.IssueReporter,
|
|
306
|
-
description: ( localize(
|
|
306
|
+
description: ( localize(8765, "The contributed issue reporter menu")),
|
|
307
307
|
proposed: 'contribIssueReporter'
|
|
308
308
|
},
|
|
309
309
|
{
|
|
310
310
|
key: 'testing/item/context',
|
|
311
311
|
id: MenuId.TestItem,
|
|
312
|
-
description: ( localize(
|
|
312
|
+
description: ( localize(8766, "The contributed test item menu")),
|
|
313
313
|
},
|
|
314
314
|
{
|
|
315
315
|
key: 'testing/item/gutter',
|
|
316
316
|
id: MenuId.TestItemGutter,
|
|
317
|
-
description: ( localize(
|
|
317
|
+
description: ( localize(8767, "The menu for a gutter decoration for a test item")),
|
|
318
318
|
},
|
|
319
319
|
{
|
|
320
320
|
key: 'testing/profiles/context',
|
|
321
321
|
id: MenuId.TestProfilesContext,
|
|
322
|
-
description: ( localize(
|
|
322
|
+
description: ( localize(8768, "The menu for configuring testing profiles.")),
|
|
323
323
|
},
|
|
324
324
|
{
|
|
325
325
|
key: 'testing/item/result',
|
|
326
326
|
id: MenuId.TestPeekElement,
|
|
327
|
-
description: ( localize(
|
|
327
|
+
description: ( localize(8769, "The menu for an item in the Test Results view or peek.")),
|
|
328
328
|
},
|
|
329
329
|
{
|
|
330
330
|
key: 'testing/message/context',
|
|
331
331
|
id: MenuId.TestMessageContext,
|
|
332
332
|
description: ( localize(
|
|
333
|
-
|
|
333
|
+
8770,
|
|
334
334
|
"A prominent button overlaying editor content where the message is displayed"
|
|
335
335
|
)),
|
|
336
336
|
},
|
|
337
337
|
{
|
|
338
338
|
key: 'testing/message/content',
|
|
339
339
|
id: MenuId.TestMessageContent,
|
|
340
|
-
description: ( localize(
|
|
340
|
+
description: ( localize(8771, "Context menu for the message in the results tree")),
|
|
341
341
|
},
|
|
342
342
|
{
|
|
343
343
|
key: 'extension/context',
|
|
344
344
|
id: MenuId.ExtensionContext,
|
|
345
|
-
description: ( localize(
|
|
345
|
+
description: ( localize(8772, "The extension context menu"))
|
|
346
346
|
},
|
|
347
347
|
{
|
|
348
348
|
key: 'timeline/title',
|
|
349
349
|
id: MenuId.TimelineTitle,
|
|
350
|
-
description: ( localize(
|
|
350
|
+
description: ( localize(8773, "The Timeline view title menu"))
|
|
351
351
|
},
|
|
352
352
|
{
|
|
353
353
|
key: 'timeline/item/context',
|
|
354
354
|
id: MenuId.TimelineItemContext,
|
|
355
|
-
description: ( localize(
|
|
355
|
+
description: ( localize(8774, "The Timeline view item context menu"))
|
|
356
356
|
},
|
|
357
357
|
{
|
|
358
358
|
key: 'ports/item/context',
|
|
359
359
|
id: MenuId.TunnelContext,
|
|
360
|
-
description: ( localize(
|
|
360
|
+
description: ( localize(8775, "The Ports view item context menu"))
|
|
361
361
|
},
|
|
362
362
|
{
|
|
363
363
|
key: 'ports/item/origin/inline',
|
|
364
364
|
id: MenuId.TunnelOriginInline,
|
|
365
|
-
description: ( localize(
|
|
365
|
+
description: ( localize(8776, "The Ports view item origin inline menu"))
|
|
366
366
|
},
|
|
367
367
|
{
|
|
368
368
|
key: 'ports/item/port/inline',
|
|
369
369
|
id: MenuId.TunnelPortInline,
|
|
370
|
-
description: ( localize(
|
|
370
|
+
description: ( localize(8777, "The Ports view item port inline menu"))
|
|
371
371
|
},
|
|
372
372
|
{
|
|
373
373
|
key: 'file/newFile',
|
|
374
374
|
id: MenuId.NewFile,
|
|
375
|
-
description: ( localize(
|
|
375
|
+
description: ( localize(8778, "The 'New File...' quick pick, shown on welcome page and File menu.")),
|
|
376
376
|
supportsSubmenus: false,
|
|
377
377
|
},
|
|
378
378
|
{
|
|
379
379
|
key: 'webview/context',
|
|
380
380
|
id: MenuId.WebviewContext,
|
|
381
|
-
description: ( localize(
|
|
381
|
+
description: ( localize(8779, "The webview context menu"))
|
|
382
382
|
},
|
|
383
383
|
{
|
|
384
384
|
key: 'file/share',
|
|
385
385
|
id: MenuId.MenubarShare,
|
|
386
|
-
description: ( localize(
|
|
386
|
+
description: ( localize(8780, "Share submenu shown in the top level File menu.")),
|
|
387
387
|
proposed: 'contribShareMenu'
|
|
388
388
|
},
|
|
389
389
|
{
|
|
390
390
|
key: 'editor/inlineCompletions/actions',
|
|
391
391
|
id: MenuId.InlineCompletionsActions,
|
|
392
|
-
description: ( localize(
|
|
392
|
+
description: ( localize(8781, "The actions shown when hovering on an inline completion")),
|
|
393
393
|
supportsSubmenus: false,
|
|
394
394
|
proposed: 'inlineCompletionsAdditions'
|
|
395
395
|
},
|
|
396
396
|
{
|
|
397
397
|
key: 'editor/content',
|
|
398
398
|
id: MenuId.EditorContent,
|
|
399
|
-
description: ( localize(
|
|
399
|
+
description: ( localize(8782, "The prominent button in an editor, overlays its content")),
|
|
400
400
|
proposed: 'contribEditorContentMenu'
|
|
401
401
|
},
|
|
402
402
|
{
|
|
403
403
|
key: 'editor/lineNumber/context',
|
|
404
404
|
id: MenuId.EditorLineNumberContext,
|
|
405
|
-
description: ( localize(
|
|
405
|
+
description: ( localize(8783, "The contributed editor line number context menu"))
|
|
406
406
|
},
|
|
407
407
|
{
|
|
408
408
|
key: 'mergeEditor/result/title',
|
|
409
409
|
id: MenuId.MergeInputResultToolbar,
|
|
410
|
-
description: ( localize(
|
|
410
|
+
description: ( localize(8784, "The result toolbar of the merge editor")),
|
|
411
411
|
proposed: 'contribMergeEditorMenus'
|
|
412
412
|
},
|
|
413
413
|
{
|
|
414
414
|
key: 'multiDiffEditor/resource/title',
|
|
415
415
|
id: MenuId.MultiDiffEditorFileToolbar,
|
|
416
|
-
description: ( localize(
|
|
416
|
+
description: ( localize(8785, "The resource toolbar in the multi diff editor")),
|
|
417
417
|
proposed: 'contribMultiDiffEditorMenus'
|
|
418
418
|
},
|
|
419
419
|
{
|
|
420
420
|
key: 'diffEditor/gutter/hunk',
|
|
421
421
|
id: MenuId.DiffEditorHunkToolbar,
|
|
422
|
-
description: ( localize(
|
|
422
|
+
description: ( localize(8786, "The gutter toolbar in the diff editor")),
|
|
423
423
|
proposed: 'contribDiffEditorGutterToolBarMenus'
|
|
424
424
|
},
|
|
425
425
|
{
|
|
426
426
|
key: 'diffEditor/gutter/selection',
|
|
427
427
|
id: MenuId.DiffEditorSelectionToolbar,
|
|
428
|
-
description: ( localize(
|
|
428
|
+
description: ( localize(8786, "The gutter toolbar in the diff editor")),
|
|
429
429
|
proposed: 'contribDiffEditorGutterToolBarMenus'
|
|
430
430
|
}
|
|
431
431
|
];
|
|
@@ -438,22 +438,22 @@ var schema;
|
|
|
438
438
|
function isValidMenuItem(item, collector) {
|
|
439
439
|
if (typeof item.command !== 'string') {
|
|
440
440
|
collector.error(( localize(
|
|
441
|
-
|
|
441
|
+
8787,
|
|
442
442
|
"property `{0}` is mandatory and must be of type `string`",
|
|
443
443
|
'command'
|
|
444
444
|
)));
|
|
445
445
|
return false;
|
|
446
446
|
}
|
|
447
447
|
if (item.alt && typeof item.alt !== 'string') {
|
|
448
|
-
collector.error(( localize(
|
|
448
|
+
collector.error(( localize(8788, "property `{0}` can be omitted or must be of type `string`", 'alt')));
|
|
449
449
|
return false;
|
|
450
450
|
}
|
|
451
451
|
if (item.when && typeof item.when !== 'string') {
|
|
452
|
-
collector.error(( localize(
|
|
452
|
+
collector.error(( localize(8788, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
453
453
|
return false;
|
|
454
454
|
}
|
|
455
455
|
if (item.group && typeof item.group !== 'string') {
|
|
456
|
-
collector.error(( localize(
|
|
456
|
+
collector.error(( localize(8788, "property `{0}` can be omitted or must be of type `string`", 'group')));
|
|
457
457
|
return false;
|
|
458
458
|
}
|
|
459
459
|
return true;
|
|
@@ -462,18 +462,18 @@ var schema;
|
|
|
462
462
|
function isValidSubmenuItem(item, collector) {
|
|
463
463
|
if (typeof item.submenu !== 'string') {
|
|
464
464
|
collector.error(( localize(
|
|
465
|
-
|
|
465
|
+
8787,
|
|
466
466
|
"property `{0}` is mandatory and must be of type `string`",
|
|
467
467
|
'submenu'
|
|
468
468
|
)));
|
|
469
469
|
return false;
|
|
470
470
|
}
|
|
471
471
|
if (item.when && typeof item.when !== 'string') {
|
|
472
|
-
collector.error(( localize(
|
|
472
|
+
collector.error(( localize(8788, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
473
473
|
return false;
|
|
474
474
|
}
|
|
475
475
|
if (item.group && typeof item.group !== 'string') {
|
|
476
|
-
collector.error(( localize(
|
|
476
|
+
collector.error(( localize(8788, "property `{0}` can be omitted or must be of type `string`", 'group')));
|
|
477
477
|
return false;
|
|
478
478
|
}
|
|
479
479
|
return true;
|
|
@@ -481,7 +481,7 @@ var schema;
|
|
|
481
481
|
schema.isValidSubmenuItem = isValidSubmenuItem;
|
|
482
482
|
function isValidItems(items, collector) {
|
|
483
483
|
if (!Array.isArray(items)) {
|
|
484
|
-
collector.error(( localize(
|
|
484
|
+
collector.error(( localize(8789, "submenu items must be an array")));
|
|
485
485
|
return false;
|
|
486
486
|
}
|
|
487
487
|
for (const item of items) {
|
|
@@ -501,15 +501,15 @@ var schema;
|
|
|
501
501
|
schema.isValidItems = isValidItems;
|
|
502
502
|
function isValidSubmenu(submenu, collector) {
|
|
503
503
|
if (typeof submenu !== 'object') {
|
|
504
|
-
collector.error(( localize(
|
|
504
|
+
collector.error(( localize(8790, "submenu items must be an object")));
|
|
505
505
|
return false;
|
|
506
506
|
}
|
|
507
507
|
if (typeof submenu.id !== 'string') {
|
|
508
|
-
collector.error(( localize(
|
|
508
|
+
collector.error(( localize(8787, "property `{0}` is mandatory and must be of type `string`", 'id')));
|
|
509
509
|
return false;
|
|
510
510
|
}
|
|
511
511
|
if (typeof submenu.label !== 'string') {
|
|
512
|
-
collector.error(( localize(
|
|
512
|
+
collector.error(( localize(8787, "property `{0}` is mandatory and must be of type `string`", 'label')));
|
|
513
513
|
return false;
|
|
514
514
|
}
|
|
515
515
|
return true;
|
|
@@ -521,24 +521,24 @@ var schema;
|
|
|
521
521
|
properties: {
|
|
522
522
|
command: {
|
|
523
523
|
description: ( localize(
|
|
524
|
-
|
|
524
|
+
8791,
|
|
525
525
|
'Identifier of the command to execute. The command must be declared in the \'commands\'-section'
|
|
526
526
|
)),
|
|
527
527
|
type: 'string'
|
|
528
528
|
},
|
|
529
529
|
alt: {
|
|
530
530
|
description: ( localize(
|
|
531
|
-
|
|
531
|
+
8792,
|
|
532
532
|
'Identifier of an alternative command to execute. The command must be declared in the \'commands\'-section'
|
|
533
533
|
)),
|
|
534
534
|
type: 'string'
|
|
535
535
|
},
|
|
536
536
|
when: {
|
|
537
|
-
description: ( localize(
|
|
537
|
+
description: ( localize(8793, 'Condition which must be true to show this item')),
|
|
538
538
|
type: 'string'
|
|
539
539
|
},
|
|
540
540
|
group: {
|
|
541
|
-
description: ( localize(
|
|
541
|
+
description: ( localize(8794, 'Group into which this item belongs')),
|
|
542
542
|
type: 'string'
|
|
543
543
|
}
|
|
544
544
|
}
|
|
@@ -548,15 +548,15 @@ var schema;
|
|
|
548
548
|
required: ['submenu'],
|
|
549
549
|
properties: {
|
|
550
550
|
submenu: {
|
|
551
|
-
description: ( localize(
|
|
551
|
+
description: ( localize(8795, 'Identifier of the submenu to display in this item.')),
|
|
552
552
|
type: 'string'
|
|
553
553
|
},
|
|
554
554
|
when: {
|
|
555
|
-
description: ( localize(
|
|
555
|
+
description: ( localize(8793, 'Condition which must be true to show this item')),
|
|
556
556
|
type: 'string'
|
|
557
557
|
},
|
|
558
558
|
group: {
|
|
559
|
-
description: ( localize(
|
|
559
|
+
description: ( localize(8794, 'Group into which this item belongs')),
|
|
560
560
|
type: 'string'
|
|
561
561
|
}
|
|
562
562
|
}
|
|
@@ -566,16 +566,16 @@ var schema;
|
|
|
566
566
|
required: ['id', 'label'],
|
|
567
567
|
properties: {
|
|
568
568
|
id: {
|
|
569
|
-
description: ( localize(
|
|
569
|
+
description: ( localize(8796, 'Identifier of the menu to display as a submenu.')),
|
|
570
570
|
type: 'string'
|
|
571
571
|
},
|
|
572
572
|
label: {
|
|
573
|
-
description: ( localize(
|
|
573
|
+
description: ( localize(8797, 'The label of the menu item which leads to this submenu.')),
|
|
574
574
|
type: 'string'
|
|
575
575
|
},
|
|
576
576
|
icon: {
|
|
577
577
|
description: ( localize(
|
|
578
|
-
|
|
578
|
+
8798,
|
|
579
579
|
'(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)`'
|
|
580
580
|
)),
|
|
581
581
|
anyOf: [{
|
|
@@ -585,11 +585,11 @@ var schema;
|
|
|
585
585
|
type: 'object',
|
|
586
586
|
properties: {
|
|
587
587
|
light: {
|
|
588
|
-
description: ( localize(
|
|
588
|
+
description: ( localize(8799, 'Icon path when a light theme is used')),
|
|
589
589
|
type: 'string'
|
|
590
590
|
},
|
|
591
591
|
dark: {
|
|
592
|
-
description: ( localize(
|
|
592
|
+
description: ( localize(8800, 'Icon path when a dark theme is used')),
|
|
593
593
|
type: 'string'
|
|
594
594
|
}
|
|
595
595
|
}
|
|
@@ -598,11 +598,11 @@ var schema;
|
|
|
598
598
|
}
|
|
599
599
|
};
|
|
600
600
|
schema.menusContribution = {
|
|
601
|
-
description: ( localize(
|
|
601
|
+
description: ( localize(8801, "Contributes menu items to the editor")),
|
|
602
602
|
type: 'object',
|
|
603
603
|
properties: index(apiMenus, menu => menu.key, menu => ({
|
|
604
604
|
markdownDescription: menu.proposed ? ( localize(
|
|
605
|
-
|
|
605
|
+
8802,
|
|
606
606
|
"Proposed API, requires `enabledApiProposal: [\"{0}\"]` - {1}",
|
|
607
607
|
menu.proposed,
|
|
608
608
|
menu.description
|
|
@@ -617,18 +617,18 @@ var schema;
|
|
|
617
617
|
}
|
|
618
618
|
};
|
|
619
619
|
schema.submenusContribution = {
|
|
620
|
-
description: ( localize(
|
|
620
|
+
description: ( localize(8803, "Contributes submenu items to the editor")),
|
|
621
621
|
type: 'array',
|
|
622
622
|
items: submenu
|
|
623
623
|
};
|
|
624
624
|
function isValidCommand(command, collector) {
|
|
625
625
|
if (!command) {
|
|
626
|
-
collector.error(( localize(
|
|
626
|
+
collector.error(( localize(8804, "expected non-empty value.")));
|
|
627
627
|
return false;
|
|
628
628
|
}
|
|
629
629
|
if (isFalsyOrWhitespace(command.command)) {
|
|
630
630
|
collector.error(( localize(
|
|
631
|
-
|
|
631
|
+
8787,
|
|
632
632
|
"property `{0}` is mandatory and must be of type `string`",
|
|
633
633
|
'command'
|
|
634
634
|
)));
|
|
@@ -642,7 +642,7 @@ var schema;
|
|
|
642
642
|
}
|
|
643
643
|
if (command.enablement && typeof command.enablement !== 'string') {
|
|
644
644
|
collector.error(( localize(
|
|
645
|
-
|
|
645
|
+
8788,
|
|
646
646
|
"property `{0}` can be omitted or must be of type `string`",
|
|
647
647
|
'precondition'
|
|
648
648
|
)));
|
|
@@ -668,7 +668,7 @@ var schema;
|
|
|
668
668
|
return true;
|
|
669
669
|
}
|
|
670
670
|
collector.error(( localize(
|
|
671
|
-
|
|
671
|
+
8805,
|
|
672
672
|
"property `icon` can be omitted or must be either a string or a literal like `{dark, light}`"
|
|
673
673
|
)));
|
|
674
674
|
return false;
|
|
@@ -676,7 +676,7 @@ var schema;
|
|
|
676
676
|
function isValidLocalizedString(localized, collector, propertyName) {
|
|
677
677
|
if (typeof localized === 'undefined') {
|
|
678
678
|
collector.error(( localize(
|
|
679
|
-
|
|
679
|
+
8806,
|
|
680
680
|
"property `{0}` is mandatory and must be of type `string` or `object`",
|
|
681
681
|
propertyName
|
|
682
682
|
)));
|
|
@@ -684,7 +684,7 @@ var schema;
|
|
|
684
684
|
}
|
|
685
685
|
else if (typeof localized === 'string' && isFalsyOrWhitespace(localized)) {
|
|
686
686
|
collector.error(( localize(
|
|
687
|
-
|
|
687
|
+
8787,
|
|
688
688
|
"property `{0}` is mandatory and must be of type `string`",
|
|
689
689
|
propertyName
|
|
690
690
|
)));
|
|
@@ -692,7 +692,7 @@ var schema;
|
|
|
692
692
|
}
|
|
693
693
|
else if (typeof localized !== 'string' && (isFalsyOrWhitespace(localized.original) || isFalsyOrWhitespace(localized.value))) {
|
|
694
694
|
collector.error(( localize(
|
|
695
|
-
|
|
695
|
+
8807,
|
|
696
696
|
"properties `{0}` and `{1}` are mandatory and must be of type `string`",
|
|
697
697
|
`${propertyName}.value`,
|
|
698
698
|
`${propertyName}.original`
|
|
@@ -706,37 +706,37 @@ var schema;
|
|
|
706
706
|
required: ['command', 'title'],
|
|
707
707
|
properties: {
|
|
708
708
|
command: {
|
|
709
|
-
description: ( localize(
|
|
709
|
+
description: ( localize(8808, 'Identifier of the command to execute')),
|
|
710
710
|
type: 'string'
|
|
711
711
|
},
|
|
712
712
|
title: {
|
|
713
|
-
description: ( localize(
|
|
713
|
+
description: ( localize(8809, 'Title by which the command is represented in the UI')),
|
|
714
714
|
type: 'string'
|
|
715
715
|
},
|
|
716
716
|
shortTitle: {
|
|
717
717
|
markdownDescription: ( localize(
|
|
718
|
-
|
|
718
|
+
8810,
|
|
719
719
|
'(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.'
|
|
720
720
|
)),
|
|
721
721
|
type: 'string'
|
|
722
722
|
},
|
|
723
723
|
category: {
|
|
724
724
|
description: ( localize(
|
|
725
|
-
|
|
725
|
+
8811,
|
|
726
726
|
'(Optional) Category string by which the command is grouped in the UI'
|
|
727
727
|
)),
|
|
728
728
|
type: 'string'
|
|
729
729
|
},
|
|
730
730
|
enablement: {
|
|
731
731
|
description: ( localize(
|
|
732
|
-
|
|
732
|
+
8812,
|
|
733
733
|
'(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.'
|
|
734
734
|
)),
|
|
735
735
|
type: 'string'
|
|
736
736
|
},
|
|
737
737
|
icon: {
|
|
738
738
|
description: ( localize(
|
|
739
|
-
|
|
739
|
+
8813,
|
|
740
740
|
'(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)`'
|
|
741
741
|
)),
|
|
742
742
|
anyOf: [{
|
|
@@ -746,11 +746,11 @@ var schema;
|
|
|
746
746
|
type: 'object',
|
|
747
747
|
properties: {
|
|
748
748
|
light: {
|
|
749
|
-
description: ( localize(
|
|
749
|
+
description: ( localize(8814, 'Icon path when a light theme is used')),
|
|
750
750
|
type: 'string'
|
|
751
751
|
},
|
|
752
752
|
dark: {
|
|
753
|
-
description: ( localize(
|
|
753
|
+
description: ( localize(8815, 'Icon path when a dark theme is used')),
|
|
754
754
|
type: 'string'
|
|
755
755
|
}
|
|
756
756
|
}
|
|
@@ -759,7 +759,7 @@ var schema;
|
|
|
759
759
|
}
|
|
760
760
|
};
|
|
761
761
|
schema.commandsContribution = {
|
|
762
|
-
description: ( localize(
|
|
762
|
+
description: ( localize(8816, "Contributes commands to the command palette.")),
|
|
763
763
|
oneOf: [
|
|
764
764
|
commandType,
|
|
765
765
|
{
|
|
@@ -803,7 +803,7 @@ commandsExtensionPoint.setHandler(extensions => {
|
|
|
803
803
|
if (existingCmd) {
|
|
804
804
|
if (existingCmd.source) {
|
|
805
805
|
extension.collector.info(( localize(
|
|
806
|
-
|
|
806
|
+
8817,
|
|
807
807
|
"Command `{0}` already registered by {1} ({2})",
|
|
808
808
|
userFriendlyCommand.command,
|
|
809
809
|
existingCmd.source.title,
|
|
@@ -811,7 +811,7 @@ commandsExtensionPoint.setHandler(extensions => {
|
|
|
811
811
|
)));
|
|
812
812
|
}
|
|
813
813
|
else {
|
|
814
|
-
extension.collector.info(( localize(
|
|
814
|
+
extension.collector.info(( localize(8818, "Command `{0}` already registered", userFriendlyCommand.command)));
|
|
815
815
|
}
|
|
816
816
|
}
|
|
817
817
|
_commandRegistrations.add(MenuRegistry.addCommand({
|
|
@@ -852,19 +852,19 @@ submenusExtensionPoint.setHandler(extensions => {
|
|
|
852
852
|
continue;
|
|
853
853
|
}
|
|
854
854
|
if (!submenuInfo.id) {
|
|
855
|
-
collector.warn(( localize(
|
|
855
|
+
collector.warn(( localize(8819, "`{0}` is not a valid submenu identifier", submenuInfo.id)));
|
|
856
856
|
continue;
|
|
857
857
|
}
|
|
858
858
|
if (( (_submenus.has(submenuInfo.id)))) {
|
|
859
859
|
collector.info(( localize(
|
|
860
|
-
|
|
860
|
+
8820,
|
|
861
861
|
"The `{0}` submenu was already previously registered.",
|
|
862
862
|
submenuInfo.id
|
|
863
863
|
)));
|
|
864
864
|
continue;
|
|
865
865
|
}
|
|
866
866
|
if (!submenuInfo.label) {
|
|
867
|
-
collector.warn(( localize(
|
|
867
|
+
collector.warn(( localize(8821, "`{0}` is not a valid submenu label", submenuInfo.label)));
|
|
868
868
|
continue;
|
|
869
869
|
}
|
|
870
870
|
let absoluteIcon;
|
|
@@ -921,7 +921,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
921
921
|
}
|
|
922
922
|
if (menu.proposed && !isProposedApiEnabled(extension.description, menu.proposed)) {
|
|
923
923
|
collector.error(( localize(
|
|
924
|
-
|
|
924
|
+
8822,
|
|
925
925
|
"{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}",
|
|
926
926
|
entry[0],
|
|
927
927
|
menu.proposed,
|
|
@@ -936,7 +936,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
936
936
|
const alt = menuItem.alt && MenuRegistry.getCommand(menuItem.alt) || undefined;
|
|
937
937
|
if (!command) {
|
|
938
938
|
collector.error(( localize(
|
|
939
|
-
|
|
939
|
+
8823,
|
|
940
940
|
"Menu item references a command `{0}` which is not defined in the 'commands' section.",
|
|
941
941
|
menuItem.command
|
|
942
942
|
)));
|
|
@@ -944,20 +944,20 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
944
944
|
}
|
|
945
945
|
if (menuItem.alt && !alt) {
|
|
946
946
|
collector.warn(( localize(
|
|
947
|
-
|
|
947
|
+
8824,
|
|
948
948
|
"Menu item references an alt-command `{0}` which is not defined in the 'commands' section.",
|
|
949
949
|
menuItem.alt
|
|
950
950
|
)));
|
|
951
951
|
}
|
|
952
952
|
if (menuItem.command === menuItem.alt) {
|
|
953
|
-
collector.info(( localize(
|
|
953
|
+
collector.info(( localize(8825, "Menu item references the same command as default and alt-command")));
|
|
954
954
|
}
|
|
955
955
|
item = { command, alt, group: undefined, order: undefined, when: undefined };
|
|
956
956
|
}
|
|
957
957
|
else {
|
|
958
958
|
if (menu.supportsSubmenus === false) {
|
|
959
959
|
collector.error(( localize(
|
|
960
|
-
|
|
960
|
+
8826,
|
|
961
961
|
"Menu item references a submenu for a menu which doesn't have submenu support."
|
|
962
962
|
)));
|
|
963
963
|
continue;
|
|
@@ -965,7 +965,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
965
965
|
const submenu = _submenus.get(menuItem.submenu);
|
|
966
966
|
if (!submenu) {
|
|
967
967
|
collector.error(( localize(
|
|
968
|
-
|
|
968
|
+
8827,
|
|
969
969
|
"Menu item references a submenu `{0}` which is not defined in the 'submenus' section.",
|
|
970
970
|
menuItem.submenu
|
|
971
971
|
)));
|
|
@@ -978,7 +978,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
978
978
|
}
|
|
979
979
|
if (( (submenuRegistrations.has(submenu.id.id)))) {
|
|
980
980
|
collector.warn(( localize(
|
|
981
|
-
|
|
981
|
+
8828,
|
|
982
982
|
"The `{0}` submenu was already contributed to the `{1}` menu.",
|
|
983
983
|
menuItem.submenu,
|
|
984
984
|
entry[0]
|
|
@@ -1000,7 +1000,7 @@ menusExtensionPoint.setHandler(extensions => {
|
|
|
1000
1000
|
}
|
|
1001
1001
|
if (menu.id === MenuId.ViewContainerTitle && !menuItem.when?.includes('viewContainer == workbench.view.debug')) {
|
|
1002
1002
|
collector.error(( localize(
|
|
1003
|
-
|
|
1003
|
+
8829,
|
|
1004
1004
|
"The {0} menu contribution must check {1} in its {2} clause.",
|
|
1005
1005
|
'`viewContainer/title`',
|
|
1006
1006
|
'`viewContainer == workbench.view.debug`',
|
|
@@ -1080,10 +1080,10 @@ let CommandsTableRenderer = class CommandsTableRenderer extends Disposable {
|
|
|
1080
1080
|
return { data: { headers: [], rows: [] }, dispose: () => { } };
|
|
1081
1081
|
}
|
|
1082
1082
|
const headers = [
|
|
1083
|
-
( localize(
|
|
1084
|
-
( localize(
|
|
1085
|
-
( localize(
|
|
1086
|
-
( localize(
|
|
1083
|
+
( localize(8830, "ID")),
|
|
1084
|
+
( localize(8831, "Title")),
|
|
1085
|
+
( localize(8832, "Keyboard Shortcuts")),
|
|
1086
|
+
( localize(8833, "Menu Contexts"))
|
|
1087
1087
|
];
|
|
1088
1088
|
const rows = ( (commands.sort((a, b) => a.id.localeCompare(b.id))
|
|
1089
1089
|
.map(command => {
|
|
@@ -1123,7 +1123,7 @@ CommandsTableRenderer = ( (__decorate([
|
|
|
1123
1123
|
], CommandsTableRenderer)));
|
|
1124
1124
|
( (Registry.as(Extensions.ExtensionFeaturesRegistry))).registerExtensionFeature({
|
|
1125
1125
|
id: 'commands',
|
|
1126
|
-
label: ( localize(
|
|
1126
|
+
label: ( localize(8834, "Commands")),
|
|
1127
1127
|
access: {
|
|
1128
1128
|
canToggle: false,
|
|
1129
1129
|
},
|
|
@@ -46,35 +46,35 @@ import { IUserDataProfileService } from 'vscode/vscode/vs/workbench/services/use
|
|
|
46
46
|
var WorkbenchKeybindingService_1;
|
|
47
47
|
function isValidContributedKeyBinding(keyBinding, rejects) {
|
|
48
48
|
if (!keyBinding) {
|
|
49
|
-
rejects.push(( localize(
|
|
49
|
+
rejects.push(( localize(3054, "expected non-empty value.")));
|
|
50
50
|
return false;
|
|
51
51
|
}
|
|
52
52
|
if (typeof keyBinding.command !== 'string') {
|
|
53
53
|
rejects.push(( localize(
|
|
54
|
-
|
|
54
|
+
3055,
|
|
55
55
|
"property `{0}` is mandatory and must be of type `string`",
|
|
56
56
|
'command'
|
|
57
57
|
)));
|
|
58
58
|
return false;
|
|
59
59
|
}
|
|
60
60
|
if (keyBinding.key && typeof keyBinding.key !== 'string') {
|
|
61
|
-
rejects.push(( localize(
|
|
61
|
+
rejects.push(( localize(3056, "property `{0}` can be omitted or must be of type `string`", 'key')));
|
|
62
62
|
return false;
|
|
63
63
|
}
|
|
64
64
|
if (keyBinding.when && typeof keyBinding.when !== 'string') {
|
|
65
|
-
rejects.push(( localize(
|
|
65
|
+
rejects.push(( localize(3056, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
66
66
|
return false;
|
|
67
67
|
}
|
|
68
68
|
if (keyBinding.mac && typeof keyBinding.mac !== 'string') {
|
|
69
|
-
rejects.push(( localize(
|
|
69
|
+
rejects.push(( localize(3056, "property `{0}` can be omitted or must be of type `string`", 'mac')));
|
|
70
70
|
return false;
|
|
71
71
|
}
|
|
72
72
|
if (keyBinding.linux && typeof keyBinding.linux !== 'string') {
|
|
73
|
-
rejects.push(( localize(
|
|
73
|
+
rejects.push(( localize(3056, "property `{0}` can be omitted or must be of type `string`", 'linux')));
|
|
74
74
|
return false;
|
|
75
75
|
}
|
|
76
76
|
if (keyBinding.win && typeof keyBinding.win !== 'string') {
|
|
77
|
-
rejects.push(( localize(
|
|
77
|
+
rejects.push(( localize(3056, "property `{0}` can be omitted or must be of type `string`", 'win')));
|
|
78
78
|
return false;
|
|
79
79
|
}
|
|
80
80
|
return true;
|
|
@@ -84,33 +84,33 @@ const keybindingType = {
|
|
|
84
84
|
default: { command: '', key: '' },
|
|
85
85
|
properties: {
|
|
86
86
|
command: {
|
|
87
|
-
description: ( localize(
|
|
87
|
+
description: ( localize(3057, 'Identifier of the command to run when keybinding is triggered.')),
|
|
88
88
|
type: 'string'
|
|
89
89
|
},
|
|
90
90
|
args: {
|
|
91
|
-
description: ( localize(
|
|
91
|
+
description: ( localize(3058, "Arguments to pass to the command to execute."))
|
|
92
92
|
},
|
|
93
93
|
key: {
|
|
94
94
|
description: ( localize(
|
|
95
|
-
|
|
95
|
+
3059,
|
|
96
96
|
'Key or key sequence (separate keys with plus-sign and sequences with space, e.g. Ctrl+O and Ctrl+L L for a chord).'
|
|
97
97
|
)),
|
|
98
98
|
type: 'string'
|
|
99
99
|
},
|
|
100
100
|
mac: {
|
|
101
|
-
description: ( localize(
|
|
101
|
+
description: ( localize(3060, 'Mac specific key or key sequence.')),
|
|
102
102
|
type: 'string'
|
|
103
103
|
},
|
|
104
104
|
linux: {
|
|
105
|
-
description: ( localize(
|
|
105
|
+
description: ( localize(3061, 'Linux specific key or key sequence.')),
|
|
106
106
|
type: 'string'
|
|
107
107
|
},
|
|
108
108
|
win: {
|
|
109
|
-
description: ( localize(
|
|
109
|
+
description: ( localize(3062, 'Windows specific key or key sequence.')),
|
|
110
110
|
type: 'string'
|
|
111
111
|
},
|
|
112
112
|
when: {
|
|
113
|
-
description: ( localize(
|
|
113
|
+
description: ( localize(3063, 'Condition when the key is active.')),
|
|
114
114
|
type: 'string'
|
|
115
115
|
},
|
|
116
116
|
}
|
|
@@ -119,7 +119,7 @@ const keybindingsExtPoint = ExtensionsRegistry.registerExtensionPoint({
|
|
|
119
119
|
extensionPoint: 'keybindings',
|
|
120
120
|
deps: [commandsExtensionPoint],
|
|
121
121
|
jsonSchema: {
|
|
122
|
-
description: ( localize(
|
|
122
|
+
description: ( localize(3064, "Contributes keybindings.")),
|
|
123
123
|
oneOf: [
|
|
124
124
|
keybindingType,
|
|
125
125
|
{
|
|
@@ -502,7 +502,7 @@ let WorkbenchKeybindingService = WorkbenchKeybindingService_1 = class WorkbenchK
|
|
|
502
502
|
}
|
|
503
503
|
if (rejects.length > 0) {
|
|
504
504
|
collector.error(( localize(
|
|
505
|
-
|
|
505
|
+
3065,
|
|
506
506
|
"Invalid `contributes.{0}`: {1}",
|
|
507
507
|
keybindingsExtPoint.name,
|
|
508
508
|
rejects.join('\n')
|
|
@@ -592,7 +592,7 @@ let WorkbenchKeybindingService = WorkbenchKeybindingService_1 = class WorkbenchK
|
|
|
592
592
|
static _getAllCommandsAsComment(boundCommands) {
|
|
593
593
|
const unboundCommands = getAllUnboundCommands(boundCommands);
|
|
594
594
|
const pretty = unboundCommands.sort().join('\n// - ');
|
|
595
|
-
return '// ' + ( localize(
|
|
595
|
+
return '// ' + ( localize(3066, "Here are other available commands: ")) + '\n// - ' + pretty;
|
|
596
596
|
}
|
|
597
597
|
mightProducePrintableCharacter(event) {
|
|
598
598
|
if (event.ctrlKey || event.metaKey || event.altKey) {
|
|
@@ -717,7 +717,7 @@ class KeybindingsJsonSchema {
|
|
|
717
717
|
this.schema = {
|
|
718
718
|
id: KeybindingsJsonSchema.schemaId,
|
|
719
719
|
type: 'array',
|
|
720
|
-
title: ( localize(
|
|
720
|
+
title: ( localize(3067, "Keybindings configuration")),
|
|
721
721
|
allowTrailingCommas: true,
|
|
722
722
|
allowComments: true,
|
|
723
723
|
definitions: {
|
|
@@ -741,7 +741,7 @@ class KeybindingsJsonSchema {
|
|
|
741
741
|
'type': 'string',
|
|
742
742
|
'enum': this.commandsEnum,
|
|
743
743
|
'enumDescriptions': this.commandsEnumDescriptions,
|
|
744
|
-
'description': ( localize(
|
|
744
|
+
'description': ( localize(3068, "Name of the command to execute")),
|
|
745
745
|
},
|
|
746
746
|
'commandType': {
|
|
747
747
|
'anyOf': [
|
|
@@ -752,7 +752,7 @@ class KeybindingsJsonSchema {
|
|
|
752
752
|
'type': 'string',
|
|
753
753
|
'enum': this.removalCommandsEnum,
|
|
754
754
|
'enumDescriptions': this.commandsEnumDescriptions,
|
|
755
|
-
'description': ( localize(
|
|
755
|
+
'description': ( localize(3069, "Name of the command to remove keyboard shortcut for")),
|
|
756
756
|
},
|
|
757
757
|
{
|
|
758
758
|
'type': 'string'
|
|
@@ -770,7 +770,7 @@ class KeybindingsJsonSchema {
|
|
|
770
770
|
'properties': {
|
|
771
771
|
'key': {
|
|
772
772
|
'type': 'string',
|
|
773
|
-
'description': ( localize(
|
|
773
|
+
'description': ( localize(3070, "Key or key sequence (separated by space)")),
|
|
774
774
|
},
|
|
775
775
|
'command': {
|
|
776
776
|
'anyOf': [
|
|
@@ -783,7 +783,7 @@ class KeybindingsJsonSchema {
|
|
|
783
783
|
'type': 'array'
|
|
784
784
|
},
|
|
785
785
|
'errorMessage': ( localize(
|
|
786
|
-
|
|
786
|
+
3071,
|
|
787
787
|
"Incorrect type. Expected \"{0}\". The field 'command' does not support running multiple commands. Use command 'runCommands' to pass it multiple commands to run.",
|
|
788
788
|
'string'
|
|
789
789
|
))
|
|
@@ -799,10 +799,10 @@ class KeybindingsJsonSchema {
|
|
|
799
799
|
},
|
|
800
800
|
'when': {
|
|
801
801
|
'type': 'string',
|
|
802
|
-
'description': ( localize(
|
|
802
|
+
'description': ( localize(3072, "Condition when the key is active."))
|
|
803
803
|
},
|
|
804
804
|
'args': {
|
|
805
|
-
'description': ( localize(
|
|
805
|
+
'description': ( localize(3073, "Arguments to pass to the command to execute."))
|
|
806
806
|
}
|
|
807
807
|
},
|
|
808
808
|
'$ref': '#/definitions/commandsSchemas'
|
|
@@ -491,12 +491,12 @@ const keyboardConfiguration = {
|
|
|
491
491
|
'id': 'keyboard',
|
|
492
492
|
'order': 15,
|
|
493
493
|
'type': 'object',
|
|
494
|
-
'title': ( localize(
|
|
494
|
+
'title': ( localize(3074, "Keyboard")),
|
|
495
495
|
'properties': {
|
|
496
496
|
'keyboard.layout': {
|
|
497
497
|
'type': 'string',
|
|
498
498
|
'default': 'autodetect',
|
|
499
|
-
'description': ( localize(
|
|
499
|
+
'description': ( localize(3075, "Control the keyboard layout used in web."))
|
|
500
500
|
}
|
|
501
501
|
}
|
|
502
502
|
};
|