Package: jupyterlab-lavender
jupyterlab_lavenderlavender, in files jupyterlab_lavender, is a JupyterLab theme extension
with a dark background, high contrast and low saturation. Example:See alsoherefor the similar lavender Matplotlib styles.RequirementsJupyterLab >= 4.0.0How to UseInstall the theme using one of the methods here. It should be
available to use under Settings -> Theme. Check installation
withjupyterlabextensionlistInstall with pipInstall fromPyPIwithpipinstalljupyterlab_lavenderOr build locally (requires NodeJS) withpipinstallgit+https://github.com/tinjano/jupyterlab_lavenderAlternativesClone this repository withgitclonehttps://www.github.com/tinjano/jupyterlab_lavenderIn the new folder, build (required NodeJS) withpipinstall-e.
jupyterlabextensiondevelop.--overwrite
jlpmrunbuildYou can also build your own extension, latest
template with guidehere,
then copy the filestyle/variables.css, setisLighttofalseinsrc/index.tsand build as above.UninstallingIf installed with pippip uninstall jupyterlab_lavenderElse usejupyter labextension listto find the folder with extensions.
(it could be$HOME/.local/share/jupyter/labextensions) and runrm-rfpath_to_folder/jupyterlab_lavenderHow to Make Your Own ExtensionSince this is a niche topic, I would like to share my experience.
For the latest template with a guide seehere,
then seeexampleswith their guides.
In the case of a theme extension, the most important file isstyle/variables.css.
I have had problems with updating the extension (the
expected changes would not be visible and would indeed not be built).
Oddly, the only solution that consistently worked was repeating this twice:
uninstall the extension and build as above. See alsoherefor info on packaging.IssuesThe use of CSS variables fromstyle/varibles.csscan be different
with different version of JupyterLab. Feel free to open an issue if
this happens.The rest of this README is inherited from the extension template.ContributingDevelopment installNote: You will need NodeJS to build the extension package.Thejlpmcommand is JupyterLab's pinned version ofyarnthat is installed with JupyterLab. You may useyarnornpmin lieu ofjlpmbelow.# Clone the repo to your local environment# Change directory to the lavender directory# Install package in development modepipinstall-e"."# Link your development version of the extension with JupyterLabjupyterlabextensiondevelop.--overwrite# Rebuild extension Typescript source after making changesjlpmbuildYou can watch the source directory and run JupyterLab at the same time in different terminals to watch for changes in the extension's source and automatically rebuild the extension.# Watch the source directory in one terminal, automatically rebuilding when neededjlpmwatch# Run JupyterLab in another terminaljupyterlabWith the watch command running, every saved change will immediately be built locally and available in your running JupyterLab. Refresh JupyterLab to load the change in your browser (you may need to wait several seconds for the extension to be rebuilt).By default, thejlpm buildcommand generates the source maps for this extension to make it easier to debug using the browser dev tools. To also generate source maps for the JupyterLab core extensions, you can run the following command:jupyterlabbuild--minimize=FalseDevelopment uninstallpipuninstalllavenderIn development mode, you will also need to remove the symlink created byjupyter labextension developcommand. To find its location, you can runjupyter labextension listto figure out where thelabextensionsfolder is located. Then you can remove the symlink namedlavenderwithin that folder.Testing the extensionFrontend testsThis extension is usingJestfor JavaScript code testing.To execute them, execute:jlpm
jlpmtestIntegration testsThis extension usesPlaywrightfor the integration tests (aka user level tests).
More precisely, the JupyterLab helperGalatais used to handle testing the extension in JupyterLab.More information are provided within theui-testsREADME.Packaging the extensionSeeRELEASE