Skip to content

Commit e4f3f63

Browse files
authored
Added Jupyter Lab 4 support (#1146)
* Added @Lumino dependencies. * Removed unused @Lumino dependencies. * Updated webpack-cli version. * Changed @Lumino dependencies to v2. * Removed @Lumino dependencies. * Fixed resize bug. Added if(!this.obj) return; for all branches. * Updated @jupyterlab/builder version. * Updated @jupyterlab/builder dependency. * Updated jupyterlab python version.
1 parent 1e48a1f commit e4f3f63

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

js/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"stream-browserify": "^3.0.0"
5151
},
5252
"devDependencies": {
53-
"@jupyterlab/builder": "^3.6.0",
53+
"@jupyterlab/builder": "^4.0.8",
5454
"css-loader": "^3.4.2",
5555
"eslint": "^8.23.1",
5656
"eslint-config-prettier": "^8.5.0",
@@ -65,7 +65,7 @@
6565
"rimraf": "^2.6.1",
6666
"style-loader": "^1.1.2",
6767
"webpack": "^5",
68-
"webpack-cli": "^3.3.10"
68+
"webpack-cli": "^5.1.4"
6969
},
7070
"jupyterlab": {
7171
"extension": "src/jupyterlab-plugin",

js/src/Map.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,6 +448,7 @@ export class LeafletMapView extends utils.LeafletDOMWidgetView {
448448

449449
_processLuminoMessage(msg, _super) {
450450
_super.call(this, msg);
451+
if(!this.obj) return;
451452
switch (msg.type) {
452453
case 'resize':
453454
// We set the dirty flag to true to prevent the sub-pixel error
@@ -468,7 +469,6 @@ export class LeafletMapView extends utils.LeafletDOMWidgetView {
468469
this.dirty = true;
469470
// If we are in a jupyter-widget tab, we get an after-show before
470471
// this.displayed is resolved. In this case, obj is not created yet.
471-
if(!this.obj) return;
472472
this.obj.invalidateSize({
473473
animate: false,
474474
pan: true,

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[build-system]
22
# avoid 3.6 so we don't need the rust buildchain
3-
requires = ["jupyter_packaging~=0.12", "jupyterlab~=3.6.0", "setuptools>=40.8.0", "wheel"]
3+
requires = ["jupyter_packaging~=0.12", "jupyterlab~=4.0.8", "setuptools>=40.8.0", "wheel"]
44
build-backend = "setuptools.build_meta"

0 commit comments

Comments
 (0)