@jupyterlab/ui-components 4.0.0-alpha.30 → 4.0.0-alpha.32

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.
@@ -0,0 +1,269 @@
1
+ /*
2
+ * Copyright (c) Jupyter Development Team.
3
+ * Distributed under the terms of the Modified BSD License.
4
+ */
5
+ import React from 'react';
6
+ import { utils } from '@rjsf/core';
7
+ import { addIcon, caretDownIcon, caretUpIcon, closeIcon, LabIcon } from './icon';
8
+ import { JSONExt } from '@lumino/coreutils';
9
+ import { reduce } from '@lumino/algorithm';
10
+ /**
11
+ * Button to move an item.
12
+ *
13
+ * @returns - the button as a react element.
14
+ */
15
+ export const MoveButton = (props) => {
16
+ var _a;
17
+ const trans = (_a = props.translator) === null || _a === void 0 ? void 0 : _a.load('jupyterlab');
18
+ let buttonContent;
19
+ /**
20
+ * Whether the button is disabled or not.
21
+ */
22
+ const disabled = () => {
23
+ if (props.direction === 'up') {
24
+ return !props.item.hasMoveUp;
25
+ }
26
+ else {
27
+ return !props.item.hasMoveDown;
28
+ }
29
+ };
30
+ if (props.buttonStyle === 'icons') {
31
+ buttonContent = (React.createElement(LabIcon.resolveReact, { icon: props.direction === 'up' ? caretUpIcon : caretDownIcon, tag: "span", elementSize: "xlarge", elementPosition: "center" }));
32
+ }
33
+ else {
34
+ buttonContent =
35
+ props.direction === 'up'
36
+ ? (trans === null || trans === void 0 ? void 0 : trans.__('Move up')) || 'Move up'
37
+ : (trans === null || trans === void 0 ? void 0 : trans.__('Move down')) || 'Move down';
38
+ }
39
+ const moveTo = props.direction === 'up' ? props.item.index - 1 : props.item.index + 1;
40
+ const button = (React.createElement("button", { className: "jp-mod-styled jp-mod-reject jp-ArrayOperationsButton", onClick: props.item.onReorderClick(props.item.index, moveTo), disabled: disabled() }, buttonContent));
41
+ return button;
42
+ };
43
+ /**
44
+ * Button to drop an item.
45
+ *
46
+ * @returns - the button as a react element.
47
+ */
48
+ export const DropButton = (props) => {
49
+ var _a;
50
+ const trans = (_a = props.translator) === null || _a === void 0 ? void 0 : _a.load('jupyterlab');
51
+ let buttonContent;
52
+ if (props.buttonStyle === 'icons') {
53
+ buttonContent = (React.createElement(LabIcon.resolveReact, { icon: closeIcon, tag: "span", elementSize: "xlarge", elementPosition: "center" }));
54
+ }
55
+ else {
56
+ buttonContent = (trans === null || trans === void 0 ? void 0 : trans.__('Remove')) || 'Remove';
57
+ }
58
+ const button = (React.createElement("button", { className: "jp-mod-styled jp-mod-warn jp-ArrayOperationsButton", onClick: props.item.onDropIndexClick(props.item.index) }, buttonContent));
59
+ return button;
60
+ };
61
+ /**
62
+ * Button to add an item.
63
+ *
64
+ * @returns - the button as a react element.
65
+ */
66
+ export const AddButton = (props) => {
67
+ var _a;
68
+ const trans = (_a = props.translator) === null || _a === void 0 ? void 0 : _a.load('jupyterlab');
69
+ let buttonContent;
70
+ if (props.buttonStyle === 'icons') {
71
+ buttonContent = (React.createElement(LabIcon.resolveReact, { icon: addIcon, tag: "span", elementSize: "xlarge", elementPosition: "center" }));
72
+ }
73
+ else {
74
+ buttonContent = (trans === null || trans === void 0 ? void 0 : trans.__('Add')) || 'Add';
75
+ }
76
+ const button = (React.createElement("button", { className: "jp-mod-styled jp-mod-reject jp-ArrayOperationsButton", onClick: props.onAddClick }, buttonContent));
77
+ return button;
78
+ };
79
+ /**
80
+ * React JSON schema form's array template.
81
+ */
82
+ export class RJSFArrayTemplate {
83
+ /**
84
+ * Create a new array template object.
85
+ *
86
+ * @param options - the container template options.
87
+ */
88
+ constructor(options = {}) {
89
+ this._translator = options.translator;
90
+ this._buttonStyle = options.buttonStyle || 'text';
91
+ this._compact = options.compact || false;
92
+ }
93
+ get template() {
94
+ const factory = (props) => {
95
+ var _a;
96
+ return (React.createElement("div", { className: props.className },
97
+ this._compact ? (React.createElement("div", { className: "jp-FormGroup-compactTitle" },
98
+ React.createElement("div", { className: "jp-FormGroup-fieldLabel jp-FormGroup-contentItem", id: `${props.idSchema.$id}__title` }, props.title || ''),
99
+ React.createElement("div", { className: "jp-FormGroup-description", id: `${props.idSchema.$id}-description` }, props.schema.description || ''))) : (React.createElement(React.Fragment, null,
100
+ props.title && (React.createElement(props.TitleField, { title: props.title, required: props.required, id: `${props.idSchema.$id}-title` })),
101
+ React.createElement(props.DescriptionField, { id: `${props.idSchema.$id}-description`, description: (_a = props.schema.description) !== null && _a !== void 0 ? _a : '' }))),
102
+ props.items.map(item => {
103
+ return (React.createElement("div", { key: item.key, className: item.className },
104
+ item.children,
105
+ React.createElement("div", { className: "jp-ArrayOperations" },
106
+ React.createElement(MoveButton, { buttonStyle: this._buttonStyle, translator: this._translator, item: item, direction: "up" }),
107
+ React.createElement(MoveButton, { buttonStyle: this._buttonStyle, translator: this._translator, item: item, direction: "down" }),
108
+ React.createElement(DropButton, { buttonStyle: this._buttonStyle, translator: this._translator, item: item }))));
109
+ }),
110
+ props.canAdd && (React.createElement(AddButton, { onAddClick: props.onAddClick, buttonStyle: this._buttonStyle, translator: this._translator }))));
111
+ };
112
+ factory.displayName = 'JupyterLabArrayTemplate';
113
+ return factory;
114
+ }
115
+ }
116
+ /**
117
+ * React JSON schema form's object template.
118
+ */
119
+ export class RJSFObjectTemplate {
120
+ /**
121
+ * Create a new object template object.
122
+ *
123
+ * @param options - the container template options.
124
+ */
125
+ constructor(options = {}) {
126
+ this._translator = options.translator;
127
+ this._buttonStyle = options.buttonStyle || 'text';
128
+ this._compact = options.compact || false;
129
+ }
130
+ get template() {
131
+ const factory = (props) => {
132
+ var _a;
133
+ return (React.createElement("fieldset", { id: props.idSchema.$id },
134
+ this._compact ? (React.createElement("div", { className: "jp-FormGroup-compactTitle" },
135
+ React.createElement("div", { className: "jp-FormGroup-fieldLabel jp-FormGroup-contentItem", id: `${props.idSchema.$id}__title` }, props.title || ''),
136
+ React.createElement("div", { className: "jp-FormGroup-description", id: `${props.idSchema.$id}__description` }, props.schema.description || ''))) : (React.createElement(React.Fragment, null,
137
+ (props.title || props.uiSchema['ui:title']) && (React.createElement(props.TitleField, { id: `${props.idSchema.$id}__title`, title: props.title || props.uiSchema['ui:title'] || '', required: props.required })),
138
+ React.createElement(props.DescriptionField, { id: `${props.idSchema.$id}__description`, description: (_a = props.schema.description) !== null && _a !== void 0 ? _a : '' }))),
139
+ props.properties.map(property => property.content),
140
+ utils.canExpand(props.schema, props.uiSchema, props.formData) && (React.createElement(AddButton, { onAddClick: props.onAddClick(props.schema), buttonStyle: this._buttonStyle, translator: this._translator }))));
141
+ };
142
+ factory.displayName = 'JupyterLabObjectTemplate';
143
+ return factory;
144
+ }
145
+ }
146
+ /**
147
+ * Custom field template for React JSON-schema form.
148
+ *
149
+ */
150
+ export class RJSFFieldTemplate {
151
+ /**
152
+ * Create a new field template object.
153
+ *
154
+ * @param options - the field template options.
155
+ */
156
+ constructor(options = {}) {
157
+ var _a, _b;
158
+ this._showModifiedFromDefault = (_a = options.showModifiedFromDefault) !== null && _a !== void 0 ? _a : false;
159
+ this._translator = options.translator;
160
+ this._compact = (_b = options.compact) !== null && _b !== void 0 ? _b : false;
161
+ }
162
+ get template() {
163
+ const factory = (props) => {
164
+ var _a, _b, _c;
165
+ const trans = (_a = this._translator) === null || _a === void 0 ? void 0 : _a.load('jupyterlab');
166
+ let isModified = false;
167
+ const { formData, schema, label, displayLabel, id, formContext, errors, rawErrors, children, onKeyChange, onDropPropertyClick } = props;
168
+ const schemaIds = id.split('_');
169
+ schemaIds.shift();
170
+ const schemaId = schemaIds.join('.');
171
+ if (this._showModifiedFromDefault) {
172
+ /**
173
+ * Determine if the field has been modified.
174
+ * Schema Id is formatted as 'root_<field name>.<nexted field name>'
175
+ * This logic parses out the field name to find the default value
176
+ * before determining if the field has been modified.
177
+ */
178
+ let defaultValue;
179
+ if (schemaIds.length === 1) {
180
+ defaultValue = formContext.settings.default(schemaId);
181
+ }
182
+ else if (schemaIds.length > 1) {
183
+ const allDefaultsForObject = {};
184
+ allDefaultsForObject[schemaIds[0]] = formContext.settings.default(schemaIds[0]);
185
+ defaultValue = reduce(schemaIds, (acc, val, i) => {
186
+ return acc === null || acc === void 0 ? void 0 : acc[val];
187
+ }, allDefaultsForObject);
188
+ }
189
+ isModified =
190
+ schemaId !== '' &&
191
+ formData !== undefined &&
192
+ defaultValue !== undefined &&
193
+ !schema.properties &&
194
+ schema.type !== 'array' &&
195
+ !JSONExt.deepEqual(formData, defaultValue);
196
+ }
197
+ const isRoot = schemaId === '';
198
+ const needsDescription = !isRoot &&
199
+ schema.type != 'object' &&
200
+ id !=
201
+ 'jp-SettingsEditor-@jupyterlab/shortcuts-extension:shortcuts_shortcuts';
202
+ // While we can implement "remove" button for array items in array template,
203
+ // object templates do not provide a way to do this; instead we need to add
204
+ // buttons here (and first check if the field can be removed = is additional).
205
+ const isAdditional = schema.hasOwnProperty(utils.ADDITIONAL_PROPERTY_FLAG);
206
+ const isItem = !(schema.type === 'object' || schema.type === 'array');
207
+ return (React.createElement("div", { className: `form-group ${displayLabel || schema.type === 'boolean' ? 'small-field' : ''}` },
208
+ // Only show the modified indicator if there are no errors
209
+ isModified && !rawErrors && React.createElement("div", { className: "jp-modifiedIndicator" }),
210
+ // Shows a red indicator for fields that have validation errors
211
+ rawErrors && (React.createElement("div", { className: "jp-modifiedIndicator jp-errorIndicator" })),
212
+ React.createElement("div", { className: `jp-FormGroup-content ${this._compact
213
+ ? 'jp-FormGroup-contentCompact'
214
+ : 'jp-FormGroup-contentNormal'}` },
215
+ isItem && displayLabel && !isRoot && label && !isAdditional ? (this._compact ? (React.createElement("div", { className: "jp-FormGroup-compactTitle" },
216
+ React.createElement("div", { className: "jp-FormGroup-fieldLabel jp-FormGroup-contentItem" }, label),
217
+ isItem && schema.description && needsDescription && (React.createElement("div", { className: "jp-FormGroup-description" }, schema.description)))) : (React.createElement("h3", { className: "jp-FormGroup-fieldLabel jp-FormGroup-contentItem" }, label))) : (React.createElement(React.Fragment, null)),
218
+ isAdditional && (React.createElement("input", { className: "jp-FormGroup-contentItem jp-mod-styled", type: "text", onBlur: event => onKeyChange(event.target.value), defaultValue: label })),
219
+ React.createElement("div", { className: `${isRoot
220
+ ? 'jp-root'
221
+ : schema.type === 'object'
222
+ ? 'jp-objectFieldWrapper'
223
+ : schema.type === 'array'
224
+ ? 'jp-arrayFieldWrapper'
225
+ : 'jp-inputFieldWrapper jp-FormGroup-contentItem'}` }, children),
226
+ isAdditional && (React.createElement("button", { className: "jp-FormGroup-contentItem jp-mod-styled jp-mod-warn jp-FormGroup-removeButton", onClick: onDropPropertyClick(label) }, (trans === null || trans === void 0 ? void 0 : trans.__('Remove')) || 'Remove')),
227
+ !this._compact && schema.description && needsDescription && (React.createElement("div", { className: "jp-FormGroup-description" }, schema.description)),
228
+ isModified && schema.default !== undefined && (React.createElement("div", { className: "jp-FormGroup-default" }, (trans === null || trans === void 0 ? void 0 : trans.__('Default: %1', (_b = schema.default) === null || _b === void 0 ? void 0 : _b.toLocaleString())) ||
229
+ `Default: ${(_c = schema.default) === null || _c === void 0 ? void 0 : _c.toLocaleString()}`)),
230
+ React.createElement("div", { className: "validationErrors" }, errors))));
231
+ };
232
+ factory.displayName = 'JupyterLabFieldTemplate';
233
+ return factory;
234
+ }
235
+ }
236
+ /**
237
+ * A templates factory for react JSON schema form.
238
+ * It includes a field template, an array template and an object template.
239
+ */
240
+ export class RJSFTemplatesFactory {
241
+ constructor(options) {
242
+ var _a, _b, _c, _d;
243
+ this._fieldTemplate = new RJSFFieldTemplate({
244
+ showModifiedFromDefault: (_a = options.showModifiedFromDefault) !== null && _a !== void 0 ? _a : false,
245
+ compact: (_b = options.compact) !== null && _b !== void 0 ? _b : false,
246
+ translator: options.translator
247
+ });
248
+ this._arrayTemplate = new RJSFArrayTemplate({
249
+ compact: (_c = options.compact) !== null && _c !== void 0 ? _c : false,
250
+ buttonStyle: options.compact ? 'icons' : 'text',
251
+ translator: options.translator
252
+ });
253
+ this._objectTemplate = new RJSFObjectTemplate({
254
+ compact: (_d = options.compact) !== null && _d !== void 0 ? _d : false,
255
+ buttonStyle: options.compact ? 'icons' : 'text',
256
+ translator: options.translator
257
+ });
258
+ }
259
+ get fieldTemplate() {
260
+ return this._fieldTemplate.template;
261
+ }
262
+ get arrayTemplate() {
263
+ return this._arrayTemplate.template;
264
+ }
265
+ get objectTemplate() {
266
+ return this._objectTemplate.template;
267
+ }
268
+ }
269
+ //# sourceMappingURL=rjsfTemplates.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rjsfTemplates.js","sourceRoot":"","sources":["../src/rjsfTemplates.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAIL,KAAK,EACN,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,OAAO,EACP,aAAa,EACb,WAAW,EACX,SAAS,EACT,OAAO,EACR,MAAM,QAAQ,CAAC;AAEhB,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AA6H3C;;;;GAIG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CACxB,KAAqC,EACxB,EAAE;;IACf,MAAM,KAAK,GAAG,MAAA,KAAK,CAAC,UAAU,0CAAE,IAAI,CAAC,YAAY,CAAC,CAAC;IACnD,IAAI,aAAmC,CAAC;IAExC;;OAEG;IACH,MAAM,QAAQ,GAAG,GAAG,EAAE;QACpB,IAAI,KAAK,CAAC,SAAS,KAAK,IAAI,EAAE;YAC5B,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC;SAC9B;aAAM;YACL,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC;SAChC;IACH,CAAC,CAAC;IAEF,IAAI,KAAK,CAAC,WAAW,KAAK,OAAO,EAAE;QACjC,aAAa,GAAG,CACd,oBAAC,OAAO,CAAC,YAAY,IACnB,IAAI,EAAE,KAAK,CAAC,SAAS,KAAK,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC,CA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CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM;YAC/C,UAAU,EAAE,OAAO,CAAC,UAAU;SAC/B,CAAC,CAAC;IACL,CAAC;IAED,IAAI,aAAa;QACf,OAAO,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC;IACtC,CAAC;IAED,IAAI,aAAa;QACf,OAAO,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC;IACtC,CAAC;IAED,IAAI,cAAc;QAChB,OAAO,IAAI,CAAC,eAAe,CAAC,QAAQ,CAAC;IACvC,CAAC;CAKF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jupyterlab/ui-components",
3
- "version": "4.0.0-alpha.30",
3
+ "version": "4.0.0-alpha.32",
4
4
  "description": "JupyterLab - UI components written in React",
