@jupyter-notebook/application 7.1.2 → 7.2.0-beta.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/lib/shell.d.ts CHANGED
@@ -3,7 +3,7 @@ import { DocumentRegistry } from '@jupyterlab/docregistry';
3
3
  import { ITranslator } from '@jupyterlab/translation';
4
4
  import { Token } from '@lumino/coreutils';
5
5
  import { ISignal } from '@lumino/signaling';
6
- import { Widget } from '@lumino/widgets';
6
+ import { FocusTracker, Widget } from '@lumino/widgets';
7
7
  import { SidePanelHandler } from './panelhandler';
8
8
  /**
9
9
  * The Jupyter Notebook application shell token.
@@ -53,7 +53,7 @@ export declare class NotebookShell extends Widget implements JupyterFrontEnd.ISh
53
53
  /**
54
54
  * A signal emitted when the current widget changes.
55
55
  */
56
- get currentChanged(): ISignal<NotebookShell, void>;
56
+ get currentChanged(): ISignal<JupyterFrontEnd.IShell, FocusTracker.IChangedArgs<Widget>>;
57
57
  /**
58
58
  * The current widget in the shell's main area.
59
59
  */
package/lib/shell.js CHANGED
@@ -4,7 +4,7 @@ import { nullTranslator } from '@jupyterlab/translation';
4
4
  import { find } from '@lumino/algorithm';
5
5
  import { JSONExt, PromiseDelegate, Token } from '@lumino/coreutils';
6
6
  import { Signal } from '@lumino/signaling';
7
- import { BoxLayout, Panel, SplitPanel, Widget } from '@lumino/widgets';
7
+ import { BoxLayout, Panel, SplitPanel, Widget, } from '@lumino/widgets';
8
8
  import { PanelHandler, SidePanelHandler } from './panelhandler';
9
9
  /**
10
10
  * The Jupyter Notebook application shell token.
@@ -226,16 +226,21 @@ export class NotebookShell extends Widget {
226
226
  case 'menu':
227
227
  return this._menuHandler.addWidget(widget, rank);
228
228
  case 'main':
229
- case undefined:
229
+ case undefined: {
230
230
  if (this._main.widgets.length > 0) {
231
231
  // do not add the widget if there is already one
232
232
  return;
233
233
  }
234
+ const previousWidget = this.currentWidget;
234
235
  this._main.addWidget(widget);
235
236
  this._main.update();
236
- this._currentChanged.emit(void 0);
237
+ this._currentChanged.emit({
238
+ newValue: widget,
239
+ oldValue: previousWidget,
240
+ });
237
241
  this._mainWidgetLoaded.resolve();
238
242
  break;
243
+ }
239
244
  case 'left':
240
245
  return this._leftHandler.addWidget(widget, rank);
241
246
  case 'right':
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jupyter-notebook/application",
3
- "version": "7.1.2",
3
+ "version": "7.2.0-beta.0",
4
4
  "description": "Jupyter Notebook - Application",
5
5
  "homepage": "https://github.com/jupyter/notebook",
6
6
  "bugs": {
@@ -42,22 +42,22 @@
42
42
  "watch": "tsc -b --watch"
43
43
  },
44
44
  "dependencies": {
45
- "@jupyterlab/application": "~4.1.5",
46
- "@jupyterlab/coreutils": "~6.1.5",
47
- "@jupyterlab/docregistry": "~4.1.5",
48
- "@jupyterlab/rendermime-interfaces": "~3.9.5",
49
- "@jupyterlab/ui-components": "~4.1.5",
45
+ "@jupyterlab/application": "~4.2.0-beta.1",
46
+ "@jupyterlab/coreutils": "~6.2.0-beta.1",
47
+ "@jupyterlab/docregistry": "~4.2.0-beta.1",
48
+ "@jupyterlab/rendermime-interfaces": "~3.10.0-beta.1",
49
+ "@jupyterlab/ui-components": "~4.2.0-beta.1",
50
50
  "@lumino/algorithm": "^2.0.1",
51
51
  "@lumino/coreutils": "^2.1.2",
52
52
  "@lumino/messaging": "^2.0.1",
53
53
  "@lumino/polling": "^2.1.2",
54
54
  "@lumino/signaling": "^2.1.2",
55
- "@lumino/widgets": "^2.3.1"
55
+ "@lumino/widgets": "^2.3.2"
56
56
  },
57
57
  "devDependencies": {
58
58
  "@babel/core": "^7.11.6",
59
59
  "@babel/preset-env": "^7.12.1",
60
- "@jupyterlab/testutils": "~4.1.5",
60
+ "@jupyterlab/testutils": "~4.2.0-beta.1",
61
61
  "@types/jest": "^29.2.5",
62
62
  "jest": "^29.3.1",
63
63
  "rimraf": "^3.0.2",