Compare commits

...

230 Commits
7.0.x ... main

Author SHA1 Message Date
p6micgy9w 472ee5d01b ADD file via upload
3 weeks ago
p6micgy9w 42ccc58dca Add src
3 weeks ago
Amulya S e54ce8ef6d
Fix grammar in notebook documentation (#7794)
4 weeks ago
jtpio 9836de423c Publish 7.6.0a0
1 month ago
dependabot[bot] e7f5e5d50e
Bump systeminformation from 5.23.14 to 5.27.14 in /ui-tests (#7788)
1 month ago
Jeremy Tuloup f0e7469483
Update to JupyterLab `4.6.0a0` (#7787)
1 month ago
jtpio 09f0f85e63 Publish 7.5.1
1 month ago
Arjun Verma fccf56801b
Add debugger display registry (#7774)
1 month ago
Jeremy Tuloup 22183446df
Update to JupyterLab v4.5.1 (#7785)
1 month ago
Jeremy Tuloup 1003f68930
Fix link to the IPython install page (#7783)
1 month ago
Jeremy Tuloup a5c9c9399d
fix selector (#7782)
1 month ago
dependabot[bot] 18411e8532
Bump the actions group with 4 updates (#7773)
1 month ago
Jeremy Tuloup 5bb41ae47c
Fix `hatch build`, ignore links to `blog.jupyter.org` (#7780)
1 month ago
jtpio b45653f564 Publish 7.5.0
2 months ago
Jeremy Tuloup be53ec8bc9
User facing changelog for 7.5 (#7770)
2 months ago
Jeremy Tuloup 7362e529a8
Update to JupyterLab v4.5.0 (#7768)
2 months ago
Jeremy Tuloup 1f8c7cd491
Clean up references to Gitpod (#7767)
2 months ago
Jeremy Tuloup 9c6ee5d5f9
Expose the cell toolbar settings (#7766)
2 months ago
jtpio 6923a84908 Publish 7.5.0rc1
2 months ago
Jeremy Tuloup 7533ccab5e
Update to JupyterLab v4.5.0rc1 (#7764)
2 months ago
dependabot[bot] 04bd4bc6f6
Bump the actions group across 1 directory with 3 updates (#7751)
2 months ago
Jeremy Tuloup 05dad4f597
Fix link to Code of Conduct in CONTRIBUTING.md (#7758)
2 months ago
Jason Grout 165e3cdf76
Remove JupyterCon 2025 announcement banner (#7757)
2 months ago
jtpio 7a960ab236 Publish 7.5.0rc0
3 months ago
Jeremy Tuloup 18ba796a58
Update to JupyterLab v4.5.0rc0 (#7755)
3 months ago
jtpio fd9c4b4427 Publish 7.5.0b1
3 months ago
Jeremy Tuloup 7f84b95ed6
Use Node.js 24 / npm 11 to publish releases (#7749)
3 months ago
Jeremy Tuloup 0201906757
Update to JupyterLab v4.5.0b1 (#7746)
3 months ago
Michał Krassowski 37ad3c4723
Update JupyterCon 2025 announcement links (#7744)
3 months ago
jtpio 79ad725908 Publish 7.5.0b0
4 months ago
Jeremy Tuloup 828708ec26
Update to JupyterLab v4.5.0b0 (#7739)
4 months ago
Chris Holdgraf 2e88202c8f
Add JupyterCon banner and add Jupyter colors (#7727)
4 months ago
jtpio efdef40919 Publish 7.5.0a3
4 months ago
Jeremy Tuloup 254b06ca4b
Update to JupyterLab v4.5.0a4 (#7728)
4 months ago
Jeremy Tuloup 0af6834093
Revert "Pin `click<8.3` (#7729)" (#7733)
4 months ago
Jeremy Tuloup c0d3e8b4d6
Pin `click<8.3` (#7729)
4 months ago
Jeremy Tuloup 9c5a275376
Remove link to `npmjs.com` (#7730)
4 months ago
dependabot[bot] 357229deac
Bump the actions group across 1 directory with 3 updates (#7704)
5 months ago
Jeremy Tuloup 346e30dec4
Define `O` as the keyboard shortcut to toggle cell outputs (#7709)
5 months ago
Jeremy Tuloup a8a8111d59
Increase checkpoint poll interval (#7711)
5 months ago
Jeremy Tuloup 5a845dcde0
Handle file rename errors (#7710)
5 months ago
jtpio 0e4fdd1941 Publish 7.5.0a2
5 months ago
Jeremy Tuloup 3100d879bf
Update to JupyterLab v4.5.0a3 (#7703)
5 months ago
Vishnutheep B 629e63445e
Encode URI file path (#7698)
5 months ago
jtpio 8f91eddf56 Publish 7.5.0a1
5 months ago
Jeremy Tuloup f56a27c17b
Update to JupyterLab v4.5.0a2 (#7694)
5 months ago
dependabot[bot] 6caeba2b22
Bump prefix-dev/setup-pixi from 0.8.10 to 0.8.11 in the actions group (#7675)
6 months ago
Jeremy Tuloup a82eeba22b
Pin `httpx` (#7691)
6 months ago
Sangam Paudel b99d42fd77
Fix grammatical errors in Contributing.md (#7669)
7 months ago
dependabot[bot] df09eaeb16
Bump prefix-dev/setup-pixi from 0.8.8 to 0.8.10 in the actions group (#7665)
7 months ago
dependabot[bot] 026fde1b38
Bump brace-expansion from 1.1.11 to 1.1.12 in /ui-tests (#7664)
7 months ago
Jeremy Tuloup 71532b9313
Update to JupyterLab v4.5.0a1 (#7656)
8 months ago
Min RK 329d55279b
Revert "CI: pin to `jupyter-core<5.8.0` on Windows (#7655)" (#7657)
8 months ago
Jeremy Tuloup 22016bb249
CI: pin to `jupyter-core<5.8.0` on Windows (#7655)
8 months ago
jchen1223 b1a5f61a24
Update CONTRIBUTING.md (#7645)
8 months ago
jtpio 1d9dbd31f8 Publish 7.5.0a0
9 months ago
Jeremy Tuloup 22e29fc419
Update to JupyterLab v4.5.0a0 (#7650)
9 months ago
dependabot[bot] b6dc5a2af2
Bump prefix-dev/setup-pixi from 0.8.5 to 0.8.8 in the actions group (#7637)
9 months ago
Jeremy Tuloup 0c45402e1a
Update to JupyterLab v4.4.1 (#7638)
9 months ago
Jeremy Tuloup 633fec9a5d
Run UI tests on `ubuntu-latest` (#7639)
9 months ago
Honnix ea978c685a
chore: Fix UP006 (#7633)
9 months ago
dependabot[bot] 40e1bbe464
Bump prefix-dev/setup-pixi from 0.8.4 to 0.8.5 in the actions group (#7632)
9 months ago
Honnix 2616caa858
fix: Update lower bound of required python to 3.9 (#7628)
9 months ago
jtpio f0bdc4756d Publish 7.4.0
10 months ago
dependabot[bot] fbfe36574e
Bump the actions group with 2 updates (#7626)
10 months ago
github-actions[bot] 3edc44b62a
Update to JupyterLab v4.4.0 (#7623)
10 months ago
jtpio 2077c92956 Publish 7.4.0rc0
10 months ago
Jeremy Tuloup 7fa19999c9
Add support for a `down` area (#7619)
10 months ago
Jeremy Tuloup 6853096044
Update to JupyterLab v4.4.0rc1 (#7622)
10 months ago
jtpio 903fef574e Publish 7.4.0b3
10 months ago
Jeremy Tuloup 434221c0fe
Update to JupyterLab v4.4.0rc0 (#7618)
10 months ago
Jeremy Tuloup 40891bd424
Support `ServiceManagerPlugin` (#7616)
10 months ago
jtpio ab63d5cd8d Publish 7.4.0b2
10 months ago
Jeremy Tuloup be2fd12f91
Add pixi step to the update workflow (#7608)
10 months ago
Jeremy Tuloup 326991fee9
Update to JupyterLab v4.4.0b2 (#7614)
10 months ago
Jeremy Tuloup 59b9411869
User facing changelog for 7.4 (#7612)
10 months ago
jtpio 9678c1831a Publish 7.4.0b1
10 months ago
Jeremy Tuloup 6d06d97302
Update to JupyterLab `v4.4.0b1` (#7607)
10 months ago
Jeremy Tuloup 6319ce6c3a
Update `@babel` dependencies (#7605)
10 months ago
Jeremy Tuloup bf1530f1b6
Add devcontainer support, backed by pixi (#7602)
10 months ago
Jeremy Tuloup 82a81c502c
Manual dependabot bumps (#7599)
11 months ago
dependabot[bot] 7dbd40a5ee
Bump vega-selections from 5.4.1 to 5.5.0 in /ui-tests (#7592)
11 months ago
jtpio fcbe87b876 Publish 7.4.0b0
11 months ago
Jeremy Tuloup 48243197bb
Update to JupyterLab v4.4.0b0 (#7591)
11 months ago
jtpio 2c66ed390e Publish 7.4.0a3
12 months ago
Jeremy Tuloup 48e52c759f
Improve handling of optional notebook tracker (#7581)
12 months ago
Jeremy Tuloup 3c4b8b59ba
Fix upgrade script (#7579)
12 months ago
Andrii Ieroshenko aad43d52f9
Add active cell border padding, remove double cell padding (#7570)
12 months ago
jtpio 0442b49351 Publish 7.4.0a2
12 months ago
Jeremy Tuloup ef4f6346cd
Update to JupyterLab v4.4.0a3 (#7577)
12 months ago
Michał Krassowski 3e125b1197
Allow owners/members/collab to trigger galata update on other's PR (#7572)
12 months ago
J. David Ibáñez 8b3b5b3ce7
Fix undefined error when checkpoints is empty (#7567)
1 year ago
jtpio 1f0ab8365b Publish 7.4.0a1
1 year ago
Jeremy Tuloup 18672b7e85
Update to JupyterLab v4.4.0a2 (#7559)
1 year ago
Jeremy Tuloup e1cd13abfe
Update `typescript` and `lerna` (#7562)
1 year ago
Jeremy Tuloup 99af31ec21
Update pre-commit hooks (#7561)
1 year ago
dependabot[bot] 4680e1a675
Bump the actions group across 1 directory with 2 updates (#7558)
1 year ago
Jeremy Tuloup 0bd4bae0b4
Improve update script (#7556)
1 year ago
jtpio 9d6f6a2042 Publish 7.4.0a0
1 year ago
Jeremy Tuloup 12efbe6018
Disable cron scheduling for now (#7555)
1 year ago
Jeremy Tuloup bb8aa0f44a
Update to JupyterLab v4.4.0a1 (#7554)
1 year ago
Jeremy Tuloup edfa5e2a6f
Update workflow improvements (#7552)
1 year ago
jtpio 0d49b45b29 Publish 7.3.2
1 year ago
github-actions[bot] 7959ba0de5
Update to JupyterLab v4.3.4 (#7551)
1 year ago
Jeremy Tuloup 8760def0b6
Fix update script (#7550)
1 year ago
Jeremy Tuloup abd1b8c96b
Fix workflow to update the JupyterLab version (#7548)
1 year ago
dependabot[bot] f11252b4ac
Bump nanoid from 3.3.7 to 3.3.8 in /ui-tests (#7547)
1 year ago
dependabot[bot] 2bfae71810
Bump systeminformation from 5.21.8 to 5.23.14 in /ui-tests (#7546)
1 year ago
Vishnutheep B c0ddf0164f
Workflow to update JupyterLab dependencies automatically (#7281)
1 year ago
Eric Gentry d9119b8cd5
Update chat links to Zulip. (#7539)
1 year ago
brichet a97b425d65 Publish 7.3.1
1 year ago
Nicolas Brichet 21d0306ece
Adds jupyter-ui-toolkit packages in shared scope (#7530)
1 year ago
jtpio d847b24653 Publish 7.3.0
1 year ago
Jeremy Tuloup b16eed26ef
Fix link to the JupyterLab 4.3 changelog (#7529)
1 year ago
Jeremy Tuloup 3b66049a62
Update to JupyterLab 4.3.2 (#7527)
1 year ago
Jeremy Tuloup 32fa1c5d89
Bump Python version used on CI (#7528)
1 year ago
jtpio 7724c41ff1 Publish 7.3.0rc0
1 year ago
Jeremy Tuloup b34449747a
Update to JupyterLab 4.3.1 (#7521)
1 year ago
jtpio 606190117a Publish 7.3.0b2
1 year ago
Greg Mooney 110e728e4a
Add webpack prod config (#7513)
1 year ago
Greg Mooney 5cac611f26
Reflect autoScrollOutput setting (#7511)
1 year ago
Greg Mooney c93015d1b6
Rename some header links to fit better (#7508)
1 year ago
Jeremy Tuloup 1249220b25
Update to JupyterLab 4.3 final (#7507)
1 year ago
jtpio d78c4e7719 Publish 7.3.0b1
1 year ago
Jeremy Tuloup f614f7c638
Move handling of the file browser settings to a separate plugin, enable file browser single click navigation (#7481)
1 year ago
Jeremy Tuloup 2a8e5797a3
Add user facing changelog for `7.3.0` (#7494)
1 year ago
Jeremy Tuloup dd6db47d46
Update to JupyterLab `4.3.0rc1` (#7497)
1 year ago
Jeremy Tuloup 390c4526df
Add a setting to enable the notebook to take up the full width (#7487)
1 year ago
Jeremy Tuloup 676a0fec82
Add the file filter button to the file browser toolbar (#7479)
1 year ago
jtpio faee9e4552 Publish 7.3.0b0
1 year ago
Jeremy Tuloup fec4431305
Remove the `StateDB` file browser trick (#7477)
1 year ago
Jeremy Tuloup 324de44521
Update to JupyterLab `4.3.0rc0` (#7423)
1 year ago
algonell 7760265de5
Fix typos (#7472)
1 year ago
Andy Schoenberger 59f8c306f8
Redirect paths from the notebooks route to the tree route if they are directories (#7446)
1 year ago
Michał Krassowski 43b8cceb69
Merge pull request from GHSA-6rpp-pfgf-g9qj
2 years ago
jtpio 53b3820664 Publish 7.3.0a1
2 years ago
Jeremy Tuloup ff2b822d06
Update to JupyterLab `4.3.0a1` (#7416)
2 years ago
Michał Krassowski fffe390408
Remove pseudoelement obstructing the cell collapser (#7392)
2 years ago
jtpio 9c70c1367e Publish 7.3.0a0
2 years ago
martinRenou 1a03b9d8e5
Add missing "Open..." file menu (#7385)
2 years ago
Michael Dempsey b010e1d5f2
Support custom page_data_hook function (#7387)
2 years ago
Jason Weill 433f18094d
Shuts the notebook down without the confirmation dialog (#7384)
2 years ago
Jason Weill eace81c87b
Adds message about building code before running 'develop' (#7382)
2 years ago
Jeremy Tuloup 368080f53a
Update to JupyterLab 4.3.0a0 (#7378)
2 years ago
Jason Weill 0a66f40c46
Duplicate notebook menu option (#7374)
2 years ago
jtpio 30587b826a Publish 7.2.0
2 years ago
Jeremy Tuloup 31bf294e85
Add user facing changelog for 7.2 (#7372)
2 years ago
Jeremy Tuloup 08fe5c5df1
Update `@jupyterlab/galata` (#7361)
2 years ago
Jason Weill 7891117aa9
Update config.yml (#7363)
2 years ago
jtpio a1e25b92bf Publish 7.2.0rc1
2 years ago
Jeremy Tuloup f5d8aea3bd
Default to the `full` windowing mode (#7321)
2 years ago
Jeremy Tuloup b18084867c
Update to JupyterLab 4.2.0 (#7357)
2 years ago
Jeremy Tuloup 91dc1190b8
Add the `@jupyterlab/notebook-extension:copy-output` plugin (#7353)
2 years ago
Aidan Feldman 094fef3104
update RISE extension installation instructions (#7299)
2 years ago
jtpio fdd36606d2 Publish 7.2.0rc0
2 years ago
Jeremy Tuloup 49ddd0fe1e
Update to JupyterLab 4.2.0rc0 (#7333)
2 years ago
Jeremy Tuloup 1c3f812338
Pin on `macos-12` on CI for now (#7346)
2 years ago
Jeremy Tuloup f6a56f5608
Fix CSS for `full` windowing mode (#7337)
2 years ago
jtpio 7becb180ea Publish 7.2.0b1
2 years ago
Jeremy Tuloup b45d666d5e
For notebook windowing mode to `defer` (#7335)
2 years ago
Jeremy Tuloup 20243fc004
Add `@jupyterlab/theme-dark-high-contrast-extension` (#7331)
2 years ago
Jeremy Tuloup e9154289a0
Fix scrollbar always showing up by default (#7327)
2 years ago
jtpio ad0e1b0d02 Publish 7.2.0b0
2 years ago
Jeremy Tuloup 09bcd99e6d
Update to JupyterLab `4.2.0b1` (#7319)
2 years ago
Jeremy Tuloup 2b9d339558
Update to JupyterLab 4.2.0b0 (#7312)
2 years ago
jtpio 3b8e673607 Publish 7.2.0a0
2 years ago
Jeremy Tuloup 80b582bce6
Update to JupyterLab 4.2.0a2 (#7307)
2 years ago
Jeremy Tuloup 4ca5dc2003
Ignore links to GitHub user and organisation profiles (#7308)
2 years ago
jtpio 851a4beaae Publish 7.1.2
2 years ago
Jeremy Tuloup ca41222a9c
Update to JupyterLab 4.1.5 packages (#7291)
2 years ago
Steven Silvester 147ce80454
Update Release Scripts (#7295)
2 years ago
Jeremy Tuloup d45362b549
Fix jupyterlab install command in the releaser hook (#7294)
2 years ago
Nicolas Brichet 2c95b1beb7
Add a section to use local dependencies (#7292)
2 years ago
jtpio c66e6ad66d Publish 7.1.1
2 years ago
Jeremy Tuloup da7b8d400e
Fix flaky mobile UI tests (#7278)
2 years ago
Jeremy Tuloup ca5eb17a2e
Update to JupyterLab 4.1.2 packages (#7277)
2 years ago
Jeremy Tuloup f2ee4ba2c5
Expose `version_info` (#7273)
2 years ago
Jeremy Tuloup 882da27432
Ignore stackoverflow link (#7274)
2 years ago
dependabot[bot] 60cd62ec90
Bump ip from 2.0.0 to 2.0.1 (#7267)
2 years ago
dependabot[bot] 55ecef9eb3
Bump ip from 2.0.0 to 2.0.1 in /ui-tests (#7268)
2 years ago
Vishnutheep B f9bddf9690
Grayout "Edit Notebook Metadata" for other file formats. (#7265)
2 years ago
jtpio f6f5a1f538 Publish 7.1.0
2 years ago
Jeremy Tuloup b8ec7e4a8e
Fix spurious kernel selection dialog on notebook creation (#7258)
2 years ago
Jeremy Tuloup 9348f1f2ed
Update to JupyterLab 4.1.1 (#7256)
2 years ago
Jeremy Tuloup d43911b23e
Create a new notebook with a specific kernel from the new dropdown (#7255)
2 years ago
jtpio e49f77ea12 Publish 7.1.0rc1
2 years ago
Jeremy Tuloup 376a2f97c8
Follow JupyterLab minor versions (#7250)
2 years ago
Jeremy Tuloup aef8e95fc5
Add documentation for updating `notebook` imports (#7244)
2 years ago
jtpio 5909ff9655 Publish 7.1.0rc0
2 years ago
Dilip-Jain 2d717f5896
Added Edit Notebook Metadata Option (#6402) (#7099)
2 years ago
pre-commit-ci[bot] 1d0a402bcc
chore: update pre-commit hooks (#7237)
2 years ago
Jeremy Tuloup 3299ee6db6
Update to JupyterLab 4.1.0 final (#7234)
2 years ago
Jeremy Tuloup 6785346d3f
Fix link in `CONTRIBUTING.md` (#7235)
2 years ago
Jeremy Tuloup 48ad63181b
Add user facing changelog for 7.1 (#7232)
2 years ago
Jeremy Tuloup e8633bd8d7
Update to JupyterLab 4.1.0rc1 (#7230)
2 years ago
Jeremy Tuloup 09f018b58c
Update to JupyterLab 4.1.0rc0 (#7227)
2 years ago
jtpio 019e8c9e5b Publish 7.1.0b0
2 years ago
Jeremy Tuloup 5d265b90ed
Workaround for the file browser tracker focus issue (#7224)
2 years ago
Jeremy Tuloup 1145745651
Update to JupyterLab 4.1.0b2 (#7222)
2 years ago
dependabot[bot] b21fede639
Bump the actions group with 1 update (#7218)
2 years ago
Jeremy Tuloup f826ac9d12
Fix `check_links` on CI (#7219)
2 years ago
dependabot[bot] 6f8680cd70
Bump the actions group with 2 updates (#7207)
2 years ago
pre-commit-ci[bot] 9a98743fc2
chore: update pre-commit hooks (#7206)
2 years ago
jtpio d21c79a474 Publish 7.1.0a2
2 years ago
Jeremy Tuloup 251e0e3606
Add the plugin manager (#7198)
2 years ago
Jeremy Tuloup 0fbb1b252c
Add nbviewer.jupyter.org to the ignore list (#7197)
2 years ago
Jeremy Tuloup 165b84e8ce
Update to JupyterLab 4.1.0b0 (#7196)
2 years ago
Aarni Koskela d67c3cb4ec
Clarify README about supported versions (post v7 release) (#7193)
2 years ago
Steven Silvester 0a08ba3f96
Update ruff config (#7190)
2 years ago
dependabot[bot] 5ec7d5eef4
Bump @babel/traverse from 7.23.0 to 7.23.6 (#7187)
2 years ago
Jeremy Tuloup c2ca209ab8
Remove viewport workaround in the UI tests (#6887)
2 years ago
Hao Kang 728807f401
Fix toggle functionality for widgets. (#7178)
2 years ago
dependabot[bot] dbb489a1d6
Bump actions/setup-python from 4 to 5 (#7180)
2 years ago
Jeremy Tuloup 360bee8dc0
Update publish-release workflow for PyPI trusted publisher (#7176)
2 years ago
pre-commit-ci[bot] 644c393580
chore: update pre-commit hooks (#7174)
2 years ago
jtpio 42fffbb725 Publish 7.1.0a1
2 years ago
Nicolas Brichet a74cd91871
Bump to JupyterLab 4.1.0a4 bis (#7172)
2 years ago
dependabot[bot] 2a0ed48473
Bump axios from 1.5.1 to 1.6.2 (#7165)
2 years ago
Jeremy Tuloup 4266df1eef
Add the JupyterLab resources plugin (#6968)
2 years ago
Jeremy Tuloup e2429db5fb
Update `yarn.lock` (#7170)
2 years ago
Jeremy Tuloup ef1f8db5c2
Update to JupyterLab `4.1.0a3` (#7161)
2 years ago
dependabot[bot] 8086d6c0cf
Bump dessant/lock-threads from 4 to 5 (#7159)
2 years ago
Steven Silvester 29d665dbac
Update ruff config and typing (#7145)
2 years ago
pre-commit-ci[bot] 875e4d754f
chore: update pre-commit hooks (#7143)
2 years ago
Steven Silvester 7c43de793e
Clean up lint handling (#7142)
2 years ago
Steven Silvester 2ee380b3e8
Adopt ruff format (#7132)
2 years ago
jtpio 55f5f6f11d Publish 7.1.0a0
2 years ago
Jeremy Tuloup 0cd6104b92
Fix python bumping to `minor` (#7131)
2 years ago
Jeremy Tuloup 53b47af37b
Update to JupyterLab 4.1 (#7096)
2 years ago
Dilip-Jain 1ff62934df
Added Lumino Plugin Description (#7008) (#7127)
2 years ago

@ -0,0 +1,13 @@
FROM mcr.microsoft.com/devcontainers/base:jammy
ARG PIXI_VERSION=v0.42.1
RUN curl -L -o /usr/local/bin/pixi -fsSL --compressed "https://github.com/prefix-dev/pixi/releases/download/${PIXI_VERSION}/pixi-$(uname -m)-unknown-linux-musl" \
&& chmod +x /usr/local/bin/pixi \
&& pixi info
# set some user and workdir settings to work nicely with vscode
USER vscode
WORKDIR /home/vscode
RUN echo 'eval "$(pixi completion -s bash)"' >> /home/vscode/.bashrc

@ -0,0 +1,21 @@
{
"name": "Jupyter Notebook",
"build": {
"dockerfile": "Dockerfile",
"context": ".."
},
"forwardPorts": [8888],
"customizations": {
"vscode": {
"settings": {},
"extensions": ["ms-python.python", "charliermarsh.ruff", "GitHub.copilot"]
}
},
"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {}
},
"mounts": [
"source=${localWorkspaceFolderBasename}-pixi,target=${containerWorkspaceFolder}/.pixi,type=volume"
],
"postCreateCommand": "sudo chown vscode .pixi && pixi install && pixi run develop && pixi run pre-commit install -f"
}

@ -18,3 +18,6 @@ app/index.template.js
# ms IDE stuff
.history/
.vscode/
# Pixi environments
.pixi

2
.gitattributes vendored

@ -0,0 +1,2 @@
# SCM syntax highlighting & preventing 3-way merges
pixi.lock merge=binary linguist-language=YAML linguist-generated=true

@ -3,11 +3,11 @@ contact_links:
- name: Is this a common issue? See our Docs.
url: https://jupyter-notebook.readthedocs.io/en/latest/troubleshooting.html#what-to-do-when-things-go-wrong
about: Before opening an issue, make sure your issue hasn't already been addressed in the documentation.
- name: \U0001F914 Support and all other questions, including if you're not sure what to do.
- name: 🤔 Support and all other questions, including if you're not sure what to do.
url: https://discourse.jupyter.org/c/notebook/31
about: If you have a question or you're having issues installing Jupyter Notebook, try posting on Discourse.
- name: "\U0001F4AC Chat with the devs"
url: https://app.gitter.im/#/room/#jupyter_notebook:gitter.im
- name: 💬 Chat with the devs
url: https://jupyter.zulipchat.com/
about: Ask short questions about using Jupyter Notebook
- name: 📝 Do you have a feature request that may be applied upstream? See JupyterLab.
url: https://github.com/jupyterlab/jupyterlab

@ -32,13 +32,13 @@ runs:
sha256sum * | tee SHA256SUMS
- name: Upload distributions
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: notebook-dist-${{ github.run_number }}
path: ./dist
- name: Upload distributions
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: notebook-pkgs-${{ github.run_number }}
path: ./pkgs

@ -4,6 +4,10 @@ updates:
directory: '/'
schedule:
interval: 'weekly'
groups:
actions:
patterns:
- "*"
- package-ecosystem: 'pip'
directory: '/'
schedule:

@ -14,4 +14,4 @@ jobs:
permissions:
pull-requests: write
steps:
- uses: toshimaru/auto-author-assign@v2.0.1
- uses: toshimaru/auto-author-assign@v2.1.1

@ -26,7 +26,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Build
uses: ./.github/actions/build-dist
@ -38,10 +38,10 @@ jobs:
fail-fast: false
matrix:
# used by the jupyterlab/maintainer-tools base-setup action
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
@ -68,7 +68,7 @@ jobs:
needs:
- test
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/report-coverage@v1
with:
fail_under: 78
@ -77,7 +77,7 @@ jobs:
name: Test Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- run: |
sudo apt-get update
@ -92,7 +92,7 @@ jobs:
timeout-minutes: 20
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
with:
dependency_type: minimum
@ -106,7 +106,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
with:
dependency_type: pre
@ -122,13 +122,13 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python: ['3.8', '3.11', '3.12']
python: ['3.9', '3.11', '3.13']
include:
- python: '3.8'
- python: '3.9'
dist: 'notebook*.tar.gz'
- python: '3.11'
dist: 'notebook*.whl'
- python: '3.12'
- python: '3.13'
dist: 'notebook*.whl'
- os: windows-latest
py_cmd: python
@ -138,12 +138,11 @@ jobs:
py_cmd: python
steps:
- name: Install Python
uses: actions/setup-python@v4
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
architecture: 'x64'
allow-prereleases: true
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v6
with:
name: notebook-dist-${{ github.run_number }}
path: ./dist
@ -171,29 +170,30 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- uses: jupyterlab/maintainer-tools/.github/actions/check-links@v1
with:
ignore_links: 'https://playwright.dev/docs/test-cli/ https://blog.jupyter.org/the-big-split-9d7b88a031a7 https://blog.jupyter.org/jupyter-ascending-1bf5b362d97e https://mybinder.org/v2/gh/jupyter/notebook/main'
ignore_links: 'https://playwright.dev/docs/test-cli/ https://blog.jupyter.org/.* https://mybinder.org/v2/gh/jupyter/notebook/main https://nbviewer.jupyter.org https://stackoverflow.com https://github.com/[^/]+/?$'
ignore_glob: 'ui-tests/test/notebooks/*'
test_lint:
name: Test Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Run Linters
run: |
hatch run typing:test
hatch run lint:style
hatch run lint:build
pipx run interrogate -v .
pipx run doc8 --max-line-length=200 docs/source *.md
npm install -g yarn
yarn
yarn eslint:check
yarn prettier:check
yarn build:utils
yarn integrity
tests_check: # This job does nothing and is only used for the branch protection

@ -22,14 +22,14 @@ jobs:
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Install dependencies
run: |
python -m pip install -U "jupyterlab>=4.0.2,<5" hatch
python -m pip install -U "jupyterlab>=4.6.0a0,<4.7" hatch
jlpm
jlpm run build
@ -69,16 +69,16 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Install Python
uses: actions/setup-python@v4
uses: actions/setup-python@v6
with:
python-version: '3.9'
python-version: '3.10'
architecture: 'x64'
- name: Install dependencies
run: |
python -m pip install -U "jupyterlab>=4.0.2,<5" pip
python -m pip install -U "jupyterlab>=4.6.0a0,<4.7" pip
jlpm
jlpm run build

@ -17,7 +17,7 @@ jobs:
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Check Release
@ -27,7 +27,7 @@ jobs:
version_spec: next
- name: Upload Distributions
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v5
with:
name: notebook-jupyter-releaser-dist-${{ github.run_number }}
path: .jupyter_releaser_checkout/dist

@ -14,7 +14,7 @@ jobs:
issues: write
pull-requests: write
steps:
- uses: dessant/lock-threads@v4
- uses: dessant/lock-threads@v5
with:
github-token: ${{ github.token }}
issue-lock-inactive-days: '180'

@ -9,7 +9,19 @@ permissions:
jobs:
update-snapshots:
if: ${{ github.event.issue.pull_request && contains(github.event.comment.body, 'update playwright snapshots') }}
if: >
(
github.event.issue.author_association == 'OWNER' ||
github.event.issue.author_association == 'COLLABORATOR' ||
github.event.issue.author_association == 'MEMBER' ||
github.event.comment.author_association == 'OWNER' ||
github.event.comment.author_association == 'COLLABORATOR' ||
github.event.comment.author_association == 'MEMBER'
) && github.event.issue.pull_request && (
contains(github.event.comment.body, 'please update playwright snapshots') ||
contains(github.event.comment.body, 'please update galata snapshots') ||
contains(github.event.comment.body, 'please update snapshots')
)
runs-on: ubuntu-latest
permissions:
# Required by actions/update-snapshots
@ -22,7 +34,7 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: React to the triggering comment
run: |
@ -30,14 +42,43 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout the branch from the PR that triggered the job
- name: Configure git to use https
run: git config --global hub.protocol https
- name: Get PR Info
id: pr
env:
PR_NUMBER: ${{ github.event.issue.number }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
COMMENT_AT: ${{ github.event.comment.created_at }}
run: |
# PR branch remote must be checked out using https URL
git config --global hub.protocol https
pr="$(gh api /repos/${GH_REPO}/pulls/${PR_NUMBER})"
head_sha="$(echo "$pr" | jq -r .head.sha)"
pushed_at="$(echo "$pr" | jq -r .pushed_at)"
if [[ $(date -d "$pushed_at" +%s) -gt $(date -d "$COMMENT_AT" +%s) ]]; then
echo "Updating is not allowed because the PR was pushed to (at $pushed_at) after the triggering comment was issued (at $COMMENT_AT)"
exit 1
fi
echo "head_sha=$head_sha" >> $GITHUB_OUTPUT
gh pr checkout ${{ github.event.issue.number }}
- name: Checkout the branch from the PR that triggered the job
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh pr checkout ${{ github.event.issue.number }}
- name: Validate the fetched branch HEAD revision
env:
EXPECTED_SHA: ${{ steps.pr.outputs.head_sha }}
run: |
actual_sha="$(git rev-parse HEAD)"
if [[ "$actual_sha" != "$EXPECTED_SHA" ]]; then
echo "The HEAD of the checked out branch ($actual_sha) differs from the HEAD commit available at the time when trigger comment was submitted ($EXPECTED_SHA)"
exit 1
fi
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
@ -45,7 +86,7 @@ jobs:
- name: Build
uses: ./.github/actions/build-dist
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v6
with:
name: notebook-dist-${{ github.run_number }}
path: ./dist

@ -1,29 +1,33 @@
name: 'Step 1: Prep Release'
name: "Step 1: Prep Release"
on:
workflow_dispatch:
inputs:
version_spec:
description: 'New Version Specifier'
default: 'next'
description: "New Version Specifier"
default: "next"
required: false
branch:
description: 'The branch to target'
description: "The branch to target"
required: false
post_version_spec:
description: 'Post Version Specifier'
description: "Post Version Specifier"
required: false
silent:
description: "Set a placeholder in the changelog and don't publish the release."
required: false
type: boolean
since:
description: 'Use PRs with activity since this date or git reference'
description: "Use PRs with activity since this date or git reference"
required: false
since_last_stable:
description: 'Use PRs with activity since the last stable git tag'
description: "Use PRs with activity since the last stable git tag"
required: false
type: boolean
permissions:
contents: read
jobs:
prep_release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
@ -31,14 +35,15 @@ jobs:
id: prep-release
uses: jupyter-server/jupyter_releaser/.github/actions/prep-release@v2
with:
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
token: ${{ secrets.GITHUB_TOKEN }}
version_spec: ${{ github.event.inputs.version_spec }}
silent: ${{ github.event.inputs.silent }}
post_version_spec: ${{ github.event.inputs.post_version_spec }}
target: ${{ github.event.inputs.target }}
branch: ${{ github.event.inputs.branch }}
since: ${{ github.event.inputs.since }}
since_last_stable: ${{ github.event.inputs.since_last_stable }}
- name: '** Next Step **'
- name: "** Next Step **"
run: |
echo "Optional): Review Draft Release: ${{ steps.prep-release.outputs.release_url }}"

@ -0,0 +1,34 @@
name: "Publish Changelog"
on:
release:
types: [published]
workflow_dispatch:
inputs:
branch:
description: "The branch to target"
required: false
jobs:
publish_changelog:
runs-on: ubuntu-latest
environment: release
steps:
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- uses: actions/create-github-app-token@v2
id: app-token
with:
app-id: ${{ vars.APP_ID }}
private-key: ${{ secrets.APP_PRIVATE_KEY }}
- name: Publish changelog
id: publish-changelog
uses: jupyter-server/jupyter_releaser/.github/actions/publish-changelog@v2
with:
token: ${{ steps.app-token.outputs.token }}
branch: ${{ github.event.inputs.branch }}
- name: "** Next Step **"
run: |
echo "Merge the changelog update PR: ${{ steps.publish-changelog.outputs.pr_url }}"

@ -1,32 +1,39 @@
name: 'Step 2: Publish Release'
name: "Step 2: Publish Release"
on:
workflow_dispatch:
inputs:
branch:
description: 'The target branch'
description: "The target branch"
required: false
release_url:
description: 'The URL of the draft GitHub release'
description: "The URL of the draft GitHub release"
required: false
steps_to_skip:
description: 'Comma separated list of steps to skip'
description: "Comma separated list of steps to skip"
required: false
permissions:
contents: read
jobs:
publish_release:
runs-on: ubuntu-latest
environment: release
permissions:
id-token: write
steps:
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
with:
node_version: '24'
- uses: actions/create-github-app-token@v2
id: app-token
with:
app-id: ${{ vars.APP_ID }}
private-key: ${{ secrets.APP_PRIVATE_KEY }}
- name: Populate Release
id: populate-release
uses: jupyter-server/jupyter_releaser/.github/actions/populate-release@v2
with:
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
target: ${{ github.event.inputs.target }}
token: ${{ steps.app-token.outputs.token }}
branch: ${{ github.event.inputs.branch }}
release_url: ${{ github.event.inputs.release_url }}
steps_to_skip: ${{ github.event.inputs.steps_to_skip }}
@ -34,23 +41,19 @@ jobs:
- name: Finalize Release
id: finalize-release
env:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
PYPI_TOKEN_MAP: ${{ secrets.PYPI_TOKEN_MAP }}
TWINE_USERNAME: __token__
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
uses: jupyter-server/jupyter-releaser/.github/actions/finalize-release@v2
uses: jupyter-server/jupyter_releaser/.github/actions/finalize-release@v2
with:
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
target: ${{ github.event.inputs.target }}
token: ${{ steps.app-token.outputs.token }}
release_url: ${{ steps.populate-release.outputs.release_url }}
- name: '** Next Step **'
- name: "** Next Step **"
if: ${{ success() }}
run: |
echo "Verify the final release"
echo ${{ steps.finalize-release.outputs.release_url }}
- name: '** Failure Message **'
- name: "** Failure Message **"
if: ${{ failure() }}
run: |
echo "Failed to Publish the Draft Release Url:"

@ -19,14 +19,14 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Build
uses: ./.github/actions/build-dist
ui-tests:
needs: [build]
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
@ -34,12 +34,12 @@ jobs:
browser: [firefox, chromium]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v6
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v6
with:
name: notebook-dist-${{ github.run_number }}
path: ./dist
@ -62,7 +62,7 @@ jobs:
- name: Upload Playwright Test assets
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v5
with:
name: notebook-${{ matrix.browser }}-test-assets
path: |
@ -70,7 +70,7 @@ jobs:
- name: Upload Playwright Test report
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v5
with:
name: notebook-${{ matrix.browser }}-test-report
path: |
@ -87,7 +87,7 @@ jobs:
- name: Upload updated snapshots
if: failure()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v5
with:
name: notebook-${{ matrix.browser }}-updated-snapshots
path: ui-tests/test

@ -0,0 +1,128 @@
name: Check for latest JupyterLab releases
on:
# schedule:
# - cron: 30 17 * * *
workflow_dispatch:
inputs:
version:
description: 'JupyterLab version'
default: latest
required: true
type: string
branch:
description: 'The branch to target'
default: main
required: false
type: string
target_repo:
description: 'Target repository'
required: false
default: jupyter/notebook
type: string
env:
version_tag: 'latest'
permissions:
actions: write
contents: write
pull-requests: write
jobs:
check_for_lab_updates:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
ref: ${{ inputs.branch || 'main' }}
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.11'
- name: Install Node
uses: actions/setup-node@v6
with:
node-version: '20.x'
- name: Install npm dependencies and build buildutils
run: |
python -m pip install -e ".[dev]"
jlpm
jlpm run build:utils
- name: Check for new releases and update
shell: bash
run: |
set -eux
for version in ${{ inputs.version || env.version_tag }}
do
if [[ "${version}" == "latest" ]]; then
export LATEST=$(jlpm run get:lab:version --set-version ${version})
else
export LATEST=${version}
fi
done
echo "latest=${LATEST}" >> $GITHUB_ENV
jlpm upgrade:lab:dependencies --set-version ${LATEST}
if [[ ! -z "$(git status --porcelain package.json)" ]]; then
jlpm
jlpm deduplicate
cd ui-tests
jlpm
jlpm deduplicate
fi
- uses: prefix-dev/setup-pixi@v0.9.3
with:
pixi-version: v0.41.4
manifest-path: pyproject.toml
locked: false
- name: Update pixi.lock
run: pixi install
- name: Create a PR
env:
GITHUB_TOKEN: ${{ secrets.PERSONAL_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
run: |
set -eux
export LATEST=${{ env.latest }}
export BRANCH_NAME=update-to-v${LATEST}
# if resulted in any change:
if [[ ! -z "$(git status --porcelain package.json)" ]]; then
# if branch already exists.
if git ls-remote --heads origin | grep "refs/heads/${BRANCH_NAME}$" > /dev/null; then
echo "Branch '${BRANCH_NAME}' exists."
else
# new branch is created
git checkout -b "${BRANCH_NAME}"
git config user.name "github-actions[bot]"
git config user.email 'github-actions[bot]@users.noreply.github.com'
git commit . -m "Update to JupyterLab v${LATEST}"
git push --set-upstream origin "${BRANCH_NAME}"
PR_ARGS=(
--base "${{ inputs.branch || 'main' }}"
--title "Update to JupyterLab v${LATEST}"
--body "New JupyterLab release [v${LATEST}](https://github.com/jupyterlab/jupyterlab/releases/tag/v${LATEST}) is available. Please review the lock file carefully."
)
# Add --repo flag only if target_repo is specified
if [[ -n "${{ inputs.target_repo }}" ]]; then
PR_ARGS+=(--repo "${{ inputs.target_repo }}")
fi
gh pr create "${PR_ARGS[@]}"
fi
fi

13
.gitignore vendored

@ -135,3 +135,16 @@ ui-tests/playwright-report
.pnp.*
ui-tests/.yarn/*
ui-tests/.pnp.*
# keep potential upstream patches
!.yarn/patches
# generated html
notebook/templates/*.html
# pixi environments
.pixi
*.egg-info
# Temporary files used for testing
tmp/

@ -1,58 +0,0 @@
github:
prebuilds:
master: true
pullRequests: true
pullRequestsFromForks: true
addCheck: false
addComment: false
addBadge: false
addLabel: false
tasks:
- name: setup
init: |
pushd /workspace
wget -qO- https://micro.mamba.pm/api/micromamba/linux-64/latest | tar -xvj bin/micromamba
popd
# bootstrap activation commands for other tasks to reuse
cat <<EOT > /workspace/bin/activate-env.sh
export MAMBA_ROOT_PREFIX=/workspace/.micromamba
export MAMBA_EXE=/workspace/bin/micromamba
$(/workspace/bin/micromamba shell hook --shell=bash)
export JUPYTER_PREFER_ENV_PATH=1
export TZ=UTC
micromamba activate
EOT
source /workspace/bin/activate-env.sh
micromamba install -n base -y -c conda-forge python=3.11 nodejs=18
source /workspace/bin/activate-env.sh
python -m pip install -e ".[dev,test]" && jlpm run build && jlpm develop
gp sync-done setup
command: |
gp sync-done setup
source /workspace/bin/activate-env.sh
jupyter notebook --no-browser --ServerApp.token='' --ServerApp.allow_remote_access=True
- name: auto-activate
command: |
gp sync-await setup
source /workspace/bin/activate-env.sh
jlpm watch
- name: shell
command: |
gp sync-await setup
echo "source /workspace/bin/activate-env.sh" >> ~/.bashrc
source /workspace/bin/activate-env.sh
- name: docs
command: |
gp sync-await setup
sudo apt-get update
sudo apt install enchant-2 -y
wget https://github.com/jgm/pandoc/releases/download/2.14.2/pandoc-2.14.2-1-amd64.deb -O /tmp/pandoc.deb && sudo dpkg -i /tmp/pandoc.deb
source /workspace/bin/activate-env.sh
hatch run docs:build
hatch run docs:serve
ports:
- port: 8888

@ -4,7 +4,7 @@ ci:
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v5.0.0
hooks:
- id: check-case-conflict
- id: check-ast
@ -21,33 +21,32 @@ repos:
- id: trailing-whitespace
- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.27.0
rev: 0.30.0
hooks:
- id: check-github-workflows
- repo: https://github.com/adamchainz/blacken-docs
rev: '1.16.0'
hooks:
- id: blacken-docs
additional_dependencies: [black==23.7.0]
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 23.9.1
hooks:
- id: black
- repo: https://github.com/codespell-project/codespell
rev: 'v2.2.6'
rev: 'v2.3.0'
hooks:
- id: codespell
args: ['-L', 'sur,nd']
args: ['-L', 'hart,noteable', '--skip', "*.spec.ts"]
exclude: |
(?x)^(
yarn.lock|
pixi.lock|
binder/example.ipynb|
docs/source/examples/images/FrontendKernel.graffle/data.plist|
)$
- repo: https://github.com/pre-commit/mirrors-mypy
rev: "v1.14.1"
hooks:
- id: mypy
files: "^notebook"
stages: [manual]
args: ["--install-types", "--non-interactive"]
additional_dependencies: ["traitlets>=5.13", "tornado", "jupyter_server>=2.10", "jupyterlab_server>=2.25", "jupyterlab>=4.6.0a0,<4.7"]
- repo: https://github.com/pre-commit/pygrep-hooks
rev: 'v1.10.0'
hooks:
@ -56,13 +55,18 @@ repos:
- id: rst-inline-touching-normal
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.292
rev: v0.8.6
hooks:
- id: ruff
types_or: [ python, jupyter ]
exclude: '^docs/source/examples/Notebook/Importing Notebooks.ipynb'
args: ['--fix', '--show-fixes']
- id: ruff-format
types_or: [ python, jupyter ]
exclude: '^docs/source/examples/Notebook/Importing Notebooks.ipynb'
- repo: https://github.com/scientific-python/cookie
rev: '2023.09.21'
rev: '2024.08.19'
hooks:
- id: sp-repo-review
additional_dependencies: ['repo-review[cli]']
@ -79,4 +83,4 @@ repos:
name: integrity
entry: 'npm run integrity --force'
language: node
stages: [push]
stages: [pre-push]

@ -9,3 +9,4 @@ node_modules
build
CHANGELOG.md
app/index.template.js
.pixi

File diff suppressed because it is too large Load Diff

@ -2,7 +2,7 @@
Thanks for contributing to Jupyter Notebook!
Make sure to follow [Project Jupyter's Code of Conduct](https://github.com/jupyter/governance/blob/master/conduct/code_of_conduct.md)
Make sure to follow [Project Jupyter's Code of Conduct](https://jupyter.org/governance/conduct/code-of-conduct)
for a friendly and welcoming collaborative environment.
## Setting up a development environment
@ -12,7 +12,7 @@ Note: You will need NodeJS to build the extension package.
The `jlpm` command is JupyterLab's pinned version of [yarn](https://yarnpkg.com/) that is installed with JupyterLab. You may use
`yarn` or `npm` in lieu of `jlpm` below.
**Note**: we recommend using `mamba` to speed the creating of the environment.
**Note**: we recommend using `mamba` to speed up the creation of the environment.
```bash
# create a new environment
@ -22,7 +22,11 @@ mamba create -n notebook -c conda-forge python nodejs -y
mamba activate notebook
# Install package in development mode
pip install -e ".[dev,test]"
pip install -e ".[dev,docs,test]"
# Install dependencies and build packages
jlpm
jlpm build
# Link the notebook extension and @jupyter-notebook schemas
jlpm develop
@ -66,6 +70,39 @@ Then start Jupyter Notebook with:
jupyter notebook
```
### Local changes in Notebook dependencies
The development installation described above fetches JavaScript dependencies from `npm`.
according to the versions in the _package.json_ file.
However, it is sometimes useful to be able to test changes in Notebook, with dependencies (e.g. `@jupyterlab` packages) that have not yet
been published.
[yalc](https://github.com/wclr/yalc) can help you use local JavaScript packages when building Notebook, acting as a local package repository.
- Install yalc globally in your environment:
`npm install -g yalc`
- Publish your dependency package:\
`yalc publish`, from the package root directory.\
For instance, if you are developing on _@jupyterlab/ui-components_, this command must be executed from
_path_to_jupyterlab/packages/ui-components_.
- Depend on this local repository in Notebook:
- from the Notebook root directory:\
`yalc add your_package` : this will create a _dependencies_ entry in the main _package.json_ file.\
With the previous example, it would be `yalc add @jupyterlab/ui-components`.
- Notebook is a monorepo, so we want this dependency to be 'linked' as a resolution (for all sub-packages) instead
of a dependency.\
The easiest way is to manually move the new entry in _package.json_ from _dependencies_ to _resolutions_.
- Build Notebook with the local dependency:\
`jlpm install && jlpm build`
Changes in the dependency must then be built and pushed using `jlpm build && yalc push` (from the package root directory),
and fetched from Notebook using `yarn install`.
**Warning**: you need to make sure that the dependencies of Notebook and the local package match correctly,
otherwise there will be errors with webpack during build.\
In the previous example, both _@jupyterlab/ui-components_ and Notebook depend on _@jupyterlab/coreutils_. We
strongly advise you to depend on the same version.
## Running Tests
To run the tests:
@ -94,11 +131,11 @@ jlpm test
The `test` script calls the Playwright test runner. You can pass additional arguments to `playwright` by appending parameters to the command. For example to run the test in headed mode, `jlpm test --headed`.
Checkout the [Playwright Command Line Reference](https://playwright.dev/docs/test-cli/) for more information about the available command line options.
Check out the [Playwright Command Line Reference](https://playwright.dev/docs/test-cli/) for more information about the available command line options.
Running the end to end tests in headful mode will trigger something like the following:
![playwight-headed-demo](https://user-images.githubusercontent.com/591645/141274633-ca9f9c2f-eef6-430e-9228-a35827f8133d.gif)
![playwright-headed-demo](https://user-images.githubusercontent.com/591645/141274633-ca9f9c2f-eef6-430e-9228-a35827f8133d.gif)
## Tasks caching
@ -119,7 +156,7 @@ Running the command will open a browser tab by default with a graph that looks l
To learn more about Lerna caching:
- https://lerna.js.org/docs/features/cache-tasks
- https://nx.dev/core-features/cache-task-results
- https://nx.dev/features/cache-task-results
### Updating reference snapshots
@ -135,11 +172,11 @@ This will trigger a GitHub Action that will run the UI tests automatically and p
## Code Styling
All non-python source code is formatted using [prettier](https://prettier.io) and python source code is formatted using [black](https://github.com/psf/black)s
All non-python source code is formatted using [prettier](https://prettier.io) and python source code is formatted using [black](https://github.com/psf/black).
When code is modified and committed, all staged files will be
automatically formatted using pre-commit git hooks (with help from
[pre-commit](https://github.com/pre-commit/pre-commit). The benefit of
using a code formatters like `prettier` and `black` is that it removes the topic of
using code formatters like `prettier` and `black` is that it removes the topic of
code style from the conversation when reviewing pull requests, thereby
speeding up the review process.
@ -174,7 +211,7 @@ yourself after that.
You may also use the prettier npm script (e.g. `npm run prettier` or
`yarn prettier` or `jlpm prettier`) to format the entire code base.
We recommend installing a prettier extension for your code editor and
configuring it to format your code with a keyboard shortcut or
configuring it to format your code with a keyboard shortcut, or
automatically on save.
Some of the hooks only run on CI by default, but you can invoke them by
@ -202,6 +239,9 @@ Now open a web browser and navigate to `http://localhost:8000` to access the doc
Alternatively you can also contribute to Jupyter Notebook without setting up a local environment, directly from a web browser:
- [Gitpod](https://gitpod.io/#https://github.com/jupyter/notebook) integration is enabled. The Gitpod config automatically builds the Jupyter Notebook application and the documentation.
- GitHubs [built-in editor](https://docs.github.com/en/repositories/working-with-files/managing-files/editing-files) is suitable for contributing small fixes
- A more advanced [github.dev](https://docs.github.com/en/codespaces/the-githubdev-web-based-editor) editor can be accessed by pressing the dot (.) key while in the Jupyter Notebook GitHub repository,
- [GitHub CodeSpaces](https://github.com/codespaces) is directly integrated into GitHub. This repository uses the [pixi](https://pixi.sh/) package manager to set up the development environment. To contribute after the Codespace is started:
- Run `pixi shell` in a terminal to activate the development environment
- Use the commands above for building the extension and running the tests, for example: `jlpm build`
- To start the application: `pixi run start`. A popup should appear with a button to open the Jupyter Notebook in a new browser tab. If the popup does not appear, you can navigate to the "Forwarded ports" panel to find the URL to the application.
- GitHub's [built-in editor](https://docs.github.com/en/repositories/working-with-files/managing-files/editing-files) is suitable for contributing small fixes.
- A more advanced [github.dev](https://docs.github.com/en/codespaces/the-githubdev-web-based-editor) editor can be accessed by pressing the dot (.) key while in the Jupyter Notebook GitHub repository

@ -3,7 +3,6 @@
![Github Actions Status](https://github.com/jupyter/notebook/workflows/Build/badge.svg)
[![Documentation Status](https://readthedocs.org/projects/jupyter-notebook/badge/?version=latest)](https://jupyter-notebook.readthedocs.io/en/latest/?badge=latest)
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/jupyter/notebook/main?urlpath=tree)
[![Gitpod](https://img.shields.io/badge/gitpod_editor-open-blue.svg)](https://gitpod.io/#https://github.com/jupyter/notebook)
The Jupyter notebook is a web-based notebook environment for interactive
computing.
@ -12,13 +11,12 @@ computing.
## Maintained versions
We maintain the **two most recently released major versions of Jupyter Notebook**, Notebook v5 and Classic Notebook v6. After Notebook v7.0 is released, we will no longer maintain Notebook v5. All Notebook v5 users are strongly advised to upgrade to Classic Notebook v6 as soon as possible.
We maintain the **two most recently released major versions of Jupyter Notebook**,
Classic Notebook v6 and Notebook v7. Notebook v5 is no longer maintained.
All Notebook v5 users are strongly advised to upgrade to Classic Notebook v6 as soon as possible.
The Jupyter Notebook project is currently undertaking a transition to a more modern code base built from the ground-up using JupyterLab components and extensions.
There is new stream of work which was submitted and then accepted as a Jupyter Enhancement Proposal (JEP) as part of the next version (v7): https://jupyter.org/enhancement-proposals/79-notebook-v7/notebook-v7.html
There is also a plan to continue maintaining Notebook v6 with bug and security fixes only, to ease the transition to Notebook v7: https://github.com/jupyter/notebook-team-compass/issues/5#issuecomment-1085254000
Upgrading to Notebook v7 may require more work, if you use custom extensions, as extensions written
for Notebook v5 or Classic Notebook v6 are not compatible with Notebook v7.
### Notebook v7
@ -33,9 +31,8 @@ To learn more about Notebook v7: https://jupyter.org/enhancement-proposals/79-no
### Classic Notebook v6
Maintenance and security-related issues are now being addressed in the [`6.4.x`](https://github.com/jupyter/notebook/tree/6.4.x) branch.
A `6.5.x` branch will be soon created and will depend on [`nbclassic`](https://github.com/jupyter/nbclassic) for the HTML/JavaScript/CSS assets.
Maintenance and security-related issues [only](https://github.com/jupyter/notebook-team-compass/issues/5#issuecomment-1085254000) are now being addressed in the [`6.5.x`](https://github.com/jupyter/notebook/tree/6.5.x) branch.
It depends on [`nbclassic`](https://github.com/jupyter/nbclassic) for the HTML/JavaScript/CSS assets.
New features and continuous improvement is now focused on Notebook v7 (see section above).

@ -5,6 +5,8 @@
import { PageConfig, URLExt } from '@jupyterlab/coreutils';
import { PluginRegistry } from '@lumino/coreutils';
require('./style.js');
require('./extraStyle.js');
@ -33,7 +35,9 @@ async function loadComponent(url, scope) {
async function createModule(scope, module) {
try {
const factory = await window._JUPYTERLAB[scope].get(module);
return factory();
const instance = factory();
instance.__scope__ = scope;
return instance;
} catch (e) {
console.warn(
`Failed to create module: package: ${scope}; module: ${module}`
@ -79,6 +83,7 @@ async function main() {
// populate the list of disabled extensions
const disabled = [];
const availablePlugins = [];
/**
* Iterate over active plugins in an extension.
@ -98,7 +103,18 @@ async function main() {
let plugins = Array.isArray(exports) ? exports : [exports];
for (let plugin of plugins) {
if (PageConfig.Extension.isDisabled(plugin.id)) {
const isDisabled = PageConfig.Extension.isDisabled(plugin.id);
availablePlugins.push({
id: plugin.id,
description: plugin.description,
requires: plugin.requires ?? [],
optional: plugin.optional ?? [],
provides: plugin.provides ?? null,
autoStart: plugin.autoStart,
enabled: !isDisabled,
extension: extension.__scope__
});
if (isDisabled) {
disabled.push(plugin.id);
continue;
}
@ -199,10 +215,20 @@ async function main() {
// plugin even if the debugger is only loaded on the notebook page.
PageConfig.setOption('allPlugins', '{{{ json notebook_plugins }}}');
const pluginRegistry = new PluginRegistry();
const NotebookApp = require('@jupyter-notebook/application').NotebookApp;
const app = new NotebookApp({ mimeExtensions });
app.registerPluginModules(mods);
pluginRegistry.registerPlugins(mods);
const IServiceManager = require('@jupyterlab/services').IServiceManager;
const serviceManager = await pluginRegistry.resolveRequiredService(IServiceManager);
const app = new NotebookApp({
pluginRegistry,
serviceManager,
mimeExtensions,
availablePlugins
});
// Expose global app instance when in dev mode or when toggled explicitly.
const exposeAppInBrowser =

@ -1,196 +1,210 @@
{
"name": "@jupyter-notebook/app",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"private": true,
"scripts": {
"build": "webpack",
"build:prod": "webpack --mode=production",
"build": "rspack",
"build:prod": "rspack --config ./rspack.prod.config.js",
"clean": "rimraf build && jlpm run clean:static",
"clean:static": "rimraf -g \"../notebook/static/!(favicons)\"",
"watch": "webpack --config ./webpack.config.watch.js"
"watch": "rspack --watch --config rspack.config.js"
},
"resolutions": {
"@codemirror/state": "~6.2.1",
"@codemirror/view": "~6.15.3",
"@jupyter-notebook/application": "~7.0.6",
"@jupyter-notebook/application-extension": "~7.0.6",
"@jupyter-notebook/console-extension": "~7.0.6",
"@jupyter-notebook/docmanager-extension": "~7.0.6",
"@jupyter-notebook/documentsearch-extension": "~7.0.6",
"@jupyter-notebook/help-extension": "~7.0.6",
"@jupyter-notebook/notebook-extension": "~7.0.6",
"@jupyter-notebook/terminal-extension": "~7.0.6",
"@jupyter-notebook/tree": "~7.0.6",
"@jupyter-notebook/tree-extension": "~7.0.6",
"@jupyter-notebook/ui-components": "~7.0.6",
"@jupyter/ydoc": "~1.0.2",
"@jupyterlab/application": "~4.0.7",
"@jupyterlab/application-extension": "~4.0.7",
"@jupyterlab/apputils": "~4.1.7",
"@jupyterlab/apputils-extension": "~4.0.7",
"@jupyterlab/attachments": "~4.0.7",
"@jupyterlab/cell-toolbar": "~4.0.7",
"@jupyterlab/cell-toolbar-extension": "~4.0.7",
"@jupyterlab/celltags-extension": "~4.0.7",
"@jupyterlab/codeeditor": "~4.0.7",
"@jupyterlab/codemirror": "~4.0.7",
"@jupyterlab/codemirror-extension": "~4.0.7",
"@jupyterlab/completer": "~4.0.7",
"@jupyterlab/completer-extension": "~4.0.7",
"@jupyterlab/console": "~4.0.7",
"@jupyterlab/console-extension": "~4.0.7",
"@jupyterlab/coreutils": "~6.0.7",
"@jupyterlab/csvviewer-extension": "~4.0.7",
"@jupyterlab/debugger": "~4.0.7",
"@jupyterlab/debugger-extension": "~4.0.7",
"@jupyterlab/docmanager": "~4.0.7",
"@jupyterlab/docmanager-extension": "~4.0.7",
"@jupyterlab/documentsearch": "~4.0.7",
"@jupyterlab/documentsearch-extension": "~4.0.7",
"@jupyterlab/extensionmanager": "~4.0.7",
"@jupyterlab/extensionmanager-extension": "~4.0.7",
"@jupyterlab/filebrowser": "~4.0.7",
"@jupyterlab/filebrowser-extension": "~4.0.7",
"@jupyterlab/fileeditor": "~4.0.7",
"@jupyterlab/fileeditor-extension": "~4.0.7",
"@jupyterlab/htmlviewer": "~4.0.7",
"@jupyterlab/htmlviewer-extension": "~4.0.7",
"@jupyterlab/hub-extension": "~4.0.7",
"@jupyterlab/imageviewer": "~4.0.7",
"@jupyterlab/imageviewer-extension": "~4.0.7",
"@jupyterlab/javascript-extension": "~4.0.7",
"@jupyterlab/json-extension": "~4.0.7",
"@jupyterlab/lsp": "~4.0.7",
"@jupyterlab/lsp-extension": "~4.0.7",
"@jupyterlab/mainmenu": "~4.0.7",
"@jupyterlab/mainmenu-extension": "~4.0.7",
"@jupyterlab/markdownviewer": "~4.0.7",
"@jupyterlab/markdownviewer-extension": "~4.0.7",
"@jupyterlab/markedparser-extension": "~4.0.7",
"@jupyterlab/mathjax-extension": "~4.0.7",
"@jupyterlab/metadataform": "~4.0.7",
"@jupyterlab/metadataform-extension": "~4.0.7",
"@jupyterlab/notebook": "~4.0.7",
"@jupyterlab/notebook-extension": "~4.0.7",
"@jupyterlab/observables": "~5.0.7",
"@jupyterlab/outputarea": "~4.0.7",
"@jupyterlab/pdf-extension": "~4.0.7",
"@jupyterlab/rendermime": "~4.0.7",
"@jupyterlab/rendermime-interfaces": "~3.8.7",
"@jupyterlab/running-extension": "~4.0.7",
"@jupyterlab/services": "~7.0.7",
"@jupyterlab/settingeditor": "~4.0.7",
"@jupyterlab/settingeditor-extension": "~4.0.7",
"@jupyterlab/settingregistry": "~4.0.7",
"@jupyterlab/shortcuts-extension": "~4.0.7",
"@jupyterlab/statedb": "~4.0.7",
"@jupyterlab/statusbar": "~4.0.7",
"@jupyterlab/terminal": "~4.0.7",
"@jupyterlab/terminal-extension": "~4.0.7",
"@jupyterlab/theme-dark-extension": "~4.0.7",
"@jupyterlab/theme-light-extension": "~4.0.7",
"@jupyterlab/toc-extension": "~6.0.7",
"@jupyterlab/tooltip": "~4.0.7",
"@jupyterlab/tooltip-extension": "~4.0.7",
"@jupyterlab/translation": "~4.0.7",
"@jupyterlab/translation-extension": "~4.0.7",
"@jupyterlab/ui-components": "~4.0.7",
"@jupyterlab/ui-components-extension": "~4.0.7",
"@jupyterlab/vega5-extension": "~4.0.7",
"@lezer/common": "~1.0.3",
"@lezer/highlight": "~1.1.6",
"@lumino/algorithm": "~2.0.1",
"@lumino/application": "~2.2.1",
"@lumino/commands": "~2.1.3",
"@lumino/coreutils": "~2.1.2",
"@lumino/disposable": "~2.1.2",
"@lumino/domutils": "~2.0.1",
"@lumino/dragdrop": "~2.1.3",
"@lumino/messaging": "~2.0.1",
"@lumino/properties": "~2.0.1",
"@lumino/signaling": "~2.1.2",
"@lumino/virtualdom": "~2.0.1",
"@lumino/widgets": "~2.3.0",
"@codemirror/state": "~6.5.2",
"@codemirror/view": "~6.38.1",
"@jupyter-notebook/application": "~7.6.0-alpha.0",
"@jupyter-notebook/application-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/console-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/docmanager-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/documentsearch-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/help-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/notebook-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/terminal-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/tree": "~7.6.0-alpha.0",
"@jupyter-notebook/tree-extension": "~7.6.0-alpha.0",
"@jupyter-notebook/ui-components": "~7.6.0-alpha.0",
"@jupyter/react-components": "~0.16.7",
"@jupyter/web-components": "~0.16.7",
"@jupyter/ydoc": "~3.1.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/application-extension": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/apputils-extension": "~4.6.0-alpha.0",
"@jupyterlab/attachments": "~4.6.0-alpha.0",
"@jupyterlab/audio-extension": "~4.6.0-alpha.0",
"@jupyterlab/cell-toolbar": "~4.6.0-alpha.0",
"@jupyterlab/cell-toolbar-extension": "~4.6.0-alpha.0",
"@jupyterlab/celltags-extension": "~4.6.0-alpha.0",
"@jupyterlab/codeeditor": "~4.6.0-alpha.0",
"@jupyterlab/codemirror": "~4.6.0-alpha.0",
"@jupyterlab/codemirror-extension": "~4.6.0-alpha.0",
"@jupyterlab/completer": "~4.6.0-alpha.0",
"@jupyterlab/completer-extension": "~4.6.0-alpha.0",
"@jupyterlab/console": "~4.6.0-alpha.0",
"@jupyterlab/console-extension": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/csvviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/debugger": "~4.6.0-alpha.0",
"@jupyterlab/debugger-extension": "~4.6.0-alpha.0",
"@jupyterlab/docmanager": "~4.6.0-alpha.0",
"@jupyterlab/docmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/documentsearch": "~4.6.0-alpha.0",
"@jupyterlab/documentsearch-extension": "~4.6.0-alpha.0",
"@jupyterlab/extensionmanager": "~4.6.0-alpha.0",
"@jupyterlab/extensionmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/filebrowser": "~4.6.0-alpha.0",
"@jupyterlab/filebrowser-extension": "~4.6.0-alpha.0",
"@jupyterlab/fileeditor": "~4.6.0-alpha.0",
"@jupyterlab/fileeditor-extension": "~4.6.0-alpha.0",
"@jupyterlab/help-extension": "~4.6.0-alpha.0",
"@jupyterlab/htmlviewer": "~4.6.0-alpha.0",
"@jupyterlab/htmlviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/hub-extension": "~4.6.0-alpha.0",
"@jupyterlab/imageviewer": "~4.6.0-alpha.0",
"@jupyterlab/imageviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/javascript-extension": "~4.6.0-alpha.0",
"@jupyterlab/json-extension": "~4.6.0-alpha.0",
"@jupyterlab/logconsole-extension": "~4.6.0-alpha.0",
"@jupyterlab/lsp": "~4.6.0-alpha.0",
"@jupyterlab/lsp-extension": "~4.6.0-alpha.0",
"@jupyterlab/mainmenu": "~4.6.0-alpha.0",
"@jupyterlab/mainmenu-extension": "~4.6.0-alpha.0",
"@jupyterlab/markdownviewer": "~4.6.0-alpha.0",
"@jupyterlab/markdownviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/markedparser-extension": "~4.6.0-alpha.0",
"@jupyterlab/mathjax-extension": "~4.6.0-alpha.0",
"@jupyterlab/mermaid": "~4.6.0-alpha.0",
"@jupyterlab/mermaid-extension": "~4.6.0-alpha.0",
"@jupyterlab/metadataform": "~4.6.0-alpha.0",
"@jupyterlab/metadataform-extension": "~4.6.0-alpha.0",
"@jupyterlab/notebook": "~4.6.0-alpha.0",
"@jupyterlab/notebook-extension": "~4.6.0-alpha.0",
"@jupyterlab/observables": "~5.6.0-alpha.0",
"@jupyterlab/outputarea": "~4.6.0-alpha.0",
"@jupyterlab/pdf-extension": "~4.6.0-alpha.0",
"@jupyterlab/pluginmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/rendermime": "~4.6.0-alpha.0",
"@jupyterlab/rendermime-interfaces": "~3.14.0-alpha.0",
"@jupyterlab/running-extension": "~4.6.0-alpha.0",
"@jupyterlab/services": "~7.6.0-alpha.0",
"@jupyterlab/services-extension": "~4.6.0-alpha.0",
"@jupyterlab/settingeditor": "~4.6.0-alpha.0",
"@jupyterlab/settingeditor-extension": "~4.6.0-alpha.0",
"@jupyterlab/settingregistry": "~4.6.0-alpha.0",
"@jupyterlab/shortcuts-extension": "~5.4.0-alpha.0",
"@jupyterlab/statedb": "~4.6.0-alpha.0",
"@jupyterlab/statusbar": "~4.6.0-alpha.0",
"@jupyterlab/terminal": "~4.6.0-alpha.0",
"@jupyterlab/terminal-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-dark-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-dark-high-contrast-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-light-extension": "~4.6.0-alpha.0",
"@jupyterlab/toc-extension": "~6.6.0-alpha.0",
"@jupyterlab/tooltip": "~4.6.0-alpha.0",
"@jupyterlab/tooltip-extension": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"@jupyterlab/translation-extension": "~4.6.0-alpha.0",
"@jupyterlab/ui-components": "~4.6.0-alpha.0",
"@jupyterlab/ui-components-extension": "~4.6.0-alpha.0",
"@jupyterlab/vega5-extension": "~4.6.0-alpha.0",
"@jupyterlab/video-extension": "~4.6.0-alpha.0",
"@lezer/common": "~1.2.1",
"@lezer/highlight": "~1.2.0",
"@lumino/algorithm": "~2.0.4",
"@lumino/application": "~2.4.5",
"@lumino/commands": "~2.3.3",
"@lumino/coreutils": "~2.2.2",
"@lumino/disposable": "~2.1.5",
"@lumino/domutils": "~2.0.4",
"@lumino/dragdrop": "~2.1.7",
"@lumino/messaging": "~2.0.4",
"@lumino/properties": "~2.0.4",
"@lumino/signaling": "~2.1.5",
"@lumino/virtualdom": "~2.0.4",
"@lumino/widgets": "~2.7.2",
"react": "~18.2.0",
"react-dom": "~18.2.0",
"yjs": "~13.6.7"
"yjs": "~13.6.8"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyter-notebook/application-extension": "^7.0.6",
"@jupyter-notebook/console-extension": "^7.0.6",
"@jupyter-notebook/docmanager-extension": "^7.0.6",
"@jupyter-notebook/documentsearch-extension": "^7.0.6",
"@jupyter-notebook/help-extension": "^7.0.6",
"@jupyter-notebook/notebook-extension": "^7.0.6",
"@jupyter-notebook/terminal-extension": "^7.0.6",
"@jupyter-notebook/tree": "^7.0.6",
"@jupyter-notebook/tree-extension": "^7.0.6",
"@jupyter-notebook/ui-components": "^7.0.6",
"@jupyterlab/application-extension": "^4.0.7",
"@jupyterlab/apputils-extension": "^4.0.7",
"@jupyterlab/attachments": "^4.0.7",
"@jupyterlab/cell-toolbar-extension": "^4.0.7",
"@jupyterlab/celltags-extension": "^4.0.7",
"@jupyterlab/codemirror": "^4.0.7",
"@jupyterlab/codemirror-extension": "^4.0.7",
"@jupyterlab/completer-extension": "^4.0.7",
"@jupyterlab/console-extension": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/csvviewer-extension": "^4.0.7",
"@jupyterlab/debugger-extension": "^4.0.7",
"@jupyterlab/docmanager-extension": "^4.0.7",
"@jupyterlab/documentsearch-extension": "^4.0.7",
"@jupyterlab/extensionmanager-extension": "^4.0.7",
"@jupyterlab/filebrowser-extension": "^4.0.7",
"@jupyterlab/fileeditor-extension": "^4.0.7",
"@jupyterlab/htmlviewer-extension": "^4.0.7",
"@jupyterlab/hub-extension": "^4.0.7",
"@jupyterlab/imageviewer-extension": "^4.0.7",
"@jupyterlab/javascript-extension": "^4.0.7",
"@jupyterlab/json-extension": "^4.0.7",
"@jupyterlab/lsp": "^4.0.7",
"@jupyterlab/lsp-extension": "^4.0.7",
"@jupyterlab/mainmenu-extension": "^4.0.7",
"@jupyterlab/markdownviewer-extension": "^4.0.7",
"@jupyterlab/markedparser-extension": "^4.0.7",
"@jupyterlab/mathjax-extension": "^4.0.7",
"@jupyterlab/metadataform-extension": "^4.0.7",
"@jupyterlab/notebook-extension": "^4.0.7",
"@jupyterlab/pdf-extension": "^4.0.7",
"@jupyterlab/running-extension": "^4.0.7",
"@jupyterlab/settingeditor": "^4.0.7",
"@jupyterlab/settingeditor-extension": "^4.0.7",
"@jupyterlab/shortcuts-extension": "^4.0.7",
"@jupyterlab/terminal-extension": "^4.0.7",
"@jupyterlab/theme-dark-extension": "^4.0.7",
"@jupyterlab/theme-light-extension": "^4.0.7",
"@jupyterlab/toc-extension": "^6.0.7",
"@jupyterlab/tooltip-extension": "^4.0.7",
"@jupyterlab/translation-extension": "^4.0.7",
"@jupyterlab/ui-components-extension": "^4.0.7",
"@jupyterlab/vega5-extension": "^4.0.7",
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyter-notebook/application-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/console-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/docmanager-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/documentsearch-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/help-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/notebook-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/terminal-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/tree": "^7.6.0-alpha.0",
"@jupyter-notebook/tree-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/ui-components": "^7.6.0-alpha.0",
"@jupyterlab/application-extension": "~4.6.0-alpha.0",
"@jupyterlab/apputils-extension": "~4.6.0-alpha.0",
"@jupyterlab/attachments": "~4.6.0-alpha.0",
"@jupyterlab/audio-extension": "~4.6.0-alpha.0",
"@jupyterlab/cell-toolbar-extension": "~4.6.0-alpha.0",
"@jupyterlab/celltags-extension": "~4.6.0-alpha.0",
"@jupyterlab/codemirror": "~4.6.0-alpha.0",
"@jupyterlab/codemirror-extension": "~4.6.0-alpha.0",
"@jupyterlab/completer-extension": "~4.6.0-alpha.0",
"@jupyterlab/console-extension": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/csvviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/debugger-extension": "~4.6.0-alpha.0",
"@jupyterlab/docmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/documentsearch-extension": "~4.6.0-alpha.0",
"@jupyterlab/extensionmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/filebrowser-extension": "~4.6.0-alpha.0",
"@jupyterlab/fileeditor-extension": "~4.6.0-alpha.0",
"@jupyterlab/help-extension": "~4.6.0-alpha.0",
"@jupyterlab/htmlviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/hub-extension": "~4.6.0-alpha.0",
"@jupyterlab/imageviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/javascript-extension": "~4.6.0-alpha.0",
"@jupyterlab/json-extension": "~4.6.0-alpha.0",
"@jupyterlab/logconsole-extension": "~4.6.0-alpha.0",
"@jupyterlab/lsp": "~4.6.0-alpha.0",
"@jupyterlab/lsp-extension": "~4.6.0-alpha.0",
"@jupyterlab/mainmenu-extension": "~4.6.0-alpha.0",
"@jupyterlab/markdownviewer-extension": "~4.6.0-alpha.0",
"@jupyterlab/markedparser-extension": "~4.6.0-alpha.0",
"@jupyterlab/mathjax-extension": "~4.6.0-alpha.0",
"@jupyterlab/mermaid-extension": "~4.6.0-alpha.0",
"@jupyterlab/metadataform-extension": "~4.6.0-alpha.0",
"@jupyterlab/notebook-extension": "~4.6.0-alpha.0",
"@jupyterlab/pdf-extension": "~4.6.0-alpha.0",
"@jupyterlab/pluginmanager-extension": "~4.6.0-alpha.0",
"@jupyterlab/running-extension": "~4.6.0-alpha.0",
"@jupyterlab/services-extension": "~4.6.0-alpha.0",
"@jupyterlab/settingeditor": "~4.6.0-alpha.0",
"@jupyterlab/settingeditor-extension": "~4.6.0-alpha.0",
"@jupyterlab/shortcuts-extension": "~5.4.0-alpha.0",
"@jupyterlab/terminal-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-dark-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-dark-high-contrast-extension": "~4.6.0-alpha.0",
"@jupyterlab/theme-light-extension": "~4.6.0-alpha.0",
"@jupyterlab/toc-extension": "~6.6.0-alpha.0",
"@jupyterlab/tooltip-extension": "~4.6.0-alpha.0",
"@jupyterlab/translation-extension": "~4.6.0-alpha.0",
"@jupyterlab/ui-components-extension": "~4.6.0-alpha.0",
"@jupyterlab/vega5-extension": "~4.6.0-alpha.0",
"@jupyterlab/video-extension": "~4.6.0-alpha.0",
"@lumino/coreutils": "~2.2.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"yjs": "^13.5.40"
},
"devDependencies": {
"@jupyterlab/builder": "^4.0.7",
"@jupyterlab/buildutils": "^4.0.7",
"@jupyterlab/builder": "~4.6.0-alpha.0",
"@jupyterlab/buildutils": "~4.6.0-alpha.0",
"@rspack/cli": "^1.1.8",
"@rspack/core": "^1.1.8",
"@types/rimraf": "^3.0.2",
"css-loader": "~5.0.1",
"extra-watch-webpack-plugin": "^1.0.3",
"fs-extra": "^8.1.0",
"glob": "~7.1.6",
"handlebars": "^4.7.7",
"mini-css-extract-plugin": "~0.9.0",
"rimraf": "^3.0.2",
"style-loader": "~1.0.1",
"svg-url-loader": "~6.0.0",
"watch": "~1.0.2",
"webpack": "^5.76.1",
"webpack-bundle-analyzer": "^4.8.0",
"webpack-cli": "^5.0.1",
"webpack-merge": "^5.8.0",
"whatwg-fetch": "^3.0.0"
},
@ -220,6 +234,7 @@
"@jupyterlab/application-extension:top-spacer"
],
"@jupyterlab/apputils-extension": [
"@jupyterlab/apputils-extension:kernels-settings",
"@jupyterlab/apputils-extension:palette",
"@jupyterlab/apputils-extension:notification",
"@jupyterlab/apputils-extension:sanitizer",
@ -231,12 +246,17 @@
"@jupyterlab/apputils-extension:toolbar-registry",
"@jupyterlab/apputils-extension:utilityCommands"
],
"@jupyterlab/audio-extension": true,
"@jupyterlab/codemirror-extension": true,
"@jupyterlab/completer-extension": [
"@jupyterlab/completer-extension:base-service",
"@jupyterlab/completer-extension:inline-completer",
"@jupyterlab/completer-extension:inline-completer-factory",
"@jupyterlab/completer-extension:inline-history",
"@jupyterlab/completer-extension:manager"
],
"@jupyterlab/console-extension": [
"@jupyterlab/console-extension:cell-executor",
"@jupyterlab/console-extension:completer",
"@jupyterlab/console-extension:factory",
"@jupyterlab/console-extension:foreign",
@ -257,33 +277,47 @@
"@jupyterlab/filebrowser-extension:default-file-browser"
],
"@jupyterlab/fileeditor-extension": [
"@jupyterlab/fileeditor-extension:plugin"
"@jupyterlab/fileeditor-extension:plugin",
"@jupyterlab/fileeditor-extension:widget-factory"
],
"@jupyterlab/help-extension": [
"@jupyterlab/help-extension:resources"
],
"@jupyterlab/htmlviewer-extension": true,
"@jupyterlab/hub-extension": true,
"@jupyterlab/imageviewer-extension": true,
"@jupyterlab/lsp-extension": true,
"@jupyterlab/mainmenu-extension": true,
"@jupyterlab/mainmenu-extension": [
"@jupyterlab/mainmenu-extension:plugin"
],
"@jupyterlab/markedparser-extension": true,
"@jupyterlab/mathjax-extension": true,
"@jupyterlab/mermaid-extension": true,
"@jupyterlab/notebook-extension": [
"@jupyterlab/notebook-extension:cell-executor",
"@jupyterlab/notebook-extension:code-console",
"@jupyterlab/notebook-extension:export",
"@jupyterlab/notebook-extension:factory",
"@jupyterlab/notebook-extension:tracker",
"@jupyterlab/notebook-extension:widget-factory"
],
"@jupyterlab/pluginmanager-extension": true,
"@jupyterlab/services-extension": true,
"@jupyterlab/shortcuts-extension": true,
"@jupyterlab/terminal-extension": true,
"@jupyterlab/theme-light-extension": true,
"@jupyterlab/theme-dark-extension": true,
"@jupyterlab/theme-dark-high-contrast-extension": true,
"@jupyterlab/translation-extension": true,
"@jupyterlab/ui-components-extension": true,
"@jupyterlab/hub-extension": true
"@jupyterlab/video-extension": true
},
"/tree": {
"@jupyterlab/cell-toolbar-extension": true,
"@jupyterlab/extensionmanager-extension": true,
"@jupyterlab/filebrowser-extension": [
"@jupyterlab/filebrowser-extension:browser",
"@jupyterlab/filebrowser-extension:create-new-language-file",
"@jupyterlab/filebrowser-extension:download",
"@jupyterlab/filebrowser-extension:file-upload-status",
"@jupyterlab/filebrowser-extension:open-with",
@ -291,24 +325,31 @@
"@jupyterlab/filebrowser-extension:share-file"
],
"@jupyter-notebook/tree-extension": true,
"@jupyterlab/running-extension": true,
"@jupyterlab/running-extension": [
"@jupyterlab/running-extension:plugin"
],
"@jupyterlab/settingeditor-extension": true
},
"/notebooks": {
"@jupyterlab/celltags-extension": true,
"@jupyterlab/cell-toolbar-extension": true,
"@jupyterlab/debugger-extension": [
"@jupyterlab/debugger-extension:completions",
"@jupyterlab/debugger-extension:config",
"@jupyterlab/debugger-extension:debug-console",
"@jupyterlab/debugger-extension:main",
"@jupyterlab/debugger-extension:notebooks",
"@jupyterlab/debugger-extension:service",
"@jupyterlab/debugger-extension:sidebar",
"@jupyterlab/debugger-extension:sources"
"@jupyterlab/debugger-extension:sources",
"@jupyterlab/debugger-extension:display-registry"
],
"@jupyterlab/logconsole-extension": true,
"@jupyterlab/metadataform-extension": true,
"@jupyterlab/notebook-extension": [
"@jupyterlab/notebook-extension:active-cell-tool",
"@jupyterlab/notebook-extension:completer",
"@jupyterlab/notebook-extension:copy-output",
"@jupyterlab/notebook-extension:metadata-editor",
"@jupyterlab/notebook-extension:search",
"@jupyterlab/notebook-extension:toc",
@ -342,6 +383,8 @@
"@codemirror/state",
"@codemirror/view",
"@jupyter-notebook/tree",
"@jupyter/react-components",
"@jupyter/web-components",
"@jupyter/ydoc",
"@jupyterlab/application",
"@jupyterlab/apputils",
@ -362,6 +405,7 @@
"@jupyterlab/lsp",
"@jupyterlab/mainmenu",
"@jupyterlab/markdownviewer",
"@jupyterlab/mermaid",
"@jupyterlab/metadataform",
"@jupyterlab/notebook",
"@jupyterlab/observables",

@ -2,19 +2,20 @@
// Distributed under the terms of the Modified BSD License.
// Heavily inspired (and slightly tweaked) from:
// https://github.com/jupyterlab/jupyterlab/blob/master/examples/federated/core_package/webpack.config.js
// https://github.com/jupyterlab/jupyterlab/blob/master/examples/federated/core_package/rspack.config.js
const fs = require('fs-extra');
const path = require('path');
const webpack = require('webpack');
const rspack = require('@rspack/core');
const merge = require('webpack-merge').default;
const Handlebars = require('handlebars');
const { ModuleFederationPlugin } = webpack.container;
const { ModuleFederationPlugin } = rspack.container;
const BundleAnalyzerPlugin =
require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
const Build = require('@jupyterlab/builder').Build;
const WPPlugin = require('@jupyterlab/builder').WPPlugin;
const HtmlWebpackPlugin = require('html-webpack-plugin');
const baseConfig = require('@jupyterlab/builder/lib/webpack.config.base');
const data = require('./package.json');
@ -93,7 +94,7 @@ const extras = Build.ensureAssets({
});
/**
* Create the webpack ``shared`` configuration
* Create the rspack ``shared`` configuration
*/
function createShared(packageData) {
// Set up module federation sharing config
@ -204,22 +205,55 @@ if (process.argv.includes('--analyze')) {
extras.push(new BundleAnalyzerPlugin());
}
const htmlPlugins = [];
['consoles', 'edit', 'error', 'notebooks', 'terminals', 'tree'].forEach(
(name) => {
htmlPlugins.push(
new HtmlWebpackPlugin({
chunksSortMode: 'none',
template: path.join(
path.resolve('./templates'),
`${name}_template.html`
),
title: name,
filename: path.join(
path.resolve(__dirname, '..', 'notebook/templates'),
`${name}.html`
),
})
);
}
);
module.exports = [
merge(baseConfig, {
mode: 'development',
entry: ['./publicpath.js', './' + path.relative(__dirname, entryPoint)],
output: {
path: path.resolve(__dirname, '..', 'notebook/static/'),
publicPath: '{{page_config.fullStaticUrl}}/',
library: {
type: 'var',
name: ['_JUPYTERLAB', 'CORE_OUTPUT'],
},
filename: 'bundle.js',
filename: '[name].[contenthash].js',
},
optimization: {
splitChunks: {
chunks: 'all',
cacheGroups: {
jlab_core: {
test: /[\\/]node_modules[\\/]@(jupyterlab|jupyter-notebook|lumino(?!\/datagrid))[\\/]/,
name: 'notebook_core',
},
},
},
},
resolve: {
fallback: { util: false },
},
plugins: [
...htmlPlugins,
new WPPlugin.JSONLicenseWebpackPlugin({
excludedPackageTest: (packageName) =>
packageName === '@jupyter-notebook/app',
@ -235,3 +269,6 @@ module.exports = [
],
}),
].concat(extras);
const logPath = path.join(buildDir, 'build_log.json');
fs.writeFileSync(logPath, JSON.stringify(module.exports, null, ' '));

@ -0,0 +1,15 @@
/*
* Copyright (c) Jupyter Development Team.
* Distributed under the terms of the Modified BSD License.
*/
const base = require('./rspack.config');
module.exports = [
{
...base[0],
bail: false,
watch: true,
},
...base.slice(1),
];

@ -0,0 +1,29 @@
/*
* Copyright (c) Jupyter Development Team.
* Distributed under the terms of the Modified BSD License.
*/
const merge = require('webpack-merge').default;
const config = require('./rspack.config');
const WPPlugin = require('@jupyterlab/builder').WPPlugin;
config[0] = merge(config[0], {
mode: 'production',
devtool: 'source-map',
output: {
// Add version argument when in production so the Jupyter server
// allows caching of files (i.e., does not set the CacheControl header to no-cache to prevent caching static files)
filename: '[name].[contenthash].js?v=[contenthash]',
},
optimization: {
minimize: false,
},
plugins: [
new WPPlugin.JSONLicenseWebpackPlugin({
excludedPackageTest: (packageName) =>
packageName === '@jupyter-notebook/app',
}),
],
});
module.exports = config;

@ -0,0 +1,45 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>{{page_config['appName'] | e}} - Console</title>
{% block favicon %}
<link
rel="icon"
type="image/x-icon"
href="{{ page_config['fullStaticUrl'] | e }}/favicons/favicon-console.ico"
class="favicon"
/>
{% endblock %} {% if custom_css %}
<link
rel="stylesheet"
type="text/css"
href="{{ base_url | escape }}custom/custom.css"
/>
{% endif %}
</head>
<body class="jp-ThemedContainer">
{# Copy so we do not modify the page_config with updates. #} {% set
page_config_full = page_config.copy() %} {# Set a dummy variable - we just
want the side effect of the update. #} {% set _ =
page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %} {# Sentinel value
to say that we are on the tree page #} {% set _ =
page_config_full.update(notebookPage='consoles') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({}, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -0,0 +1,39 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>{{page_config['appName'] | e}} - Edit</title>
{% block favicon %}
<link
rel="icon"
type="image/x-icon"
href="{{ base_url | escape }}static/favicons/favicon-file.ico"
class="favicon"
/>
{% endblock %}
</head>
<body class="jp-ThemedContainer" data-notebook="edit">
{# Copy so we do not modify the page_config with updates. #} {% set
page_config_full = page_config.copy() %} {# Set a dummy variable - we just
want the side effect of the update. #} {% set _ =
page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %} {# Sentinel value
to say that we are on the tree page #} {% set _ =
page_config_full.update(notebookPage='edit') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({}, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -14,7 +14,7 @@ Distributed under the terms of the Modified BSD License.
</head>
<body>
<body class="jp-ThemedContainer">
{% block stylesheet %}
<style type="text/css">

@ -0,0 +1,45 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>{{page_config['appName'] | e}} - Notebook</title>
{% block favicon %}
<link
rel="icon"
type="image/x-icon"
href="{{ base_url | escape }}static/favicons/favicon-notebook.ico"
class="favicon"
/>
{% endblock %} {% if custom_css %}
<link
rel="stylesheet"
type="text/css"
href="{{ base_url | escape }}custom/custom.css"
/>
{% endif %}
</head>
<body class="jp-ThemedContainer" data-notebook="notebooks">
{# Copy so we do not modify the page_config with updates. #} {% set
page_config_full = page_config.copy() %} {# Set a dummy variable - we just
want the side effect of the update. #} {% set _ =
page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %} {# Sentinel value
to say that we are on the tree page #} {% set _ =
page_config_full.update(notebookPage='notebooks') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({}, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -0,0 +1,45 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>{{page_config['appName'] | e}} - Terminal</title>
{% block favicon %}
<link
rel="icon"
type="image/x-icon"
href="{{ base_url | escape }}static/favicons/favicon-terminal.ico"
class="favicon"
/>
{% endblock %} {% if custom_css %}
<link
rel="stylesheet"
type="text/css"
href="{{ base_url | escape }}custom/custom.css"
/>
{% endif %}
</head>
<body class="jp-ThemedContainer">
{# Copy so we do not modify the page_config with updates. #} {% set
page_config_full = page_config.copy() %} {# Set a dummy variable - we just
want the side effect of the update. #} {% set _ =
page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %} {# Sentinel value
to say that we are on the tree page #} {% set _ =
page_config_full.update(notebookPage='terminals') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({}, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -0,0 +1,45 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Home</title>
{% block favicon %}
<link
rel="icon"
type="image/x-icon"
href="{{ base_url | escape }}static/favicons/favicon.ico"
class="favicon"
/>
{% endblock %} {% if custom_css %}
<link
rel="stylesheet"
type="text/css"
href="{{ base_url | escape }}custom/custom.css"
/>
{% endif %}
</head>
<body class="jp-ThemedContainer">
{# Copy so we do not modify the page_config with updates. #} {% set
page_config_full = page_config.copy() %} {# Set a dummy variable - we just
want the side effect of the update. #} {% set _ =
page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %} {# Sentinel value
to say that we are on the tree page #} {% set _ =
page_config_full.update(notebookPage='tree') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({}, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -1,17 +0,0 @@
const base = require('./webpack.config');
const ExtraWatchWebpackPlugin = require('extra-watch-webpack-plugin');
module.exports = [
{
...base[0],
bail: false,
watch: true,
plugins: [
...base[0].plugins,
new ExtraWatchWebpackPlugin({
files: ['../packages/_metapackage/tsconfig.tsbuildinfo'],
}),
],
},
...base.slice(1),
];

@ -235,7 +235,7 @@
"\\nabla \\times \\vec{\\mathbf{B}} -\\, \\frac1c\\, \\frac{\\partial\\vec{\\mathbf{E}}}{\\partial t} & = \\frac{4\\pi}{c}\\vec{\\mathbf{j}} \\\\\n",
"\\nabla \\cdot \\vec{\\mathbf{E}} & = 4 \\pi \\rho \\\\\n",
"\\nabla \\times \\vec{\\mathbf{E}}\\, +\\, \\frac1c\\, \\frac{\\partial\\vec{\\mathbf{B}}}{\\partial t} & = \\vec{\\mathbf{0}} \\\\\n",
"\\nabla \\cdot \\vec{\\mathbf{B}} & = 0 \n",
"\\nabla \\cdot \\vec{\\mathbf{B}} & = 0\n",
"\\end{eqnarray}\"\"\"\n",
")"
]
@ -277,8 +277,7 @@
"metadata": {},
"outputs": [],
"source": [
"from IPython.display import HTML\n",
"from IPython.display import display\n",
"from IPython.display import HTML, display\n",
"\n",
"s = \"\"\"<table>\n",
"<tr>\n",

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/buildutils",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"private": true,
"description": "Jupyter Notebook - Build Utilities",
"homepage": "https://github.com/jupyter/notebook",
@ -29,14 +29,16 @@
"watch": "tsc -w --listEmittedFiles"
},
"dependencies": {
"@jupyterlab/buildutils": "^4.0.7",
"@jupyterlab/buildutils": "~4.6.0-alpha.0",
"commander": "^6.2.0",
"fs-extra": "^9.1.0",
"typescript": "~5.0.2"
"semver": "^7.6.3",
"typescript": "~5.5.4"
},
"devDependencies": {
"@types/fs-extra": "^9.0.10",
"@types/node": "^14.6.1",
"@types/node": "^22.13.4",
"@types/semver": "^7.5.8",
"rimraf": "^3.0.2"
}
}

@ -0,0 +1,86 @@
import * as fs from 'fs-extra';
import * as semver from 'semver';
function convertPythonVersion(version: string): string {
return version
.replace('a', '-alpha')
.replace('b', '-beta')
.replace('rc', '-rc');
}
function extractVersionFromReleases(
releases: any,
versionTag: string,
currentVersion: string
): string | null {
const npmCurrentVersion = convertPythonVersion(currentVersion);
const isCurrentPreRelease = semver.prerelease(npmCurrentVersion) !== null;
if (versionTag === 'latest') {
// Find first version that is newer than current and matches pre-release criteria
const release = releases.find((r: any) => {
const version = r['tag_name'].substring(1); // Remove 'v' prefix for semver
const npmVersion = convertPythonVersion(version);
return (
(isCurrentPreRelease || !r['prerelease']) &&
semver.gte(npmVersion, npmCurrentVersion)
);
});
return release ? release['tag_name'] : null;
} else {
// Find exact version match
const release = releases.find((r: any) => r['tag_name'] === versionTag);
return release ? release['tag_name'] : null;
}
}
function extractCurrentJupyterLabVersion(): string {
const toml = fs.readFileSync('pyproject.toml', 'utf8');
const match = toml.match(/jupyterlab>=([^,]+)/);
if (!match) {
throw new Error('Could not find JupyterLab version in pyproject.toml');
}
return match[1];
}
async function findVersion(versionTag: string): Promise<string> {
const url = 'https://api.github.com/repos/jupyterlab/jupyterlab/releases';
const response = await fetch(url);
if (!response.ok) {
const error_message = `Failed to fetch package.json from ${url}. HTTP status code: ${response.status}`;
throw new Error(error_message);
}
const currentVersion = extractCurrentJupyterLabVersion();
const releases: any = await response.json();
const version: string | null = extractVersionFromReleases(
releases,
versionTag,
currentVersion
);
if (version === null) {
const error_message = 'Invalid release tag';
throw new Error(error_message);
}
return version.substring(1);
}
async function getLatestLabVersion(): Promise<void> {
const args: string[] = process.argv.slice(2);
if (args.length !== 2 || args[0] !== '--set-version') {
console.error('Usage: node script.js --set-version <version>');
process.exit(1);
}
const version_tag: string = args[1];
try {
const result: string = await findVersion(version_tag);
console.log(result);
} catch (error: any) {
console.error('Error:', error.message);
process.exit(1);
}
}
getLatestLabVersion();

@ -128,6 +128,16 @@ commander
} else if (prev.indexOf('rc') !== -1) {
pySpec = 'rc';
}
} else if (spec === 'major' || spec === 'minor') {
if (prev.indexOf('a') !== -1) {
pySpec = `${spec},beta`;
} else if (prev.indexOf('b') !== -1) {
pySpec = `${spec},rc`;
} else if (prev.indexOf('rc') !== -1) {
pySpec = `${spec},release`;
} else {
pySpec = `${spec},alpha`;
}
}
utils.run(`hatch version ${pySpec}`);

@ -0,0 +1,170 @@
import fs from 'fs';
import path from 'path';
const PACKAGE_JSON_PATHS: string[] = [
'app/package.json',
'buildutils/package.json',
'package.json',
'packages/application-extension/package.json',
'packages/application/package.json',
'packages/console-extension/package.json',
'packages/docmanager-extension/package.json',
'packages/documentsearch-extension/package.json',
'packages/help-extension/package.json',
'packages/lab-extension/package.json',
'packages/notebook-extension/package.json',
'packages/terminal-extension/package.json',
'packages/tree-extension/package.json',
'packages/tree/package.json',
'packages/ui-components/package.json',
'ui-tests/package.json',
];
const DEPENDENCY_GROUP = '@jupyterlab';
interface IVersion {
major: number;
minor: number;
patch: number;
preRelease?: string;
}
function parseVersion(version: string): IVersion {
const match = version.match(/^(\d+)\.(\d+)\.(\d+)(?:(a|b|rc)(\d+))?$/);
if (!match) {
throw new Error(`Invalid version format: ${version}`);
}
const [, major, minor, patch, type, preVersion] = match;
const baseVersion = {
major: parseInt(major, 10),
minor: parseInt(minor, 10),
patch: parseInt(patch, 10),
};
if (type && preVersion) {
return {
...baseVersion,
preRelease: `${type}${preVersion}`,
};
}
return baseVersion;
}
function getVersionRange(version: IVersion): string {
const baseVersion = `${version.major}.${version.minor}.${version.patch}${
version.preRelease ?? ''
}`;
return `>=${baseVersion},<${version.major}.${version.minor + 1}`;
}
function updateVersionInFile(
filePath: string,
pattern: RegExp,
version: IVersion
): void {
const content = fs.readFileSync(filePath, 'utf-8');
const versionRange = getVersionRange(version);
const updatedContent = content.replace(pattern, `$1${versionRange}`);
fs.writeFileSync(filePath, updatedContent);
}
async function updatePackageJson(newVersion: string): Promise<void> {
const url = `https://raw.githubusercontent.com/jupyterlab/jupyterlab/v${newVersion}/jupyterlab/staging/package.json`;
const response = await fetch(url);
if (!response.ok) {
const errorMessage = `Failed to fetch package.json from ${url}. HTTP status code: ${response.status}`;
throw new Error(errorMessage);
}
// fetch the new galata version
const galataUrl = `https://raw.githubusercontent.com/jupyterlab/jupyterlab/v${newVersion}/galata/package.json`;
const galataResponse = await fetch(galataUrl);
if (!galataResponse.ok) {
const errorMessage = `Failed to fetch galata/package.json from ${galataUrl}. HTTP status code: ${galataResponse.status}`;
throw new Error(errorMessage);
}
const newPackageJson = await response.json();
const galataPackageJson = await galataResponse.json();
for (const packageJsonPath of PACKAGE_JSON_PATHS) {
const filePath: string = path.resolve(packageJsonPath);
const existingPackageJson = JSON.parse(fs.readFileSync(filePath, 'utf-8'));
const newDependencies = {
...newPackageJson.devDependencies,
...newPackageJson.resolutions,
[galataPackageJson.name]: galataPackageJson.version,
};
updateDependencyVersion(existingPackageJson, newDependencies);
fs.writeFileSync(
filePath,
JSON.stringify(existingPackageJson, null, 2) + '\n'
);
}
}
function updateDependencyVersion(existingJson: any, newJson: any): void {
if (!existingJson) {
return;
}
const sectionPaths: string[] = [
'resolutions',
'dependencies',
'devDependencies',
];
for (const section of sectionPaths) {
if (!existingJson[section]) {
continue;
}
const updated = existingJson[section];
for (const [pkg, version] of Object.entries<string>(
existingJson[section]
)) {
if (pkg.startsWith(DEPENDENCY_GROUP) && pkg in newJson) {
if (version[0] === '^' || version[0] === '~') {
updated[pkg] = version[0] + absoluteVersion(newJson[pkg]);
} else {
updated[pkg] = absoluteVersion(newJson[pkg]);
}
}
}
}
}
function absoluteVersion(version: string): string {
if (version.length > 0 && (version[0] === '^' || version[0] === '~')) {
return version.substring(1);
}
return version;
}
const versionPattern = /(jupyterlab)(>=[\d.]+(?:[a|b|rc]\d+)?,<[\d.]+)/g;
const FILES_TO_UPDATE = ['pyproject.toml', '.pre-commit-config.yaml'];
async function upgradeLabDependencies(): Promise<void> {
const args: string[] = process.argv.slice(2);
if (args.length < 2) {
throw new Error('Please provide the set-version flag and version');
}
const version = parseVersion(args[1]);
await updatePackageJson(args[1]); // Keep original string version for package.json
for (const file of FILES_TO_UPDATE) {
updateVersionInFile(path.resolve(file), versionPattern, version);
}
}
upgradeLabDependencies();

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 272 KiB

File diff suppressed because one or more lines are too long

@ -1,5 +1,3 @@
#!/usr/bin/env python3
#
# Jupyter Notebook documentation build configuration file, created by
# sphinx-quickstart on Mon Apr 13 09:51:11 2015.
#
@ -73,7 +71,7 @@ extensions = [
]
try:
import enchant # type:ignore # noqa
import enchant # noqa: F401
extensions += ["sphinxcontrib.spelling"]
except ImportError:
@ -97,7 +95,7 @@ master_doc = "index"
# General information about the project.
project = "Jupyter Notebook"
copyright = "2015, Jupyter Team, https://jupyter.org" # noqa
copyright = "2015, Jupyter Team, https://jupyter.org"
author = "The Jupyter Team"
# ghissue config
@ -109,9 +107,9 @@ github_project_url = "https://github.com/jupyter/notebook"
#
_version_py = os.path.join(here, "../../notebook/_version.py")
version_ns = {}
exec(compile(open(_version_py).read(), _version_py, "exec"), version_ns) # noqa
exec(compile(open(_version_py).read(), _version_py, "exec"), version_ns) # noqa: S102, SIM115
# The short X.Y version.
version = "%i.%i" % version_ns["version_info"][:2]
version = "{}.{}".format(*version_ns["version_info"][:2])
# The full version, including alpha/beta/rc tags.
release = version_ns["__version__"]
@ -174,6 +172,7 @@ html_theme = "pydata_sphinx_theme"
# further. For a list of options available for each theme, see the
# documentation.
html_theme_options = {
"header_links_before_dropdown": 5,
"icon_links": [
{
"name": "jupyter.org",
@ -192,9 +191,10 @@ html_theme_options = {
"icon": "fab fa-discourse",
},
{
"name": "Gitter",
"url": "https://gitter.im/jupyter/jupyter",
"icon": "fab fa-gitter",
"name": "Zulip",
"url": "https://jupyter.zulipchat.com/",
"icon": "_static/zulip-icon-square.svg",
"type": "local",
},
],
"logo": {
@ -400,3 +400,7 @@ intersphinx_mapping = {
spelling_lang = "en_US"
spelling_word_list_filename = "spelling_wordlist.txt"
def setup(app):
app.add_css_file("https://docs.jupyter.org/en/latest/_static/jupyter.css")

@ -52,6 +52,12 @@ front-end Notebook client (i.e. the familiar notebook interface).
> - Related: [Configuring a language kernel](https://ipython.readthedocs.io/en/latest/install/kernel_install.html)
> to run in the Jupyter Server enables your server to run other languages, like R or Julia.
```{warning}
Jupyter Notebook 7 is now based on Jupyter Server. This may break some previous `notebook` imports you may have been using, such as `notebook.auth` or `notebook.notebookapp`.
Check out the [migration guide](../migrating/server-imports.md) to learn more on how to update these server imports.
```
(configure-nbextensions)=
## Notebook extensions

@ -1,4 +1,4 @@
# Contributor
# Contributing
```{toctree}
:caption: Contributor Documentation

@ -185,7 +185,7 @@
"source": [
"The first idea of mouse based navigation is that **cells can be selected by clicking on them.** The currently selected cell gets a grey or green border depending on whether the notebook is in edit or command mode. If you click inside a cell's editor area, you will enter edit mode. If you click on the prompt or output area of a cell you will enter command mode.\n",
"\n",
"If you are running this notebook in a live session (not on http://nbviewer.jupyter.org) try selecting different cells and going between edit and command mode. Try typing into a cell."
"If you are running this notebook in a live session (not on https://nbviewer.jupyter.org) try selecting different cells and going between edit and command mode. Try typing into a cell."
]
},
{

@ -124,7 +124,6 @@
"outputs": [],
"source": [
"import sys\n",
"from ctypes import CDLL\n",
"\n",
"# This will crash a Linux or Mac system\n",
"# equivalent calls can be made on Windows\n",
@ -225,9 +224,7 @@
}
],
"source": [
"from __future__ import print_function\n",
"\n",
"print('hi, stderr', file=sys.stderr)"
"print(\"hi, stderr\", file=sys.stderr)"
]
},
{
@ -270,7 +267,8 @@
}
],
"source": [
"import time, sys\n",
"import sys\n",
"import time\n",
"\n",
"for i in range(8):\n",
" print(i)\n",

@ -1,4 +1,4 @@
# Migrating to Notebook 7
# Migrating
_Updated 2023-05-17_
@ -73,6 +73,7 @@ notebook_7_features.md
migrating/frontend-extensions.md
migrating/server-extensions.md
migrating/server-imports.md
migrating/custom-themes.md
migrating/multiple-interfaces.md
```

@ -8,7 +8,7 @@ This is for example the case for community contributed themes such as [jupyter-t
Fortunately installing a custom theme for Notebook 7 is very easy. It is the same process as installing a regular extension.
For exampe let's say you want to install the [JupyterLab Night](https://github.com/martinRenou/jupyterlab-night) theme. You can do so by running the following command:
For example let's say you want to install the [JupyterLab Night](https://github.com/jupyterlab-contrib/jupyterlab-night) theme. You can do so by running the following command:
```bash
pip install jupyterlab-night

@ -0,0 +1,33 @@
# Server Imports in Notebook 7
Notebook 7 is now based on Jupyter Server, which lets users run multiple Jupyter frontends (e.g. Notebook, JupyterLab, NBClassic, etc.) on the same server.
Prior to Notebook 7, the Classic Notebook server included the server modules in the `notebook` package. This means it was possible to import the server modules from the `notebook` package, for example:
```python
from notebook.auth import passwd
passwd("foo")
```
Or:
```python
from notebook import notebookapp
notebookapp.list_running_servers()
```
In Notebook 7, these server modules are now exposed by the `jupyter_server` package. The code snippets above should be updated to:
```python
from jupyter_server.auth import passwd
passwd("foo")
```
And:
```python
from jupyter_server import serverapp
serverapp.list_running_servers()
```
These are just examples, so you may have to adjust your use of `notebook` imports based on the specific server modules you were using.

@ -45,7 +45,7 @@ notebook and its dependencies.
### Notebook documents
Notebook documents contains the inputs and outputs of a interactive session as
Notebook documents contain the inputs and outputs of an interactive session as
well as additional text that accompanies the code but is not meant for
execution. In this way, notebook files can serve as a complete computational
record of a session, interleaving executable code with explanatory text,
@ -355,7 +355,7 @@ Specific plotting library integration is a feature of the kernel.
## Installing kernels
For information on how to install a Python kernel, refer to the
[IPython install page](https://ipython.org/install.html).
[IPython install page](https://ipython.org/install).
The Jupyter wiki has a long list of [Kernels for other languages](https://github.com/jupyter/jupyter/wiki/Jupyter-kernels).
They usually come with instructions on how to make the kernel available

@ -110,17 +110,7 @@ However a version compatible with Notebook 7 will be available before the final
### RISE
```{warning}
The RISE extension is still under active development and a version compatible with Notebook 7 is not yet available on PyPI.
```
The RISE extension is another popular JupyterLab extension that is being ported to work with Notebook 7. It allows you to turn your Jupyter Notebooks into a slideshow.
The extension is still under [active development](https://github.com/jupyterlab-contrib/rise). When ready, it will be possible to install it with `pip`:
```bash
pip install jupyterlab-rise
```
The RISE extension is another popular JupyterLab extension that has been ported to work with Notebook 7. It allows you to turn your Jupyter Notebooks into a slideshow. See the [installation instructions](https://github.com/jupyterlab-contrib/rise#install).
## A document-centric user experience

@ -1,4 +1,4 @@
# User Documentation
# Documentation
Use this page to navigate to different parts of the user documentation.

@ -1,5 +1,4 @@
{
"$schema": "node_modules/lerna/schemas/lerna-schema.json",
"version": "independent",
"useWorkspaces": true
"version": "independent"
}

@ -2,7 +2,7 @@ from __future__ import annotations
from typing import Any
from ._version import __version__ # noqa
from ._version import __version__, version_info # noqa: F401
def _jupyter_server_extension_paths() -> list[dict[str, str]]:

@ -1,4 +1,5 @@
"""CLI entry point for notebook."""
import sys
from notebook.app import main

@ -1,11 +1,12 @@
"""Version info for notebook."""
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
import re
from collections import namedtuple
# Use "hatch version xx.yy.zz" to handle version changes
__version__ = "7.0.6"
__version__ = "7.6.0a0"
# PEP440 version parser
_version_regex = re.compile(
@ -23,7 +24,7 @@ _version_regex = re.compile(
_version_fields = _version_regex.match(__version__).groupdict() # type:ignore[union-attr]
VersionInfo = namedtuple("VersionInfo", ["major", "minor", "micro", "releaselevel", "serial"])
VersionInfo = namedtuple("VersionInfo", ["major", "minor", "micro", "releaselevel", "serial"]) # noqa: PYI024
version_info = VersionInfo(
*[

@ -1,10 +1,11 @@
"""Jupyter notebook application."""
from __future__ import annotations
import os
import re
import typing as t
from os.path import join as pjoin
from pathlib import Path
from jupyter_client.utils import ensure_async # type:ignore[attr-defined]
from jupyter_core.application import base_aliases
@ -36,11 +37,11 @@ from traitlets.config.loader import Config
from ._version import __version__
HERE = os.path.dirname(__file__)
HERE = Path(__file__).parent.resolve()
Flags = t.Dict[t.Union[str, t.Tuple[str, ...]], t.Tuple[t.Union[t.Dict[str, t.Any], Config], str]]
Flags = dict[t.Union[str, tuple[str, ...]], tuple[t.Union[dict[str, t.Any], Config], str]]
app_dir = get_app_dir()
app_dir = Path(get_app_dir())
version = __version__
# mypy: disable-error-code="no-untyped-call"
@ -72,7 +73,7 @@ class NotebookBaseHandler(ExtensionHandlerJinjaMixin, ExtensionHandlerMixin, Jup
server_root = self.settings.get("server_root_dir", "")
server_root = server_root.replace(os.sep, "/")
server_root = os.path.normpath(os.path.expanduser(server_root))
server_root = os.path.normpath(Path(server_root).expanduser())
try:
# Remove the server_root from pref dir
if self.serverapp.preferred_dir != server_root:
@ -120,6 +121,12 @@ class NotebookBaseHandler(ExtensionHandlerJinjaMixin, ExtensionHandlerMixin, Jup
logger=self.log,
),
)
# modify page config with custom hook
page_config_hook = self.settings.get("page_config_hook", None)
if page_config_hook:
page_config = page_config_hook(self, page_config)
return page_config
@ -149,7 +156,7 @@ class TreeHandler(NotebookBaseHandler):
tpl = self.render_template("tree.html", page_config=page_config)
return self.write(tpl)
elif await ensure_async(cm.file_exists(path)):
if await ensure_async(cm.file_exists(path)):
# it's not a directory, we have redirecting to do
model = await ensure_async(cm.get(path, content=False))
if model["type"] == "notebook":
@ -159,15 +166,15 @@ class TreeHandler(NotebookBaseHandler):
url = ujoin(self.base_url, "files", url_escape(path))
self.log.debug("Redirecting %s to %s", self.request.path, url)
self.redirect(url)
else:
raise web.HTTPError(404)
return None
raise web.HTTPError(404)
class ConsoleHandler(NotebookBaseHandler):
"""A console page handler."""
@web.authenticated
def get(self, path: str | None = None) -> t.Any:
def get(self, path: str | None = None) -> t.Any: # noqa: ARG002
"""Get the console page."""
tpl = self.render_template("consoles.html", page_config=self.get_page_config())
return self.write(tpl)
@ -177,7 +184,7 @@ class TerminalHandler(NotebookBaseHandler):
"""A terminal page handler."""
@web.authenticated
def get(self, path: str | None = None) -> t.Any:
def get(self, path: str | None = None) -> t.Any: # noqa: ARG002
"""Get the terminal page."""
tpl = self.render_template("terminals.html", page_config=self.get_page_config())
return self.write(tpl)
@ -187,7 +194,7 @@ class FileHandler(NotebookBaseHandler):
"""A file page handler."""
@web.authenticated
def get(self, path: str | None = None) -> t.Any:
def get(self, path: str | None = None) -> t.Any: # noqa: ARG002
"""Get the file page."""
tpl = self.render_template("edit.html", page_config=self.get_page_config())
return self.write(tpl)
@ -197,8 +204,16 @@ class NotebookHandler(NotebookBaseHandler):
"""A notebook page handler."""
@web.authenticated
def get(self, path: str | None = None) -> t.Any:
"""Get the notebook page."""
async def get(self, path: str = "") -> t.Any:
"""Get the notebook page. Redirect if it's a directory."""
path = path.strip("/")
cm = self.contents_manager
if await ensure_async(cm.dir_exists(path=path)):
url = ujoin(self.base_url, "tree", url_escape(path))
self.log.debug("Redirecting %s to %s since path is a directory", self.request.path, url)
self.redirect(url)
return None
tpl = self.render_template("notebooks.html", page_config=self.get_page_config())
return self.write(tpl)
@ -210,17 +225,17 @@ class CustomCssHandler(NotebookBaseHandler):
def get(self) -> t.Any:
"""Get the custom css file."""
self.set_header("Content-Type", 'text/css')
self.set_header("Content-Type", "text/css")
page_config = self.get_page_config()
custom_css_file = f"{page_config['jupyterConfigDir']}/custom/custom.css"
if not os.path.isfile(custom_css_file):
static_path_root = re.match('^(.*?)static', page_config['staticDir'])
if not Path(custom_css_file).is_file():
static_path_root = re.match("^(.*?)static", page_config["staticDir"])
if static_path_root is not None:
custom_dir = static_path_root.groups()[0]
custom_css_file = f"{custom_dir}custom/custom.css"
with open(custom_css_file) as css_f:
with Path(custom_css_file).open() as css_f:
return self.write(css_f.read())
@ -269,23 +284,23 @@ class JupyterNotebookApp(NotebookConfigShimMixin, LabServerApp): # type:ignore[
@default("static_dir")
def _default_static_dir(self) -> str:
return os.path.join(HERE, "static")
return str(HERE / "static")
@default("templates_dir")
def _default_templates_dir(self) -> str:
return os.path.join(HERE, "templates")
return str(HERE / "templates")
@default("app_settings_dir")
def _default_app_settings_dir(self) -> str:
return pjoin(app_dir, "settings")
return str(app_dir / "settings")
@default("schemas_dir")
def _default_schemas_dir(self) -> str:
return pjoin(app_dir, "schemas")
return str(app_dir / "schemas")
@default("themes_dir")
def _default_themes_dir(self) -> str:
return pjoin(app_dir, "themes")
return str(app_dir / "themes")
@default("user_settings_dir")
def _default_user_settings_dir(self) -> str:
@ -301,6 +316,8 @@ class JupyterNotebookApp(NotebookConfigShimMixin, LabServerApp): # type:ignore[
def server_extension_is_enabled(self, extension: str) -> bool:
"""Check if server extension is enabled."""
if self.serverapp is None:
return False
try:
extension_enabled = (
self.serverapp.extension_manager.extensions[extension].enabled is True
@ -311,6 +328,7 @@ class JupyterNotebookApp(NotebookConfigShimMixin, LabServerApp): # type:ignore[
def initialize_handlers(self) -> None:
"""Initialize handlers."""
assert self.serverapp is not None # noqa: S101
page_config = self.serverapp.web_app.settings.setdefault("page_config_data", {})
nbclassic_enabled = self.server_extension_is_enabled("nbclassic")
page_config["nbclassic_enabled"] = nbclassic_enabled
@ -340,7 +358,7 @@ class JupyterNotebookApp(NotebookConfigShimMixin, LabServerApp): # type:ignore[
self.handlers.append(("/custom/custom.css", CustomCssHandler))
super().initialize_handlers()
def initialize(self, argv: list[str] | None = None) -> None:
def initialize(self, argv: list[str] | None = None) -> None: # noqa: ARG002
"""Subclass because the ExtensionApp.initialize() method does not take arguments"""
super().initialize()

@ -1,43 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{page_config['appName'] | e}} - Console</title>
{% block favicon %}
<link rel="icon" type="image/x-icon" href="{{ page_config['fullStaticUrl'] | e }}/favicons/favicon-console.ico" class="favicon">
{% endblock %}
{% if custom_css %}
<link rel="stylesheet" type="text/css" href="{{ base_url | escape }}custom/custom.css">
{% endif %}
</head>
<body>
{# Copy so we do not modify the page_config with updates. #}
{% set page_config_full = page_config.copy() %}
{# Set a dummy variable - we just want the side effect of the update. #}
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
{# Sentinel value to say that we are on the tree page #}
{% set _ = page_config_full.update(notebookPage='consoles') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script src="{{page_config['fullStaticUrl'] | e}}/bundle.js" main="index"></script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({ }, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -1,39 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{page_config['appName'] | e}} - Edit</title>
{% block favicon %}
<link rel="icon" type="image/x-icon" href="{{ base_url | escape }}static/favicons/favicon-file.ico" class="favicon">
{% endblock %}
</head>
<body data-notebook="edit">
{# Copy so we do not modify the page_config with updates. #}
{% set page_config_full = page_config.copy() %}
{# Set a dummy variable - we just want the side effect of the update. #}
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
{# Sentinel value to say that we are on the tree page #}
{% set _ = page_config_full.update(notebookPage='edit') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script src="{{page_config['fullStaticUrl'] | e}}/bundle.js" main="index"></script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({ }, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -1,43 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{page_config['appName'] | e}} - Notebook</title>
{% block favicon %}
<link rel="icon" type="image/x-icon" href="{{ base_url | escape }}static/favicons/favicon-notebook.ico" class="favicon">
{% endblock %}
{% if custom_css %}
<link rel="stylesheet" type="text/css" href="{{ base_url | escape }}custom/custom.css">
{% endif %}
</head>
<body data-notebook="notebooks">
{# Copy so we do not modify the page_config with updates. #}
{% set page_config_full = page_config.copy() %}
{# Set a dummy variable - we just want the side effect of the update. #}
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
{# Sentinel value to say that we are on the tree page #}
{% set _ = page_config_full.update(notebookPage='notebooks') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script src="{{page_config['fullStaticUrl'] | e}}/bundle.js" main="index"></script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({ }, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -1,43 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{page_config['appName'] | e}} - Terminal</title>
{% block favicon %}
<link rel="icon" type="image/x-icon" href="{{ base_url | escape }}static/favicons/favicon-terminal.ico" class="favicon">
{% endblock %}
{% if custom_css %}
<link rel="stylesheet" type="text/css" href="{{ base_url | escape }}custom/custom.css">
{% endif %}
</head>
<body>
{# Copy so we do not modify the page_config with updates. #}
{% set page_config_full = page_config.copy() %}
{# Set a dummy variable - we just want the side effect of the update. #}
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
{# Sentinel value to say that we are on the tree page #}
{% set _ = page_config_full.update(notebookPage='terminals') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script src="{{page_config['fullStaticUrl'] | e}}/bundle.js" main="index"></script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({ }, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -1,43 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Home</title>
{% block favicon %}
<link rel="icon" type="image/x-icon" href="{{ base_url | escape }}static/favicons/favicon.ico" class="favicon">
{% endblock %}
{% if custom_css %}
<link rel="stylesheet" type="text/css" href="{{ base_url | escape }}custom/custom.css">
{% endif %}
</head>
<body>
{# Copy so we do not modify the page_config with updates. #}
{% set page_config_full = page_config.copy() %}
{# Set a dummy variable - we just want the side effect of the update. #}
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
{# Sentinel value to say that we are on the tree page #}
{% set _ = page_config_full.update(notebookPage='tree') %}
<script id="jupyter-config-data" type="application/json">
{{ page_config_full | tojson }}
</script>
<script src="{{page_config['fullStaticUrl'] | e}}/bundle.js" main="index"></script>
<script type="text/javascript">
/* Remove token from URL. */
(function () {
var parsedUrl = new URL(window.location.href);
if (parsedUrl.searchParams.get('token')) {
parsedUrl.searchParams.delete('token');
window.history.replaceState({ }, '', parsedUrl.href);
}
})();
</script>
</body>
</html>

@ -31,6 +31,7 @@
"eslint": "eslint . --ext .ts,.tsx --fix",
"eslint:check": "eslint . --ext .ts,.tsx",
"eslint:files": "eslint --fix",
"get:lab:version": "node ./buildutils/lib/get-latest-lab-version.js",
"integrity": "node buildutils/lib/ensure-repo.js",
"prettier": "prettier --write \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md}\"",
"prettier:check": "prettier --list-different \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md}\"",
@ -39,6 +40,7 @@
"release:patch": "node ./buildutils/lib/release-patch.js",
"test": "lerna run test",
"update:dependency": "node ./node_modules/@jupyterlab/buildutils/lib/update-dependency.js --lerna",
"upgrade:lab:dependencies": "node ./buildutils/lib/upgrade-lab-dependencies.js",
"watch": "run-p watch:lib watch:app",
"watch:app": "lerna exec --stream --scope \"@jupyter-notebook/app\" jlpm watch",
"watch:lib": "lerna exec --stream --scope @jupyter-notebook/metapackage jlpm watch"
@ -49,7 +51,7 @@
"yjs": "^13.5.40"
},
"devDependencies": {
"@jupyterlab/buildutils": "^4.0.7",
"@jupyterlab/buildutils": "~4.6.0-alpha.0",
"@typescript-eslint/eslint-plugin": "^5.55.0",
"@typescript-eslint/parser": "^5.55.0",
"eslint": "^8.36.0",
@ -57,11 +59,12 @@
"eslint-plugin-jest": "^27.2.1",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-react": "^7.32.2",
"lerna": "^6.6.2",
"html-webpack-plugin": "^5.6.3",
"lerna": "^7.1.4",
"npm-run-all": "^4.1.5",
"prettier": "^2.8.5",
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"nx": {}
}

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/metapackage",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"private": true,
"description": "Jupyter Notebook - Metapackage",
"homepage": "https://github.com/jupyter/notebook",
@ -20,20 +20,20 @@
"watch": "tsc -b -w --preserveWatchOutput"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyter-notebook/application-extension": "^7.0.6",
"@jupyter-notebook/console-extension": "^7.0.6",
"@jupyter-notebook/docmanager-extension": "^7.0.6",
"@jupyter-notebook/documentsearch-extension": "^7.0.6",
"@jupyter-notebook/help-extension": "^7.0.6",
"@jupyter-notebook/lab-extension": "^7.0.6",
"@jupyter-notebook/notebook-extension": "^7.0.6",
"@jupyter-notebook/terminal-extension": "^7.0.6",
"@jupyter-notebook/tree": "^7.0.6",
"@jupyter-notebook/tree-extension": "^7.0.6",
"@jupyter-notebook/ui-components": "^7.0.6"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyter-notebook/application-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/console-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/docmanager-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/documentsearch-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/help-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/lab-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/notebook-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/terminal-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/tree": "^7.6.0-alpha.0",
"@jupyter-notebook/tree-extension": "^7.6.0-alpha.0",
"@jupyter-notebook/ui-components": "^7.6.0-alpha.0"
},
"devDependencies": {
"typescript": "~5.0.2"
"typescript": "~5.5.4"
}
}

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/application-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Application Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,26 +38,26 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyter-notebook/ui-components": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/apputils": "^4.1.7",
"@jupyterlab/codeeditor": "^4.0.7",
"@jupyterlab/console": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/docmanager": "^4.0.7",
"@jupyterlab/docregistry": "^4.0.7",
"@jupyterlab/mainmenu": "^4.0.7",
"@jupyterlab/rendermime": "^4.0.7",
"@jupyterlab/settingregistry": "^4.0.7",
"@jupyterlab/translation": "^4.0.7",
"@lumino/coreutils": "^2.1.2",
"@lumino/disposable": "^2.1.2",
"@lumino/widgets": "^2.3.0"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyter-notebook/ui-components": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/codeeditor": "~4.6.0-alpha.0",
"@jupyterlab/console": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/docmanager": "~4.6.0-alpha.0",
"@jupyterlab/docregistry": "~4.6.0-alpha.0",
"@jupyterlab/mainmenu": "~4.6.0-alpha.0",
"@jupyterlab/rendermime": "~4.6.0-alpha.0",
"@jupyterlab/settingregistry": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"@lumino/coreutils": "^2.2.2",
"@lumino/disposable": "^2.1.5",
"@lumino/widgets": "^2.7.2"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -10,6 +10,10 @@
"command": "application:rename",
"rank": 4.5
},
{
"command": "application:duplicate",
"rank": 4.8
},
{
"command": "notebook:trust",
"rank": 20

@ -9,7 +9,9 @@
"title": "Customize shell widget positioning",
"description": "Overrides default widget position in the application layout",
"default": {
"Markdown Preview": { "area": "right" }
"Debugger Console": { "area": "down" },
"Markdown Preview": { "area": "right" },
"Plugins": { "area": "left" }
}
}
},

@ -0,0 +1,16 @@
{
"jupyter.lab.setting-icon": "notebook-ui-components:jupyter",
"jupyter.lab.setting-icon-label": "Jupyter Notebook shortcuts",
"title": "Jupyter Notebook Shortcuts",
"description": "Keyboard shortcuts for Jupyter Notebook",
"jupyter.lab.shortcuts": [
{
"args": {},
"command": "notebook:toggle-cell-outputs",
"keys": ["O"],
"selector": ".jp-Notebook.jp-mod-commandMode:not(.jp-mod-readWrite) :focus"
}
],
"additionalProperties": false,
"type": "object"
}

@ -7,6 +7,7 @@ import {
ITreePathUpdater,
JupyterFrontEnd,
JupyterFrontEndPlugin,
JupyterLab,
} from '@jupyterlab/application';
import {
@ -15,6 +16,7 @@ import {
ISanitizer,
ISplashScreen,
IToolbarWidgetRegistry,
showErrorMessage,
} from '@jupyterlab/apputils';
import { ConsolePanel } from '@jupyterlab/console';
@ -83,6 +85,11 @@ const JUPYTERLAB_DOCMANAGER_PLUGIN_ID =
* The command IDs used by the application plugin.
*/
namespace CommandIDs {
/**
* Duplicate the current document and open the new document
*/
export const duplicate = 'application:duplicate';
/**
* Handle local links
*/
@ -129,6 +136,8 @@ namespace CommandIDs {
*/
const dirty: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:dirty',
description:
'Check if the application is dirty before closing the browser tab.',
autoStart: true,
requires: [ILabStatus, ITranslator],
activate: (
@ -152,11 +161,27 @@ const dirty: JupyterFrontEndPlugin<void> = {
},
};
/**
* The application info.
*/
const info: JupyterFrontEndPlugin<JupyterLab.IInfo> = {
id: '@jupyter-notebook/application-extension:info',
autoStart: true,
provides: JupyterLab.IInfo,
activate: (app: JupyterFrontEnd): JupyterLab.IInfo => {
if (!(app instanceof NotebookApp)) {
throw new Error(`${info.id} must be activated in Jupyter Notebook.`);
}
return app.info;
},
};
/**
* The logo plugin.
*/
const logo: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:logo',
description: 'The logo plugin.',
autoStart: true,
activate: (app: JupyterFrontEnd) => {
const baseUrl = PageConfig.getBaseUrl();
@ -185,6 +210,7 @@ const logo: JupyterFrontEndPlugin<void> = {
*/
const opener: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:opener',
description: 'A plugin to open documents in the main area.',
autoStart: true,
requires: [IRouter, IDocumentManager],
optional: [ISettingRegistry],
@ -253,6 +279,7 @@ const opener: JupyterFrontEndPlugin<void> = {
*/
const menus: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:menus',
description: 'A plugin to customize menus.',
requires: [IMainMenu],
autoStart: true,
activate: (app: JupyterFrontEnd, menu: IMainMenu) => {
@ -283,6 +310,7 @@ const menus: JupyterFrontEndPlugin<void> = {
*/
const menuSpacer: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:menu-spacer',
description: 'A plugin to provide a spacer at rank 900 in the menu area.',
autoStart: true,
activate: (app: JupyterFrontEnd) => {
const menu = new Widget();
@ -297,6 +325,7 @@ const menuSpacer: JupyterFrontEndPlugin<void> = {
*/
const pages: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:pages',
description: 'Add commands to open the tree and running pages.',
autoStart: true,
requires: [ITranslator],
optional: [ICommandPalette],
@ -339,6 +368,7 @@ const pages: JupyterFrontEndPlugin<void> = {
*/
const pathOpener: JupyterFrontEndPlugin<INotebookPathOpener> = {
id: '@jupyter-notebook/application-extension:path-opener',
description: 'A plugin to open paths in new browser tabs.',
autoStart: true,
provides: INotebookPathOpener,
activate: (app: JupyterFrontEnd): INotebookPathOpener => {
@ -351,6 +381,7 @@ const pathOpener: JupyterFrontEndPlugin<INotebookPathOpener> = {
*/
const paths: JupyterFrontEndPlugin<JupyterFrontEnd.IPaths> = {
id: '@jupyter-notebook/application-extension:paths',
description: 'The default paths for a Jupyter Notebook app.',
autoStart: true,
provides: JupyterFrontEnd.IPaths,
activate: (app: JupyterFrontEnd): JupyterFrontEnd.IPaths => {
@ -366,9 +397,9 @@ const paths: JupyterFrontEndPlugin<JupyterFrontEnd.IPaths> = {
*/
const rendermime: JupyterFrontEndPlugin<IRenderMimeRegistry> = {
id: '@jupyter-notebook/application-extension:rendermime',
description: 'A plugin providing a rendermime registry.',
autoStart: true,
provides: IRenderMimeRegistry,
description: 'Provides the render mime registry.',
optional: [
IDocumentManager,
ILatexTypesetter,
@ -439,6 +470,7 @@ const rendermime: JupyterFrontEndPlugin<IRenderMimeRegistry> = {
*/
const shell: JupyterFrontEndPlugin<INotebookShell> = {
id: '@jupyter-notebook/application-extension:shell',
description: 'The default Jupyter Notebook application shell.',
autoStart: true,
provides: INotebookShell,
optional: [ISettingRegistry],
@ -505,6 +537,7 @@ const splash: JupyterFrontEndPlugin<ISplashScreen> = {
*/
const status: JupyterFrontEndPlugin<ILabStatus> = {
id: '@jupyter-notebook/application-extension:status',
description: 'The default JupyterLab application status provider.',
autoStart: true,
provides: ILabStatus,
activate: (app: JupyterFrontEnd) => {
@ -520,6 +553,8 @@ const status: JupyterFrontEndPlugin<ILabStatus> = {
*/
const tabTitle: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:tab-title',
description:
'A plugin to display the document title in the browser tab title.',
autoStart: true,
requires: [INotebookShell],
activate: (app: JupyterFrontEnd, shell: INotebookShell) => {
@ -556,6 +591,7 @@ const tabTitle: JupyterFrontEndPlugin<void> = {
*/
const title: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:title',
description: 'A plugin to display and rename the title of a file.',
autoStart: true,
requires: [INotebookShell, ITranslator],
optional: [IDocumentManager, IRouter, IToolbarWidgetRegistry],
@ -601,6 +637,20 @@ const title: JupyterFrontEndPlugin<void> = {
return !!(currentWidget && docManager.contextForWidget(currentWidget));
};
commands.addCommand(CommandIDs.duplicate, {
label: () => trans.__('Duplicate'),
isEnabled,
execute: async () => {
if (!isEnabled()) {
return;
}
// Duplicate the file, and open the new file.
const result = await docManager.duplicate(current.context.path);
await commands.execute('docmanager:open', { path: result.path });
},
});
commands.addCommand(CommandIDs.rename, {
label: () => trans.__('Rename…'),
isEnabled,
@ -609,14 +659,23 @@ const title: JupyterFrontEndPlugin<void> = {
return;
}
const result = await renameDialog(docManager, current.context);
try {
const result = await renameDialog(docManager, current.context);
// activate the current widget to bring the focus
if (current) {
current.activate();
}
// activate the current widget to bring the focus
if (current) {
current.activate();
}
if (result === null) {
if (result === null) {
return;
}
} catch (error) {
showErrorMessage(
trans.__('Rename Error'),
(error as Error).message ||
trans.__('An error occurred while renaming the file.')
);
return;
}
@ -654,6 +713,7 @@ const title: JupyterFrontEndPlugin<void> = {
*/
const topVisibility: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:top',
description: 'Plugin to toggle the top header visibility.',
requires: [INotebookShell, ITranslator],
optional: [ISettingRegistry, ICommandPalette],
activate: (
@ -735,6 +795,7 @@ const topVisibility: JupyterFrontEndPlugin<void> = {
*/
const sidePanelVisibility: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:sidepanel',
description: 'Plugin to toggle the visibility of left or right side panel.',
requires: [INotebookShell, ITranslator],
optional: [IMainMenu, ICommandPalette],
autoStart: true,
@ -945,11 +1006,26 @@ const sidePanelVisibility: JupyterFrontEndPlugin<void> = {
},
};
/**
* A plugin for defining keyboard shortcuts specific to the notebook application.
*/
const shortcuts: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:shortcuts',
description:
'A plugin for defining keyboard shortcuts specific to the notebook application.',
autoStart: true,
activate: (app: JupyterFrontEnd) => {
// for now this plugin is mostly useful for defining keyboard shortcuts
// specific to the notebook application
},
};
/**
* The default tree route resolver plugin.
*/
const tree: JupyterFrontEndPlugin<JupyterFrontEnd.ITreeResolver> = {
id: '@jupyter-notebook/application-extension:tree-resolver',
description: 'The default tree route resolver plugin.',
autoStart: true,
requires: [IRouter],
provides: JupyterFrontEnd.ITreeResolver,
@ -1007,8 +1083,12 @@ const tree: JupyterFrontEndPlugin<JupyterFrontEnd.ITreeResolver> = {
},
};
/**
* Plugin to update tree path.
*/
const treePathUpdater: JupyterFrontEndPlugin<ITreePathUpdater> = {
id: '@jupyter-notebook/application-extension:tree-updater',
description: 'Plugin to update tree path.',
requires: [IRouter],
provides: ITreePathUpdater,
activate: (app: JupyterFrontEnd, router: IRouter) => {
@ -1029,8 +1109,12 @@ const treePathUpdater: JupyterFrontEndPlugin<ITreePathUpdater> = {
autoStart: true,
};
/**
* Translator plugin
*/
const translator: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:translator',
description: 'Translator plugin',
requires: [INotebookShell, ITranslator],
autoStart: true,
activate: (
@ -1047,6 +1131,7 @@ const translator: JupyterFrontEndPlugin<void> = {
*/
const zen: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/application-extension:zen',
description: 'Zen mode plugin.',
autoStart: true,
requires: [ITranslator],
optional: [ICommandPalette, INotebookShell],
@ -1103,6 +1188,7 @@ const zen: JupyterFrontEndPlugin<void> = {
*/
const plugins: JupyterFrontEndPlugin<any>[] = [
dirty,
info,
logo,
menus,
menuSpacer,
@ -1113,6 +1199,7 @@ const plugins: JupyterFrontEndPlugin<any>[] = [
rendermime,
shell,
sidePanelVisibility,
shortcuts,
splash,
status,
tabTitle,

@ -38,3 +38,8 @@
/* bring logo to the front so it is selectable by tab*/
z-index: 10;
}
/* Hide the notification status item */
.jp-Notification-Status {
display: none;
}

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/application",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Application",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -42,27 +42,27 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/docregistry": "^4.0.7",
"@jupyterlab/rendermime-interfaces": "^3.8.7",
"@jupyterlab/ui-components": "^4.0.7",
"@lumino/algorithm": "^2.0.1",
"@lumino/coreutils": "^2.1.2",
"@lumino/messaging": "^2.0.1",
"@lumino/polling": "^2.1.2",
"@lumino/signaling": "^2.1.2",
"@lumino/widgets": "^2.3.0"
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/docregistry": "~4.6.0-alpha.0",
"@jupyterlab/rendermime-interfaces": "~3.14.0-alpha.0",
"@jupyterlab/ui-components": "~4.6.0-alpha.0",
"@lumino/algorithm": "^2.0.4",
"@lumino/coreutils": "^2.2.2",
"@lumino/messaging": "^2.0.4",
"@lumino/polling": "^2.1.5",
"@lumino/signaling": "^2.1.5",
"@lumino/widgets": "^2.7.2"
},
"devDependencies": {
"@babel/core": "^7.11.6",
"@babel/preset-env": "^7.12.1",
"@jupyterlab/testutils": "^4.0.7",
"@jupyterlab/testutils": "~4.6.0-alpha.0",
"@types/jest": "^29.2.5",
"jest": "^29.3.1",
"rimraf": "^3.0.2",
"ts-jest": "^29.0.3",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -2,6 +2,7 @@
// Distributed under the terms of the Modified BSD License.
import {
JupyterLab,
JupyterFrontEnd,
JupyterFrontEndPlugin,
} from '@jupyterlab/application';
@ -40,6 +41,17 @@ export class NotebookApp extends JupyterFrontEnd<INotebookShell> {
}
}
// Create an IInfo dictionary from the options to override the defaults.
const info = Object.keys(JupyterLab.defaultInfo).reduce((acc, val) => {
if (val in options) {
(acc as any)[val] = JSON.parse(JSON.stringify((options as any)[val]));
}
return acc;
}, {} as Partial<JupyterLab.IInfo>);
// Populate application info.
this._info = { ...JupyterLab.defaultInfo, ...info };
this.restored = this.shell.restored;
this.restored.then(() => this._formatter.invoke());
@ -71,6 +83,13 @@ export class NotebookApp extends JupyterFrontEnd<INotebookShell> {
readonly version = PageConfig.getOption('appVersion') ?? 'unknown';
/**
* The NotebookApp application information dictionary.
*/
get info(): JupyterLab.IInfo {
return this._info;
}
/**
* The JupyterLab application paths dictionary.
*/
@ -149,6 +168,7 @@ export class NotebookApp extends JupyterFrontEnd<INotebookShell> {
});
}
private _info: JupyterLab.IInfo = JupyterLab.defaultInfo;
private _formatter = new Throttler(() => {
Private.setFormat(this);
}, 250);
@ -173,6 +193,11 @@ export namespace NotebookApp {
* The mime renderer extensions.
*/
readonly mimeExtensions: IRenderMime.IExtensionModule[];
/**
* The information about available plugins.
*/
readonly availablePlugins: JupyterLab.IPluginInfo[];
}
/**

@ -165,17 +165,20 @@ export class SidePanelHandler extends PanelHandler {
* if there is no most recently used.
*/
expand(id?: string): void {
if (this._currentWidget) {
this.collapse();
}
if (id) {
this.activate(id);
} else {
const visibleWidget = this.currentWidget;
if (visibleWidget) {
this._currentWidget = visibleWidget;
this.activate(visibleWidget.id);
if (this._currentWidget && this._currentWidget.id === id) {
this.collapse();
this.hide();
} else {
this.collapse();
this.hide();
this.activate(id);
this.show();
}
} else if (this.currentWidget) {
this._currentWidget = this.currentWidget;
this.activate(this._currentWidget.id);
this.show();
}
}

@ -15,7 +15,7 @@ class DefaultNotebookPathOpener implements INotebookPathOpener {
open(options: INotebookPathOpener.IOpenOptions): WindowProxy | null {
const { prefix, path, searchParams, target, features } = options;
const url = new URL(
URLExt.join(prefix, path ?? ''),
URLExt.join(prefix, URLExt.encodeParts(path ?? '')),
window.location.origin
);
if (searchParams) {

@ -9,8 +9,16 @@ import { find } from '@lumino/algorithm';
import { JSONExt, PromiseDelegate, Token } from '@lumino/coreutils';
import { ISignal, Signal } from '@lumino/signaling';
import { BoxLayout, Panel, SplitPanel, Widget } from '@lumino/widgets';
import {
BoxLayout,
FocusTracker,
Panel,
SplitPanel,
TabPanel,
Widget,
} from '@lumino/widgets';
import { PanelHandler, SidePanelHandler } from './panelhandler';
import { TabPanelSvg } from '@jupyterlab/ui-components';
/**
* The Jupyter Notebook application shell token.
@ -31,7 +39,7 @@ export namespace INotebookShell {
/**
* The areas of the application shell where widgets can reside.
*/
export type Area = 'main' | 'top' | 'menu' | 'left' | 'right';
export type Area = 'main' | 'top' | 'menu' | 'left' | 'right' | 'down';
/**
* Widget position
@ -128,6 +136,18 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
middlePanel.addWidget(this._spacer_bottom);
middlePanel.layout = middleLayout;
const vsplitPanel = new SplitPanel();
vsplitPanel.id = 'jp-main-vsplit-panel';
vsplitPanel.spacing = 1;
vsplitPanel.orientation = 'vertical';
SplitPanel.setStretch(vsplitPanel, 1);
const downPanel = new TabPanelSvg({
tabsMovable: true,
});
this._downPanel = downPanel;
this._downPanel.id = 'jp-down-stack';
// TODO: Consider storing this as an attribute this._hsplitPanel if saving/restoring layout needed
const hsplitPanel = new SplitPanel();
hsplitPanel.id = 'main-split-panel';
@ -147,8 +167,21 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
// panel.
hsplitPanel.setRelativeSizes([1, 2.5, 1]);
vsplitPanel.addWidget(hsplitPanel);
vsplitPanel.addWidget(downPanel);
rootLayout.spacing = 0;
rootLayout.addWidget(hsplitPanel);
rootLayout.addWidget(vsplitPanel);
// initially hiding the down panel
this._downPanel.hide();
// Connect down panel change listeners
this._downPanel.tabBar.tabMoved.connect(this._onTabPanelChanged, this);
this._downPanel.stackedPanel.widgetRemoved.connect(
this._onTabPanelChanged,
this
);
this.layout = rootLayout;
@ -163,7 +196,10 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
/**
* A signal emitted when the current widget changes.
*/
get currentChanged(): ISignal<NotebookShell, void> {
get currentChanged(): ISignal<
JupyterFrontEnd.IShell,
FocusTracker.IChangedArgs<Widget>
> {
return this._currentChanged;
}
@ -258,7 +294,7 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
*/
activateById(id: string): void {
// Search all areas that can have widgets for this widget, starting with main.
for (const area of ['main', 'top', 'left', 'right', 'menu']) {
for (const area of ['main', 'top', 'left', 'right', 'menu', 'down']) {
const widget = find(
this.widgets(area as INotebookShell.Area),
(w) => w.id === id
@ -268,6 +304,9 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
this.expandLeft(id);
} else if (area === 'right') {
this.expandRight(id);
} else if (area === 'down') {
this._downPanel.show();
widget.activate();
} else {
widget.activate();
}
@ -314,20 +353,27 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
case 'menu':
return this._menuHandler.addWidget(widget, rank);
case 'main':
case undefined:
case undefined: {
if (this._main.widgets.length > 0) {
// do not add the widget if there is already one
return;
}
const previousWidget = this.currentWidget;
this._main.addWidget(widget);
this._main.update();
this._currentChanged.emit(void 0);
this._currentChanged.emit({
newValue: widget,
oldValue: previousWidget,
});
this._mainWidgetLoaded.resolve();
break;
}
case 'left':
return this._leftHandler.addWidget(widget, rank);
case 'right':
return this._rightHandler.addWidget(widget, rank);
case 'down':
return this._downPanel.addWidget(widget);
default:
console.warn(`Cannot add widget to area: ${area}`);
}
@ -371,6 +417,9 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
case 'right':
yield* this._rightHandler.widgets;
return;
case 'down':
yield* this._downPanel.widgets;
return;
default:
console.error(`This shell has no area called "${area}"`);
return;
@ -418,6 +467,15 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
this._userLayout = configuration;
}
/**
* Handle a change on the down panel widgets
*/
private _onTabPanelChanged(): void {
if (this._downPanel.stackedPanel.widgets.length === 0) {
this._downPanel.hide();
}
}
private _topWrapper: Panel;
private _topHandler: PanelHandler;
private _menuWrapper: Panel;
@ -428,8 +486,11 @@ export class NotebookShell extends Widget implements JupyterFrontEnd.IShell {
private _spacer_bottom: Widget;
private _skipLinkWidgetHandler: Private.SkipLinkWidgetHandler;
private _main: Panel;
private _downPanel: TabPanel;
private _translator: ITranslator = nullTranslator;
private _currentChanged = new Signal<this, void>(this);
private _currentChanged = new Signal<this, FocusTracker.IChangedArgs<Widget>>(
this
);
private _mainWidgetLoaded = new PromiseDelegate<void>();
private _userLayout: INotebookShell.IUserLayout;
}

@ -10,18 +10,23 @@
--jp-notebook-max-width: 1200px;
}
body {
/*
Override the default background
See https://github.com/jupyterlab/jupyterlab/pull/16519 for more information
*/
body.jp-ThemedContainer {
margin: 0;
padding: 0;
background: var(--jp-layout-color2);
}
#main {
#main.jp-ThemedContainer {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: var(--jp-layout-color2);
}
#top-panel-wrapper {

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/console-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Console Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,15 +38,15 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/console": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@lumino/algorithm": "^2.0.1"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/console": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@lumino/algorithm": "^2.0.4"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -25,6 +25,7 @@ const opener: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/console-extension:opener',
requires: [IRouter],
autoStart: true,
description: 'A plugin to open consoles in a new tab',
activate: (app: JupyterFrontEnd, router: IRouter) => {
const { commands } = app;
const consolePattern = new RegExp('/consoles/(.*)');
@ -59,6 +60,7 @@ const redirect: JupyterFrontEndPlugin<void> = {
requires: [IConsoleTracker],
optional: [INotebookPathOpener],
autoStart: true,
description: 'Open consoles in a new tab',
activate: (
app: JupyterFrontEnd,
tracker: IConsoleTracker,

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/docmanager-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Document Manager Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,18 +38,18 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/docmanager": "^4.0.7",
"@jupyterlab/docregistry": "^4.0.7",
"@jupyterlab/services": "^7.0.7",
"@lumino/algorithm": "^2.0.1",
"@lumino/signaling": "^2.1.2"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/docmanager": "~4.6.0-alpha.0",
"@jupyterlab/docregistry": "~4.6.0-alpha.0",
"@jupyterlab/services": "~7.6.0-alpha.0",
"@lumino/algorithm": "^2.0.4",
"@lumino/signaling": "^2.1.5"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -29,6 +29,7 @@ const opener: JupyterFrontEndPlugin<IDocumentWidgetOpener> = {
autoStart: true,
optional: [INotebookPathOpener, INotebookShell],
provides: IDocumentWidgetOpener,
description: 'Open documents in a new browser tab',
activate: (
app: JupyterFrontEnd,
notebookPathOpener: INotebookPathOpener,
@ -39,7 +40,10 @@ const opener: JupyterFrontEndPlugin<IDocumentWidgetOpener> = {
const pathOpener = notebookPathOpener ?? defaultNotebookPathOpener;
let id = 0;
return new (class {
open(widget: IDocumentWidget, options?: DocumentRegistry.IOpenOptions) {
async open(
widget: IDocumentWidget,
options?: DocumentRegistry.IOpenOptions
) {
const widgetName = options?.type ?? '';
const ref = options?.ref;
// check if there is an setting override and if it would add the widget in the main area
@ -53,6 +57,11 @@ const opener: JupyterFrontEndPlugin<IDocumentWidgetOpener> = {
(widgetName === 'default' && ext === '.ipynb') ||
widgetName.includes('Notebook')
) {
// make sure to save the notebook before opening it in a new tab
// so the kernel info is saved (if created from the New dropdown)
if (widget.context.sessionContext.kernelPreference.name) {
await widget.context.save();
}
route = 'notebooks';
}
// append ?factory only if it's not the default

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/documentsearch-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Document Search Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,14 +38,14 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/documentsearch": "^4.0.7",
"@lumino/widgets": "^2.3.0"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/documentsearch": "~4.6.0-alpha.0",
"@lumino/widgets": "^2.7.2"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -18,6 +18,7 @@ const notebookShellWidgetListener: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/documentsearch-extension:notebookShellWidgetListener',
requires: [INotebookShell, ISearchProviderRegistry],
autoStart: true,
description: 'A plugin to add document search functionalities',
activate: (
app: JupyterFrontEnd,
notebookShell: INotebookShell,

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/help-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Help Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,17 +38,17 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/ui-components": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/apputils": "^4.1.7",
"@jupyterlab/mainmenu": "^4.0.7",
"@jupyterlab/translation": "^4.0.7",
"@jupyter-notebook/ui-components": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/mainmenu": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -49,6 +49,7 @@ namespace CommandIDs {
const open: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/help-extension:open',
autoStart: true,
description: 'A plugin to open the about section with resources',
activate: (app: JupyterFrontEnd): void => {
const { commands } = app;
@ -70,6 +71,8 @@ const about: JupyterFrontEndPlugin<void> = {
autoStart: true,
requires: [ITranslator],
optional: [IMainMenu, ICommandPalette],
description:
'Plugin to add a command to show an About Jupyter Notebook and Markdown Reference',
activate: (
app: JupyterFrontEnd,
translator: ITranslator,

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/lab-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Lab Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -43,21 +43,21 @@
"watch:src": "tsc -w"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/apputils": "^4.1.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/docregistry": "^4.0.7",
"@jupyterlab/notebook": "^4.0.7",
"@jupyterlab/translation": "^4.0.7",
"@jupyterlab/ui-components": "^4.0.7",
"@lumino/commands": "^2.1.3",
"@lumino/disposable": "^2.1.2"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/docregistry": "~4.6.0-alpha.0",
"@jupyterlab/notebook": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"@jupyterlab/ui-components": "~4.6.0-alpha.0",
"@lumino/commands": "^2.3.3",
"@lumino/disposable": "^2.1.5"
},
"devDependencies": {
"@jupyterlab/builder": "^4.0.7",
"@jupyterlab/builder": "~4.6.0-alpha.0",
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -67,9 +67,11 @@ interface ISwitcherChoice {
*/
const interfaceSwitcher: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/lab-extension:interface-switcher',
description: 'A plugin to add custom toolbar items to the notebook page.',
autoStart: true,
requires: [ITranslator, INotebookTracker],
requires: [ITranslator],
optional: [
INotebookTracker,
ICommandPalette,
INotebookPathOpener,
INotebookShell,
@ -79,13 +81,18 @@ const interfaceSwitcher: JupyterFrontEndPlugin<void> = {
activate: (
app: JupyterFrontEnd,
translator: ITranslator,
notebookTracker: INotebookTracker,
notebookTracker: INotebookTracker | null,
palette: ICommandPalette | null,
notebookPathOpener: INotebookPathOpener | null,
notebookShell: INotebookShell | null,
labShell: ILabShell | null,
toolbarRegistry: IToolbarWidgetRegistry | null
) => {
if (!notebookTracker) {
// bail if trying to use this plugin without a notebook tracker
return;
}
const { commands, shell } = app;
const baseUrl = PageConfig.getBaseUrl();
const trans = translator.load('notebook');
@ -218,6 +225,7 @@ const interfaceSwitcher: JupyterFrontEndPlugin<void> = {
*/
const launchNotebookTree: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/lab-extension:launch-tree',
description: 'A plugin to add a command to open the Jupyter Notebook Tree.',
autoStart: true,
requires: [ITranslator],
optional: [ICommandPalette],

@ -14,12 +14,10 @@
vertical-align: sub;
}
.jp-nb-interface-switcher-button > .jp-ToolbarButtonComponent {
.jp-nb-interface-switcher-button > .jp-ToolbarButtonComponent::part(content) {
flex-direction: row-reverse;
}
.jp-nb-interface-switcher-button
> .jp-ToolbarButtonComponent
> .jp-ToolbarButtonComponent-icon {
.jp-nb-interface-switcher-button > .jp-ToolbarButtonComponent > svg {
padding-left: 3px;
}

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/notebook-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Notebook Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,22 +38,22 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/apputils": "^4.1.7",
"@jupyterlab/cells": "^4.0.7",
"@jupyterlab/docmanager": "^4.0.7",
"@jupyterlab/notebook": "^4.0.7",
"@jupyterlab/settingregistry": "^4.0.7",
"@jupyterlab/translation": "^4.0.7",
"@lumino/polling": "^2.1.2",
"@lumino/widgets": "^2.3.0",
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/cells": "~4.6.0-alpha.0",
"@jupyterlab/docmanager": "~4.6.0-alpha.0",
"@jupyterlab/notebook": "~4.6.0-alpha.0",
"@jupyterlab/settingregistry": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"@lumino/polling": "^2.1.5",
"@lumino/widgets": "^2.7.2",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -4,7 +4,15 @@
"jupyter.lab.toolbars": {
"TopBar": [{ "name": "checkpoint", "rank": 20 }]
},
"properties": {},
"properties": {
"checkpointPollingInterval": {
"type": "number",
"title": "Checkpoint Polling Interval (seconds)",
"description": "How often to check for checkpoints (in seconds). Set to 0 to disable polling.",
"default": 30,
"minimum": 0
}
},
"additionalProperties": false,
"type": "object"
}

@ -0,0 +1,37 @@
{
"title": "Jupyter Notebook Menu Entries",
"description": "Jupyter Notebook Menu Entries",
"jupyter.lab.menus": {
"main": [
{
"id": "jp-mainmenu-file",
"items": [
{
"command": "notebook:open-tree-tab",
"rank": 1
}
]
},
{
"id": "jp-mainmenu-edit",
"items": [
{
"type": "separator",
"rank": 8.5
},
{
"command": "notebook:edit-metadata",
"rank": 8.5
},
{
"type": "separator",
"rank": 8.5
}
]
}
]
},
"properties": {},
"additionalProperties": false,
"type": "object"
}

@ -0,0 +1,27 @@
{
"title": "Jupyter Notebook Full Width Notebook",
"description": "Jupyter Notebook Notebook With settings",
"jupyter.lab.menus": {
"main": [
{
"id": "jp-mainmenu-view",
"items": [
{
"command": "notebook:toggle-full-width",
"rank": 4
}
]
}
]
},
"properties": {
"fullWidthNotebook": {
"type": "boolean",
"title": "Full Width Notebook",
"description": "Whether to the notebook should take up the full width of the application",
"default": false
}
},
"additionalProperties": false,
"type": "object"
}

@ -10,6 +10,7 @@ import {
ISessionContext,
DOMUtils,
IToolbarWidgetRegistry,
ICommandPalette,
} from '@jupyterlab/apputils';
import { Cell, CodeCell } from '@jupyterlab/cells';
@ -18,6 +19,8 @@ import { PageConfig, Text, Time, URLExt } from '@jupyterlab/coreutils';
import { IDocumentManager } from '@jupyterlab/docmanager';
import { DocumentRegistry } from '@jupyterlab/docregistry';
import { IMainMenu } from '@jupyterlab/mainmenu';
import {
@ -63,20 +66,42 @@ const KERNEL_STATUS_FADE_OUT_CLASS = 'jp-NotebookKernelStatus-fade';
*/
const SCROLLED_OUTPUTS_CLASS = 'jp-mod-outputsScrolled';
/**
* The class for the full width notebook
*/
const FULL_WIDTH_NOTEBOOK_CLASS = 'jp-mod-fullwidth';
/**
* The command IDs used by the notebook plugins.
*/
namespace CommandIDs {
/**
* A command to open right sidebar for Editing Notebook Metadata
*/
export const openEditNotebookMetadata = 'notebook:edit-metadata';
/**
* A command to toggle full width of the notebook
*/
export const toggleFullWidth = 'notebook:toggle-full-width';
}
/**
* A plugin for the checkpoint indicator
*/
const checkpoints: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:checkpoints',
description: 'A plugin for the checkpoint indicator.',
autoStart: true,
requires: [IDocumentManager, ITranslator],
optional: [INotebookShell, IToolbarWidgetRegistry],
optional: [INotebookShell, IToolbarWidgetRegistry, ISettingRegistry],
activate: (
app: JupyterFrontEnd,
docManager: IDocumentManager,
translator: ITranslator,
notebookShell: INotebookShell | null,
toolbarRegistry: IToolbarWidgetRegistry | null
toolbarRegistry: IToolbarWidgetRegistry | null,
settingRegistry: ISettingRegistry | null
) => {
const { shell } = app;
const trans = translator.load('notebook');
@ -91,18 +116,26 @@ const checkpoints: JupyterFrontEndPlugin<void> = {
});
}
const onChange = async () => {
const getCurrent = () => {
const current = shell.currentWidget;
if (!current) {
return;
return null;
}
const context = docManager.contextForWidget(current);
if (!context) {
return null;
}
return context;
};
context?.fileChanged.disconnect(onChange);
context?.fileChanged.connect(onChange);
const checkpoints = await context?.listCheckpoints();
if (!checkpoints) {
const updateCheckpointDisplay = async () => {
const current = getCurrent();
if (!current) {
return;
}
const checkpoints = await current.listCheckpoints();
if (!checkpoints || !checkpoints.length) {
node.textContent = '';
return;
}
const checkpoint = checkpoints[checkpoints.length - 1];
@ -112,19 +145,80 @@ const checkpoints: JupyterFrontEndPlugin<void> = {
);
};
const onSaveState = async (
sender: DocumentRegistry.IContext<DocumentRegistry.IModel>,
state: DocumentRegistry.SaveState
) => {
if (state !== 'completed') {
return;
}
// Add a small artificial delay so that the UI can pick up the newly created checkpoint.
// Since the save state signal is emitted after a file save, but not after a checkpoint has been created.
setTimeout(() => {
void updateCheckpointDisplay();
}, 500);
};
const onChange = async () => {
const context = getCurrent();
if (!context) {
return;
}
context.saveState.disconnect(onSaveState);
context.saveState.connect(onSaveState);
await updateCheckpointDisplay();
};
if (notebookShell) {
notebookShell.currentChanged.connect(onChange);
}
new Poll({
auto: true,
factory: () => onChange(),
frequency: {
interval: 2000,
backoff: false,
},
standby: 'when-hidden',
});
let checkpointPollingInterval = 30; // Default 30 seconds
let poll: Poll | null = null;
const createPoll = () => {
if (poll) {
poll.dispose();
}
if (checkpointPollingInterval > 0) {
poll = new Poll({
auto: true,
factory: () => updateCheckpointDisplay(),
frequency: {
interval: checkpointPollingInterval * 1000,
backoff: false,
},
standby: 'when-hidden',
});
}
};
const updateSettings = (settings: ISettingRegistry.ISettings): void => {
checkpointPollingInterval = settings.get('checkpointPollingInterval')
.composite as number;
createPoll();
};
if (settingRegistry) {
const loadSettings = settingRegistry.load(checkpoints.id);
Promise.all([loadSettings, app.restored])
.then(([settings]) => {
updateSettings(settings);
settings.changed.connect(updateSettings);
})
.catch((reason: Error) => {
console.error(
`Failed to load settings for ${checkpoints.id}: ${reason.message}`
);
// Fall back to creating poll with default settings
createPoll();
});
} else {
// Create poll with default settings
createPoll();
}
},
};
@ -133,6 +227,8 @@ const checkpoints: JupyterFrontEndPlugin<void> = {
*/
const closeTab: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:close-tab',
description:
'Add a command to close the browser tab when clicking on "Close and Shut Down".',
autoStart: true,
requires: [IMainMenu],
optional: [ITranslator],
@ -149,7 +245,8 @@ const closeTab: JupyterFrontEndPlugin<void> = {
commands.addCommand(id, {
label: trans.__('Close and Shut Down Notebook'),
execute: async () => {
await commands.execute('notebook:close-and-shutdown');
// Shut the kernel down, without confirmation
await commands.execute('notebook:shutdown-kernel', { activate: false });
window.close();
},
});
@ -162,11 +259,114 @@ const closeTab: JupyterFrontEndPlugin<void> = {
},
};
/**
* Add a command to open the tree view from the notebook view
*/
const openTreeTab: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:open-tree-tab',
description:
'Add a command to open a browser tab on the tree view when clicking "Open...".',
autoStart: true,
optional: [ITranslator],
activate: (app: JupyterFrontEnd, translator: ITranslator | null) => {
const { commands } = app;
translator = translator ?? nullTranslator;
const trans = translator.load('notebook');
const id = 'notebook:open-tree-tab';
commands.addCommand(id, {
label: trans.__('Open…'),
execute: async () => {
const url = URLExt.join(PageConfig.getBaseUrl(), 'tree');
window.open(url);
},
});
},
};
/**
* A plugin to set the notebook to full width.
*/
const fullWidthNotebook: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:full-width-notebook',
description: 'A plugin to set the notebook to full width.',
autoStart: true,
requires: [INotebookTracker],
optional: [ICommandPalette, ISettingRegistry, ITranslator],
activate: (
app: JupyterFrontEnd,
tracker: INotebookTracker,
palette: ICommandPalette | null,
settingRegistry: ISettingRegistry | null,
translator: ITranslator | null
) => {
const trans = (translator ?? nullTranslator).load('notebook');
let fullWidth = false;
const toggleFullWidth = () => {
const current = tracker.currentWidget;
fullWidth = !fullWidth;
if (!current) {
return;
}
const content = current;
content.toggleClass(FULL_WIDTH_NOTEBOOK_CLASS, fullWidth);
};
let notebookSettings: ISettingRegistry.ISettings;
if (settingRegistry) {
const loadSettings = settingRegistry.load(fullWidthNotebook.id);
const updateSettings = (settings: ISettingRegistry.ISettings): void => {
const newFullWidth = settings.get('fullWidthNotebook')
.composite as boolean;
if (newFullWidth !== fullWidth) {
toggleFullWidth();
}
};
Promise.all([loadSettings, app.restored])
.then(([settings]) => {
notebookSettings = settings;
updateSettings(settings);
settings.changed.connect((settings) => {
updateSettings(settings);
});
})
.catch((reason: Error) => {
console.error(reason.message);
});
}
app.commands.addCommand(CommandIDs.toggleFullWidth, {
label: trans.__('Enable Full Width Notebook'),
execute: () => {
toggleFullWidth();
if (notebookSettings) {
notebookSettings.set('fullWidthNotebook', fullWidth);
}
},
isEnabled: () => tracker.currentWidget !== null,
isToggled: () => fullWidth,
});
if (palette) {
palette.addItem({
command: CommandIDs.toggleFullWidth,
category: 'Notebook Operations',
});
}
},
};
/**
* The kernel logo plugin.
*/
const kernelLogo: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:kernel-logo',
description: 'The kernel logo plugin.',
autoStart: true,
requires: [INotebookShell],
optional: [IToolbarWidgetRegistry],
@ -230,6 +430,7 @@ const kernelLogo: JupyterFrontEndPlugin<void> = {
*/
const kernelStatus: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:kernel-status',
description: 'A plugin to display the kernel status.',
autoStart: true,
requires: [INotebookShell, ITranslator],
activate: (
@ -294,6 +495,7 @@ const kernelStatus: JupyterFrontEndPlugin<void> = {
*/
const scrollOutput: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:scroll-output',
description: 'A plugin to enable scrolling for outputs by default.',
autoStart: true,
requires: [INotebookTracker],
optional: [ISettingRegistry],
@ -309,6 +511,7 @@ const scrollOutput: JupyterFrontEndPlugin<void> = {
const autoScroll = (cell: CodeCell) => {
if (!autoScrollOutputs) {
// bail if disabled via the settings
cell.removeClass(SCROLLED_OUTPUTS_CLASS);
return;
}
const { outputArea } = cell;
@ -379,6 +582,7 @@ const scrollOutput: JupyterFrontEndPlugin<void> = {
*/
const notebookToolsWidget: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:notebook-tools',
description: 'A plugin to add the NotebookTools to the side panel.',
autoStart: true,
requires: [INotebookShell],
optional: [INotebookTools],
@ -407,6 +611,7 @@ const notebookToolsWidget: JupyterFrontEndPlugin<void> = {
*/
const tabIcon: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:tab-icon',
description: 'A plugin to update the tab icon based on the kernel status.',
autoStart: true,
requires: [INotebookTracker],
activate: (app: JupyterFrontEnd, tracker: INotebookTracker) => {
@ -456,6 +661,7 @@ const tabIcon: JupyterFrontEndPlugin<void> = {
*/
const trusted: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:trusted',
description: 'A plugin that adds a Trusted indicator to the menu area.',
autoStart: true,
requires: [INotebookShell, ITranslator],
activate: (
@ -482,12 +688,76 @@ const trusted: JupyterFrontEndPlugin<void> = {
},
};
/**
* Add a command to open right sidebar for Editing Notebook Metadata when clicking on "Edit Notebook Metadata" under Edit menu
*/
const editNotebookMetadata: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/notebook-extension:edit-notebook-metadata',
description:
'Add a command to open right sidebar for Editing Notebook Metadata when clicking on "Edit Notebook Metadata" under Edit menu',
autoStart: true,
optional: [ICommandPalette, ITranslator, INotebookTools],
activate: (
app: JupyterFrontEnd,
palette: ICommandPalette | null,
translator: ITranslator | null,
notebookTools: INotebookTools | null
) => {
const { commands, shell } = app;
translator = translator ?? nullTranslator;
const trans = translator.load('notebook');
commands.addCommand(CommandIDs.openEditNotebookMetadata, {
label: trans.__('Edit Notebook Metadata'),
execute: async () => {
const command = 'application:toggle-panel';
const args = {
side: 'right',
title: 'Show Notebook Tools',
id: 'notebook-tools',
};
// Check if Show Notebook Tools (Right Sidebar) is open (expanded)
if (!commands.isToggled(command, args)) {
await commands.execute(command, args).then((_) => {
// For expanding the 'Advanced Tools' section (default: collapsed)
if (notebookTools) {
const tools = (notebookTools?.layout as any).widgets;
tools.forEach((tool: any) => {
if (
tool.widget.title.label === trans.__('Advanced Tools') &&
tool.collapsed
) {
tool.toggle();
}
});
}
});
}
},
isVisible: () =>
shell.currentWidget !== null &&
shell.currentWidget instanceof NotebookPanel,
});
if (palette) {
palette.addItem({
command: CommandIDs.openEditNotebookMetadata,
category: 'Notebook Operations',
});
}
},
};
/**
* Export the plugins as default.
*/
const plugins: JupyterFrontEndPlugin<any>[] = [
checkpoints,
closeTab,
openTreeTab,
editNotebookMetadata,
fullWidthNotebook,
kernelLogo,
kernelStatus,
notebookToolsWidget,

@ -16,6 +16,16 @@
- compact view on mobile
*/
/* Make the notebook take up the full width of the page when jp-mod-fullwidth is set */
body[data-notebook='notebooks']
.jp-NotebookPanel.jp-mod-fullwidth
.jp-WindowedPanel-outer {
padding-left: unset;
padding-right: unset !important;
width: unset;
}
/* Keep the notebook centered on the page */
body[data-notebook='notebooks'] .jp-NotebookPanel-toolbar {
@ -23,35 +33,38 @@ body[data-notebook='notebooks'] .jp-NotebookPanel-toolbar {
padding-right: calc(calc(100% - var(--jp-notebook-max-width)) * 0.5);
}
body[data-notebook='notebooks'] .jp-Notebook {
body[data-notebook='notebooks'] .jp-WindowedPanel-outer {
width: unset !important;
padding-top: unset;
padding-left: calc(calc(100% - var(--jp-notebook-max-width)) * 0.5);
padding-right: calc(
calc(
100% - var(--jp-notebook-max-width) - var(--jp-notebook-padding-offset)
) * 0.5
);
) !important;
background: var(--jp-layout-color2);
}
body[data-notebook='notebooks'] .jp-WindowedPanel-inner {
margin-top: var(--jp-notebook-toolbar-margin-bottom);
/* Adjustments for the extra top and bottom notebook padding */
margin-bottom: calc(4 * var(--jp-notebook-padding));
}
body[data-notebook='notebooks'] .jp-Notebook-cell {
background: var(--jp-layout-color0);
padding-left: calc(2 * var(--jp-cell-padding));
padding-right: calc(2 * var(--jp-cell-padding));
}
/* Empty space at the bottom of the notebook (similar to classic) */
body[data-notebook='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
body[data-notebook='notebooks']
.jp-Notebook.jp-mod-scrollPastEnd
.jp-WindowedPanel-outer::after {
min-height: 100px;
}
/* Fix background colors */
body[data-notebook='notebooks'] .jp-Notebook > * {
body[data-notebook='notebooks'] .jp-WindowedPanel-outer > * {
background: var(--jp-layout-color0);
}
@ -61,18 +74,6 @@ body[data-notebook='notebooks']
background: var(--jp-layout-color0) !important;
}
/**
Extra padding to the first and and last cell of the notebook.
TODO: revisit when https://github.com/jupyterlab/jupyterlab/issues/13151 is fixed
*/
.jp-Notebook-cell[data-windowed-list-index='0'] {
padding-top: calc(2 * var(--jp-notebook-padding));
}
body[data-notebook='notebooks'] .jp-WindowedPanel-window > *:last-child {
padding-bottom: calc(2 * var(--jp-notebook-padding));
}
body[data-notebook='notebooks']
.jp-Notebook
.jp-Notebook-cell:not(:first-child)::before {
@ -90,15 +91,6 @@ body[data-notebook='notebooks'] .jp-cell-toolbar {
box-shadow: unset;
}
body[data-notebook='notebooks']
.jp-RawCell[data-windowed-list-index='0']
.jp-cell-toolbar,
body[data-notebook='notebooks']
.jp-MarkdownCell[data-windowed-list-index='0']
.jp-cell-toolbar {
top: calc(2 * var(--jp-notebook-padding));
}
/** first code cell on mobile
(keep the selector above the media query)
*/
@ -124,9 +116,9 @@ body[data-notebook='notebooks']
/* Tweak the notebook footer (to add a new cell) */
body[data-notebook='notebooks'] .jp-Notebook-footer {
background: unset;
width: 100%;
margin-left: unset;
background: unset;
}
/* Mobile View */
@ -135,7 +127,7 @@ body[data-format='mobile'] .jp-NotebookCheckpoint {
display: none;
}
body[data-format='mobile'] .jp-Notebook > *:first-child {
body[data-format='mobile'] .jp-WindowedPanel-outer > *:first-child {
margin-top: 0;
}
@ -143,18 +135,17 @@ body[data-format='mobile'] .jp-ToolbarButton .jp-DebuggerBugButton {
display: none;
}
/* Virtual Notebook fixes */
body[data-notebook='notebooks'] .jp-WindowedPanel-window {
body[data-notebook='notebooks'] .jp-WindowedPanel-viewport {
background: var(--jp-layout-color0);
box-shadow: var(--jp-elevation-z4);
/* Extra padding at the top and bottom so the notebook looks nicer */
padding-top: calc(2 * var(--jp-notebook-padding));
padding-bottom: calc(2 * var(--jp-notebook-padding));
}
/* Notebook box shadow */
body[data-notebook='notebooks'] .jp-Notebook > *:first-child:not(:last-child) {
box-shadow: var(--jp-elevation-z4);
}
body[data-notebook='notebooks']
.jp-Notebook
> *:first-child:last-child::before {
@ -167,19 +158,6 @@ body[data-notebook='notebooks']
box-shadow: 0px 0px 12px 1px var(--jp-shadow-umbra-color);
}
body[data-notebook='notebooks']
.jp-Notebook
.jp-Notebook-cell:not(:first-child)::after,
body[data-notebook='notebooks']
.jp-Notebook
.jp-Notebook-cell:not(:first-child)::before {
content: ' ';
height: 100%;
position: absolute;
top: 0;
width: 11px;
}
/* Additional customizations of the components on the notebook page */
.jp-NotebookKernelLogo {

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/terminal-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Terminal Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,15 +38,15 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/terminal": "^4.0.7",
"@lumino/algorithm": "^2.0.1"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/terminal": "~4.6.0-alpha.0",
"@lumino/algorithm": "^2.0.4"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

@ -23,6 +23,7 @@ import { find } from '@lumino/algorithm';
*/
const opener: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/terminal-extension:opener',
description: 'A plugin to open terminals in a new tab.',
requires: [IRouter, ITerminalTracker],
autoStart: true,
activate: (
@ -62,6 +63,7 @@ const opener: JupyterFrontEndPlugin<void> = {
*/
const redirect: JupyterFrontEndPlugin<void> = {
id: '@jupyter-notebook/terminal-extension:redirect',
description: 'Open terminals in a new tab.',
requires: [ITerminalTracker],
optional: [INotebookPathOpener],
autoStart: true,

@ -1,6 +1,6 @@
{
"name": "@jupyter-notebook/tree-extension",
"version": "7.0.6",
"version": "7.6.0-alpha.0",
"description": "Jupyter Notebook - Tree Extension",
"homepage": "https://github.com/jupyter/notebook",
"bugs": {
@ -38,27 +38,27 @@
"watch": "tsc -b --watch"
},
"dependencies": {
"@jupyter-notebook/application": "^7.0.6",
"@jupyter-notebook/tree": "^7.0.6",
"@jupyterlab/application": "^4.0.7",
"@jupyterlab/apputils": "^4.1.7",
"@jupyterlab/coreutils": "^6.0.7",
"@jupyterlab/docmanager": "^4.0.7",
"@jupyterlab/filebrowser": "^4.0.7",
"@jupyterlab/mainmenu": "^4.0.7",
"@jupyterlab/services": "^7.0.7",
"@jupyterlab/settingeditor": "^4.0.7",
"@jupyterlab/settingregistry": "^4.0.7",
"@jupyterlab/statedb": "^4.0.7",
"@jupyterlab/translation": "^4.0.7",
"@jupyterlab/ui-components": "^4.0.7",
"@lumino/algorithm": "^2.0.1",
"@lumino/commands": "^2.1.3",
"@lumino/widgets": "^2.3.0"
"@jupyter-notebook/application": "^7.6.0-alpha.0",
"@jupyter-notebook/tree": "^7.6.0-alpha.0",
"@jupyterlab/application": "~4.6.0-alpha.0",
"@jupyterlab/apputils": "~4.7.0-alpha.0",
"@jupyterlab/coreutils": "~6.6.0-alpha.0",
"@jupyterlab/docmanager": "~4.6.0-alpha.0",
"@jupyterlab/filebrowser": "~4.6.0-alpha.0",
"@jupyterlab/mainmenu": "~4.6.0-alpha.0",
"@jupyterlab/services": "~7.6.0-alpha.0",
"@jupyterlab/settingeditor": "~4.6.0-alpha.0",
"@jupyterlab/settingregistry": "~4.6.0-alpha.0",
"@jupyterlab/statedb": "~4.6.0-alpha.0",
"@jupyterlab/translation": "~4.6.0-alpha.0",
"@jupyterlab/ui-components": "~4.6.0-alpha.0",
"@lumino/algorithm": "^2.0.4",
"@lumino/commands": "^2.3.3",
"@lumino/widgets": "^2.7.2"
},
"devDependencies": {
"rimraf": "^3.0.2",
"typescript": "~5.0.2"
"typescript": "~5.5.4"
},
"publishConfig": {
"access": "public"

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save