5
5
  "homepage": "https://github.com/jupyterlab/jupyterlab",
6
6
  "bugs": {
@@ -40,10 +40,10 @@
40
40
  "watch": "tsc -b --watch"
41
41
  },
42
42
  "dependencies": {
43
- "@jupyterlab/coreutils": "^6.0.0-alpha.15",
44
- "@jupyterlab/observables": "^5.0.0-alpha.15",
45
- "@jupyterlab/rendermime-interfaces": "^3.8.0-alpha.15",
46
- "@jupyterlab/translation": "^4.0.0-alpha.15",
43
+ "@jupyterlab/coreutils": "^6.0.0-alpha.17",
44
+ "@jupyterlab/observables": "^5.0.0-alpha.17",
45
+ "@jupyterlab/rendermime-interfaces": "^3.8.0-alpha.17",
46
+ "@jupyterlab/translation": "^4.0.0-alpha.17",
47
47
  "@lumino/algorithm": "^2.0.0-alpha.6",
48
48
  "@lumino/commands": "^2.0.0-alpha.6",
49
49
  "@lumino/coreutils": "^2.0.0-alpha.6",
@@ -60,16 +60,11 @@
60
60
  "typestyle": "^2.0.4"
61
61
  },
62
62
  "devDependencies": {
63
- "@babel/core": "^7.10.2",
64
- "@babel/preset-env": "^7.10.2",
65
- "@jupyterlab/testutils": "^4.0.0-alpha.15",
66
- "@types/jest": "^26.0.10",
63
+ "@jupyterlab/testing": "^4.0.0-alpha.17",
64
+ "@types/jest": "^29.2.0",
67
65
  "@types/react": "^17.0.0",
68
- "babel-loader": "^8.0.6",
69
- "jest": "^26.4.2",
70
66
  "rimraf": "~3.0.0",
71
- "svgo": "^2.8.0",
72
- "ts-jest": "^26.3.0",
67
+ "svgo": "^3.0.1",
73
68
  "typedoc": "~0.22.10",
74
69
  "typescript": "~4.7.3"
75
70
  },
