Skip to content

Commit 002feec

Browse files
authored
Merge pull request #714 from martinRenou/jupyterlab3
JupyterLab 3 update
2 parents 6637471 + eb1bf2b commit 002feec

File tree

11 files changed

+18451
-9720
lines changed

11 files changed

+18451
-9720
lines changed

.github/workflows/main.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,25 +27,26 @@ jobs:
2727
mamba-version: "*"
2828
channels: conda-forge
2929

30-
- name: Conda install dependencies
30+
- name: Mamba install dependencies
3131
shell: bash -l {0}
32-
run: mamba install python=${{ matrix.python-version }} pip nodejs ipywidgets jupyter jupyterlab flake8
32+
run: mamba install python=${{ matrix.python-version }} pip nodejs flake8
3333

34-
- name: Install ipyleaflet
34+
- name: Mamba install JupyterLab 3
3535
shell: bash -l {0}
36-
run: pip install .
36+
run: mamba install jupyterlab=3 ipywidgets=7.6
3737

38-
- name: Install JupyterLab extension (Only on Linux for saving time)
39-
if: matrix.os == 'ubuntu-latest'
38+
- name: Install ipyleaflet
4039
shell: bash -l {0}
41-
run: jupyter labextension install js
40+
run: pip install .
4241

4342
- name: Check installation files
4443
shell: bash -l {0}
4544
run: |
4645
test -d $CONDA_PREFIX/share/jupyter/nbextensions/jupyter-leaflet
4746
test -f $CONDA_PREFIX/share/jupyter/nbextensions/jupyter-leaflet/extension.js
4847
test -f $CONDA_PREFIX/share/jupyter/nbextensions/jupyter-leaflet/index.js
48+
test -d $CONDA_PREFIX/share/jupyter/labextensions/jupyter-leaflet
49+
test -f $CONDA_PREFIX/share/jupyter/labextensions/jupyter-leaflet/package.json
4950
5051
- name: Flake8 check
5152
shell: bash -l {0}

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@ build/
66
node_modules/
77

88
# Compiled javascript
9-
ipyleaflet/static/
9+
ipyleaflet/nbextension/
10+
ipyleaflet/labextension/
11+
js/dist/
1012

1113
# OS X
1214
.DS_Store

MANIFEST.in

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
1-
recursive-include ipyleaflet/static *.*
1+
recursive-include ipyleaflet/nbextension *.*
2+
recursive-include ipyleaflet/labextension *.*
3+
24
include jupyter-leaflet.json
3-
include js/*tgz
5+
graft js/src
46
include js/package.json
7+
include js/webpack.config.js
8+
9+
include LICENSE
10+
include setup.py
11+
include pyproject.toml

ipyleaflet/__init__.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,17 @@
1414
pass
1515

1616

17+
def _jupyter_labextension_paths():
18+
return [{
19+
'src': 'labextension',
20+
'dest': 'jupyter-leaflet'
21+
}]
22+
23+
1724
def _jupyter_nbextension_paths():
1825
return [{
1926
'section': 'notebook',
20-
'src': 'static',
27+
'src': 'nbextension',
2128
'dest': 'jupyter-leaflet',
2229
'require': 'jupyter-leaflet/extension'
2330
}]

0 commit comments

Comments
 (0)