@codingame/monaco-vscode-notebook-service-override 25.1.2 → 26.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/index.js +2 -2
- package/package.json +3 -3
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/emptyTextEditorHint/emptyTextEditorHint.js +112 -94
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellCommands/cellCommands.js +95 -96
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/cellDiagnosticEditorContrib.js +28 -19
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/cellDiagnosticsActions.js +15 -9
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellDiagnostics/diagnosticCellStatusBarContrib.js +22 -17
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/contributedStatusBarItemController.js +25 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/statusBarProviders.js +37 -44
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard.js +211 -115
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/debug/notebookBreakpoints.js +16 -18
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/debug/notebookCellPausing.js +5 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/debug/notebookDebugDecorations.js +57 -49
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorHint/emptyCellEditorHint.js +24 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.js +78 -76
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/execute/executionEditorProgress.js +14 -15
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFind.js +43 -28
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/format/formatting.js +65 -34
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/gettingStarted/notebookGettingStarted.js +19 -16
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/kernelDetection/notebookKernelDetection.js +6 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/layout/layoutActions.js +15 -17
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/marker/markerProvider.js +28 -16
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/multicursor/notebookMulticursor.js +211 -170
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/multicursor/notebookSelectionHighlight.js +11 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/navigation/arrow.js +158 -156
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookInlineVariables.js +109 -105
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariableContextKeys.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariables.js +28 -22
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesDataSource.js +26 -17
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesTree.js +23 -16
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/notebookVariables/notebookVariablesView.js +72 -40
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/outline/notebookOutline.js +233 -186
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/profile/notebookProfile.js +22 -18
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/saveParticipants/saveParticipants.js +239 -151
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/troubleshoot/layout.js +85 -86
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/undoRedo/notebookUndoRedo.js +25 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/viewportWarmup/viewportWarmup.js +13 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/apiActions.js +8 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/editActions.js +218 -196
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/executeActions.js +258 -255
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/layoutActions.js +106 -98
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/notebookIndentationActions.js +63 -49
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/sectionActions.js +55 -64
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/variablesActions.js +21 -25
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffActions.js +149 -129
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.d.ts +57 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.js +286 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.js +82 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebook.contribution.js +452 -363
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibilityHelp.js +44 -61
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibleView.js +9 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookExtensionPoint.js +203 -207
- package/vscode/src/vs/workbench/contrib/notebook/browser/outputEditor/notebookOutputEditor.js +148 -104
- package/vscode/src/vs/workbench/contrib/notebook/browser/outputEditor/notebookOutputEditorInput.js +19 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/replEditorAccessibleView.js +9 -11
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookCellStatusBarServiceImpl.js +9 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookEditorServiceImpl.js +34 -22
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookExecutionServiceImpl.js +29 -18
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookExecutionStateServiceImpl.js +70 -52
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKernelHistoryServiceImpl.js +31 -19
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKernelServiceImpl.js +78 -41
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookKeymapServiceImpl.js +37 -27
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookLoggingServiceImpl.js +9 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookRendererMessagingServiceImpl.js +8 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookServiceImpl.js +214 -119
- package/vscode/src/vs/workbench/contrib/notebook/browser/services/notebookWorkerServiceImpl.js +38 -36
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineDataSource.js +24 -25
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineDataSourceFactory.js +2 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineEntryFactory.js +26 -15
- package/vscode/src/vs/workbench/contrib/notebook/common/model/cellEdit.js +35 -15
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookTextModel.js +468 -258
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.d.ts +33 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.js +113 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookEditorModelResolverServiceImpl.js +74 -58
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookOutputRenderer.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookOutputRenderer.js +7 -10
- package/vscode/src/vs/workbench/contrib/notebook/common/services/notebookCellMatching.js +72 -16
- package/vscode/src/vs/workbench/contrib/notebook/common/services/notebookWebWorker.js +70 -51
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/repl.contribution.js +195 -149
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorAccessibilityHelp.js +60 -81
- package/vscode/src/vs/workbench/services/workingCopy/common/abstractFileWorkingCopyManager.js +7 -12
- package/vscode/src/vs/workbench/services/workingCopy/common/fileWorkingCopyManager.js +104 -66
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopyManager.js +115 -77
- package/vscode/src/vs/workbench/services/workingCopy/common/untitledFileWorkingCopy.js +42 -26
- package/vscode/src/vs/workbench/services/workingCopy/common/untitledFileWorkingCopyManager.js +19 -12
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.d.ts +0 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +0 -198
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +0 -333
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +0 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.d.ts +0 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +0 -261
|
@@ -14,21 +14,19 @@ import { executeSectionCondition } from './executeActions.js';
|
|
|
14
14
|
class NotebookRunSingleCellInSection extends Action2 {
|
|
15
15
|
constructor() {
|
|
16
16
|
super({
|
|
17
|
-
id:
|
|
17
|
+
id: "notebook.section.runSingleCell",
|
|
18
18
|
title: {
|
|
19
|
-
...( localize2(
|
|
20
|
-
mnemonicTitle: ( localize(
|
|
19
|
+
...( localize2(9777, "Run Cell")),
|
|
20
|
+
mnemonicTitle: ( localize(9778, "&&Run Cell"))
|
|
21
21
|
},
|
|
22
|
-
shortTitle: ( localize(
|
|
22
|
+
shortTitle: ( localize(9777, "Run Cell")),
|
|
23
23
|
icon: executeIcon,
|
|
24
|
-
menu: [
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}
|
|
31
|
-
]
|
|
24
|
+
menu: [{
|
|
25
|
+
id: MenuId.NotebookOutlineActionMenu,
|
|
26
|
+
group: "inline",
|
|
27
|
+
order: 1,
|
|
28
|
+
when: ( ContextKeyExpr.and(( NotebookOutlineContext.CellKind.isEqualTo(CellKind.Code)), ( NotebookOutlineContext.OutlineElementTarget.isEqualTo(OutlineTarget.OutlinePane)), ( NotebookOutlineContext.CellHasChildren.toNegated()), ( NotebookOutlineContext.CellHasHeader.toNegated())))
|
|
29
|
+
}]
|
|
32
30
|
});
|
|
33
31
|
}
|
|
34
32
|
async run(_accessor, context) {
|
|
@@ -41,43 +39,37 @@ class NotebookRunSingleCellInSection extends Action2 {
|
|
|
41
39
|
class NotebookRunCellsInSection extends Action2 {
|
|
42
40
|
constructor() {
|
|
43
41
|
super({
|
|
44
|
-
id:
|
|
42
|
+
id: "notebook.section.runCells",
|
|
45
43
|
title: {
|
|
46
|
-
...( localize2(
|
|
47
|
-
mnemonicTitle: ( localize(
|
|
44
|
+
...( localize2(9779, "Run Cells In Section")),
|
|
45
|
+
mnemonicTitle: ( localize(9780, "&&Run Cells In Section"))
|
|
48
46
|
},
|
|
49
|
-
shortTitle: ( localize(
|
|
47
|
+
shortTitle: ( localize(9779, "Run Cells In Section")),
|
|
50
48
|
icon: executeIcon,
|
|
51
|
-
menu: [
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
group: CELL_TITLE_CELL_GROUP_ID,
|
|
67
|
-
when: executeSectionCondition
|
|
68
|
-
}
|
|
69
|
-
]
|
|
49
|
+
menu: [{
|
|
50
|
+
id: MenuId.NotebookStickyScrollContext,
|
|
51
|
+
group: "notebookExecution",
|
|
52
|
+
order: 1
|
|
53
|
+
}, {
|
|
54
|
+
id: MenuId.NotebookOutlineActionMenu,
|
|
55
|
+
group: "inline",
|
|
56
|
+
order: 1,
|
|
57
|
+
when: ( ContextKeyExpr.and(( NotebookOutlineContext.CellKind.isEqualTo(CellKind.Markup)), ( NotebookOutlineContext.OutlineElementTarget.isEqualTo(OutlineTarget.OutlinePane)), NotebookOutlineContext.CellHasChildren, NotebookOutlineContext.CellHasHeader))
|
|
58
|
+
}, {
|
|
59
|
+
id: MenuId.NotebookCellTitle,
|
|
60
|
+
order: CellToolbarOrder.RunSection,
|
|
61
|
+
group: CELL_TITLE_CELL_GROUP_ID,
|
|
62
|
+
when: executeSectionCondition
|
|
63
|
+
}]
|
|
70
64
|
});
|
|
71
65
|
}
|
|
72
66
|
async run(_accessor, context) {
|
|
73
67
|
let cell;
|
|
74
68
|
if (checkOutlineEntryContext(context)) {
|
|
75
69
|
cell = context.outlineEntry.cell;
|
|
76
|
-
}
|
|
77
|
-
else if (checkNotebookCellContext(context)) {
|
|
70
|
+
} else if (checkNotebookCellContext(context)) {
|
|
78
71
|
cell = context.cell;
|
|
79
|
-
}
|
|
80
|
-
else {
|
|
72
|
+
} else {
|
|
81
73
|
return;
|
|
82
74
|
}
|
|
83
75
|
if (cell.getEditState() === CellEditState.Editing) {
|
|
@@ -96,27 +88,28 @@ class NotebookRunCellsInSection extends Action2 {
|
|
|
96
88
|
if (length === undefined) {
|
|
97
89
|
return;
|
|
98
90
|
}
|
|
99
|
-
const cells = context.notebookEditor.getCellsInRange({
|
|
91
|
+
const cells = context.notebookEditor.getCellsInRange({
|
|
92
|
+
start: sectionIdx,
|
|
93
|
+
end: sectionIdx + length + 1
|
|
94
|
+
});
|
|
100
95
|
context.notebookEditor.executeNotebookCells(cells);
|
|
101
96
|
}
|
|
102
97
|
}
|
|
103
98
|
class NotebookFoldSection extends Action2 {
|
|
104
99
|
constructor() {
|
|
105
100
|
super({
|
|
106
|
-
id:
|
|
101
|
+
id: "notebook.section.foldSection",
|
|
107
102
|
title: {
|
|
108
|
-
...( localize2(
|
|
109
|
-
mnemonicTitle: ( localize(
|
|
103
|
+
...( localize2(9781, "Fold Section")),
|
|
104
|
+
mnemonicTitle: ( localize(9782, "&&Fold Section"))
|
|
110
105
|
},
|
|
111
|
-
shortTitle: ( localize(
|
|
112
|
-
menu: [
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
}
|
|
119
|
-
]
|
|
106
|
+
shortTitle: ( localize(9781, "Fold Section")),
|
|
107
|
+
menu: [{
|
|
108
|
+
id: MenuId.NotebookOutlineActionMenu,
|
|
109
|
+
group: "notebookFolding",
|
|
110
|
+
order: 2,
|
|
111
|
+
when: ( ContextKeyExpr.and(( NotebookOutlineContext.CellKind.isEqualTo(CellKind.Markup)), ( NotebookOutlineContext.OutlineElementTarget.isEqualTo(OutlineTarget.OutlinePane)), NotebookOutlineContext.CellHasChildren, NotebookOutlineContext.CellHasHeader, ( NotebookOutlineContext.CellFoldingState.isEqualTo(CellFoldingState.Expanded))))
|
|
112
|
+
}]
|
|
120
113
|
});
|
|
121
114
|
}
|
|
122
115
|
async run(_accessor, context) {
|
|
@@ -136,20 +129,18 @@ class NotebookFoldSection extends Action2 {
|
|
|
136
129
|
class NotebookExpandSection extends Action2 {
|
|
137
130
|
constructor() {
|
|
138
131
|
super({
|
|
139
|
-
id:
|
|
132
|
+
id: "notebook.section.expandSection",
|
|
140
133
|
title: {
|
|
141
|
-
...( localize2(
|
|
142
|
-
mnemonicTitle: ( localize(
|
|
134
|
+
...( localize2(9783, "Expand Section")),
|
|
135
|
+
mnemonicTitle: ( localize(9784, "&&Expand Section"))
|
|
143
136
|
},
|
|
144
|
-
shortTitle: ( localize(
|
|
145
|
-
menu: [
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
}
|
|
152
|
-
]
|
|
137
|
+
shortTitle: ( localize(9783, "Expand Section")),
|
|
138
|
+
menu: [{
|
|
139
|
+
id: MenuId.NotebookOutlineActionMenu,
|
|
140
|
+
group: "notebookFolding",
|
|
141
|
+
order: 2,
|
|
142
|
+
when: ( ContextKeyExpr.and(( NotebookOutlineContext.CellKind.isEqualTo(CellKind.Markup)), ( NotebookOutlineContext.OutlineElementTarget.isEqualTo(OutlineTarget.OutlinePane)), NotebookOutlineContext.CellHasChildren, NotebookOutlineContext.CellHasHeader, ( NotebookOutlineContext.CellFoldingState.isEqualTo(CellFoldingState.Collapsed))))
|
|
143
|
+
}]
|
|
153
144
|
});
|
|
154
145
|
}
|
|
155
146
|
async run(_accessor, context) {
|
|
@@ -8,39 +8,35 @@ import { NOTEBOOK_VARIABLE_VIEW_ENABLED } from '../contrib/notebookVariables/not
|
|
|
8
8
|
import { variablesViewIcon } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/notebookIcons';
|
|
9
9
|
import { NotebookAction } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/notebook/browser/controller/coreActions';
|
|
10
10
|
|
|
11
|
-
const OPEN_VARIABLES_VIEW_COMMAND_ID =
|
|
11
|
+
const OPEN_VARIABLES_VIEW_COMMAND_ID = "notebook.openVariablesView";
|
|
12
12
|
registerAction2(class OpenVariablesViewAction extends NotebookAction {
|
|
13
13
|
constructor() {
|
|
14
14
|
super({
|
|
15
15
|
id: OPEN_VARIABLES_VIEW_COMMAND_ID,
|
|
16
|
-
title: ( localize2(
|
|
16
|
+
title: ( localize2(9785, "Variables")),
|
|
17
17
|
icon: variablesViewIcon,
|
|
18
|
-
menu: [
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
when: ( ContextKeyExpr.and(KERNEL_HAS_VARIABLE_PROVIDER, (
|
|
37
|
-
ContextKeyExpr.notEquals('jupyter.kernel.isjupyter', true)), ( ContextKeyExpr.equals('config.notebook.globalToolbar', true)), NOTEBOOK_VARIABLE_VIEW_ENABLED))
|
|
38
|
-
}
|
|
39
|
-
]
|
|
18
|
+
menu: [{
|
|
19
|
+
id: MenuId.InteractiveToolbar,
|
|
20
|
+
group: "navigation",
|
|
21
|
+
when: ( ContextKeyExpr.and(KERNEL_HAS_VARIABLE_PROVIDER, (
|
|
22
|
+
ContextKeyExpr.notEquals("jupyter.kernel.isjupyter", true)), NOTEBOOK_VARIABLE_VIEW_ENABLED))
|
|
23
|
+
}, {
|
|
24
|
+
id: MenuId.EditorTitle,
|
|
25
|
+
order: -1,
|
|
26
|
+
group: "navigation",
|
|
27
|
+
when: ( ContextKeyExpr.and(KERNEL_HAS_VARIABLE_PROVIDER, (
|
|
28
|
+
ContextKeyExpr.notEquals("jupyter.kernel.isjupyter", true)), ( ContextKeyExpr.notEquals("config.notebook.globalToolbar", true)), NOTEBOOK_VARIABLE_VIEW_ENABLED))
|
|
29
|
+
}, {
|
|
30
|
+
id: MenuId.NotebookToolbar,
|
|
31
|
+
order: -1,
|
|
32
|
+
group: "navigation",
|
|
33
|
+
when: ( ContextKeyExpr.and(KERNEL_HAS_VARIABLE_PROVIDER, (
|
|
34
|
+
ContextKeyExpr.notEquals("jupyter.kernel.isjupyter", true)), ( ContextKeyExpr.equals("config.notebook.globalToolbar", true)), NOTEBOOK_VARIABLE_VIEW_ENABLED))
|
|
35
|
+
}]
|
|
40
36
|
});
|
|
41
37
|
}
|
|
42
38
|
async runWithContext(accessor, context) {
|
|
43
|
-
const variableViewId =
|
|
39
|
+
const variableViewId = "workbench.notebook.variables";
|
|
44
40
|
accessor.get(IViewsService).openView(variableViewId, true);
|
|
45
41
|
}
|
|
46
42
|
});
|