package/style/base.css CHANGED
@@ -13,9 +13,10 @@
13
13
  @import './iconshover.css';
14
14
  @import './iframe.css';
15
15
  @import './hoverbox.css';
16
+ @import './rjsfTemplates.css';
17
+ @import './sidepanel.css';
16
18
  @import './spinner.css';
17
19
  @import './styling.css';
18
- @import './sidepanel.css';
19
20
  @import './switch.css';
20
21
  @import './toolbar.css';
21
22
  @import './windowedlist.css';
@@ -36,13 +37,6 @@ a:hover {
36
37
  color: unset;
37
38
  }
38
39
 
39
- /* Disable default focus outline */
40
- :focus {
41
- outline: unset;
42
- outline-offset: unset;
43
- -moz-outline-radius: unset;
44
- }
45
-
46
40
  /* Accessibility for links inside dialog box text */
47
41
  .jp-Dialog-content a {
48
42
  text-decoration: revert;
@@ -165,6 +159,7 @@ input::placeholder {
165
159
  color: var(--jp-ui-font-color0);
166
160
  display: block;
167
161
  font-size: var(--jp-ui-font-size1);
162
+ font-family: var(--jp-ui-font-family);
168
163
  height: 24px;
169
164
  line-height: 14px;
170
165
  padding: 0 25px 0 10px;
@@ -15,6 +15,7 @@
15
15
  --jp-icon-add-above: url('icons/toolbar/add-above.svg');
16
16
  --jp-icon-add-below: url('icons/toolbar/add-below.svg');
17
17
  --jp-icon-add: url('icons/toolbar/add.svg');
18
+ --jp-icon-bell: url('icons/statusbar/bell.svg');
18
19
  --jp-icon-bug-dot: url('icons/toolbar/bug-dot.svg');
19
20
  --jp-icon-bug: url('icons/toolbar/bug.svg');
20
21
  --jp-icon-build: url('icons/sidebar/build.svg');
@@ -43,6 +44,7 @@
43
44
  --jp-icon-duplicate: url('icons/toolbar/duplicate.svg');
44
45
  --jp-icon-edit: url('icons/toolbar/edit.svg');
45
46
  --jp-icon-ellipses: url('icons/toolbar/ellipses.svg');
47
+ --jp-icon-error: url('icons/error.svg');
46
48
  --jp-icon-expand-all: url('icons/toolbar/expand-all.svg');
47
49
  --jp-icon-extension: url('icons/sidebar/extension.svg');
48
50
  --jp-icon-fast-forward: url('icons/toolbar/fast-forward.svg');
@@ -122,6 +124,10 @@
122
124
  background-image: var(--jp-icon-add);
123
125
  }
124
126
 
127
+ .jp-BellIcon {
128
+ background-image: var(--jp-icon-bell);
129
+ }
130
+
125
131
  .jp-BugDotIcon {
126
132
  background-image: var(--jp-icon-bug-dot);
127
133
  }
@@ -234,6 +240,10 @@
234
240
  background-image: var(--jp-icon-ellipses);
235
241
  }
