@difizen/libro-jupyter 0.2.25 → 0.2.27
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kernel-selector-dropdown.d.ts","sourceRoot":"","sources":["../../src/toolbar/kernel-selector-dropdown.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"kernel-selector-dropdown.d.ts","sourceRoot":"","sources":["../../src/toolbar/kernel-selector-dropdown.tsx"],"names":[],"mappings":";AAUA,OAAO,cAAc,CAAC;AAEtB,MAAM,WAAW,8BAA8B;IAC7C,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;CACtB;AAsGD,eAAO,MAAM,cAAc,EAAE,KAAK,CAAC,EA0HlC,CAAC"}
|
|
@@ -87,9 +87,17 @@ function getKernelListItems(preferredSessionKernelList, otherKernelList, allowPr
|
|
|
87
87
|
key: 'ShutDownKernel',
|
|
88
88
|
label: 'Shut Down the Kernel'
|
|
89
89
|
}];
|
|
90
|
-
if (
|
|
91
|
-
array
|
|
92
|
-
|
|
90
|
+
if (allowPreferredSession) {
|
|
91
|
+
array.splice(2, 0, {
|
|
92
|
+
key: 'UseKernelFromPreferredSession',
|
|
93
|
+
type: 'group',
|
|
94
|
+
label: 'Use Kernel from Preferred Session',
|
|
95
|
+
children: preferredSessionKernelList.map(function (item) {
|
|
96
|
+
return {
|
|
97
|
+
key: item.fileName,
|
|
98
|
+
label: item.fileName
|
|
99
|
+
};
|
|
100
|
+
})
|
|
93
101
|
});
|
|
94
102
|
}
|
|
95
103
|
return array;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@difizen/libro-jupyter",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.27",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"libro"
|
|
@@ -31,22 +31,22 @@
|
|
|
31
31
|
"src"
|
|
32
32
|
],
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@difizen/libro-cofine-editor": "^0.2.
|
|
35
|
-
"@difizen/libro-code-editor": "^0.2.
|
|
36
|
-
"@difizen/libro-code-cell": "^0.2.
|
|
37
|
-
"@difizen/libro-codemirror": "^0.2.
|
|
38
|
-
"@difizen/libro-rendermime": "^0.2.
|
|
39
|
-
"@difizen/libro-common": "^0.2.
|
|
40
|
-
"@difizen/libro-core": "^0.2.
|
|
41
|
-
"@difizen/libro-kernel": "^0.2.
|
|
42
|
-
"@difizen/libro-l10n": "^0.2.
|
|
43
|
-
"@difizen/libro-output": "^0.2.
|
|
44
|
-
"@difizen/libro-search": "^0.2.
|
|
45
|
-
"@difizen/libro-search-code-cell": "^0.2.
|
|
46
|
-
"@difizen/libro-lsp": "^0.2.
|
|
47
|
-
"@difizen/libro-markdown-cell": "^0.2.
|
|
48
|
-
"@difizen/libro-raw-cell": "^0.2.
|
|
49
|
-
"@difizen/libro-language-client": "^0.2.
|
|
34
|
+
"@difizen/libro-cofine-editor": "^0.2.27",
|
|
35
|
+
"@difizen/libro-code-editor": "^0.2.27",
|
|
36
|
+
"@difizen/libro-code-cell": "^0.2.27",
|
|
37
|
+
"@difizen/libro-codemirror": "^0.2.27",
|
|
38
|
+
"@difizen/libro-rendermime": "^0.2.27",
|
|
39
|
+
"@difizen/libro-common": "^0.2.27",
|
|
40
|
+
"@difizen/libro-core": "^0.2.27",
|
|
41
|
+
"@difizen/libro-kernel": "^0.2.27",
|
|
42
|
+
"@difizen/libro-l10n": "^0.2.27",
|
|
43
|
+
"@difizen/libro-output": "^0.2.27",
|
|
44
|
+
"@difizen/libro-search": "^0.2.27",
|
|
45
|
+
"@difizen/libro-search-code-cell": "^0.2.27",
|
|
46
|
+
"@difizen/libro-lsp": "^0.2.27",
|
|
47
|
+
"@difizen/libro-markdown-cell": "^0.2.27",
|
|
48
|
+
"@difizen/libro-raw-cell": "^0.2.27",
|
|
49
|
+
"@difizen/libro-language-client": "^0.2.27",
|
|
50
50
|
"@difizen/mana-app": "latest",
|
|
51
51
|
"@difizen/mana-l10n": "latest",
|
|
52
52
|
"@ant-design/colors": "^7.0.0",
|
|
@@ -3,6 +3,7 @@ import type { LibroView } from '@difizen/libro-core';
|
|
|
3
3
|
import { LibroKernelConnectionManager, KernelSpecManager } from '@difizen/libro-kernel';
|
|
4
4
|
import { ConfigurationService, useInject, ViewInstance } from '@difizen/mana-app';
|
|
5
5
|
import { Dropdown, Space } from 'antd';
|
|
6
|
+
import type { MenuProps } from 'antd';
|
|
6
7
|
import { useCallback, useEffect, useState } from 'react';
|
|
7
8
|
|
|
8
9
|
import { LibroJupyterConfiguration } from '../config/index.js';
|
|
@@ -57,7 +58,7 @@ function getKernelListItems(
|
|
|
57
58
|
otherKernelList: OtherKernelListElem[],
|
|
58
59
|
allowPreferredSession: boolean,
|
|
59
60
|
) {
|
|
60
|
-
|
|
61
|
+
const array: MenuProps['items'] = [
|
|
61
62
|
{
|
|
62
63
|
key: 'StartPreferredKernel',
|
|
63
64
|
type: 'group',
|
|
@@ -104,9 +105,17 @@ function getKernelListItems(
|
|
|
104
105
|
label: 'Shut Down the Kernel',
|
|
105
106
|
},
|
|
106
107
|
];
|
|
107
|
-
if (
|
|
108
|
-
array
|
|
109
|
-
|
|
108
|
+
if (allowPreferredSession) {
|
|
109
|
+
array.splice(2, 0, {
|
|
110
|
+
key: 'UseKernelFromPreferredSession',
|
|
111
|
+
type: 'group',
|
|
112
|
+
label: 'Use Kernel from Preferred Session',
|
|
113
|
+
children: preferredSessionKernelList.map((item) => {
|
|
114
|
+
return {
|
|
115
|
+
key: item.fileName,
|
|
116
|
+
label: item.fileName,
|
|
117
|
+
};
|
|
118
|
+
}),
|
|
110
119
|
});
|
|
111
120
|
}
|
|
112
121
|
return array;
|