@codingame/monaco-vscode-notebook-service-override 8.0.4 → 9.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 +3 -2
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/emptyTextEditorHint/emptyTextEditorHint.js +8 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands.js +21 -21
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/cellDiagnosticsActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/diagnosticCellStatusBarContrib.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard.js +6 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.js +26 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFind.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/format/formatting.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/gettingStarted/notebookGettingStarted.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/layout/layoutActions.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/multicursor/notebookMulticursor.js +624 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/navigation/arrow.js +13 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariables.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesDataSource.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesTree.js +4 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesView.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/outline/notebookOutline.js +9 -9
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/profile/notebookProfile.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/saveParticipants/saveParticipants.js +12 -12
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/troubleshoot/layout.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +24 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/editActions.js +54 -55
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/executeActions.js +22 -22
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +24 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/layoutActions.js +23 -21
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/notebookIndentationActions.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/sectionActions.js +12 -12
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffActions.js +297 -21
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebook.contribution.js +124 -73
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibilityHelp.js +27 -19
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookEditorServiceImpl.js +62 -39
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookExecutionServiceImpl.js +7 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKernelHistoryServiceImpl.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKeymapServiceImpl.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookLoggingServiceImpl.js +7 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookServiceImpl.js +18 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookWorkerServiceImpl.js +15 -40
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineEntryFactory.js +0 -1
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookTextModel.js +28 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookEditorModelResolverServiceImpl.js +55 -45
- package/vscode/src/vs/workbench/contrib/notebook/common/services/notebookSimpleWorker.js +6 -6
- package/vscode/src/vs/workbench/services/workingCopy/common/fileWorkingCopyManager.js +12 -12
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopyManager.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.js +0 -47
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +0 -1303
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +0 -267
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.js +0 -569
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.js +0 -115
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.js +0 -39
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiff.css.js +0 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +0 -903
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +0 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +0 -397
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.js +0 -186
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.js +0 -107
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-notebook-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "9.0.0",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "CodinGame",
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
}
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"vscode": "npm:@codingame/monaco-vscode-api@
|
|
32
|
+
"vscode": "npm:@codingame/monaco-vscode-api@9.0.0",
|
|
33
|
+
"marked": "~14.0.0"
|
|
33
34
|
}
|
|
34
35
|
}
|
|
@@ -197,8 +197,8 @@ class EmptyTextEditorHintContentWidget {
|
|
|
197
197
|
getActions: () => {
|
|
198
198
|
return [{
|
|
199
199
|
id: 'workench.action.disableEmptyEditorHint',
|
|
200
|
-
label: ( localize(
|
|
201
|
-
tooltip: ( localize(
|
|
200
|
+
label: ( localize(10799, "Disable Empty Editor Hint")),
|
|
201
|
+
tooltip: ( localize(10799, "Disable Empty Editor Hint")),
|
|
202
202
|
enabled: true,
|
|
203
203
|
class: undefined,
|
|
204
204
|
run: () => {
|
|
@@ -236,7 +236,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
236
236
|
const keybindingHintLabel = keybindingHint?.getLabel();
|
|
237
237
|
if (keybindingHint && keybindingHintLabel) {
|
|
238
238
|
const actionPart = ( localize(
|
|
239
|
-
|
|
239
|
+
10800,
|
|
240
240
|
'Press {0} to ask {1} to do something. ',
|
|
241
241
|
keybindingHintLabel,
|
|
242
242
|
providerName
|
|
@@ -267,7 +267,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
267
267
|
this.toDispose.add(addDisposableListener(label.element, EventType.CLICK, handleClick));
|
|
268
268
|
}
|
|
269
269
|
hintElement.appendChild(after);
|
|
270
|
-
const typeToDismiss = ( localize(
|
|
270
|
+
const typeToDismiss = ( localize(10801, 'Start typing to dismiss.'));
|
|
271
271
|
const textHint2 = $('span', undefined, typeToDismiss);
|
|
272
272
|
textHint2.style.fontStyle = 'italic';
|
|
273
273
|
hintElement.appendChild(textHint2);
|
|
@@ -275,7 +275,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
275
275
|
}
|
|
276
276
|
else {
|
|
277
277
|
const hintMsg = ( localize(
|
|
278
|
-
|
|
278
|
+
10802,
|
|
279
279
|
'[[Ask {0} to do something]] or start typing to dismiss.',
|
|
280
280
|
providerName
|
|
281
281
|
));
|
|
@@ -335,7 +335,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
335
335
|
}
|
|
336
336
|
};
|
|
337
337
|
const hintMsg = ( localize(
|
|
338
|
-
|
|
338
|
+
10803,
|
|
339
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.'
|
|
340
340
|
));
|
|
341
341
|
const hintElement = renderFormattedText(hintMsg, {
|
|
@@ -346,7 +346,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
346
346
|
const keybindingsLookup = [ChangeLanguageAction.ID, ApplyFileSnippetAction.Id, 'welcome.showNewFileEntries'];
|
|
347
347
|
const keybindingLabels = ( (keybindingsLookup.map((id) => this.keybindingService.lookupKeybinding(id)?.getLabel() ?? id)));
|
|
348
348
|
const ariaLabel = ( localize(
|
|
349
|
-
|
|
349
|
+
10804,
|
|
350
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.',
|
|
351
351
|
...keybindingLabels
|
|
352
352
|
));
|
|
@@ -367,7 +367,7 @@ class EmptyTextEditorHintContentWidget {
|
|
|
367
367
|
const { hintElement, ariaLabel } = !inlineChatProviders.length ? this._getHintDefault() : this._getHintInlineChat(inlineChatProviders);
|
|
368
368
|
this.domNode.append(hintElement);
|
|
369
369
|
this.ariaLabel = ariaLabel.concat(( localize(
|
|
370
|
-
|
|
370
|
+
10805,
|
|
371
371
|
' Toggle {0} in settings to disable this hint.',
|
|
372
372
|
AccessibilityVerbositySettingId.EmptyEditorHint
|
|
373
373
|
)));
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands.js
CHANGED
|
@@ -25,7 +25,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
25
25
|
constructor() {
|
|
26
26
|
super({
|
|
27
27
|
id: MOVE_CELL_UP_COMMAND_ID,
|
|
28
|
-
title: ( localize2(
|
|
28
|
+
title: ( localize2(8235, "Move Cell Up")),
|
|
29
29
|
icon: moveUpIcon,
|
|
30
30
|
keybinding: {
|
|
31
31
|
primary: KeyMod.Alt | KeyCode.UpArrow,
|
|
@@ -48,7 +48,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
48
48
|
constructor() {
|
|
49
49
|
super({
|
|
50
50
|
id: MOVE_CELL_DOWN_COMMAND_ID,
|
|
51
|
-
title: ( localize2(
|
|
51
|
+
title: ( localize2(8236, "Move Cell Down")),
|
|
52
52
|
icon: moveDownIcon,
|
|
53
53
|
keybinding: {
|
|
54
54
|
primary: KeyMod.Alt | KeyCode.DownArrow,
|
|
@@ -71,7 +71,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
71
71
|
constructor() {
|
|
72
72
|
super({
|
|
73
73
|
id: COPY_CELL_UP_COMMAND_ID,
|
|
74
|
-
title: ( localize2(
|
|
74
|
+
title: ( localize2(8237, "Copy Cell Up")),
|
|
75
75
|
keybinding: {
|
|
76
76
|
primary: KeyMod.Alt | KeyMod.Shift | KeyCode.UpArrow,
|
|
77
77
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, (InputFocusedContext.toNegated())))),
|
|
@@ -87,7 +87,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
87
87
|
constructor() {
|
|
88
88
|
super({
|
|
89
89
|
id: COPY_CELL_DOWN_COMMAND_ID,
|
|
90
|
-
title: ( localize2(
|
|
90
|
+
title: ( localize2(8238, "Copy Cell Down")),
|
|
91
91
|
keybinding: {
|
|
92
92
|
primary: KeyMod.Alt | KeyMod.Shift | KeyCode.DownArrow,
|
|
93
93
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, (InputFocusedContext.toNegated())))),
|
|
@@ -113,7 +113,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
113
113
|
constructor() {
|
|
114
114
|
super({
|
|
115
115
|
id: SPLIT_CELL_COMMAND_ID,
|
|
116
|
-
title: ( localize2(
|
|
116
|
+
title: ( localize2(8239, "Split Cell")),
|
|
117
117
|
menu: {
|
|
118
118
|
id: MenuId.NotebookCellTitle,
|
|
119
119
|
when: ( (ContextKeyExpr.and(
|
|
@@ -183,7 +183,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
183
183
|
constructor() {
|
|
184
184
|
super({
|
|
185
185
|
id: JOIN_CELL_ABOVE_COMMAND_ID,
|
|
186
|
-
title: ( localize2(
|
|
186
|
+
title: ( localize2(8240, "Join With Previous Cell")),
|
|
187
187
|
keybinding: {
|
|
188
188
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
189
189
|
primary: KeyMod.WinCtrl | KeyMod.Alt | KeyMod.Shift | KeyCode.KeyJ,
|
|
@@ -206,7 +206,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
206
206
|
constructor() {
|
|
207
207
|
super({
|
|
208
208
|
id: JOIN_CELL_BELOW_COMMAND_ID,
|
|
209
|
-
title: ( localize2(
|
|
209
|
+
title: ( localize2(8241, "Join With Next Cell")),
|
|
210
210
|
keybinding: {
|
|
211
211
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
212
212
|
primary: KeyMod.WinCtrl | KeyMod.Alt | KeyCode.KeyJ,
|
|
@@ -229,7 +229,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
229
229
|
constructor() {
|
|
230
230
|
super({
|
|
231
231
|
id: JOIN_SELECTED_CELLS_COMMAND_ID,
|
|
232
|
-
title: ( localize2(
|
|
232
|
+
title: ( localize2(8242, "Join Selected Cells")),
|
|
233
233
|
menu: {
|
|
234
234
|
id: MenuId.NotebookCellTitle,
|
|
235
235
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE))),
|
|
@@ -250,7 +250,7 @@ registerAction2(class ChangeCellToCodeAction extends NotebookMultiCellAction {
|
|
|
250
250
|
constructor() {
|
|
251
251
|
super({
|
|
252
252
|
id: CHANGE_CELL_TO_CODE_COMMAND_ID,
|
|
253
|
-
title: ( localize2(
|
|
253
|
+
title: ( localize2(8243, "Change Cell to Code")),
|
|
254
254
|
keybinding: {
|
|
255
255
|
when: ( (ContextKeyExpr.and(
|
|
256
256
|
NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -284,7 +284,7 @@ registerAction2(class ChangeCellToMarkdownAction extends NotebookMultiCellAction
|
|
|
284
284
|
constructor() {
|
|
285
285
|
super({
|
|
286
286
|
id: CHANGE_CELL_TO_MARKDOWN_COMMAND_ID,
|
|
287
|
-
title: ( localize2(
|
|
287
|
+
title: ( localize2(8244, "Change Cell to Markdown")),
|
|
288
288
|
keybinding: {
|
|
289
289
|
when: ( (ContextKeyExpr.and(
|
|
290
290
|
NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -326,7 +326,7 @@ registerAction2(class CollapseCellInputAction extends NotebookMultiCellAction {
|
|
|
326
326
|
constructor() {
|
|
327
327
|
super({
|
|
328
328
|
id: COLLAPSE_CELL_INPUT_COMMAND_ID,
|
|
329
|
-
title: ( localize2(
|
|
329
|
+
title: ( localize2(8245, "Collapse Cell Input")),
|
|
330
330
|
keybinding: {
|
|
331
331
|
when: ( (ContextKeyExpr.and(
|
|
332
332
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -354,7 +354,7 @@ registerAction2(class ExpandCellInputAction extends NotebookMultiCellAction {
|
|
|
354
354
|
constructor() {
|
|
355
355
|
super({
|
|
356
356
|
id: EXPAND_CELL_INPUT_COMMAND_ID,
|
|
357
|
-
title: ( localize2(
|
|
357
|
+
title: ( localize2(8246, "Expand Cell Input")),
|
|
358
358
|
keybinding: {
|
|
359
359
|
when: ( (ContextKeyExpr.and(NOTEBOOK_CELL_LIST_FOCUSED, NOTEBOOK_CELL_INPUT_COLLAPSED))),
|
|
360
360
|
primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyMod.CtrlCmd | KeyCode.KeyC),
|
|
@@ -378,7 +378,7 @@ registerAction2(class CollapseCellOutputAction extends NotebookMultiCellAction {
|
|
|
378
378
|
constructor() {
|
|
379
379
|
super({
|
|
380
380
|
id: COLLAPSE_CELL_OUTPUT_COMMAND_ID,
|
|
381
|
-
title: ( localize2(
|
|
381
|
+
title: ( localize2(8247, "Collapse Cell Output")),
|
|
382
382
|
keybinding: {
|
|
383
383
|
when: ( (ContextKeyExpr.and(
|
|
384
384
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -404,7 +404,7 @@ registerAction2(class ExpandCellOuputAction extends NotebookMultiCellAction {
|
|
|
404
404
|
constructor() {
|
|
405
405
|
super({
|
|
406
406
|
id: EXPAND_CELL_OUTPUT_COMMAND_ID,
|
|
407
|
-
title: ( localize2(
|
|
407
|
+
title: ( localize2(8248, "Expand Cell Output")),
|
|
408
408
|
keybinding: {
|
|
409
409
|
when: ( (ContextKeyExpr.and(NOTEBOOK_CELL_LIST_FOCUSED, NOTEBOOK_CELL_OUTPUT_COLLAPSED))),
|
|
410
410
|
primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyCode.KeyT),
|
|
@@ -426,9 +426,9 @@ registerAction2(class extends NotebookMultiCellAction {
|
|
|
426
426
|
super({
|
|
427
427
|
id: TOGGLE_CELL_OUTPUTS_COMMAND_ID,
|
|
428
428
|
precondition: NOTEBOOK_CELL_LIST_FOCUSED,
|
|
429
|
-
title: ( localize2(
|
|
429
|
+
title: ( localize2(8249, "Toggle Outputs")),
|
|
430
430
|
metadata: {
|
|
431
|
-
description: ( localize(
|
|
431
|
+
description: ( localize(8249, "Toggle Outputs")),
|
|
432
432
|
args: cellExecutionArgs
|
|
433
433
|
}
|
|
434
434
|
});
|
|
@@ -453,7 +453,7 @@ registerAction2(class CollapseAllCellInputsAction extends NotebookMultiCellActio
|
|
|
453
453
|
constructor() {
|
|
454
454
|
super({
|
|
455
455
|
id: COLLAPSE_ALL_CELL_INPUTS_COMMAND_ID,
|
|
456
|
-
title: ( localize2(
|
|
456
|
+
title: ( localize2(8250, "Collapse All Cell Inputs")),
|
|
457
457
|
f1: true,
|
|
458
458
|
});
|
|
459
459
|
}
|
|
@@ -465,7 +465,7 @@ registerAction2(class ExpandAllCellInputsAction extends NotebookMultiCellAction
|
|
|
465
465
|
constructor() {
|
|
466
466
|
super({
|
|
467
467
|
id: EXPAND_ALL_CELL_INPUTS_COMMAND_ID,
|
|
468
|
-
title: ( localize2(
|
|
468
|
+
title: ( localize2(8251, "Expand All Cell Inputs")),
|
|
469
469
|
f1: true
|
|
470
470
|
});
|
|
471
471
|
}
|
|
@@ -477,7 +477,7 @@ registerAction2(class CollapseAllCellOutputsAction extends NotebookMultiCellActi
|
|
|
477
477
|
constructor() {
|
|
478
478
|
super({
|
|
479
479
|
id: COLLAPSE_ALL_CELL_OUTPUTS_COMMAND_ID,
|
|
480
|
-
title: ( localize2(
|
|
480
|
+
title: ( localize2(8252, "Collapse All Cell Outputs")),
|
|
481
481
|
f1: true,
|
|
482
482
|
});
|
|
483
483
|
}
|
|
@@ -489,7 +489,7 @@ registerAction2(class ExpandAllCellOutputsAction extends NotebookMultiCellAction
|
|
|
489
489
|
constructor() {
|
|
490
490
|
super({
|
|
491
491
|
id: EXPAND_ALL_CELL_OUTPUTS_COMMAND_ID,
|
|
492
|
-
title: ( localize2(
|
|
492
|
+
title: ( localize2(8253, "Expand All Cell Outputs")),
|
|
493
493
|
f1: true
|
|
494
494
|
});
|
|
495
495
|
}
|
|
@@ -501,7 +501,7 @@ registerAction2(class ToggleCellOutputScrolling extends NotebookMultiCellAction
|
|
|
501
501
|
constructor() {
|
|
502
502
|
super({
|
|
503
503
|
id: TOGGLE_CELL_OUTPUT_SCROLLING,
|
|
504
|
-
title: ( localize2(
|
|
504
|
+
title: ( localize2(8254, "Toggle Scroll Cell Output")),
|
|
505
505
|
keybinding: {
|
|
506
506
|
when: ( (ContextKeyExpr.and(
|
|
507
507
|
NOTEBOOK_CELL_LIST_FOCUSED,
|
|
@@ -15,7 +15,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
15
15
|
constructor() {
|
|
16
16
|
super({
|
|
17
17
|
id: OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID,
|
|
18
|
-
title: ( localize2(
|
|
18
|
+
title: ( localize2(10807, "Show Cell Failure Actions")),
|
|
19
19
|
precondition: ( (ContextKeyExpr.and(
|
|
20
20
|
NOTEBOOK_CELL_FOCUSED,
|
|
21
21
|
NOTEBOOK_CELL_HAS_ERROR_DIAGNOSTICS,
|
|
@@ -47,7 +47,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
47
47
|
const editor = findTargetCellEditor(context, context.cell);
|
|
48
48
|
if (editor) {
|
|
49
49
|
const controller = CodeActionController.get(editor);
|
|
50
|
-
controller?.manualTriggerAtCurrentPosition(( localize(
|
|
50
|
+
controller?.manualTriggerAtCurrentPosition(( localize(10808, "No code actions available")), CodeActionTriggerSource.Default, { include: CodeActionKind.QuickFix });
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
53
|
}
|
|
@@ -40,7 +40,7 @@ let DiagnosticCellStatusBarItem = class DiagnosticCellStatusBarItem extends Disp
|
|
|
40
40
|
let item;
|
|
41
41
|
if (error?.location) {
|
|
42
42
|
const keybinding = this.keybindingService.lookupKeybinding(OPEN_CELL_FAILURE_ACTIONS_COMMAND_ID)?.getLabel();
|
|
43
|
-
const tooltip = ( localize(
|
|
43
|
+
const tooltip = ( localize(10809, "Quick Actions {0}", `(${keybinding})`));
|
|
44
44
|
item = {
|
|
45
45
|
text: `$(sparkle)`,
|
|
46
46
|
tooltip,
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders.js
CHANGED
|
@@ -40,7 +40,7 @@ let CellStatusBarLanguagePickerProvider = class CellStatusBarLanguagePickerProvi
|
|
|
40
40
|
}
|
|
41
41
|
else {
|
|
42
42
|
const searchTooltip = ( localize(
|
|
43
|
-
|
|
43
|
+
8217,
|
|
44
44
|
"Unknown cell language. Click to search for '{0}' extensions",
|
|
45
45
|
cell.language
|
|
46
46
|
));
|
|
@@ -56,7 +56,7 @@ let CellStatusBarLanguagePickerProvider = class CellStatusBarLanguagePickerProvi
|
|
|
56
56
|
statusBarItems.push({
|
|
57
57
|
text: displayLanguage,
|
|
58
58
|
command: CHANGE_CELL_LANGUAGE,
|
|
59
|
-
tooltip: ( localize(
|
|
59
|
+
tooltip: ( localize(8218, "Select Cell Language Mode")),
|
|
60
60
|
alignment: CellStatusbarAlignment.Right,
|
|
61
61
|
priority: -Number.MAX_SAFE_INTEGER
|
|
62
62
|
});
|
|
@@ -120,7 +120,7 @@ let CellStatusBarLanguageDetectionProvider = class CellStatusBarLanguageDetectio
|
|
|
120
120
|
const items = [];
|
|
121
121
|
if (cached.guess && currentLanguageId !== cached.guess) {
|
|
122
122
|
const detectedName = this._languageService.getLanguageName(cached.guess) || cached.guess;
|
|
123
|
-
let tooltip = ( localize(
|
|
123
|
+
let tooltip = ( localize(8219, "Accept Detected Language: {0}", detectedName));
|
|
124
124
|
const keybinding = this._keybindingService.lookupKeybinding(DETECT_CELL_LANGUAGE);
|
|
125
125
|
const label = keybinding?.getLabel();
|
|
126
126
|
if (label) {
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard.js
CHANGED
|
@@ -349,7 +349,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
349
349
|
constructor() {
|
|
350
350
|
super({
|
|
351
351
|
id: COPY_CELL_COMMAND_ID,
|
|
352
|
-
title: ( localize(
|
|
352
|
+
title: ( localize(8170, "Copy Cell")),
|
|
353
353
|
menu: {
|
|
354
354
|
id: MenuId.NotebookCellTitle,
|
|
355
355
|
when: NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -372,7 +372,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
372
372
|
constructor() {
|
|
373
373
|
super({
|
|
374
374
|
id: CUT_CELL_COMMAND_ID,
|
|
375
|
-
title: ( localize(
|
|
375
|
+
title: ( localize(8171, "Cut Cell")),
|
|
376
376
|
menu: {
|
|
377
377
|
id: MenuId.NotebookCellTitle,
|
|
378
378
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE, NOTEBOOK_CELL_EDITABLE))),
|
|
@@ -395,7 +395,7 @@ registerAction2(class extends NotebookAction {
|
|
|
395
395
|
constructor() {
|
|
396
396
|
super({
|
|
397
397
|
id: PASTE_CELL_COMMAND_ID,
|
|
398
|
-
title: ( localize(
|
|
398
|
+
title: ( localize(8172, "Paste Cell")),
|
|
399
399
|
menu: {
|
|
400
400
|
id: MenuId.NotebookCellTitle,
|
|
401
401
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_EDITOR_EDITABLE))),
|
|
@@ -427,7 +427,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
427
427
|
constructor() {
|
|
428
428
|
super({
|
|
429
429
|
id: PASTE_CELL_ABOVE_COMMAND_ID,
|
|
430
|
-
title: ( localize(
|
|
430
|
+
title: ( localize(8173, "Paste Cell Above")),
|
|
431
431
|
keybinding: {
|
|
432
432
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, ContextKeyExpr.not(InputFocusedContextKey)))),
|
|
433
433
|
primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KeyV,
|
|
@@ -471,7 +471,7 @@ registerAction2(class extends Action2 {
|
|
|
471
471
|
constructor() {
|
|
472
472
|
super({
|
|
473
473
|
id: 'workbench.action.toggleNotebookClipboardLog',
|
|
474
|
-
title: ( localize2(
|
|
474
|
+
title: ( localize2(8174, 'Toggle Notebook Clipboard Troubleshooting')),
|
|
475
475
|
category: Categories.Developer,
|
|
476
476
|
f1: true
|
|
477
477
|
});
|
|
@@ -488,7 +488,7 @@ registerAction2(class extends NotebookCellAction {
|
|
|
488
488
|
constructor() {
|
|
489
489
|
super({
|
|
490
490
|
id: 'notebook.cell.output.selectAll',
|
|
491
|
-
title: ( localize(
|
|
491
|
+
title: ( localize(8175, "Select All")),
|
|
492
492
|
keybinding: {
|
|
493
493
|
primary: KeyMod.CtrlCmd | KeyCode.KeyA,
|
|
494
494
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, NOTEBOOK_OUTPUT_FOCUSED))),
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.js
CHANGED
|
@@ -17,7 +17,7 @@ import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/commo
|
|
|
17
17
|
import { StatusbarAlignment } from 'vscode/vscode/vs/workbench/services/statusbar/browser/statusbar';
|
|
18
18
|
import { IStatusbarService } from 'vscode/vscode/vs/workbench/services/statusbar/browser/statusbar.service';
|
|
19
19
|
import { IEditorGroupsService } from 'vscode/vscode/vs/workbench/services/editor/common/editorGroupsService.service';
|
|
20
|
-
import {
|
|
20
|
+
import { Event } from 'vscode/vscode/vs/base/common/event';
|
|
21
21
|
|
|
22
22
|
let ImplictKernelSelector = class ImplictKernelSelector {
|
|
23
23
|
constructor(notebook, suggested, notebookKernelService, languageFeaturesService, logService) {
|
|
@@ -110,19 +110,19 @@ let KernelStatus = class KernelStatus extends Disposable {
|
|
|
110
110
|
}
|
|
111
111
|
const tooltip = kernel.description ?? kernel.detail ?? kernel.label;
|
|
112
112
|
this._kernelInfoElement.add(this._statusbarService.addEntry({
|
|
113
|
-
name: ( localize(
|
|
113
|
+
name: ( localize(8226, "Notebook Kernel Info")),
|
|
114
114
|
text: `$(notebook-kernel-select) ${kernel.label}`,
|
|
115
115
|
ariaLabel: kernel.label,
|
|
116
|
-
tooltip: isSuggested ? ( localize(
|
|
116
|
+
tooltip: isSuggested ? ( localize(8227, "{0} (suggestion)", tooltip)) : tooltip,
|
|
117
117
|
command: SELECT_KERNEL_ID,
|
|
118
118
|
}, SELECT_KERNEL_ID, StatusbarAlignment.RIGHT, 10));
|
|
119
119
|
this._kernelInfoElement.add(kernel.onDidChange(() => this._showKernelStatus(notebook)));
|
|
120
120
|
}
|
|
121
121
|
else {
|
|
122
122
|
this._kernelInfoElement.add(this._statusbarService.addEntry({
|
|
123
|
-
name: ( localize(
|
|
124
|
-
text: ( localize(
|
|
125
|
-
ariaLabel: ( localize(
|
|
123
|
+
name: ( localize(8228, "Notebook Kernel Selection")),
|
|
124
|
+
text: ( localize(8229, "Select Kernel")),
|
|
125
|
+
ariaLabel: ( localize(8229, "Select Kernel")),
|
|
126
126
|
command: SELECT_KERNEL_ID,
|
|
127
127
|
kind: 'prominent'
|
|
128
128
|
}, SELECT_KERNEL_ID, StatusbarAlignment.RIGHT, 10));
|
|
@@ -167,7 +167,7 @@ let ActiveCellStatus = class ActiveCellStatus extends Disposable {
|
|
|
167
167
|
return;
|
|
168
168
|
}
|
|
169
169
|
const entry = {
|
|
170
|
-
name: ( localize(
|
|
170
|
+
name: ( localize(8230, "Notebook Editor Selections")),
|
|
171
171
|
text: newText,
|
|
172
172
|
ariaLabel: newText,
|
|
173
173
|
command: CENTER_ACTIVE_CELL
|
|
@@ -191,8 +191,8 @@ let ActiveCellStatus = class ActiveCellStatus extends Disposable {
|
|
|
191
191
|
const numSelected = editor.getSelections().reduce((prev, range) => prev + (range.end - range.start), 0);
|
|
192
192
|
const totalCells = editor.getLength();
|
|
193
193
|
return numSelected > 1 ?
|
|
194
|
-
( localize(
|
|
195
|
-
( localize(
|
|
194
|
+
( localize(8231, "Cell {0} ({1} selected)", idxFocused, numSelected)) :
|
|
195
|
+
( localize(8232, "Cell {0} of {1}", idxFocused, totalCells));
|
|
196
196
|
}
|
|
197
197
|
};
|
|
198
198
|
ActiveCellStatus = ( (__decorate([
|
|
@@ -251,10 +251,10 @@ let NotebookIndentationStatus = class NotebookIndentationStatus extends Disposab
|
|
|
251
251
|
return;
|
|
252
252
|
}
|
|
253
253
|
const entry = {
|
|
254
|
-
name: ( localize(
|
|
254
|
+
name: ( localize(8233, "Notebook Indentation")),
|
|
255
255
|
text: newText,
|
|
256
256
|
ariaLabel: newText,
|
|
257
|
-
tooltip: ( localize(
|
|
257
|
+
tooltip: ( localize(8234, "Select Indentation")),
|
|
258
258
|
command: SELECT_NOTEBOOK_INDENTATION_ID
|
|
259
259
|
};
|
|
260
260
|
if (!this._accessor.value) {
|
|
@@ -272,23 +272,25 @@ NotebookIndentationStatus = ( (__decorate([
|
|
|
272
272
|
], NotebookIndentationStatus)));
|
|
273
273
|
let NotebookEditorStatusContribution = class NotebookEditorStatusContribution extends Disposable {
|
|
274
274
|
static { this.ID = 'notebook.contrib.editorStatus'; }
|
|
275
|
-
constructor(
|
|
275
|
+
constructor(editorGroupService) {
|
|
276
276
|
super();
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
this._register(editorGroupService.onDidCreateAuxiliaryEditorPart(
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
277
|
+
this.editorGroupService = editorGroupService;
|
|
278
|
+
for (const part of editorGroupService.parts) {
|
|
279
|
+
this.createNotebookStatus(part);
|
|
280
|
+
}
|
|
281
|
+
this._register(editorGroupService.onDidCreateAuxiliaryEditorPart(part => this.createNotebookStatus(part)));
|
|
282
|
+
}
|
|
283
|
+
createNotebookStatus(part) {
|
|
284
|
+
const disposables = ( (new DisposableStore()));
|
|
285
|
+
Event.once(part.onWillDispose)(() => disposables.dispose());
|
|
286
|
+
const scopedInstantiationService = this.editorGroupService.getScopedInstantiationService(part);
|
|
287
|
+
disposables.add(scopedInstantiationService.createInstance(KernelStatus));
|
|
288
|
+
disposables.add(scopedInstantiationService.createInstance(ActiveCellStatus));
|
|
289
|
+
disposables.add(scopedInstantiationService.createInstance(NotebookIndentationStatus));
|
|
286
290
|
}
|
|
287
291
|
};
|
|
288
292
|
NotebookEditorStatusContribution = ( (__decorate([
|
|
289
|
-
( (__param(0,
|
|
290
|
-
( (__param(1, IEditorGroupsService))),
|
|
291
|
-
( (__param(2, IEditorService)))
|
|
293
|
+
( (__param(0, IEditorGroupsService)))
|
|
292
294
|
], NotebookEditorStatusContribution)));
|
|
293
295
|
registerWorkbenchContribution2(NotebookEditorStatusContribution.ID, NotebookEditorStatusContribution, WorkbenchPhase.AfterRestored);
|
|
294
296
|
|
|
@@ -23,7 +23,7 @@ registerAction2(class extends Action2 {
|
|
|
23
23
|
constructor() {
|
|
24
24
|
super({
|
|
25
25
|
id: 'notebook.hideFind',
|
|
26
|
-
title: ( localize2(
|
|
26
|
+
title: ( localize2(8176, 'Hide Find in Notebook')),
|
|
27
27
|
keybinding: {
|
|
28
28
|
when: ( (ContextKeyExpr.and(NOTEBOOK_EDITOR_FOCUSED, KEYBINDING_CONTEXT_NOTEBOOK_FIND_WIDGET_FOCUSED))),
|
|
29
29
|
primary: KeyCode.Escape,
|
|
@@ -46,7 +46,7 @@ registerAction2(class extends NotebookMultiCellAction {
|
|
|
46
46
|
constructor() {
|
|
47
47
|
super({
|
|
48
48
|
id: 'notebook.find',
|
|
49
|
-
title: ( localize2(
|
|
49
|
+
title: ( localize2(8177, 'Find in Notebook')),
|
|
50
50
|
keybinding: {
|
|
51
51
|
when: ( (ContextKeyExpr.and(
|
|
52
52
|
NOTEBOOK_EDITOR_FOCUSED,
|
|
@@ -32,7 +32,7 @@ registerAction2(class extends Action2 {
|
|
|
32
32
|
constructor() {
|
|
33
33
|
super({
|
|
34
34
|
id: 'notebook.format',
|
|
35
|
-
title: ( localize2(
|
|
35
|
+
title: ( localize2(8178, 'Format Notebook')),
|
|
36
36
|
category: NOTEBOOK_ACTIONS_CATEGORY,
|
|
37
37
|
precondition: ( (ContextKeyExpr.and(NOTEBOOK_IS_ACTIVE_EDITOR, NOTEBOOK_EDITOR_EDITABLE))),
|
|
38
38
|
keybinding: {
|
|
@@ -83,7 +83,7 @@ registerAction2(class extends Action2 {
|
|
|
83
83
|
}
|
|
84
84
|
return [];
|
|
85
85
|
}))));
|
|
86
|
-
await bulkEditService.apply( allCellEdits.flat(), { label: ( localize(
|
|
86
|
+
await bulkEditService.apply( allCellEdits.flat(), { label: ( localize(8179, "Format Notebook")), code: 'undoredo.formatNotebook', });
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
finally {
|
|
@@ -95,7 +95,7 @@ registerEditorAction(class FormatCellAction extends EditorAction {
|
|
|
95
95
|
constructor() {
|
|
96
96
|
super({
|
|
97
97
|
id: 'notebook.formatCell',
|
|
98
|
-
label: ( localize(
|
|
98
|
+
label: ( localize(8180, "Format Cell")),
|
|
99
99
|
alias: 'Format Cell',
|
|
100
100
|
precondition: ( (ContextKeyExpr.and(
|
|
101
101
|
NOTEBOOK_IS_ACTIVE_EDITOR,
|
|
@@ -167,7 +167,7 @@ let FormatOnCellExecutionParticipant = class FormatOnCellExecutionParticipant {
|
|
|
167
167
|
}
|
|
168
168
|
return [];
|
|
169
169
|
}))));
|
|
170
|
-
await this.bulkEditService.apply( allCellEdits.flat(), { label: ( localize(
|
|
170
|
+
await this.bulkEditService.apply( allCellEdits.flat(), { label: ( localize(8181, "Format Cells")), code: 'undoredo.notebooks.onWillExecuteFormat', });
|
|
171
171
|
}
|
|
172
172
|
finally {
|
|
173
173
|
disposable.dispose();
|
|
@@ -65,7 +65,7 @@ registerAction2(class NotebookClearNotebookLayoutAction extends Action2 {
|
|
|
65
65
|
constructor() {
|
|
66
66
|
super({
|
|
67
67
|
id: 'workbench.notebook.layout.gettingStarted',
|
|
68
|
-
title: ( localize2(
|
|
68
|
+
title: ( localize2(8192, "Reset notebook getting started")),
|
|
69
69
|
f1: true,
|
|
70
70
|
precondition: ( (ContextKeyExpr.equals(`config.${NotebookSetting.openGettingStarted}`, true))),
|
|
71
71
|
category: Categories.Developer,
|
|
@@ -9,7 +9,7 @@ class ToggleCellToolbarPositionAction extends Action2 {
|
|
|
9
9
|
constructor() {
|
|
10
10
|
super({
|
|
11
11
|
id: TOGGLE_CELL_TOOLBAR_POSITION,
|
|
12
|
-
title: ( localize2(
|
|
12
|
+
title: ( localize2(8193, 'Toggle Cell Toolbar Position')),
|
|
13
13
|
menu: [{
|
|
14
14
|
id: MenuId.NotebookCellTitle,
|
|
15
15
|
group: 'View',
|