236
242
 
243
+ .jp-ErrorIcon {
244
+ background-image: var(--jp-icon-error);
245
+ }
246
+
237
247
  .jp-ExpandAllIcon {
238
248
  background-image: var(--jp-icon-expand-all);
239
249
  }
@@ -0,0 +1,4 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 24 24">
2
+ <g class="jp-icon3" fill="#616161"><circle cx="12" cy="19" r="2"/><path d="M10 3h4v12h-4z"/></g>
3
+ <path fill="none" d="M0 0h24v24H0z"/>
4
+ </svg>
@@ -1,8 +1,8 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 200 200">
2
- <g class="jp-icon-brand1 jp-icon-selectable" fill="#0288D1">
2
+ <g class="jp-console-icon-background-color jp-icon-selectable" fill="#0288D1">
3
3
  <path d="M20 19.8h160v159.9H20z"/>
4
4
  </g>
5
- <g class="jp-icon-selectable-inverse" fill="#fff">
5
+ <g class="jp-console-icon-color jp-icon-selectable-inverse" fill="#fff">
6
6
  <path d="M105 127.3h40v12.8h-40zM51.1 77L74 99.9l-23.3 23.3 10.5 10.5 23.3-23.3L95 99.9 84.5 89.4 61.6 66.5z"/>
