-
Notifications
You must be signed in to change notification settings - Fork 1
/
variables.css
467 lines (391 loc) · 16.7 KB
/
variables.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
/*-----------------------------------------------------------------------------
| Gruvbox retro groove colorscheme for JupyterLab
| https://github.com/morhetz/gruvbox
|
| Copyright (c) Jupyter Development Team.
| Distributed under the terms of the Modified BSD License.
|----------------------------------------------------------------------------*/
/*
The following CSS variables define the main, public API for styling JupyterLab.
These variables should be used by all plugins wherever possible. In other
words, plugins should not define custom colors, sizes, etc unless absolutely
necessary. This enables users to change the visual theme of JupyterLab
by changing these variables.
Many variables appear in an ordered sequence (0,1,2,3). These sequences
are designed to work well together, so for example, `--jp-border-color1` should
be used with `--jp-layout-color1`. The numbers have the following meanings:
* 0: super-primary, reserved for special emphasis
* 1: primary, most important under normal situations
* 2: secondary, next most important under normal situations
* 3: tertiary, next most important under normal situations
Throughout JupyterLab, we are mostly following principles from Google's
Material Design when selecting colors. We are not, however, following
all of MD as it is not optimized for dense, information rich UIs.
*/
:root {
--gruvbox-dark0 : #282828;
--gruvbox-dark0_hard : #1d2021;
--gruvbox-dark0_soft : #32302f;
--gruvbox-dark1 : #3c3836;
--gruvbox-dark2 : #504945;
--gruvbox-dark3 : #665c54;
--gruvbox-dark4 : #7c6f64;
--gruvbox-light0 : #fbf1c7;
--gruvbox-light0_hard : #f9f5d7;
--gruvbox-light0_soft : #f2e5bc;
--gruvbox-light1 : #ebdbb2;
--gruvbox-light2 : #d5c4a1;
--gruvbox-light3 : #bdae93;
--gruvbox-light4 : #a89984;
/* choosing the contrast */
--gruvbox-bg : var(--gruvbox-dark0);
--gruvbox-fg : var(--gruvbox-light0_soft);
--gruvbox-gray : #928374;
--gruvbox-red : #cc241d;
--gruvbox-light-red : #fb4934;
--gruvbox-faded-red : #9d0006;
--gruvbox-green : #98971a;
--gruvbox-light-green : #b8bb26;
--gruvbox-faded-green : #79740e;
--gruvbox-yellow : #d79921;
--gruvbox-light-yellow : #fabd2f;
--gruvbox-faded-yellow : #b57614;
--gruvbox-blue : #458588;
--gruvbox-light-blue : #83a598;
--gruvbox-faded-blue : #076678;
--gruvbox-purple : #b16286;
--gruvbox-light-purple : #d3869b;
--gruvbox-faded-purple : #8f3f71;
--gruvbox-aqua : #689d6a;
--gruvbox-light-aqua : #8ec07c;
--gruvbox-faded-aqua : #427b58;
--gruvbox-orange : #d65d0e;
--gruvbox-light-orange : #fe8019;
--gruvbox-faded-orange : #af3a03;
/* Elevation
*
* We style box-shadows using Material Design's idea of elevation. These particular numbers are taken from here:
*
* https://github.com/material-components/material-components-web
* https://material-components-web.appspot.com/elevation.html
*/
/* The dark theme shadows need a bit of work, but this will probably also require work on the core layout
* colors used in the theme as well. */
--jp-shadow-base-lightness: 32;
--jp-shadow-umbra-color: rgba(
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
0.2
);
--jp-shadow-penumbra-color: rgba(
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
0.14
);
--jp-shadow-ambient-color: rgba(
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
var(--jp-shadow-base-lightness),
0.12
);
--jp-elevation-z0: none;
--jp-elevation-z1: 0px 2px 1px -1px var(--jp-shadow-umbra-color),
0px 1px 1px 0px var(--jp-shadow-penumbra-color),
0px 1px 3px 0px var(--jp-shadow-ambient-color);
--jp-elevation-z2: 0px 3px 1px -2px var(--jp-shadow-umbra-color),
0px 2px 2px 0px var(--jp-shadow-penumbra-color),
0px 1px 5px 0px var(--jp-shadow-ambient-color);
--jp-elevation-z4: 0px 2px 4px -1px var(--jp-shadow-umbra-color),
0px 4px 5px 0px var(--jp-shadow-penumbra-color),
0px 1px 10px 0px var(--jp-shadow-ambient-color);
--jp-elevation-z6: 0px 3px 5px -1px var(--jp-shadow-umbra-color),
0px 6px 10px 0px var(--jp-shadow-penumbra-color),
0px 1px 18px 0px var(--jp-shadow-ambient-color);
--jp-elevation-z8: 0px 5px 5px -3px var(--jp-shadow-umbra-color),
0px 8px 10px 1px var(--jp-shadow-penumbra-color),
0px 3px 14px 2px var(--jp-shadow-ambient-color);
--jp-elevation-z12: 0px 7px 8px -4px var(--jp-shadow-umbra-color),
0px 12px 17px 2px var(--jp-shadow-penumbra-color),
0px 5px 22px 4px var(--jp-shadow-ambient-color);
--jp-elevation-z16: 0px 8px 10px -5px var(--jp-shadow-umbra-color),
0px 16px 24px 2px var(--jp-shadow-penumbra-color),
0px 6px 30px 5px var(--jp-shadow-ambient-color);
--jp-elevation-z20: 0px 10px 13px -6px var(--jp-shadow-umbra-color),
0px 20px 31px 3px var(--jp-shadow-penumbra-color),
0px 8px 38px 7px var(--jp-shadow-ambient-color);
--jp-elevation-z24: 0px 11px 15px -7px var(--jp-shadow-umbra-color),
0px 24px 38px 3px var(--jp-shadow-penumbra-color),
0px 9px 46px 8px var(--jp-shadow-ambient-color);
/* Borders
*
* The following variables, specify the visual styling of borders in JupyterLab.
*/
--jp-border-width: 1px;
--jp-border-color0: var(--gruvbox-dark4);
--jp-border-color1: var(--gruvbox-dark4);
--jp-border-color2: var(--gruvbox-dark4);
--jp-border-color3: var(--gruvbox-dark4);
--jp-border-radius: 1px;
/* UI Fonts
*
* The UI font CSS variables are used for the typography all of the JupyterLab
* user interface elements that are not directly user generated content.
*
* The font sizing here is done assuming that the body font size of --jp-ui-font-size1
* is applied to a parent element. When children elements, such as headings, are sized
* in em all things will be computed relative to that body size.
*/
--jp-ui-font-scale-factor: 1.2;
--jp-ui-font-size0: 0.83333em;
--jp-ui-font-size1: 13px; /* Base font size */
--jp-ui-font-size2: 1.2em;
--jp-ui-font-size3: 1.44em;
--jp-ui-font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica,
Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
/*
* Use these font colors against the corresponding main layout colors.
* In a light theme, these go from dark to light.
*/
/* Defaults use Material Design specification */
--jp-ui-font-color0: var(--gruvbox-fg);
--jp-ui-font-color1: var(--gruvbox-fg);
--jp-ui-font-color2: var(--gruvbox-fg);
--jp-ui-font-color3: var(--gruvbox-fg);
/*
* Use these against the brand/accent/warn/error colors.
* These will typically go from light to darker, in both a dark and light theme.
*/
--jp-ui-inverse-font-color0: rgba(0, 0, 0, 1);
--jp-ui-inverse-font-color1: rgba(0, 0, 0, 0.8);
--jp-ui-inverse-font-color2: rgba(0, 0, 0, 0.5);
--jp-ui-inverse-font-color3: rgba(0, 0, 0, 0.3);
/* Content Fonts
*
* Content font variables are used for typography of user generated content.
*
* The font sizing here is done assuming that the body font size of --jp-content-font-size1
* is applied to a parent element. When children elements, such as headings, are sized
* in em all things will be computed relative to that body size.
*/
--jp-content-line-height: 1.6;
--jp-content-font-scale-factor: 1.2;
--jp-content-font-size0: 0.83333em;
--jp-content-font-size1: 15px; /* Base font size */
--jp-content-font-size2: 1.2em;
--jp-content-font-size3: 1.44em;
--jp-content-font-size4: 1.728em;
--jp-content-font-size5: 2.0736em;
/* This gives a magnification of about 125% in presentation mode over normal. */
--jp-content-presentation-font-size1: 17px;
--jp-content-heading-line-height: 1;
--jp-content-heading-margin-top: 1.2em;
--jp-content-heading-margin-bottom: 0.8em;
--jp-content-heading-font-weight: 500;
/* Defaults use Material Design specification */
--jp-content-font-color0: rgba(255,255,255,1.0);
--jp-content-font-color1: var(--gruvbox-fg); /* this will colour all markdown and output text */
--jp-content-font-color2: rgba(255,255,255,0.7);
--jp-content-font-color3: rgba(255,255,255,0.5);
--jp-content-link-color: var(--md-blue-300);
--jp-content-font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI',
Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji',
'Segoe UI Symbol';
/*
* Code Fonts
*
* Code font variables are used for typography of code and other monospaces content.
*/
--jp-code-font-size: 16px;
--jp-code-line-height: 1.3077; /* 17px for 13px base */
--jp-code-padding: 0.385em; /* 5px for 13px base */
--jp-code-font-family: 'Ubuntu Mono', 'Source Code Pro', monospace;
/* This gives a magnification of about 125% in presentation mode over normal. */
--jp-code-presentation-font-size: 16px;
/* Layout
*
* The following are the main layout colors use in JupyterLab. In a light
* theme these would go from light to dark.
*/
--jp-layout-color0: var(--gruvbox-bg);
--jp-layout-color1: var(--gruvbox-bg);
--jp-layout-color2: var(--gruvbox-dark1); /* these are for unselected tabs amongst other things... */
--jp-layout-color3: var(--gruvbox-dark1); /* this is for the area behind the tabs of the notebooks open */
--jp-layout-color4: var(--gruvbox-dark2); /* ?? */
/* Brand/accent */
--jp-brand-color0: var(--gruvbox-faded-blue); /* selected cell colour on hover */
--jp-brand-color1: var(--gruvbox-blue); /* selected cell colour, bar to left of cell, selected file in browser */
--jp-brand-color2: var(--md-blue-300);
--jp-brand-color3: var(--md-blue-100);
--jp-accent-color0: var(--md-green-700);
--jp-accent-color1: var(--md-green-500);
--jp-accent-color2: var(--md-green-300);
--jp-accent-color3: var(--md-green-100);
/* State colors (warn, error, success, info) */
--jp-warn-color0: var(--md-orange-700);
--jp-warn-color1: var(--md-orange-500);
--jp-warn-color2: var(--md-orange-300);
--jp-warn-color3: var(--md-orange-100);
--jp-error-color0: var(--md-red-700);
--jp-error-color1: var(--md-red-500);
--jp-error-color2: var(--md-red-300);
--jp-error-color3: var(--md-red-100);
--jp-success-color0: var(--md-green-700);
--jp-success-color1: var(--md-green-500);
--jp-success-color2: var(--md-green-300);
--jp-success-color3: var(--md-green-100);
--jp-info-color0: var(--md-cyan-700);
--jp-info-color1: var(--md-cyan-500);
--jp-info-color2: var(--md-cyan-300);
--jp-info-color3: var(--md-cyan-100);
/* Cell specific styles */
--jp-cell-padding: 5px 5px 5px 0px; /* T R B L */
--jp-cell-collapser-width: 8px;
--jp-cell-collapser-min-height: 20px;
--jp-cell-collapser-not-active-hover-opacity: 0.6;
--jp-cell-editor-background: var(--gruvbox-bg); /* background colour of all cells */
--jp-cell-editor-border-color: var(--gruvbox-dark4);
--jp-cell-editor-box-shadow: inset 0 0 2px var(--gruvbox-blue);
--jp-cell-editor-active-background: var(--jp-layout-color0); /* background colour of current cell */
--jp-cell-editor-active-border-color: var(--jp-brand-color1); /* border colour of current cell */
--jp-cell-prompt-width: 90px;
--jp-cell-prompt-font-family: 'Ubuntu Mono', 'Source Code Pro', monospace;
--jp-cell-prompt-letter-spacing: 0px;
--jp-cell-prompt-opacity: 1;
--jp-cell-prompt-not-active-opacity: 0.5;
--jp-cell-prompt-not-active-font-color: var(--gruvbox-fg);
--jp-cell-inprompt-font-color: var(--jp-brand-color1);
--jp-cell-outprompt-font-color: var(--gruvbox-red);
/* Notebook specific styles */
--jp-notebook-padding: 10px 10px 10px 0px;
--jp-notebook-scroll-padding: 100px;
--jp-notebook-select-background: var(--jp-layout-color1);
--jp-notebook-multiselected-color:rgba(132,165,152,.24); /* multi select colour */
/* Rendermime styles */
--jp-rendermime-error-background: rgba(244, 67, 54, 0.28);
--jp-rendermime-table-row-background: var(--md-grey-900);
--jp-rendermime-table-row-hover-background: rgba(3, 169, 244, 0.2);
/* Dialog specific styles */
--jp-dialog-background: rgba(0, 0, 0, 0.6);
/* Console specific styles */
--jp-console-padding: 10px;
/* Toolbar specific styles */
--jp-toolbar-border-color: var(--jp-border-color2);
--jp-toolbar-micro-height: 8px;
--jp-toolbar-background: var(--jp-layout-color1);
--jp-toolbar-box-shadow: 0px 0px 2px 0px rgba(0, 0, 0, 0.8);
--jp-toolbar-header-margin: 4px 4px 0px 4px;
--jp-toolbar-active-background: var(--jp-layout-color0);
/* Input field styles */
--jp-input-box-shadow: inset 0 0 2px var(--gruvbox-blue);
--jp-input-active-background: var(--jp-layout-color0);
--jp-input-hover-background: var(--jp-layout-color2);
--jp-input-background: var(--md-grey-800);
--jp-input-border-color: var(--jp-border-color1);
--jp-input-active-border-color: var(--jp-brand-color1);
/* General editor styles */
--jp-editor-selected-background: var(--gruvbox-dark1); /* ?? */
--jp-editor-selected-focused-background: var(--gruvbox-dark1); /* ?? */
--jp-editor-cursor-color: var(--gruvbox-blue);
/* Code mirror specific styles */
--jp-mirror-editor-keyword-color: var(--gruvbox-orange);
--jp-mirror-editor-atom-color: var(--gruvbox-blue); /* ?? */
--jp-mirror-editor-number-color: var(--gruvbox-yellow);
--jp-mirror-editor-def-color: var(--gruvbox-blue);
--jp-mirror-editor-variable-color: var(--gruvbox-fg);
--jp-mirror-editor-variable-2-color: var(--gruvbox-light-purple); /* self */
--jp-mirror-editor-variable-3-color: var(--gruvbox-green); /* ?? */
--jp-mirror-editor-punctuation-color: var(--gruvbox-fg); /* ?? */
--jp-mirror-editor-property-color: var(--gruvbox-light-blue);
--jp-mirror-editor-operator-color: var(--gruvbox-purple);
--jp-mirror-editor-comment-color: var(--gruvbox-gray);
--jp-mirror-editor-string-color: var(--gruvbox-green);
--jp-mirror-editor-string-2-color: #f50;
--jp-mirror-editor-meta-color: #AA22FF;
--jp-mirror-editor-qualifier-color: #555;
--jp-mirror-editor-builtin-color: var(--gruvbox-aqua);
--jp-mirror-editor-bracket-color: var(--gruvbox-fg);
--jp-mirror-editor-tag-color: var(--md-green-700);
--jp-mirror-editor-attribute-color: var(--gruvbox-red);
--jp-mirror-editor-header-color: var(--gruvbox-blue);
--jp-mirror-editor-quote-color: var(--md-green-300);
--jp-mirror-editor-link-color: var(--gruvbox-red);
--jp-mirror-editor-error-color: var(--gruvbox-red);
--jp-mirror-editor-hr-color: #FFFFFF;
/* Code search styles */
--jp-search-unselected-match-background-color: var(--gruvbox-light-yellow);
--jp-search-unselected-match-color: var(--gruvbox-bg);
/* Vega extension styles */
--jp-vega-background: var(--gruvbox-bg);
/* ?? */
/*--jp-SideBar-background: var(--gruvbox-bg);*/
--jp-main-dock-panel-background: var(--gruvbox-bg);
}
/* Change the colour of linenumbers */
.CodeMirror-linenumber {
padding: 0 3px 0 5px;
min-width: 20px;
text-align: right;
color: var(--gruvbox-gray);
white-space: nowrap;
}
/* This is the region where the linenumbers are */
.CodeMirror-gutters {
border-right: 1px solid var(--gruvbox-dark1);
background-color: var(--gruvbox-bg);
white-space: nowrap;
}
/* ?? */
.jp-Completer-item.jp-mod-active{
color: var(--gruvbox-fg);
background: var(--gruvbox-dark1);
}
/* Item selected in menu for files and what not */
/*.jp-DirListing-item.jp-mod-selected {
color: white;
background: var(--gruvbox-dark1);
}*/
/* Makes the running icon a tiny bit bigger */
.jp-DirListing-item.jp-mod-running .jp-DirListing-itemIcon:before {
color: var(--gruvbox-green);
content: "\25CF";
font-size: 12px;
position: relative;
width: 100%;
height: 100%;
top: -2px;
left: -8px;
}
/* Do some nice things with brackets */
div.CodeMirror span.CodeMirror-matchingbracket {color: var(--gruvbox-fg); border-bottom: 1px solid var(--gruvbox-blue); line-height: 1;}
div.CodeMirror span.CodeMirror-nonmatchingbracket {color: var(--gruvbox-fg); border-bottom: 1px solid var(--gruvbox-red); line-height: 0.55;}
.CodeMirror-matchingtag { background: rgba(255, 150, 0, .3); }
.CodeMirror-activeline-background {background: #e8f2ff;}
.CodeMirror-selected { background: var(--gruvbox-dark2); }
.CodeMirror-focused .CodeMirror-selected { background: var(--gruvbox-dark2); } /* selected text highlight */
/* Custom markdown line rule */
.jp-RenderedHTMLCommon hr {
display: block;
margin-top: 0.5em;
margin-bottom: 0.5em;
margin-left: 0em;
margin-right: 0em;
border-style: inset;
border-width: 1px;
border-top: 1px solid var(--gruvbox-light4);
border-bottom: 1px solid var(--gruvbox-light4);
}
/* Centered markdown output */
.jp-MarkdownOutput {
flex: 1 1 auto;
margin-top: 0;
margin-bottom: 0;
padding: var(--jp-code-padding);
}
.cm-s-jupyter span.cm-operator {
font-weight: normal;
}
.cm-s-jupyter span.cm-keyword {
font-weight: normal;
}