5

What is the easiest way to create a custom css (global to all documents) for the Jupyter Lab (Installed via anaconda)?

2 Answers 2

4

JupyterLab uses themes which are extensions. These themes have CSS rules. There's no "official" way to have custom CSS in JupyterLab the same way as Notebook had (custom.css file in ~/.jupyter/custom directory).

Because of the above I've developed an extension where you can place custom (global) CSS rules in the settings editor: https://github.com/wallneradam/jupyterlab-custom-css

Sign up to request clarification or add additional context in comments.

1 Comment

This unfortunately uses an deprecated installation procedure and you have to install Node.js first.
2

You can edit the index.css for one enviroment. It should be in:

~/anaconda3/envs/[ENVIRONMENT NAME]/share/jupyter/lab/@jupyterlab/theme-dark-extension/index.css 

for the dark theme or in:

~/anaconda3/envs/[ENVIRONMENT NAME]/share/jupyter/lab/@jupyterlab/theme-light-extension/index.css 

for the light theme.

2 Comments

I did not manage to change the index.css. - I want to change the style of the header in the markdown cell how do I do that (where and what to put in the index.css file). Do you know about an example for that ?
Is there a way to set a global css for all environments?

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.