7
7
  </g>
8
8
  </svg>
@@ -1,3 +1,3 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 24 24">
2
- <path class="jp-icon3 jp-icon-selectable" fill="#616161" d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z"/>
2
+ <path class="jp-inspector-icon-color jp-icon-selectable" fill="#616161" d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z"/>
3
3
  </svg>
@@ -1,5 +1,5 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 22 22">
2
- <g class="jp-icon-warn1 jp-icon-selectable" fill="#F9A825">
2
+ <g class="jp-json-icon-color jp-icon-selectable" fill="#F9A825">
3
3
  <path d="M20.2 11.8c-1.6 0-1.7.5-1.7 1 0 .4.1.9.1 1.3.1.5.1.9.1 1.3 0 1.7-1.4 2.3-3.5 2.3h-.9v-1.9h.5c1.1 0 1.4 0 1.4-.8 0-.3 0-.6-.1-1 0-.4-.1-.8-.1-1.2 0-1.3 0-1.8 1.3-2-1.3-.2-1.3-.7-1.3-2 0-.4.1-.8.1-1.2.1-.4.1-.7.1-1 0-.8-.4-.7-1.4-.8h-.5V4.1h.9c2.2 0 3.5.7 3.5 2.3 0 .4-.1.9-.1 1.3-.1.5-.1.9-.1 1.3 0 .5.2 1 1.7 1v1.8zM1.8 10.1c1.6 0 1.7-.5 1.7-1 0-.4-.1-.9-.1-1.3-.1-.5-.1-.9-.1-1.3 0-1.6 1.4-2.3 3.5-2.3h.9v1.9h-.5c-1 0-1.4 0-1.4.8 0 .3 0 .6.1 1 0 .2.1.6.1 1 0 1.3 0 1.8-1.3 2C6 11.2 6 11.7 6 13c0 .4-.1.8-.1 1.2-.1.3-.1.7-.1 1 0 .8.3.8 1.4.8h.5v1.9h-.9c-2.1 0-3.5-.6-3.5-2.3 0-.4.1-.9.1-1.3.1-.5.1-.9.1-1.3 0-.5-.2-1-1.7-1v-1.9z"/>
