@codingame/monaco-vscode-notebook-service-override 7.1.0 → 8.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 +2 -2
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/emptyTextEditorHint/emptyTextEditorHint.js +14 -20
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands.js +22 -23
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/cellDiagnosticsActions.js +3 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/diagnosticCellStatusBarContrib.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders.js +5 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard.js +7 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.js +12 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFind.js +3 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/format/formatting.js +5 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/gettingStarted/notebookGettingStarted.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/layout/layoutActions.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/navigation/arrow.js +16 -19
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariables.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesDataSource.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesTree.js +3 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesView.js +4 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/outline/notebookOutline.js +13 -17
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/profile/notebookProfile.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/saveParticipants/saveParticipants.js +15 -18
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/troubleshoot/layout.js +4 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +25 -26
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +3 -20
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/editActions.js +629 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/executeActions.js +23 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +25 -26
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/layoutActions.js +18 -19
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/notebookIndentationActions.js +208 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/sectionActions.js +13 -14
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +11 -15
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffActions.js +12 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebook.contribution.js +95 -163
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibilityHelp.js +38 -50
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibleView.js +11 -12
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookExtensionPoint.js +43 -53
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookExecutionServiceImpl.js +2 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKernelHistoryServiceImpl.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKeymapServiceImpl.js +5 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookLoggingServiceImpl.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookServiceImpl.js +2 -3
- package/vscode/src/vs/workbench/services/workingCopy/common/fileWorkingCopyManager.js +16 -20
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopyManager.js +2 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-notebook-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "8.0.0",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "CodinGame",
|
|
@@ -29,6 +29,6 @@
|
|
|
29
29
|
}
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"vscode": "npm:@codingame/monaco-vscode-api@
|
|
32
|
+
"vscode": "npm:@codingame/monaco-vscode-api@8.0.0"
|
|
33
33
|
}
|
|
34
34
|
}
|
|
@@ -3,7 +3,7 @@ import './emptyTextEditorHint.css.js';
|
|
|
3
3
|
import { $ as $$1, getActiveWindow, addDisposableListener, EventType } from 'vscode/vscode/vs/base/browser/dom';
|
|
4
4
|
import { dispose, DisposableStore } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
5
5
|
import { ContentWidgetPositionPreference } from 'vscode/vscode/vs/editor/browser/editorBrowser';
|
|
6
|
-
import {
|
|
6
|
+
import { localize } from 'vscode/vscode/vs/nls';
|
|
7
7
|
import { ChangeLanguageAction } from 'vscode/vscode/vs/workbench/browser/parts/editor/editorStatus';
|
|
8
8
|
import { ICommandService } from 'vscode/vscode/vs/platform/commands/common/commands.service';
|
|
9
9
|
import { PLAINTEXT_LANGUAGE_ID } from 'vscode/vscode/vs/editor/common/languages/modesRegistry';
|
|
@@ -32,7 +32,6 @@ import { IChatAgentService } from 'vscode/vscode/vs/workbench/contrib/chat/commo
|
|
|
32
32
|
import { IContextMenuService } from 'vscode/vscode/vs/platform/contextview/browser/contextView.service';
|
|
33
33
|
import { StandardMouseEvent } from 'vscode/vscode/vs/base/browser/mouseEvent';
|
|
34
34
|
|
|
35
|
-
const _moduleId = "vs/workbench/contrib/codeEditor/browser/emptyTextEditorHint/emptyTextEditorHint";
|
|
36
35
|
const $ = $$1;
|
|
37
36
|
const emptyTextEditorHintSetting = 'workbench.editor.empty.hint';
|
|
38
37
|
let EmptyTextEditorHintContribution = class EmptyTextEditorHintContribution {
|
|
@@ -198,8 +197,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
198
197
|
getActions: () => {
|
|
199
198
|
return [{
|
|
200
199
|
id: 'workench.action.disableEmptyEditorHint',
|
|
201
|
-
label: (
|
|
202
|
-
tooltip: (
|
|
200
|
+
label: ( localize(10702, "Disable Empty Editor Hint")),
|
|
201
|
+
tooltip: ( localize(10702, "Disable Empty Editor Hint")),
|
|
203
202
|
enabled: true,
|
|
204
203
|
class: undefined,
|
|
205
204
|
run: () => {
|
|
@@ -236,9 +235,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
236
235
|
const keybindingHint = this.keybindingService.lookupKeybinding(inlineChatId);
|
|
237
236
|
const keybindingHintLabel = keybindingHint?.getLabel();
|
|
238
237
|
if (keybindingHint && keybindingHintLabel) {
|
|
239
|
-
const actionPart = (
|
|
240
|
-
|
|
241
|
-
1,
|
|
238
|
+
const actionPart = ( localize(
|
|
239
|
+
10703,
|
|
242
240
|
'Press {0} to ask {1} to do something. ',
|
|
243
241
|
keybindingHintLabel,
|
|
244
242
|
providerName
|
|
@@ -269,16 +267,15 @@ class EmptyTextEditorHintContentWidget {
|
|
|
269
267
|
this.toDispose.add(addDisposableListener(label.element, EventType.CLICK, handleClick));
|
|
270
268
|
}
|
|
271
269
|
hintElement.appendChild(after);
|
|
272
|
-
const typeToDismiss = (
|
|
270
|
+
const typeToDismiss = ( localize(10704, 'Start typing to dismiss.'));
|
|
273
271
|
const textHint2 = $('span', undefined, typeToDismiss);
|
|
274
272
|
textHint2.style.fontStyle = 'italic';
|
|
275
273
|
hintElement.appendChild(textHint2);
|
|
276
274
|
ariaLabel = actionPart.concat(typeToDismiss);
|
|
277
275
|
}
|
|
278
276
|
else {
|
|
279
|
-
const hintMsg = (
|
|
280
|
-
|
|
281
|
-
3,
|
|
277
|
+
const hintMsg = ( localize(
|
|
278
|
+
10705,
|
|
282
279
|
'[[Ask {0} to do something]] or start typing to dismiss.',
|
|
283
280
|
providerName
|
|
284
281
|
));
|
|
@@ -337,9 +334,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
337
334
|
this.editorGroupsService.activeGroup.closeEditor(activeEditorInput, { preserveFocus: true });
|
|
338
335
|
}
|
|
339
336
|
};
|
|
340
|
-
const hintMsg = (
|
|
341
|
-
|
|
342
|
-
4,
|
|
337
|
+
const hintMsg = ( localize(
|
|
338
|
+
10706,
|
|
343
339
|
'[[Select a language]], or [[fill with template]], or [[open a different editor]] to get started.\nStart typing to dismiss or [[don\'t show]] this again.'
|
|
344
340
|
));
|
|
345
341
|
const hintElement = renderFormattedText(hintMsg, {
|
|
@@ -349,9 +345,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
349
345
|
hintElement.style.fontStyle = 'italic';
|
|
350
346
|
const keybindingsLookup = [ChangeLanguageAction.ID, ApplyFileSnippetAction.Id, 'welcome.showNewFileEntries'];
|
|
351
347
|
const keybindingLabels = ( (keybindingsLookup.map((id) => this.keybindingService.lookupKeybinding(id)?.getLabel() ?? id)));
|
|
352
|
-
const ariaLabel = (
|
|
353
|
-
|
|
354
|
-
5,
|
|
348
|
+
const ariaLabel = ( localize(
|
|
349
|
+
10707,
|
|
355
350
|
'Execute {0} to select a language, execute {1} to fill with template, or execute {2} to open a different editor and get started. Start typing to dismiss.',
|
|
356
351
|
...keybindingLabels
|
|
357
352
|
));
|
|
@@ -371,9 +366,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
371
366
|
const inlineChatProviders = this.chatAgentService.getActivatedAgents().filter(candidate => candidate.locations.includes(ChatAgentLocation.Editor));
|
|
372
367
|
const { hintElement, ariaLabel } = !inlineChatProviders.length ? this._getHintDefault() : this._getHintInlineChat(inlineChatProviders);
|
|
373
368
|
this.domNode.append(hintElement);
|
|
374
|
-
this.ariaLabel = ariaLabel.concat((
|
|
375
|
-
|
|
376
|
-
6,
|
|
369
|
+
this.ariaLabel = ariaLabel.concat(( localize(
|
|
370
|
+
10708,
|
|
377
371
|
' Toggle {0} in settings to disable this hint.',
|
|
378
372
|
AccessibilityVerbositySettingId.EmptyEditorHint
|
|
379
373
|
)));
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { KeyMod, KeyCode, KeyChord } from 'vscode/vscode/vs/base/common/keyCodes';
|
|
2
2
|
import { Mimes } from 'vscode/vscode/vs/base/common/mime';
|
|
3
3
|
import { IBulkEditService, ResourceTextEdit } from 'vscode/vscode/vs/editor/browser/services/bulkEditService';
|
|
4
|
-
import {
|
|
4
|
+
import { localize2, localize } from 'vscode/vscode/vs/nls';
|
|
5
5
|
import { registerAction2, MenuId } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
6
6
|
import { ContextKeyExpr } from 'vscode/vscode/vs/platform/contextkey/common/contextkey';
|
|
7
7
|
import { InputFocusedContext, InputFocusedContextKey } from 'vscode/vscode/vs/platform/contextkey/common/contextkeys';
|
|
@@ -17,7 +17,6 @@ import { INotificationService } from 'vscode/vscode/vs/platform/notification/com
|
|
|
17
17
|
import { EditorContextKeys } from 'vscode/vscode/vs/editor/common/editorContextKeys';
|
|
18
18
|
import { IConfigurationService } from 'vscode/vscode/vs/platform/configuration/common/configuration.service';
|
|
19
19
|
|
|
20
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands";
|
|
21
20
|
const MOVE_CELL_UP_COMMAND_ID = 'notebook.cell.moveUp';
|
|
22
21
|
const MOVE_CELL_DOWN_COMMAND_ID = 'notebook.cell.moveDown';
|
|
23
22
|
const COPY_CELL_UP_COMMAND_ID = 'notebook.cell.copyUp';
|
|
@@ -26,7 +25,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
26
25
|
constructor() {
|
|
27
26
|
super({
|
|
28
27
|
id: MOVE_CELL_UP_COMMAND_ID,
|
|
29
|
-
title: (
|
|
28
|
+
title: ( localize2(7955, "Move Cell Up")),
|
|
30
29
|
icon: moveUpIcon,
|
|
31
30
|
keybinding: {
|
|
32
31
|
primary: KeyMod.Alt | KeyCode.UpArrow,
|
|
@@ -49,7 +48,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
49
48
|
constructor() {
|
|
50
49
|
super({
|
|
51
50
|
id: MOVE_CELL_DOWN_COMMAND_ID,
|
|
52
|
-
title: (
|
|
51
|
+
title: ( localize2(7956, "Move Cell Down")),
|
|
53
52
|
icon: moveDownIcon,
|
|
54
53
|
keybinding: {
|
|
55
54
|
primary: KeyMod.Alt | KeyCode.DownArrow,
|
|
@@ -72,7 +71,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
72
71
|
constructor() {
|
|
73
72
|
super({
|
|
74
73
|
id: COPY_CELL_UP_COMMAND_ID,
|
|
75
|
-
title: (
|
|
74
|
+
title: ( localize2(7957, "Copy Cell Up")),
|
|
76
75
|
keybinding: {
|
|
77
76
|
primary: KeyMod.Alt | KeyMod.Shift | KeyCode.UpArrow,
|
|
78
77
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, (InputFocusedContext.toNegated())))),
|
|
@@ -88,7 +87,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
88
87
|
constructor() {
|
|
89
88
|
super({
|
|
90
89
|
id: COPY_CELL_DOWN_COMMAND_ID,
|
|
91
|
-
title: (
|
|
90
|
+
title: ( localize2(7958, "Copy Cell Down")),
|
|
92
91
|
keybinding: {
|
|
93
92
|
primary: KeyMod.Alt | KeyMod.Shift | KeyCode.DownArrow,
|
|
94
93
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, (InputFocusedContext.toNegated())))),
|
|
@@ -114,7 +113,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
114
113
|
constructor() {
|
|
115
114
|
super({
|
|
116
115
|
id: SPLIT_CELL_COMMAND_ID,
|
|
117
|
-
title: (
|
|
116
|
+
title: ( localize2(7959, "Split Cell")),
|
|
118
117
|
menu: {
|
|
119
118
|
id: MenuId.NotebookCellTitle,
|
|
120
119
|
when: ( (ContextKeyExpr.and(
|
|
@@ -184,7 +183,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
184
183
|
constructor() {
|
|
185
184
|
super({
|
|
186
185
|
id: JOIN_CELL_ABOVE_COMMAND_ID,
|
|
187
|
-
title: (
|
|
186
|
+
title: ( localize2(7960, "Join With Previous Cell")),
|
|
188
187
|
keybinding: {
|
|
189
188
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
190
189
|
primary: KeyMod.WinCtrl | KeyMod.Alt | KeyMod.Shift | KeyCode.KeyJ,
|
|
@@ -207,7 +206,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
207
206
|
constructor() {
|
|
208
207
|
super({
|
|
209
208
|
id: JOIN_CELL_BELOW_COMMAND_ID,
|
|
210
|
-
title: (
|
|
209
|
+
title: ( localize2(7961, "Join With Next Cell")),
|
|
211
210
|
keybinding: {
|
|
212
211
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
213
212
|
primary: KeyMod.WinCtrl | KeyMod.Alt | KeyCode.KeyJ,
|
|
@@ -230,7 +229,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
230
229
|
constructor() {
|
|
231
230
|
super({
|
|
232
231
|
id: JOIN_SELECTED_CELLS_COMMAND_ID,
|
|
233
|
-
title: (
|
|
232
|
+
title: ( localize2(7962, "Join Selected Cells")),
|
|
234
233
|
menu: {
|
|
235
234
|
id: MenuId.NotebookCellTitle,
|
|
236
235
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE))),
|
|
@@ -251,7 +250,7 @@ registerAction2(class ChangeCellToCodeAction extends NotebookMultiCellAction {
|
|
|
251
250
|
constructor() {
|
|
252
251
|
super({
|
|
253
252
|
id: CHANGE_CELL_TO_CODE_COMMAND_ID,
|
|
254
|
-
title: (
|
|
253
|
+
title: ( localize2(7963, "Change Cell to Code")),
|
|
255
254
|
keybinding: {
|
|
256
255
|
when: ( (ContextKeyExpr.and(
|
|
257
256
|
NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -285,7 +284,7 @@ registerAction2(class ChangeCellToMarkdownAction extends NotebookMultiCellAction
|
|
|
285
284
|
constructor() {
|
|
286
285
|
super({
|
|
287
286
|
id: CHANGE_CELL_TO_MARKDOWN_COMMAND_ID,
|
|
288
|
-
title: (
|
|
287
|
+
title: ( localize2(7964, "Change Cell to Markdown")),
|
|
289
288
|
keybinding: {
|
|
290
289
|
when: ( (ContextKeyExpr.and(
|
|
291
290
|
NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -327,7 +326,7 @@ registerAction2(class CollapseCellInputAction extends NotebookMultiCellAction {
|
|
|
327
326
|
constructor() {
|
|
328
327
|
super({
|
|
329
328
|
id: COLLAPSE_CELL_INPUT_COMMAND_ID,
|
|
330
|
-
title: (
|
|
329
|
+
title: ( localize2(7965, "Collapse Cell Input")),
|
|
331
330
|
keybinding: {
|
|
332
331
|
when: ( (ContextKeyExpr.and(
|
|
333
332
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -355,7 +354,7 @@ registerAction2(class ExpandCellInputAction extends NotebookMultiCellAction {
|
|
|
355
354
|
constructor() {
|
|
356
355
|
super({
|
|
357
356
|
id: EXPAND_CELL_INPUT_COMMAND_ID,
|
|
358
|
-
title: (
|
|
357
|
+
title: ( localize2(7966, "Expand Cell Input")),
|
|
359
358
|
keybinding: {
|
|
360
359
|
when: ( (ContextKeyExpr.and(NOTEBOOK_CELL_LIST_FOCUSED, NOTEBOOK_CELL_INPUT_COLLAPSED))),
|
|
361
360
|
primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyMod.CtrlCmd | KeyCode.KeyC),
|
|
@@ -379,7 +378,7 @@ registerAction2(class CollapseCellOutputAction extends NotebookMultiCellAction {
|
|
|
379
378
|
constructor() {
|
|
380
379
|
super({
|
|
381
380
|
id: COLLAPSE_CELL_OUTPUT_COMMAND_ID,
|
|
382
|
-
title: (
|
|
381
|
+
title: ( localize2(7967, "Collapse Cell Output")),
|
|
383
382
|
keybinding: {
|
|
384
383
|
when: ( (ContextKeyExpr.and(
|
|
385
384
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -405,7 +404,7 @@ registerAction2(class ExpandCellOuputAction extends NotebookMultiCellAction {
|
|
|
405
404
|
constructor() {
|
|
406
405
|
super({
|
|
407
406
|
id: EXPAND_CELL_OUTPUT_COMMAND_ID,
|
|
408
|
-
title: (
|
|
407
|
+
title: ( localize2(7968, "Expand Cell Output")),
|
|
409
408
|
keybinding: {
|
|
410
409
|
when: ( (ContextKeyExpr.and(NOTEBOOK_CELL_LIST_FOCUSED, NOTEBOOK_CELL_OUTPUT_COLLAPSED))),
|
|
411
410
|
primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyCode.KeyT),
|
|
@@ -427,9 +426,9 @@ registerAction2(class extends NotebookMultiCellAction {
|
|
|
427
426
|
super({
|
|
428
427
|
id: TOGGLE_CELL_OUTPUTS_COMMAND_ID,
|
|
429
428
|
precondition: NOTEBOOK_CELL_LIST_FOCUSED,
|
|
430
|
-
title: (
|
|
429
|
+
title: ( localize2(7969, "Toggle Outputs")),
|
|
431
430
|
metadata: {
|
|
432
|
-
description: (
|
|
431
|
+
description: ( localize(7969, "Toggle Outputs")),
|
|
433
432
|
args: cellExecutionArgs
|
|
434
433
|
}
|
|
435
434
|
});
|
|
@@ -454,7 +453,7 @@ registerAction2(class CollapseAllCellInputsAction extends NotebookMultiCellActio
|
|
|
454
453
|
constructor() {
|
|
455
454
|
super({
|
|
456
455
|
id: COLLAPSE_ALL_CELL_INPUTS_COMMAND_ID,
|
|
457
|
-
title: (
|
|
456
|
+
title: ( localize2(7970, "Collapse All Cell Inputs")),
|
|
458
457
|
f1: true,
|
|
459
458
|
});
|
|
460
459
|
}
|
|
@@ -466,7 +465,7 @@ registerAction2(class ExpandAllCellInputsAction extends NotebookMultiCellAction
|
|
|
466
465
|
constructor() {
|
|
467
466
|
super({
|
|
468
467
|
id: EXPAND_ALL_CELL_INPUTS_COMMAND_ID,
|
|
469
|
-
title: (
|
|
468
|
+
title: ( localize2(7971, "Expand All Cell Inputs")),
|
|
470
469
|
f1: true
|
|
471
470
|
});
|
|
472
471
|
}
|
|
@@ -478,7 +477,7 @@ registerAction2(class CollapseAllCellOutputsAction extends NotebookMultiCellActi
|
|
|
478
477
|
constructor() {
|
|
479
478
|
super({
|
|
480
479
|
id: COLLAPSE_ALL_CELL_OUTPUTS_COMMAND_ID,
|
|
481
|
-
title: (
|
|
480
|
+
title: ( localize2(7972, "Collapse All Cell Outputs")),
|
|
482
481
|
f1: true,
|
|
483
482
|
});
|
|
484
483
|
}
|
|
@@ -490,7 +489,7 @@ registerAction2(class ExpandAllCellOutputsAction extends NotebookMultiCellAction
|
|
|
490
489
|
constructor() {
|
|
491
490
|
super({
|
|
492
491
|
id: EXPAND_ALL_CELL_OUTPUTS_COMMAND_ID,
|
|
493
|
-
title: (
|
|
492
|
+
title: ( localize2(7973, "Expand All Cell Outputs")),
|
|
494
493
|
f1: true
|
|
495
494
|
});
|
|
496
495
|
}
|
|
@@ -502,7 +501,7 @@ registerAction2(class ToggleCellOutputScrolling extends NotebookMultiCellAction
|
|
|
502
501
|
constructor() {
|
|
503
502
|
super({
|
|
504
503
|
id: TOGGLE_CELL_OUTPUT_SCROLLING,
|
|
505
|
-
title: (
|
|
504
|
+
title: ( localize2(7974, "Toggle Scroll Cell Output")),
|
|
506
505
|
keybinding: {
|
|
507
506
|
when: ( (ContextKeyExpr.and(
|
|
508
507
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -2,7 +2,7 @@ import { KeyMod, KeyCode } from 'vscode/vscode/vs/base/common/keyCodes';
|
|
|
2
2
|
import { Range } from 'vscode/vscode/vs/editor/common/core/range';
|
|
3
3
|
import { CodeActionController } from 'vscode/vscode/vs/editor/contrib/codeAction/browser/codeActionController';
|
|
4
4
|
import { CodeActionTriggerSource, CodeActionKind } from 'vscode/vscode/vs/editor/contrib/codeAction/common/types';
|
|
5
|
-
import {
|
|
5
|
+
import { localize2, localize } from 'vscode/vscode/vs/nls';
|
|
6
6
|
import { registerAction2 } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
7
7
|
import { ContextKeyExpr } from 'vscode/vscode/vs/platform/contextkey/common/contextkey';
|
|
8
8
|
import { KeybindingWeight } from 'vscode/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
@@ -10,13 +10,12 @@ import { NotebookCellAction, findTargetCellEditor } from 'vscode/vscode/vs/workb
|
|
|
10
10
|
import { CodeCellViewModel } from 'vscode/vscode/vs/workbench/contrib/notebook/browser/viewModel/codeCellViewModel';
|
|
11
11
|
import { NOTEBOOK_CELL_FOCUSED, NOTEBOOK_CELL_HAS_ERROR_DIAGNOSTICS, NOTEBOOK_CELL_EDITOR_FOCUSED } from 'vscode/vscode/vs/workbench/contrib/notebook/common/notebookContextKeys';
|
|
12
12
|
|
|
13
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/cellDiagnosticsActions";
|
|
14
13
|
const OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID = 'notebook.cell.openFailureActions';
|
|
15
14
|
registerAction2(class extends NotebookCellAction {
|
|
16
15
|
constructor() {
|
|
17
16
|
super({
|
|
18
17
|
id: OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID,
|
|
19
|
-
title: (
|
|
18
|
+
title: ( localize2(10710, "Show Cell Failure Actions")),
|
|
20
19
|
precondition: ( (ContextKeyExpr.and(
|
|
21
20
|
NOTEBOOK_CELL_FOCUSED,
|
|
22
21
|
NOTEBOOK_CELL_HAS_ERROR_DIAGNOSTICS,
|
|
@@ -48,7 +47,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
48
47
|
const editor = findTargetCellEditor(context, context.cell);
|
|
49
48
|
if (editor) {
|
|
50
49
|
const controller = CodeActionController.get(editor);
|
|
51
|
-
controller?.manualTriggerAtCurrentPosition((
|
|
50
|
+
controller?.manualTriggerAtCurrentPosition(( localize(10711, "No code actions available")), CodeActionTriggerSource.Default, { include: CodeActionKind.QuickFix });
|
|
52
51
|
}
|
|
53
52
|
}
|
|
54
53
|
}
|
|
@@ -5,7 +5,7 @@ import 'vscode/vscode/vs/base/common/observableInternal/derived';
|
|
|
5
5
|
import { autorun } from 'vscode/vscode/vs/base/common/observableInternal/autorun';
|
|
6
6
|
import 'vscode/vscode/vs/base/common/observableInternal/utils';
|
|
7
7
|
import 'vscode/vscode/vs/base/common/cancellation';
|
|
8
|
-
import {
|
|
8
|
+
import { localize } from 'vscode/vscode/vs/nls';
|
|
9
9
|
import { IInstantiationService } from 'vscode/vscode/vs/platform/instantiation/common/instantiation';
|
|
10
10
|
import { IKeybindingService } from 'vscode/vscode/vs/platform/keybinding/common/keybinding.service';
|
|
11
11
|
import { OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID } from './cellDiagnosticsActions.js';
|
|
@@ -14,7 +14,6 @@ import { registerNotebookContribution } from 'vscode/vscode/vs/workbench/contrib
|
|
|
14
14
|
import { CodeCellViewModel } from 'vscode/vscode/vs/workbench/contrib/notebook/browser/viewModel/codeCellViewModel';
|
|
15
15
|
import { CellStatusbarAlignment } from 'vscode/vscode/vs/workbench/contrib/notebook/common/notebookCommon';
|
|
16
16
|
|
|
17
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/diagnosticCellStatusBarContrib";
|
|
18
17
|
let DiagnosticCellStatusBarContrib = class DiagnosticCellStatusBarContrib extends Disposable {
|
|
19
18
|
static { this.id = 'workbench.notebook.statusBar.diagtnostic'; }
|
|
20
19
|
constructor(notebookEditor, instantiationService) {
|
|
@@ -41,7 +40,7 @@ let DiagnosticCellStatusBarItem = class DiagnosticCellStatusBarItem extends Disp
|
|
|
41
40
|
let item;
|
|
42
41
|
if (error?.location) {
|
|
43
42
|
const keybinding = this.keybindingService.lookupKeybinding(OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID)?.getLabel();
|
|
44
|
-
const tooltip = (
|
|
43
|
+
const tooltip = ( localize(10712, "Quick Actions {0}", `(${keybinding})`));
|
|
45
44
|
item = {
|
|
46
45
|
text: `$(sparkle)`,
|
|
47
46
|
tooltip,
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders.js
CHANGED
|
@@ -2,7 +2,7 @@ import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
|
|
|
2
2
|
import { Disposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
3
3
|
import { ResourceMap } from 'vscode/vscode/vs/base/common/map';
|
|
4
4
|
import { ILanguageService } from 'vscode/vscode/vs/editor/common/languages/language';
|
|
5
|
-
import {
|
|
5
|
+
import { localize } from 'vscode/vscode/vs/nls';
|
|
6
6
|
import { IConfigurationService } from 'vscode/vscode/vs/platform/configuration/common/configuration.service';
|
|
7
7
|
import { IInstantiationService } from 'vscode/vscode/vs/platform/instantiation/common/instantiation';
|
|
8
8
|
import { IKeybindingService } from 'vscode/vscode/vs/platform/keybinding/common/keybinding.service';
|
|
@@ -16,7 +16,6 @@ import { INotebookService } from 'vscode/vscode/vs/workbench/contrib/notebook/co
|
|
|
16
16
|
import { ILanguageDetectionService } from 'vscode/vscode/vs/workbench/services/languageDetection/common/languageDetectionWorkerService.service';
|
|
17
17
|
import { LifecyclePhase } from 'vscode/vscode/vs/workbench/services/lifecycle/common/lifecycle';
|
|
18
18
|
|
|
19
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders";
|
|
20
19
|
let CellStatusBarLanguagePickerProvider = class CellStatusBarLanguagePickerProvider {
|
|
21
20
|
constructor(_notebookService, _languageService) {
|
|
22
21
|
this._notebookService = _notebookService;
|
|
@@ -40,9 +39,8 @@ let CellStatusBarLanguagePickerProvider = class CellStatusBarLanguagePickerProvi
|
|
|
40
39
|
displayLanguage = this._languageService.getLanguageName(displayLanguage) ?? displayLanguage;
|
|
41
40
|
}
|
|
42
41
|
else {
|
|
43
|
-
const searchTooltip = (
|
|
44
|
-
|
|
45
|
-
0,
|
|
42
|
+
const searchTooltip = ( localize(
|
|
43
|
+
7937,
|
|
46
44
|
"Unknown cell language. Click to search for '{0}' extensions",
|
|
47
45
|
cell.language
|
|
48
46
|
));
|
|
@@ -58,7 +56,7 @@ let CellStatusBarLanguagePickerProvider = class CellStatusBarLanguagePickerProvi
|
|
|
58
56
|
statusBarItems.push({
|
|
59
57
|
text: displayLanguage,
|
|
60
58
|
command: CHANGE_CELL_LANGUAGE,
|
|
61
|
-
tooltip: (
|
|
59
|
+
tooltip: ( localize(7938, "Select Cell Language Mode")),
|
|
62
60
|
alignment: CellStatusbarAlignment.Right,
|
|
63
61
|
priority: -Number.MAX_SAFE_INTEGER
|
|
64
62
|
});
|
|
@@ -122,7 +120,7 @@ let CellStatusBarLanguageDetectionProvider = class CellStatusBarLanguageDetectio
|
|
|
122
120
|
const items = [];
|
|
123
121
|
if (cached.guess && currentLanguageId !== cached.guess) {
|
|
124
122
|
const detectedName = this._languageService.getLanguageName(cached.guess) || cached.guess;
|
|
125
|
-
let tooltip = (
|
|
123
|
+
let tooltip = ( localize(7939, "Accept Detected Language: {0}", detectedName));
|
|
126
124
|
const keybinding = this._keybindingService.lookupKeybinding(DETECT_CELL_LANGUAGE);
|
|
127
125
|
const label = keybinding?.getLabel();
|
|
128
126
|
if (label) {
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
|
|
2
|
-
import {
|
|
2
|
+
import { localize, localize2 } from 'vscode/vscode/vs/nls';
|
|
3
3
|
import { Disposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
4
4
|
import { registerWorkbenchContribution2, WorkbenchPhase } from 'vscode/vscode/vs/workbench/common/contributions';
|
|
5
5
|
import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
@@ -24,7 +24,6 @@ import { ICommandService } from 'vscode/vscode/vs/platform/commands/common/comma
|
|
|
24
24
|
import { showWindowLogActionId } from 'vscode/vscode/vs/workbench/services/log/common/logConstants';
|
|
25
25
|
import { getWindow, getActiveElement, isHTMLElement, isAncestor } from 'vscode/vscode/vs/base/browser/dom';
|
|
26
26
|
|
|
27
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard";
|
|
28
27
|
let _logging = false;
|
|
29
28
|
function toggleLogging() {
|
|
30
29
|
_logging = !_logging;
|
|
@@ -350,7 +349,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
350
349
|
constructor() {
|
|
351
350
|
super({
|
|
352
351
|
id: COPY_CELL_COMMAND_ID,
|
|
353
|
-
title: (
|
|
352
|
+
title: ( localize(7890, "Copy Cell")),
|
|
354
353
|
menu: {
|
|
355
354
|
id: MenuId.NotebookCellTitle,
|
|
356
355
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -373,7 +372,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
373
372
|
constructor() {
|
|
374
373
|
super({
|
|
375
374
|
id: CUT_CELL_COMMAND_ID,
|
|
376
|
-
title: (
|
|
375
|
+
title: ( localize(7891, "Cut Cell")),
|
|
377
376
|
menu: {
|
|
378
377
|
id: MenuId.NotebookCellTitle,
|
|
379
378
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE, NOTEBOOK_CELL_EDITABLE))),
|
|
@@ -396,7 +395,7 @@ registerAction2(class extends NotebookAction {
|
|
|
396
395
|
constructor() {
|
|
397
396
|
super({
|
|
398
397
|
id: PASTE_CELL_COMMAND_ID,
|
|
399
|
-
title: (
|
|
398
|
+
title: ( localize(7892, "Paste Cell")),
|
|
400
399
|
menu: {
|
|
401
400
|
id: MenuId.NotebookCellTitle,
|
|
402
401
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE))),
|
|
@@ -428,7 +427,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
428
427
|
constructor() {
|
|
429
428
|
super({
|
|
430
429
|
id: PASTE_CELL_ABOVE_COMMAND_ID,
|
|
431
|
-
title: (
|
|
430
|
+
title: ( localize(7893, "Paste Cell Above")),
|
|
432
431
|
keybinding: {
|
|
433
432
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, ContextKeyExpr.not(InputFocusedContextKey)))),
|
|
434
433
|
primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KeyV,
|
|
@@ -472,7 +471,7 @@ registerAction2(class extends Action2 {
|
|
|
472
471
|
constructor() {
|
|
473
472
|
super({
|
|
474
473
|
id: 'workbench.action.toggleNotebookClipboardLog',
|
|
475
|
-
title: (
|
|
474
|
+
title: ( localize2(7894, 'Toggle Notebook Clipboard Troubleshooting')),
|
|
476
475
|
category: Categories.Developer,
|
|
477
476
|
f1: true
|
|
478
477
|
});
|
|
@@ -489,7 +488,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
489
488
|
constructor() {
|
|
490
489
|
super({
|
|
491
490
|
id: 'notebook.cell.output.selectAll',
|
|
492
|
-
title: (
|
|
491
|
+
title: ( localize(7895, "Select All")),
|
|
493
492
|
keybinding: {
|
|
494
493
|
primary: KeyMod.CtrlCmd | KeyCode.KeyA,
|
|
495
494
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_OUTPUT_FOCUSED))),
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
|
|
2
|
-
import {
|
|
2
|
+
import { localize } from 'vscode/vscode/vs/nls';
|
|
3
3
|
import { DisposableStore, Disposable, MutableDisposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
4
4
|
import { Schemas } from 'vscode/vscode/vs/base/common/network';
|
|
5
5
|
import { ILanguageFeaturesService } from 'vscode/vscode/vs/editor/common/services/languageFeatures';
|
|
@@ -9,7 +9,7 @@ import { ILogService } from 'vscode/vscode/vs/platform/log/common/log.service';
|
|
|
9
9
|
import { registerWorkbenchContribution2, WorkbenchPhase } from 'vscode/vscode/vs/workbench/common/contributions';
|
|
10
10
|
import { CENTER_ACTIVE_CELL } from '../navigation/arrow.js';
|
|
11
11
|
import { SELECT_KERNEL_ID } from 'vscode/vscode/vs/workbench/contrib/notebook/browser/controller/coreActions';
|
|
12
|
-
import { SELECT_NOTEBOOK_INDENTATION_ID } from '
|
|
12
|
+
import { SELECT_NOTEBOOK_INDENTATION_ID } from '../../controller/editActions.js';
|
|
13
13
|
import { getNotebookEditorFromEditorPane } from 'vscode/vscode/vs/workbench/contrib/notebook/browser/notebookBrowser';
|
|
14
14
|
import { NotebookCellsChangeType } from 'vscode/vscode/vs/workbench/contrib/notebook/common/notebookCommon';
|
|
15
15
|
import { INotebookKernelService } from 'vscode/vscode/vs/workbench/contrib/notebook/common/notebookKernelService.service';
|
|
@@ -19,7 +19,6 @@ import { IStatusbarService } from 'vscode/vscode/vs/workbench/services/statusbar
|
|
|
19
19
|
import { IEditorGroupsService } from 'vscode/vscode/vs/workbench/services/editor/common/editorGroupsService.service';
|
|
20
20
|
import { ServiceCollection } from 'vscode/vscode/vs/platform/instantiation/common/serviceCollection';
|
|
21
21
|
|
|
22
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar";
|
|
23
22
|
let ImplictKernelSelector = class ImplictKernelSelector {
|
|
24
23
|
constructor(notebook, suggested, notebookKernelService, languageFeaturesService, logService) {
|
|
25
24
|
const disposables = ( (new DisposableStore()));
|
|
@@ -111,19 +110,19 @@ let KernelStatus = class KernelStatus extends Disposable {
|
|
|
111
110
|
}
|
|
112
111
|
const tooltip = kernel.description ?? kernel.detail ?? kernel.label;
|
|
113
112
|
this._kernelInfoElement.add(this._statusbarService.addEntry({
|
|
114
|
-
name: (
|
|
113
|
+
name: ( localize(7946, "Notebook Kernel Info")),
|
|
115
114
|
text: `$(notebook-kernel-select) ${kernel.label}`,
|
|
116
115
|
ariaLabel: kernel.label,
|
|
117
|
-
tooltip: isSuggested ? (
|
|
116
|
+
tooltip: isSuggested ? ( localize(7947, "{0} (suggestion)", tooltip)) : tooltip,
|
|
118
117
|
command: SELECT_KERNEL_ID,
|
|
119
118
|
}, SELECT_KERNEL_ID, StatusbarAlignment.RIGHT, 10));
|
|
120
119
|
this._kernelInfoElement.add(kernel.onDidChange(() => this._showKernelStatus(notebook)));
|
|
121
120
|
}
|
|
122
121
|
else {
|
|
123
122
|
this._kernelInfoElement.add(this._statusbarService.addEntry({
|
|
124
|
-
name: (
|
|
125
|
-
text: (
|
|
126
|
-
ariaLabel: (
|
|
123
|
+
name: ( localize(7948, "Notebook Kernel Selection")),
|
|
124
|
+
text: ( localize(7949, "Select Kernel")),
|
|
125
|
+
ariaLabel: ( localize(7949, "Select Kernel")),
|
|
127
126
|
command: SELECT_KERNEL_ID,
|
|
128
127
|
kind: 'prominent'
|
|
129
128
|
}, SELECT_KERNEL_ID, StatusbarAlignment.RIGHT, 10));
|
|
@@ -168,7 +167,7 @@ let ActiveCellStatus = class ActiveCellStatus extends Disposable {
|
|
|
168
167
|
return;
|
|
169
168
|
}
|
|
170
169
|
const entry = {
|
|
171
|
-
name: (
|
|
170
|
+
name: ( localize(7950, "Notebook Editor Selections")),
|
|
172
171
|
text: newText,
|
|
173
172
|
ariaLabel: newText,
|
|
174
173
|
command: CENTER_ACTIVE_CELL
|
|
@@ -192,8 +191,8 @@ let ActiveCellStatus = class ActiveCellStatus extends Disposable {
|
|
|
192
191
|
const numSelected = editor.getSelections().reduce((prev, range) => prev + (range.end - range.start), 0);
|
|
193
192
|
const totalCells = editor.getLength();
|
|
194
193
|
return numSelected > 1 ?
|
|
195
|
-
(
|
|
196
|
-
(
|
|
194
|
+
( localize(7951, "Cell {0} ({1} selected)", idxFocused, numSelected)) :
|
|
195
|
+
( localize(7952, "Cell {0} of {1}", idxFocused, totalCells));
|
|
197
196
|
}
|
|
198
197
|
};
|
|
199
198
|
ActiveCellStatus = ( (__decorate([
|
|
@@ -252,10 +251,10 @@ let NotebookIndentationStatus = class NotebookIndentationStatus extends Disposab
|
|
|
252
251
|
return;
|
|
253
252
|
}
|
|
254
253
|
const entry = {
|
|
255
|
-
name: (
|
|
254
|
+
name: ( localize(7953, "Notebook Indentation")),
|
|
256
255
|
text: newText,
|
|
257
256
|
ariaLabel: newText,
|
|
258
|
-
tooltip: (
|
|
257
|
+
tooltip: ( localize(7954, "Select Indentation")),
|
|
259
258
|
command: SELECT_NOTEBOOK_INDENTATION_ID
|
|
260
259
|
};
|
|
261
260
|
if (!this._accessor.value) {
|
|
@@ -6,7 +6,7 @@ import { ICodeEditorService } from 'vscode/vscode/vs/editor/browser/services/cod
|
|
|
6
6
|
import { EditorOption } from 'vscode/vscode/vs/editor/common/config/editorOptions';
|
|
7
7
|
import { EditorContextKeys } from 'vscode/vscode/vs/editor/common/editorContextKeys';
|
|
8
8
|
import { getSelectionSearchString, StartFindAction, FindStartFocusAction, StartFindReplaceAction } from 'vscode/vscode/vs/editor/contrib/find/browser/findController';
|
|
9
|
-
import {
|
|
9
|
+
import { localize2 } from 'vscode/vscode/vs/nls';
|
|
10
10
|
import { registerAction2, Action2 } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
11
11
|
import { ContextKeyExpr } from 'vscode/vscode/vs/platform/contextkey/common/contextkey';
|
|
12
12
|
import { KeybindingWeight } from 'vscode/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
@@ -18,13 +18,12 @@ import { NotebookFindScopeType, CellUri } from 'vscode/vscode/vs/workbench/contr
|
|
|
18
18
|
import { NOTEBOOK_EDITOR_FOCUSED, KEYBINDING_CONTEXT_NOTEBOOK_FIND_WIDGET_FOCUSED, NOTEBOOK_IS_ACTIVE_EDITOR, INTERACTIVE_WINDOW_IS_ACTIVE_EDITOR } from 'vscode/vscode/vs/workbench/contrib/notebook/common/notebookContextKeys';
|
|
19
19
|
import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
20
20
|
|
|
21
|
-
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/find/notebookFind";
|
|
22
21
|
registerNotebookContribution(NotebookFindContrib.id, NotebookFindContrib);
|
|
23
22
|
registerAction2(class extends Action2 {
|
|
24
23
|
constructor() {
|
|
25
24
|
super({
|
|
26
25
|
id: 'notebook.hideFind',
|
|
27
|
-
title: (
|
|
26
|
+
title: ( localize2(7896, 'Hide Find in Notebook')),
|
|
28
27
|
keybinding: {
|
|
29
28
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, KEYBINDING_CONTEXT_NOTEBOOK_FIND_WIDGET_FOCUSED))),
|
|
30
29
|
primary: KeyCode.Escape,
|
|
@@ -47,7 +46,7 @@ registerAction2(class extends NotebookMultiCellAction {
|
|
|
47
46
|
constructor() {
|
|
48
47
|
super({
|
|
49
48
|
id: 'notebook.find',
|
|
50
|
-
title: (
|
|
49
|
+
title: ( localize2(7897, 'Find in Notebook')),
|
|
51
50
|
keybinding: {
|
|
52
51
|
when: ( (ContextKeyExpr.and(
|
|
53
52
|
NOTEBOOK_EDITOR_FOCUSED,
|