4
4
  <circle cx="11" cy="13.8" r="2.1"/>
5
5
  <circle cx="11" cy="8.2" r="2.1"/>
@@ -1,5 +1,5 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 22 22">
2
- <g class="jp-icon-warn0 jp-icon-selectable" fill="#EF6C00">
2
+ <g class="jp-notebook-icon-color jp-icon-selectable" fill="#EF6C00">
3
3
  <path d="M18.7 3.3v15.4H3.3V3.3h15.4m1.5-1.5H1.8v18.3h18.3l.1-18.3z"/>
4
4
  <path d="M16.5 16.5l-5.4-4.3-5.6 4.3v-11h11z"/>
5
5
  </g>
@@ -1,3 +1,3 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 24 24">
2
- <path class="jp-icon3 jp-icon-selectable" fill="#616161" d="M15 15H3v2h12v-2zm0-8H3v2h12V7zM3 13h18v-2H3v2zm0 8h18v-2H3v2zM3 3v2h18V3H3z"/>
2
+ <path class="jp-text-editor-icon-color jp-icon-selectable" fill="#616161" d="M15 15H3v2h12v-2zm0-8H3v2h12V7zM3 13h18v-2H3v2zm0 8h18v-2H3v2zM3 3v2h18V3H3z"/>
3
3
  </svg>
@@ -1,5 +1,5 @@
1
1
  <svg width="152" height="165" viewBox="0 0 152 165" version="1.1" xmlns="http://www.w3.org/2000/svg">
2
- <g class="jp-icon-warn0" fill="#F37726">
2
+ <g class="jp-jupyter-icon-color" fill="#F37726">
3
3
  <path transform="translate(0.078947, 110.582927)" d="M75.9422842,29.5804561 C43.3023947,29.5804561 14.7967832,17.6534634 0,0 C5.51083211,15.8406829 15.7815389,29.5667732 29.3904947,39.2784171 C42.9997,48.9898537 59.2737,54.2067805 75.9605789,54.2067805 C92.6474579,54.2067805 108.921458,48.9898537 122.530663,39.2784171 C136.139453,29.5667732 146.410284,15.8406829 151.921158,0 C137.087868,17.6534634 108.582589,29.5804561 75.9422842,29.5804561 L75.9422842,29.5804561 Z" />
4
4
  <path transform="translate(0.037368, 0.704878)" d="M75.9784579,24.6264073 C108.618763,24.6264073 137.124458,36.5534415 151.921158,54.2067805 C146.410284,38.366222 136.139453,24.6401317 122.530663,14.9284878 C108.921458,5.2168439 92.6474579,0 75.9605789,0 C59.2737,0 42.9997,5.2168439 29.3904947,14.9284878 C15.7815389,24.6401317 5.51083211,38.366222 0,54.2067805 C14.8330816,36.5899293 43.3385684,24.6264073 75.9784579,24.6264073 L75.9784579,24.6264073 Z" />
5
5
  </g>
@@ -1,6 +1,6 @@
1
1
  <svg width="39" height="51" viewBox="0 0 39 51" xmlns="http://www.w3.org/2000/svg">
2
2
  <g transform="translate(-1638 -2281)">
3
- <g class="jp-icon-warn0" fill="#F37726">
3
+ <g class="jp-jupyter-icon-color" fill="#F37726">
4
4
  <path transform="translate(1639.74 2311.98)" d="M 18.2646 7.13411C 10.4145 7.13411 3.55872 4.2576 0 0C 1.32539 3.8204 3.79556 7.13081 7.0686 9.47303C 10.3417 11.8152 14.2557 13.0734 18.269 13.0734C 22.2823 13.0734 26.1963 11.8152 29.4694 9.47303C 32.7424 7.13081 35.2126 3.8204 36.538 0C 32.9705 4.2576 26.1148 7.13411 18.2646 7.13411Z"/>
5
5
  <path transform="translate(1639.73 2285.48)" d="M 18.2733 5.93931C 26.1235 5.93931 32.9793 8.81583 36.538 13.0734C 35.2126 9.25303 32.7424 5.94262 29.4694 3.6004C 26.1963 1.25818 22.2823 0 18.269 0C 14.2557 0 10.3417 1.25818 7.0686 3.6004C 3.79556 5.94262 1.32539 9.25303 0 13.0734C 3.56745 8.82463 10.4232 5.93931 18.2733 5.93931Z"/>
6
6
  </g>
@@ -0,0 +1,4 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 16 16" version="1.1">
2
+ <path class="jp-icon2 jp-icon-selectable" fill="#333333"
3
+ d="m8 0.29c-1.4 0-2.7 0.73-3.6 1.8-1.2 1.5-1.4 3.4-1.5 5.2-0.18 2.2-0.44 4-2.3 5.3l0.28 1.3h5c0.026 0.66 0.32 1.1 0.71 1.5 0.84 0.61 2 0.61 2.8 0 0.52-0.4 0.6-1 0.71-1.5h5l0.28-1.3c-1.9-0.97-2.2-3.3-2.3-5.3-0.13-1.8-0.26-3.7-1.5-5.2-0.85-1-2.2-1.8-3.6-1.8zm0 1.4c0.88 0 1.9 0.55 2.5 1.3 0.88 1.1 1.1 2.7 1.2 4.4 0.13 1.7 0.23 3.6 1.3 5.2h-10c1.1-1.6 1.2-3.4 1.3-5.2 0.13-1.7 0.3-3.3 1.2-4.4 0.59-0.72 1.6-1.3 2.5-1.3zm-0.74 12h1.5c-0.0015 0.28 0.015 0.79-0.74 0.79-0.73 0.0016-0.72-0.53-0.74-0.79z" />
4
+ </svg>
@@ -1,4 +1,4 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" width="16" viewBox="0 0 24 24" >
2
- <rect class="jp-icon2 jp-icon-selectable" width="20" height="20" transform="translate(2 2)" fill="#333333"/>
3
- <path class="jp-icon-accent2 jp-icon-selectable-inverse" d="M5.05664 8.76172C5.05664 8.59766 5.03125 8.45312 4.98047 8.32812C4.93359 8.19922 4.85547 8.08203 4.74609 7.97656C4.64062 7.87109 4.5 7.77539 4.32422 7.68945C4.15234 7.59961 3.94336 7.51172 3.69727 7.42578C3.30273 7.28516 2.94336 7.13672 2.61914 6.98047C2.29492 6.82422 2.01758 6.64258 1.78711 6.43555C1.56055 6.22852 1.38477 5.98828 1.25977 5.71484C1.13477 5.4375 1.07227 5.10938 1.07227 4.73047C1.07227 4.39844 1.12891 4.0957 1.24219 3.82227C1.35547 3.54492 1.51562 3.30469 1.72266 3.10156C1.92969 2.89844 2.17969 2.73437 2.47266 2.60938C2.76562 2.48438 3.0918 2.4043 3.45117 2.36914V1.10938H4.38867V2.38086C4.74023 2.42773 5.05664 2.52344 5.33789 2.66797C5.61914 2.8125 5.85742 3.00195 6.05273 3.23633C6.25195 3.4668 6.4043 3.74023 6.50977 4.05664C6.61914 4.36914 6.67383 4.7207 6.67383 5.11133H5.04492C5.04492 4.63867 4.9375 4.28125 4.72266 4.03906C4.50781 3.79297 4.2168 3.66992 3.84961 3.66992C3.65039 3.66992 3.47656 3.69727 3.32812 3.75195C3.18359 3.80273 3.06445 3.87695 2.9707 3.97461C2.87695 4.06836 2.80664 4.17969 2.75977 4.30859C2.7168 4.4375 2.69531 4.57812 2.69531 4.73047C2.69531 4.88281 2.7168 5.01953 2.75977 5.14062C2.80664 5.25781 2.88281 5.36719 2.98828 5.46875C3.09766 5.57031 3.24023 5.66797 3.41602 5.76172C3.5918 5.85156 3.81055 5.94336 4.07227 6.03711C4.4668 6.18555 4.82422 6.33984 5.14453 6.5C5.46484 6.65625 5.73828 6.83984 5.96484 7.05078C6.19531 7.25781 6.37109 7.5 6.49219 7.77734C6.61719 8.05078 6.67969 8.375 6.67969 8.75C6.67969 9.09375 6.62305 9.4043 6.50977 9.68164C6.39648 9.95508 6.23438 10.1914 6.02344 10.3906C5.8125 10.5898 5.55859 10.75 5.26172 10.8711C4.96484 10.9883 4.63281 11.0645 4.26562 11.0996V12.248H3.33398V11.0996C3.00195 11.0684 2.67969 10.9961 2.36719 10.8828C2.05469 10.7656 1.77734 10.5977 1.53516 10.3789C1.29688 10.1602 1.10547 9.88477 0.960938 9.55273C0.816406 9.2168 0.744141 8.81445 0.744141 8.3457H2.37891C2.37891 8.62695 2.41992 8.86328 2.50195 9.05469C2.58398 9.24219 2.68945 9.39258 2.81836 9.50586C2.95117 9.61523 3.10156 9.69336 3.26953 9.74023C3.4375 9.78711 3.60938 9.81055 3.78516 9.81055C4.20312 9.81055 4.51953 9.71289 4.73438 9.51758C4.94922 9.32227 5.05664 9.07031 5.05664 8.76172ZM13.418 12.2715H8.07422V11H13.418V12.2715Z" transform="translate(3.95264 6)" fill="white"/>
2
+ <rect class="jp-terminal-icon-background-color jp-icon-selectable" width="20" height="20" transform="translate(2 2)" fill="#333333"/>
3
+ <path class="jp-terminal-icon-color jp-icon-selectable-inverse" d="M5.05664 8.76172C5.05664 8.59766 5.03125 8.45312 4.98047 8.32812C4.93359 8.19922 4.85547 8.08203 4.74609 7.97656C4.64062 7.87109 4.5 7.77539 4.32422 7.68945C4.15234 7.59961 3.94336 7.51172 3.69727 7.42578C3.30273 7.28516 2.94336 7.13672 2.61914 6.98047C2.29492 6.82422 2.01758 6.64258 1.78711 6.43555C1.56055 6.22852 1.38477 5.98828 1.25977 5.71484C1.13477 5.4375 1.07227 5.10938 1.07227 4.73047C1.07227 4.39844 1.12891 4.0957 1.24219 3.82227C1.35547 3.54492 1.51562 3.30469 1.72266 3.10156C1.92969 2.89844 2.17969 2.73437 2.47266 2.60938C2.76562 2.48438 3.0918 2.4043 3.45117 2.36914V1.10938H4.38867V2.38086C4.74023 2.42773 5.05664 2.52344 5.33789 2.66797C5.61914 2.8125 5.85742 3.00195 6.05273 3.23633C6.25195 3.4668 6.4043 3.74023 6.50977 4.05664C6.61914 4.36914 6.67383 4.7207 6.67383 5.11133H5.04492C5.04492 4.63867 4.9375 4.28125 4.72266 4.03906C4.50781 3.79297 4.2168 3.66992 3.84961 3.66992C3.65039 3.66992 3.47656 3.69727 3.32812 3.75195C3.18359 3.80273 3.06445 3.87695 2.9707 3.97461C2.87695 4.06836 2.80664 4.17969 2.75977 4.30859C2.7168 4.4375 2.69531 4.57812 2.69531 4.73047C2.69531 4.88281 2.7168 5.01953 2.75977 5.14062C2.80664 5.25781 2.88281 5.36719 2.98828 5.46875C3.09766 5.57031 3.24023 5.66797 3.41602 5.76172C3.5918 5.85156 3.81055 5.94336 4.07227 6.03711C4.4668 6.18555 4.82422 6.33984 5.14453 6.5C5.46484 6.65625 5.73828 6.83984 5.96484 7.05078C6.19531 7.25781 6.37109 7.5 6.49219 7.77734C6.61719 8.05078 6.67969 8.375 6.67969 8.75C6.67969 9.09375 6.62305 9.4043 6.50977 9.68164C6.39648 9.95508 6.23438 10.1914 6.02344 10.3906C5.8125 10.5898 5.55859 10.75 5.26172 10.8711C4.96484 10.9883 4.63281 11.0645 4.26562 11.0996V12.248H3.33398V11.0996C3.00195 11.0684 2.67969 10.9961 2.36719 10.8828C2.05469 10.7656 1.77734 10.5977 1.53516 10.3789C1.29688 10.1602 1.10547 9.88477 0.960938 9.55273C0.816406 9.2168 0.744141 8.81445 0.744141 8.3457H2.37891C2.37891 8.62695 2.41992 8.86328 2.50195 9.05469C2.58398 9.24219 2.68945 9.39258 2.81836 9.50586C2.95117 9.61523 3.10156 9.69336 3.26953 9.74023C3.4375 9.78711 3.60938 9.81055 3.78516 9.81055C4.20312 9.81055 4.51953 9.71289 4.73438 9.51758C4.94922 9.32227 5.05664 9.07031 5.05664 8.76172ZM13.418 12.2715H8.07422V11H13.418V12.2715Z" transform="translate(3.95264 6)" fill="white"/>
4
4
  </svg>
package/style/icons.css CHANGED
@@ -205,6 +205,42 @@
205
205
  stroke: var(--jp-icon-contrast-color3);
206
206
  }
207
207
 
208
+ .jp-jupyter-icon-color[fill] {
209
+ fill: var(--jp-jupyter-icon-color, var(--jp-warn-color0));
210
+ }
211
+
212
+ .jp-notebook-icon-color[fill] {
213
+ fill: var(--jp-notebook-icon-color, var(--jp-warn-color0));
214
+ }
215
+
216
+ .jp-json-icon-color[fill] {
217
+ fill: var(--jp-json-icon-color, var(--jp-warn-color1));
218
+ }
219
+
220
+ .jp-console-icon-color[fill] {
221
+ fill: var(--jp-console-icon-color, white);
222
+ }
223
+
224
+ .jp-console-icon-background-color[fill] {
225
+ fill: var(--jp-console-icon-background-color, var(--jp-brand-color1));
226
+ }
227
+
228
+ .jp-terminal-icon-color[fill] {
229
+ fill: var(--jp-terminal-icon-color, var(--jp-layout-color2));
230
+ }
231
+
232
+ .jp-terminal-icon-background-color[fill] {
233
+ fill: var(--jp-terminal-icon-background-color, var(--jp-inverse-layout2));
234
+ }
235
+
236
+ .jp-text-editor-icon-color[fill] {
237
+ fill: var(--jp-text-editor-icon-color, var(--jp-inverse-layout3));
238
+ }
239
+
240
+ .jp-inspector-icon-color[fill] {
241
+ fill: var(--jp-inspector-icon-color, var(--jp-inverse-layout3));
242
+ }
243
+
208
244
  /* CSS for icons in selected filebrowser listing items */
209
245
  .jp-DirListing-item.jp-mod-selected .jp-icon-selectable[fill] {
210
246
  fill: #fff;