escience_theme 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +133 -11
- package/escience.css +448 -0
- package/{escience_5.1.0.esm.js → escience.js} +180 -1118
- package/package.json +23 -4
- package/flake.lock +0 -61
- package/flake.nix +0 -16
- package/index.js +0 -2
|
@@ -1,742 +1,192 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
// eScience Center decorations for reveal.js.
|
|
2
|
+
//
|
|
3
|
+
// A slide's data-state lists what it shows: a preset ("standard", "title",
|
|
4
|
+
// ...), decoration names ("blue_overlay", "yellow_flag", ...) and optionally
|
|
5
|
+
// a number 0-10 for the overlay opacity in tenths. The plugin turns that into
|
|
6
|
+
// attributes on a decoration root; escience.css positions and animates the
|
|
7
|
+
// decorations from those attributes:
|
|
8
|
+
//
|
|
9
|
+
// data-show the decorations to show (plus "footer" if the slide has one)
|
|
10
|
+
// data-logo which logo variant is visible: color, white or part-white
|
|
11
|
+
// --escience-overlay-opacity
|
|
12
|
+
//
|
|
13
|
+
// On screen there is one root in the .reveal element, updated on every slide
|
|
14
|
+
// change. In the overview every slide background gets its own root while the
|
|
15
|
+
// overview is open, so the thumbnails look like their slides. In print view
|
|
16
|
+
// (?print-pdf) every page gets its own root, set once from that page's slide.
|
|
17
|
+
|
|
18
|
+
const LOGGING = false;
|
|
19
|
+
|
|
20
|
+
function log (content) {
|
|
21
|
+
if (LOGGING == true) {
|
|
22
|
+
console.log(content);
|
|
5
23
|
}
|
|
6
24
|
}
|
|
7
25
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
@font-face {
|
|
18
|
-
font-family: 'Source Sans Pro';
|
|
19
|
-
src: url('./source-sans-pro-regular.eot');
|
|
20
|
-
src: url('./source-sans-pro-regular.eot?#iefix') format('embedded-opentype'),
|
|
21
|
-
url('./source-sans-pro-regular.woff') format('woff'),
|
|
22
|
-
url('./source-sans-pro-regular.ttf') format('truetype');
|
|
23
|
-
font-weight: normal;
|
|
24
|
-
font-style: normal;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
@font-face {
|
|
28
|
-
font-family: 'Source Sans Pro';
|
|
29
|
-
src: url('./source-sans-pro-italic.eot');
|
|
30
|
-
src: url('./source-sans-pro-italic.eot?#iefix') format('embedded-opentype'),
|
|
31
|
-
url('./source-sans-pro-italic.woff') format('woff'),
|
|
32
|
-
url('./source-sans-pro-italic.ttf') format('truetype');
|
|
33
|
-
font-weight: normal;
|
|
34
|
-
font-style: italic;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
@font-face {
|
|
38
|
-
font-family: 'Source Sans Pro';
|
|
39
|
-
src: url('./source-sans-pro-semibold.eot');
|
|
40
|
-
src: url('./source-sans-pro-semibold.eot?#iefix') format('embedded-opentype'),
|
|
41
|
-
url('./source-sans-pro-semibold.woff') format('woff'),
|
|
42
|
-
url('./source-sans-pro-semibold.ttf') format('truetype');
|
|
43
|
-
font-weight: 600;
|
|
44
|
-
font-style: normal;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
@font-face {
|
|
48
|
-
font-family: 'Source Sans Pro';
|
|
49
|
-
src: url('./source-sans-pro-semibolditalic.eot');
|
|
50
|
-
src: url('./source-sans-pro-semibolditalic.eot?#iefix') format('embedded-opentype'),
|
|
51
|
-
url('./source-sans-pro-semibolditalic.woff') format('woff'),
|
|
52
|
-
url('./source-sans-pro-semibolditalic.ttf') format('truetype');
|
|
53
|
-
font-weight: 600;
|
|
54
|
-
font-style: italic;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
section.has-light-background, section.has-light-background h1, section.has-light-background h2, section.has-light-background h3, section.has-light-background h4, section.has-light-background h5, section.has-light-background h6 {
|
|
58
|
-
color: #222;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/*********************************************
|
|
62
|
-
* GLOBAL STYLES
|
|
63
|
-
*********************************************/
|
|
64
|
-
:root {
|
|
65
|
-
--r-background-color: #191919;
|
|
66
|
-
--r-main-font: Source Sans Pro, Helvetica, sans-serif;
|
|
67
|
-
--r-main-font-size: 42px;
|
|
68
|
-
--r-main-color: #fff;
|
|
69
|
-
--r-block-margin: 20px;
|
|
70
|
-
--r-heading-margin: 0 0 20px 0;
|
|
71
|
-
--r-heading-font: Source Sans Pro, Helvetica, sans-serif;
|
|
72
|
-
--r-heading-color: #fff;
|
|
73
|
-
--r-heading-line-height: 1.2;
|
|
74
|
-
--r-heading-letter-spacing: normal;
|
|
75
|
-
--r-heading-text-transform: uppercase;
|
|
76
|
-
--r-heading-text-shadow: none;
|
|
77
|
-
--r-heading-font-weight: 600;
|
|
78
|
-
--r-heading1-text-shadow: none;
|
|
79
|
-
--r-heading1-size: 2.5em;
|
|
80
|
-
--r-heading2-size: 1.6em;
|
|
81
|
-
--r-heading3-size: 1.3em;
|
|
82
|
-
--r-heading4-size: 1em;
|
|
83
|
-
--r-code-font: monospace;
|
|
84
|
-
--r-link-color: #42affa;
|
|
85
|
-
--r-link-color-dark: #068de9;
|
|
86
|
-
--r-link-color-hover: #8dcffc;
|
|
87
|
-
--r-selection-background-color: rgba(66, 175, 250, 0.75);
|
|
88
|
-
--r-selection-color: #fff;
|
|
89
|
-
--r-overlay-element-bg-color: 240, 240, 240;
|
|
90
|
-
--r-overlay-element-fg-color: 0, 0, 0;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.reveal-viewport {
|
|
94
|
-
background: #191919;
|
|
95
|
-
background-color: var(--r-background-color);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
.reveal {
|
|
99
|
-
font-family: var(--r-main-font);
|
|
100
|
-
font-size: var(--r-main-font-size);
|
|
101
|
-
font-weight: normal;
|
|
102
|
-
color: var(--r-main-color);
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.reveal ::selection {
|
|
106
|
-
color: var(--r-selection-color);
|
|
107
|
-
background: var(--r-selection-background-color);
|
|
108
|
-
text-shadow: none;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
.reveal ::-moz-selection {
|
|
112
|
-
color: var(--r-selection-color);
|
|
113
|
-
background: var(--r-selection-background-color);
|
|
114
|
-
text-shadow: none;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.reveal .slides section,
|
|
118
|
-
.reveal .slides section > section {
|
|
119
|
-
line-height: 1.3;
|
|
120
|
-
font-weight: inherit;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
/*********************************************
|
|
124
|
-
* HEADERS
|
|
125
|
-
*********************************************/
|
|
126
|
-
.reveal h1,
|
|
127
|
-
.reveal h2,
|
|
128
|
-
.reveal h3,
|
|
129
|
-
.reveal h4,
|
|
130
|
-
.reveal h5,
|
|
131
|
-
.reveal h6 {
|
|
132
|
-
margin: var(--r-heading-margin);
|
|
133
|
-
color: var(--r-heading-color);
|
|
134
|
-
font-family: var(--r-heading-font);
|
|
135
|
-
font-weight: var(--r-heading-font-weight);
|
|
136
|
-
line-height: var(--r-heading-line-height);
|
|
137
|
-
letter-spacing: var(--r-heading-letter-spacing);
|
|
138
|
-
text-transform: var(--r-heading-text-transform);
|
|
139
|
-
text-shadow: var(--r-heading-text-shadow);
|
|
140
|
-
word-wrap: break-word;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
.reveal h1 {
|
|
144
|
-
font-size: var(--r-heading1-size);
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
.reveal h2 {
|
|
148
|
-
font-size: var(--r-heading2-size);
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.reveal h3 {
|
|
152
|
-
font-size: var(--r-heading3-size);
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
.reveal h4 {
|
|
156
|
-
font-size: var(--r-heading4-size);
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
.reveal h1 {
|
|
160
|
-
text-shadow: var(--r-heading1-text-shadow);
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
/*********************************************
|
|
164
|
-
* OTHER
|
|
165
|
-
*********************************************/
|
|
166
|
-
.reveal p {
|
|
167
|
-
margin: var(--r-block-margin) 0;
|
|
168
|
-
line-height: 1.3;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
/* Remove trailing margins after titles */
|
|
172
|
-
.reveal h1:last-child,
|
|
173
|
-
.reveal h2:last-child,
|
|
174
|
-
.reveal h3:last-child,
|
|
175
|
-
.reveal h4:last-child,
|
|
176
|
-
.reveal h5:last-child,
|
|
177
|
-
.reveal h6:last-child {
|
|
178
|
-
margin-bottom: 0;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
/* Ensure certain elements are never larger than the slide itself */
|
|
182
|
-
.reveal img,
|
|
183
|
-
.reveal video,
|
|
184
|
-
.reveal iframe {
|
|
185
|
-
max-width: 95%;
|
|
186
|
-
max-height: 95%;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.reveal strong,
|
|
190
|
-
.reveal b {
|
|
191
|
-
font-weight: bold;
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
.reveal em {
|
|
195
|
-
font-style: italic;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
.reveal ol,
|
|
199
|
-
.reveal dl,
|
|
200
|
-
.reveal ul {
|
|
201
|
-
display: inline-block;
|
|
202
|
-
text-align: left;
|
|
203
|
-
margin: 0 0 0 1em;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
.reveal ol {
|
|
207
|
-
list-style-type: decimal;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
.reveal ul {
|
|
211
|
-
list-style-type: disc;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
.reveal ul ul {
|
|
215
|
-
list-style-type: square;
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
.reveal ul ul ul {
|
|
219
|
-
list-style-type: circle;
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
.reveal ul ul,
|
|
223
|
-
.reveal ul ol,
|
|
224
|
-
.reveal ol ol,
|
|
225
|
-
.reveal ol ul {
|
|
226
|
-
display: block;
|
|
227
|
-
margin-left: 40px;
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
.reveal dt {
|
|
231
|
-
font-weight: bold;
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
.reveal dd {
|
|
235
|
-
margin-left: 40px;
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
.reveal blockquote {
|
|
239
|
-
display: block;
|
|
240
|
-
position: relative;
|
|
241
|
-
width: 70%;
|
|
242
|
-
margin: var(--r-block-margin) auto;
|
|
243
|
-
padding: 5px;
|
|
244
|
-
font-style: italic;
|
|
245
|
-
background: rgba(255, 255, 255, 0.05);
|
|
246
|
-
box-shadow: 0px 0px 2px rgba(0, 0, 0, 0.2);
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
.reveal blockquote p:first-child,
|
|
250
|
-
.reveal blockquote p:last-child {
|
|
251
|
-
display: inline-block;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
.reveal q {
|
|
255
|
-
font-style: italic;
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
.reveal pre {
|
|
259
|
-
display: block;
|
|
260
|
-
position: relative;
|
|
261
|
-
width: 90%;
|
|
262
|
-
margin: var(--r-block-margin) auto;
|
|
263
|
-
text-align: left;
|
|
264
|
-
font-size: 0.55em;
|
|
265
|
-
font-family: var(--r-code-font);
|
|
266
|
-
line-height: 1.2em;
|
|
267
|
-
word-wrap: break-word;
|
|
268
|
-
box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.15);
|
|
269
|
-
}
|
|
270
|
-
|
|
271
|
-
.reveal code {
|
|
272
|
-
font-family: var(--r-code-font);
|
|
273
|
-
text-transform: none;
|
|
274
|
-
tab-size: 2;
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
.reveal pre code {
|
|
278
|
-
display: block;
|
|
279
|
-
padding: 5px;
|
|
280
|
-
overflow: auto;
|
|
281
|
-
max-height: 400px;
|
|
282
|
-
word-wrap: normal;
|
|
283
|
-
}
|
|
284
|
-
|
|
285
|
-
.reveal .code-wrapper {
|
|
286
|
-
white-space: normal;
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
.reveal .code-wrapper code {
|
|
290
|
-
white-space: pre;
|
|
291
|
-
}
|
|
292
|
-
|
|
293
|
-
.reveal table {
|
|
294
|
-
margin: auto;
|
|
295
|
-
border-collapse: collapse;
|
|
296
|
-
border-spacing: 0;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
.reveal table th {
|
|
300
|
-
font-weight: bold;
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
.reveal table th,
|
|
304
|
-
.reveal table td {
|
|
305
|
-
text-align: left;
|
|
306
|
-
padding: 0.2em 0.5em 0.2em 0.5em;
|
|
307
|
-
border-bottom: 1px solid;
|
|
308
|
-
}
|
|
309
|
-
|
|
310
|
-
.reveal table th[align=center],
|
|
311
|
-
.reveal table td[align=center] {
|
|
312
|
-
text-align: center;
|
|
313
|
-
}
|
|
314
|
-
|
|
315
|
-
.reveal table th[align=right],
|
|
316
|
-
.reveal table td[align=right] {
|
|
317
|
-
text-align: right;
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
.reveal table tbody tr:last-child th,
|
|
321
|
-
.reveal table tbody tr:last-child td {
|
|
322
|
-
border-bottom: none;
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
.reveal sup {
|
|
326
|
-
vertical-align: super;
|
|
327
|
-
font-size: smaller;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
.reveal sub {
|
|
331
|
-
vertical-align: sub;
|
|
332
|
-
font-size: smaller;
|
|
333
|
-
}
|
|
334
|
-
|
|
335
|
-
.reveal small {
|
|
336
|
-
display: inline-block;
|
|
337
|
-
font-size: 0.6em;
|
|
338
|
-
line-height: 1.2em;
|
|
339
|
-
vertical-align: top;
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
.reveal small * {
|
|
343
|
-
vertical-align: top;
|
|
344
|
-
}
|
|
345
|
-
|
|
346
|
-
.reveal img {
|
|
347
|
-
margin: var(--r-block-margin) 0;
|
|
348
|
-
}
|
|
349
|
-
|
|
350
|
-
/*********************************************
|
|
351
|
-
* LINKS
|
|
352
|
-
*********************************************/
|
|
353
|
-
.reveal a {
|
|
354
|
-
color: var(--r-link-color);
|
|
355
|
-
text-decoration: none;
|
|
356
|
-
transition: color 0.15s ease;
|
|
357
|
-
}
|
|
358
|
-
|
|
359
|
-
.reveal a:hover {
|
|
360
|
-
color: var(--r-link-color-hover);
|
|
361
|
-
text-shadow: none;
|
|
362
|
-
border: none;
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
.reveal .roll span:after {
|
|
366
|
-
color: #fff;
|
|
367
|
-
background: var(--r-link-color-dark);
|
|
368
|
-
}
|
|
369
|
-
|
|
370
|
-
/*********************************************
|
|
371
|
-
* Frame helper
|
|
372
|
-
*********************************************/
|
|
373
|
-
.reveal .r-frame {
|
|
374
|
-
border: 4px solid var(--r-main-color);
|
|
375
|
-
box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
|
|
376
|
-
}
|
|
377
|
-
|
|
378
|
-
.reveal a .r-frame {
|
|
379
|
-
transition: all 0.15s linear;
|
|
380
|
-
}
|
|
381
|
-
|
|
382
|
-
.reveal a:hover .r-frame {
|
|
383
|
-
border-color: var(--r-link-color);
|
|
384
|
-
box-shadow: 0 0 20px rgba(0, 0, 0, 0.55);
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
/*********************************************
|
|
388
|
-
* NAVIGATION CONTROLS
|
|
389
|
-
*********************************************/
|
|
390
|
-
.reveal .controls {
|
|
391
|
-
color: var(--r-link-color);
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
/*********************************************
|
|
395
|
-
* PROGRESS BAR
|
|
396
|
-
*********************************************/
|
|
397
|
-
.reveal .progress {
|
|
398
|
-
background: rgba(0, 0, 0, 0.2);
|
|
399
|
-
color: var(--r-link-color);
|
|
400
|
-
}
|
|
26
|
+
const PRESETS = {
|
|
27
|
+
standard: 'logo yellow_flag white_overlay',
|
|
28
|
+
two_pane: 'logo yellow_flag white_overlay blue_pane_right',
|
|
29
|
+
about: 'logo white_overlay blue_pane_left purple_half_circle_top purple_strip_bottom yellow_half_strip',
|
|
30
|
+
touch: 'logo blue_overlay touch_pane purple_blob right_e_bottom',
|
|
31
|
+
keepintouch: 'logo blue_overlay touch_pane purple_blob right_e_bottom',
|
|
32
|
+
title: 'blue_overlay yellow_flag yellow_strip purple_half_circle_bottom purple_blob right_e_top',
|
|
33
|
+
};
|
|
401
34
|
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
35
|
+
// Decorations that change the logo variant, the link colours (data-escience-links
|
|
36
|
+
// on the slide) or reveal's has-light/dark-background classes on the slide.
|
|
37
|
+
// Later entries take precedence over earlier ones.
|
|
38
|
+
const EFFECTS = [
|
|
39
|
+
['purple_overlay', { logo: 'part-white', links: 'on-dark', background: ['-light'] }],
|
|
40
|
+
['white_overlay', { logo: 'color', links: 'on-light', background: ['+light'] }],
|
|
41
|
+
['black_overlay', { logo: 'part-white', links: 'on-dark', background: ['-light'] }],
|
|
42
|
+
['blue_overlay', { logo: 'white', links: 'on-blue', background: ['-light'] }],
|
|
43
|
+
['blue_pane_right', { background: ['-dark', '+light'] }],
|
|
44
|
+
['blue_pane_left', { logo: 'white', background: ['-dark', '+light'] }],
|
|
45
|
+
['touch_pane', { logo: 'color', background: ['-light', '+dark'] }],
|
|
46
|
+
['purple_half_circle_top', { logo: 'part-white' }],
|
|
47
|
+
];
|
|
48
|
+
|
|
49
|
+
// Overlays let background images, videos and iframes show through at 0.8
|
|
50
|
+
// unless data-state gives a number.
|
|
51
|
+
const BACKGROUND_MEDIA = ['data-background-image', 'data-background-video', 'data-background-iframe'];
|
|
52
|
+
|
|
53
|
+
function slideState(slide) {
|
|
54
|
+
const words = (slide.getAttribute('data-state') || '').split(/\s+/).filter(Boolean);
|
|
55
|
+
const show = new Set();
|
|
56
|
+
let opacity = BACKGROUND_MEDIA.some(a => slide.hasAttribute(a)) ? 0.8 : 1;
|
|
57
|
+
for (const word of words) {
|
|
58
|
+
if (/^(10|[0-9])$/.test(word)) { opacity = Number(word) / 10; continue; }
|
|
59
|
+
for (const name of (PRESETS[word] || word).split(' ')) show.add(name);
|
|
408
60
|
}
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
const
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
.
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
padding: 0.5em;
|
|
421
|
-
background: #272822;
|
|
422
|
-
color: #ddd;
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
.hljs-tag,
|
|
426
|
-
.hljs-keyword,
|
|
427
|
-
.hljs-selector-tag,
|
|
428
|
-
.hljs-literal,
|
|
429
|
-
.hljs-strong,
|
|
430
|
-
.hljs-name {
|
|
431
|
-
color: #f92672;
|
|
432
|
-
}
|
|
433
|
-
|
|
434
|
-
.hljs-code {
|
|
435
|
-
color: #66d9ef;
|
|
436
|
-
}
|
|
437
|
-
|
|
438
|
-
.hljs-class .hljs-title {
|
|
439
|
-
color: white;
|
|
440
|
-
}
|
|
441
|
-
|
|
442
|
-
.hljs-attribute,
|
|
443
|
-
.hljs-symbol,
|
|
444
|
-
.hljs-regexp,
|
|
445
|
-
.hljs-link {
|
|
446
|
-
color: #bf79db;
|
|
447
|
-
}
|
|
448
|
-
|
|
449
|
-
.hljs-string,
|
|
450
|
-
.hljs-bullet,
|
|
451
|
-
.hljs-subst,
|
|
452
|
-
.hljs-title,
|
|
453
|
-
.hljs-section,
|
|
454
|
-
.hljs-emphasis,
|
|
455
|
-
.hljs-type,
|
|
456
|
-
.hljs-built_in,
|
|
457
|
-
.hljs-builtin-name,
|
|
458
|
-
.hljs-selector-attr,
|
|
459
|
-
.hljs-selector-pseudo,
|
|
460
|
-
.hljs-addition,
|
|
461
|
-
.hljs-variable,
|
|
462
|
-
.hljs-template-tag,
|
|
463
|
-
.hljs-template-variable {
|
|
464
|
-
color: #a6e22e;
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
.hljs-comment,
|
|
468
|
-
.hljs-quote,
|
|
469
|
-
.hljs-deletion,
|
|
470
|
-
.hljs-meta {
|
|
471
|
-
color: #75715e;
|
|
472
|
-
}
|
|
473
|
-
|
|
474
|
-
.hljs-keyword,
|
|
475
|
-
.hljs-selector-tag,
|
|
476
|
-
.hljs-literal,
|
|
477
|
-
.hljs-doctag,
|
|
478
|
-
.hljs-title,
|
|
479
|
-
.hljs-section,
|
|
480
|
-
.hljs-type,
|
|
481
|
-
.hljs-selector-id {
|
|
482
|
-
font-weight: bold;
|
|
483
|
-
}
|
|
484
|
-
`;
|
|
485
|
-
|
|
486
|
-
const escience_css = `
|
|
487
|
-
/*********************************************
|
|
488
|
-
* COLORS
|
|
489
|
-
*********************************************/
|
|
490
|
-
|
|
491
|
-
:root {
|
|
492
|
-
--nlesc-blue: #009DDD;
|
|
493
|
-
--nlesc-purple: #380339;
|
|
494
|
-
--nlesc-yellow: #FFB213;
|
|
495
|
-
--light-gray: #D8D8D8;
|
|
496
|
-
--dark-gray: #2b2b2b;
|
|
497
|
-
--gray-transparent: rgba(128, 128, 128, .5);
|
|
498
|
-
|
|
499
|
-
--link-color: var(--nlesc-purple);
|
|
500
|
-
--link-color-hover: var(--nlesc-yellow);
|
|
501
|
-
|
|
502
|
-
}
|
|
503
|
-
|
|
504
|
-
/*********************************************
|
|
505
|
-
* GLOBAL STYLES
|
|
506
|
-
*********************************************/
|
|
507
|
-
|
|
508
|
-
p, div, ul {
|
|
509
|
-
font-family: "Assistant", sans-serif !important;
|
|
510
|
-
font-optical-sizing: auto;
|
|
511
|
-
font-weight: 400 !important;
|
|
512
|
-
font-style: normal;
|
|
513
|
-
}
|
|
514
|
-
|
|
515
|
-
h1, h2, h3 {
|
|
516
|
-
font-family: "Nunito" !important;
|
|
517
|
-
font-weight: 700 !important;
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
h4, h5 {
|
|
521
|
-
font-family: "Assistant", sans-serif !important;
|
|
522
|
-
font-optical-sizing: auto;
|
|
523
|
-
font-weight: 700 !important;
|
|
524
|
-
font-style: normal;
|
|
525
|
-
}
|
|
526
|
-
|
|
527
|
-
code {
|
|
528
|
-
font-family: "Fira Code", monospace !important;
|
|
529
|
-
font-optical-sizing: auto !important;
|
|
530
|
-
font-weight: 500;
|
|
531
|
-
font-style: normal;
|
|
532
|
-
background-color: var(--gray-transparent);
|
|
533
|
-
}
|
|
534
|
-
|
|
535
|
-
.reveal h1,
|
|
536
|
-
.reveal h2,
|
|
537
|
-
.reveal h3,
|
|
538
|
-
.reveal h4,
|
|
539
|
-
.reveal h5,
|
|
540
|
-
.reveal h6 {
|
|
541
|
-
text-transform: none;
|
|
542
|
-
}
|
|
543
|
-
|
|
544
|
-
.reveal {
|
|
545
|
-
font-size: 36px; } /* make stuff smaller */
|
|
546
|
-
|
|
547
|
-
::selection {
|
|
548
|
-
color: #0f0;
|
|
549
|
-
background: var(--nlesc-purple);
|
|
550
|
-
text-shadow: none; }
|
|
551
|
-
|
|
552
|
-
::-moz-selection {
|
|
553
|
-
color: #fff;
|
|
554
|
-
background: var(--nlesc-purple);
|
|
555
|
-
text-shadow: none; }
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
/*********************************************
|
|
559
|
-
* CUSTOM COLORS
|
|
560
|
-
*********************************************/
|
|
561
|
-
.primary { color: var(--nlesc-blue) !important; }
|
|
562
|
-
.secondary { color: var(--nlesc-purple) !important; }
|
|
563
|
-
.tertiary { color: var(--light-gray) !important; }
|
|
564
|
-
|
|
565
|
-
/*********************************************
|
|
566
|
-
* LINKS
|
|
567
|
-
*********************************************/
|
|
568
|
-
.reveal a {
|
|
569
|
-
color: var(--link-color); }
|
|
570
|
-
|
|
571
|
-
.reveal a:hover {
|
|
572
|
-
color: var(--link-color-hover); }
|
|
573
|
-
|
|
574
|
-
.reveal .roll span:after {
|
|
575
|
-
color: #fff;
|
|
576
|
-
background: var(--nlesc-blue); }
|
|
577
|
-
|
|
578
|
-
/*********************************************
|
|
579
|
-
* IMAGES
|
|
580
|
-
*********************************************/
|
|
581
|
-
.reveal section img { /* undo stupid img frames */
|
|
582
|
-
background: none;
|
|
583
|
-
border: none;
|
|
584
|
-
box-shadow: none;
|
|
585
|
-
}
|
|
586
|
-
|
|
587
|
-
.reveal a:hover img {
|
|
588
|
-
border-color: var(--nlesc-blue); }
|
|
589
|
-
|
|
590
|
-
/*********************************************
|
|
591
|
-
* HIGHLIGHT COLORS
|
|
592
|
-
*********************************************/
|
|
593
|
-
|
|
594
|
-
.reveal .slides section .fragment.highlight-blue.visible {
|
|
595
|
-
color: var(--nlesc-blue); }
|
|
596
|
-
|
|
597
|
-
/*********************************************
|
|
598
|
-
* NAVIGATION CONTROLS
|
|
599
|
-
*********************************************/
|
|
600
|
-
.reveal .controls {
|
|
601
|
-
color: var(--nlesc-yellow); }
|
|
602
|
-
|
|
603
|
-
/*********************************************
|
|
604
|
-
* PROGRESS BAR
|
|
605
|
-
*********************************************/
|
|
606
|
-
.reveal .progress {
|
|
607
|
-
background: rgba(0, 0, 0, 0.2);
|
|
608
|
-
color: var(--nlesc-yellow); }
|
|
609
|
-
|
|
610
|
-
.reveal .progress span {
|
|
611
|
-
background: var(--nlesc-yellow);
|
|
612
|
-
-webkit-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985);
|
|
613
|
-
-moz-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985);
|
|
614
|
-
transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); }
|
|
615
|
-
|
|
616
|
-
/*********************************************
|
|
617
|
-
* FOOTER
|
|
618
|
-
*********************************************/
|
|
619
|
-
|
|
620
|
-
.slides .footer {
|
|
621
|
-
font-size: x-small !important;
|
|
622
|
-
width: 100%;
|
|
623
|
-
clear: both;
|
|
624
|
-
/* padding: 50px 0 0 0;*/
|
|
61
|
+
if (slide.querySelector('footer')) show.add('footer');
|
|
62
|
+
|
|
63
|
+
let logo = 'color', links = null;
|
|
64
|
+
const background = [];
|
|
65
|
+
for (const [name, effect] of EFFECTS) {
|
|
66
|
+
if (!show.has(name)) continue;
|
|
67
|
+
logo = effect.logo || logo;
|
|
68
|
+
links = effect.links || links;
|
|
69
|
+
background.push(...(effect.background || []));
|
|
70
|
+
}
|
|
71
|
+
return { show, opacity, logo, links, background };
|
|
625
72
|
}
|
|
626
73
|
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
.
|
|
632
|
-
background-color: var(--dark-gray); } }
|
|
74
|
+
function render(root, slide) {
|
|
75
|
+
const state = slideState(slide);
|
|
76
|
+
root.dataset.show = [...state.show].join(' ');
|
|
77
|
+
root.dataset.logo = state.logo;
|
|
78
|
+
root.style.setProperty('--escience-overlay-opacity', state.opacity);
|
|
633
79
|
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
.dim .backgrounds {
|
|
638
|
-
-webkit-filter: brightness(.4) !important;
|
|
639
|
-
-moz-filter: brightness(.4) !important;
|
|
640
|
-
-o-filter: brightness(.4) !important;
|
|
641
|
-
-ms-filter: brightness(.4) !important;
|
|
642
|
-
filter: brightness(.4) !important;
|
|
643
|
-
-webkit-transition: -webkit-filter 100ms linear;
|
|
644
|
-
transition: filter 100ms linear;
|
|
645
|
-
}
|
|
646
|
-
|
|
647
|
-
.dim_3 .backgrounds {
|
|
648
|
-
-webkit-filter: brightness(.3) !important;
|
|
649
|
-
-moz-filter: brightness(.3) !important;
|
|
650
|
-
-o-filter: brightness(.3) !important;
|
|
651
|
-
-ms-filter: brightness(.3) !important;
|
|
652
|
-
filter: brightness(.3) !important;
|
|
653
|
-
-webkit-transition: -webkit-filter 100ms linear;
|
|
654
|
-
transition: filter 100ms linear;
|
|
655
|
-
}
|
|
80
|
+
// Without a footer the strip slides out with its previous content.
|
|
81
|
+
const footer = slide.querySelector('footer');
|
|
82
|
+
if (footer) root.querySelector('.escience-footer').innerHTML = footer.innerHTML;
|
|
656
83
|
|
|
657
|
-
.
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
-webkit-transition: -webkit-filter 100ms linear;
|
|
664
|
-
transition: filter 100ms linear;
|
|
84
|
+
if (state.links) slide.dataset.escienceLinks = state.links;
|
|
85
|
+
else delete slide.dataset.escienceLinks;
|
|
86
|
+
for (const change of state.background) {
|
|
87
|
+
slide.classList.toggle(`has-${change.slice(1)}-background`, change[0] === '+');
|
|
88
|
+
}
|
|
89
|
+
log(`decorations: ${root.dataset.show} (logo ${state.logo}, opacity ${state.opacity})`);
|
|
665
90
|
}
|
|
666
91
|
|
|
667
|
-
.
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
92
|
+
// In every .stepper inside `scope`, the last shown .step (a plain one, or a
|
|
93
|
+
// fragment that is visible) gets the class current-step; escience.css
|
|
94
|
+
// highlights it and shows only its details.
|
|
95
|
+
function markSteps(scope) {
|
|
96
|
+
for (const stepper of scope.querySelectorAll('.stepper')) {
|
|
97
|
+
const steps = [...stepper.querySelectorAll('.step')];
|
|
98
|
+
const current = steps.filter(s => !s.classList.contains('fragment') || s.classList.contains('visible')).at(-1);
|
|
99
|
+
for (const step of steps) step.classList.toggle('current-step', step === current);
|
|
100
|
+
}
|
|
675
101
|
}
|
|
676
102
|
|
|
677
|
-
|
|
678
|
-
* ALLOW FOR DECORATIONS
|
|
679
|
-
*********************************************/
|
|
680
|
-
.slides {
|
|
681
|
-
/* puts the slide content above overlays and decorations*/
|
|
682
|
-
z-index: 10 !important;
|
|
683
|
-
}
|
|
103
|
+
let template;
|
|
684
104
|
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
105
|
+
function createRoot(parent) {
|
|
106
|
+
template ??= Object.assign(document.createElement('template'), { innerHTML: DECORATIONS });
|
|
107
|
+
const root = template.content.firstElementChild.cloneNode(true);
|
|
108
|
+
parent.prepend(root);
|
|
109
|
+
return root;
|
|
688
110
|
}
|
|
689
111
|
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
}
|
|
693
|
-
`;
|
|
112
|
+
const Escience = () => {
|
|
113
|
+
let deck, root;
|
|
694
114
|
|
|
695
|
-
|
|
696
|
-
|
|
115
|
+
const update = () => {
|
|
116
|
+
markSteps(deck.getCurrentSlide());
|
|
117
|
+
if (!deck.isOverview()) render(root, deck.getCurrentSlide());
|
|
118
|
+
};
|
|
119
|
+
const ready = () => { markSteps(deck.getRevealElement()); update(); };
|
|
120
|
+
const steps = () => markSteps(deck.getCurrentSlide());
|
|
121
|
+
|
|
122
|
+
const thumbnailRoots = () => deck.getRevealElement().querySelectorAll('.backgrounds .escience-decorations');
|
|
123
|
+
const showOverview = () => {
|
|
124
|
+
root.dataset.show = '';
|
|
125
|
+
for (const slide of deck.getSlides()) {
|
|
126
|
+
if (slide.slideBackgroundElement) render(createRoot(slide.slideBackgroundElement), slide);
|
|
127
|
+
}
|
|
128
|
+
};
|
|
129
|
+
const hideOverview = () => {
|
|
130
|
+
for (const thumbnail of thumbnailRoots()) thumbnail.remove();
|
|
131
|
+
update();
|
|
132
|
+
};
|
|
697
133
|
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
134
|
+
return {
|
|
135
|
+
id: 'Escience',
|
|
136
|
+
init: (reveal) => {
|
|
137
|
+
deck = reveal;
|
|
138
|
+
if (deck.isPrintView()) {
|
|
139
|
+
deck.on('pdf-ready', () => {
|
|
140
|
+
for (const page of deck.getRevealElement().querySelectorAll('.pdf-page')) {
|
|
141
|
+
const slide = page.querySelector('section');
|
|
142
|
+
const background = page.querySelector('.slide-background');
|
|
143
|
+
markSteps(page);
|
|
144
|
+
if (slide && background) render(createRoot(background), slide);
|
|
145
|
+
}
|
|
146
|
+
});
|
|
147
|
+
return;
|
|
148
|
+
}
|
|
149
|
+
root = createRoot(deck.getRevealElement());
|
|
150
|
+
deck.on('ready', ready);
|
|
151
|
+
deck.on('slidechanged', update);
|
|
152
|
+
deck.on('fragmentshown', steps);
|
|
153
|
+
deck.on('fragmenthidden', steps);
|
|
154
|
+
deck.on('overviewshown', showOverview);
|
|
155
|
+
deck.on('overviewhidden', hideOverview);
|
|
156
|
+
},
|
|
157
|
+
destroy: () => {
|
|
158
|
+
if (!root) return;
|
|
159
|
+
deck.off('ready', ready);
|
|
160
|
+
deck.off('slidechanged', update);
|
|
161
|
+
deck.off('fragmentshown', steps);
|
|
162
|
+
deck.off('fragmenthidden', steps);
|
|
163
|
+
deck.off('overviewshown', showOverview);
|
|
164
|
+
deck.off('overviewhidden', hideOverview);
|
|
165
|
+
for (const thumbnail of thumbnailRoots()) thumbnail.remove();
|
|
166
|
+
root.remove();
|
|
167
|
+
},
|
|
168
|
+
};
|
|
169
|
+
};
|
|
709
170
|
|
|
710
|
-
|
|
711
|
-
{
|
|
712
|
-
var head = document.getElementsByTagName('head')[0];
|
|
713
|
-
var link = document.createElement('link');
|
|
714
|
-
link.id = 'icons';
|
|
715
|
-
link.rel = 'stylesheet';
|
|
716
|
-
link.type = 'text/css';
|
|
717
|
-
link.href = 'https://fonts.googleapis.com/icon?family=Material+Icons';
|
|
718
|
-
link.media = 'all';
|
|
719
|
-
head.appendChild(link);
|
|
720
|
-
}
|
|
171
|
+
export default Escience;
|
|
721
172
|
|
|
722
|
-
const
|
|
723
|
-
<div
|
|
724
|
-
<div
|
|
725
|
-
<div
|
|
726
|
-
<h1
|
|
173
|
+
const DECORATIONS = `<div class="escience-decorations">
|
|
174
|
+
<div class="escience-blue-pane-left"></div>
|
|
175
|
+
<div class="escience-blue-pane-right"></div>
|
|
176
|
+
<div class="escience-touch-pane">
|
|
177
|
+
<h1>Let's stay<br>in touch</h1>
|
|
727
178
|
</div>
|
|
728
|
-
<div
|
|
729
|
-
<div
|
|
730
|
-
<div
|
|
731
|
-
<div
|
|
179
|
+
<div class="escience-purple-half-circle-top"></div>
|
|
180
|
+
<div class="escience-yellow-half-strip"></div>
|
|
181
|
+
<div class="escience-purple-strip-bottom"></div>
|
|
182
|
+
<div class="escience-logo-color escience-logo">
|
|
732
183
|
<svg
|
|
733
184
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
734
185
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
735
186
|
xmlns:svg="http://www.w3.org/2000/svg"
|
|
736
187
|
xmlns="http://www.w3.org/2000/svg"
|
|
737
188
|
viewBox="0 0 182.94 50.27"
|
|
738
|
-
version="1.1"
|
|
739
|
-
style="width: 12vw;">
|
|
189
|
+
version="1.1">
|
|
740
190
|
<metadata
|
|
741
191
|
id="metadata1137">
|
|
742
192
|
<rdf:RDF>
|
|
@@ -868,7 +318,7 @@ const decoration_elements = `
|
|
|
868
318
|
id="path1132" />
|
|
869
319
|
</svg>
|
|
870
320
|
</div>
|
|
871
|
-
<div
|
|
321
|
+
<div class="escience-logo-part-white escience-logo">
|
|
872
322
|
<svg
|
|
873
323
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
874
324
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
@@ -876,8 +326,7 @@ const decoration_elements = `
|
|
|
876
326
|
xmlns="http://www.w3.org/2000/svg"
|
|
877
327
|
viewBox="0 0 182.94 50.27"
|
|
878
328
|
version="1.1"
|
|
879
|
-
inkscape:version="1.0.2 (1.0.2+r75+1)"
|
|
880
|
-
style="width: 12vw;">
|
|
329
|
+
inkscape:version="1.0.2 (1.0.2+r75+1)">
|
|
881
330
|
<sodipodi:namedview
|
|
882
331
|
pagecolor="#505050"
|
|
883
332
|
bordercolor="#eeeeee"
|
|
@@ -1014,7 +463,7 @@ const decoration_elements = `
|
|
|
1014
463
|
style="fill:#ffffff;fill-opacity:1" />
|
|
1015
464
|
</svg>
|
|
1016
465
|
</div>
|
|
1017
|
-
<div
|
|
466
|
+
<div class="escience-logo-white escience-logo">
|
|
1018
467
|
<svg
|
|
1019
468
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
1020
469
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
@@ -1023,7 +472,6 @@ const decoration_elements = `
|
|
|
1023
472
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
1024
473
|
viewBox="0 0 182.94 50.27"
|
|
1025
474
|
version="1.1"
|
|
1026
|
-
style="width: 12vw;"
|
|
1027
475
|
>
|
|
1028
476
|
<metadata
|
|
1029
477
|
id="metadata1137">
|
|
@@ -1178,18 +626,18 @@ const decoration_elements = `
|
|
|
1178
626
|
style="fill:#ffffff;fill-opacity:1" />
|
|
1179
627
|
</svg>
|
|
1180
628
|
</div>
|
|
1181
|
-
<div
|
|
629
|
+
<div class="escience-purple-overlay">
|
|
1182
630
|
</div>
|
|
1183
|
-
<div
|
|
631
|
+
<div class="escience-blue-overlay">
|
|
1184
632
|
</div>
|
|
1185
|
-
<div
|
|
633
|
+
<div class="escience-white-overlay">
|
|
1186
634
|
</div>
|
|
1187
|
-
<div
|
|
635
|
+
<div class="escience-black-overlay">
|
|
1188
636
|
</div>
|
|
1189
|
-
<div
|
|
637
|
+
<div class="escience-yellow-strip">
|
|
1190
638
|
</div>
|
|
1191
|
-
<div
|
|
1192
|
-
<svg
|
|
639
|
+
<div class="escience-yellow-flag">
|
|
640
|
+
<svg viewBox="0 0 27 59" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
1193
641
|
<defs>
|
|
1194
642
|
<polygon id="path-1" points="0 0.132265672 26.8359 0.132265672 26.8359 33.3422209 0 33.3422209"></polygon>
|
|
1195
643
|
<polygon id="path-3" points="0 0.662473134 25.2148 0.662473134 25.2148 18.629294 0 18.629294"></polygon>
|
|
@@ -1218,15 +666,14 @@ const decoration_elements = `
|
|
|
1218
666
|
</g>
|
|
1219
667
|
</svg>
|
|
1220
668
|
</div>
|
|
1221
|
-
<div
|
|
1222
|
-
<svg
|
|
669
|
+
<div class="escience-purple-half-circle-bottom">
|
|
670
|
+
<svg
|
|
1223
671
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
1224
672
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
1225
673
|
xmlns:svg="http://www.w3.org/2000/svg"
|
|
1226
674
|
xmlns="http://www.w3.org/2000/svg"
|
|
1227
675
|
viewBox="0 0 182.94 50.27"
|
|
1228
|
-
version="1.1"
|
|
1229
|
-
style="position: absolute; bottom: 2vw; left: 6vw; width: 8vw;">
|
|
676
|
+
version="1.1">
|
|
1230
677
|
<metadata
|
|
1231
678
|
id="metadata1137">
|
|
1232
679
|
<rdf:RDF>
|
|
@@ -1376,397 +823,12 @@ const decoration_elements = `
|
|
|
1376
823
|
</svg>
|
|
1377
824
|
|
|
1378
825
|
</div>
|
|
1379
|
-
<div
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
<div style="background-color: var(--nlesc-purple); width: 10vw; height: 50vh; border-radius: 0 0 10vw 10vw;">
|
|
1383
|
-
</div>
|
|
1384
|
-
<div class="box" style="background: var(--nlesc-purple); position: absolute; right: 10vw; top: 0; width: 5vw; height: calc(25vh + 5vw); border-corner-shape: scoop; background: yellow; background: linear-gradient(45deg, transparent 10vw, var(--nlesc-purple) 0) bottom left; background-image: radial-gradient(circle at 0 100%, rgba(204,0,0,0) 5vw, var(--nlesc-purple) 15px)">
|
|
1385
|
-
</div>
|
|
1386
|
-
</div>
|
|
1387
|
-
<div id="blue_strip" style="background-color: var(--nlesc-blue); transition: left 1s, right 1s; margin: 0; padding: 0; border-radius: 20vw 0 0 0; z-index: 2; position: absolute; right: -100vw; bottom: 0;">
|
|
1388
|
-
<div id="footer" style="text-align: right; line-height: 130%; padding: 0; margin: 1vw 1vw 1vw 3vw; bottom: 0; right: 0;">
|
|
826
|
+
<div class="escience-purple-blob"></div>
|
|
827
|
+
<div class="escience-blue-strip">
|
|
828
|
+
<div class="escience-footer">
|
|
1389
829
|
</div>
|
|
1390
830
|
</div>
|
|
1391
|
-
<svg
|
|
831
|
+
<svg class="escience-right-e" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 272.549 662.141">
|
|
1392
832
|
<path id="Path_88" data-name="Path 88" d="M342.892,527.031q17.52-21.911,45.055-35.264a133.418,133.418,0,0,1,36-11.063V357.814c-33.264,2.515-63.486,9.336-90.408,20.725q-52.012,21.874-88.269,58.407-47.551,46.277-70.694,111.421-23.2,65.132-23.177,141.8,0,77.95,25.652,142.459Q202.723,897.2,251.563,943.4a314.339,314.339,0,0,0,88.213,56.587q37.073,15.944,84.176,19.965V896.642a104.455,104.455,0,0,1-25.345-8.657,178.837,178.837,0,0,1-40.683-27.369Q334.157,838.7,322.27,805.822a202.364,202.364,0,0,1-11.888-69.4h113.57V625.625H309.123q1.256-31.6,8.759-54.767Q325.384,547.762,342.892,527.031Z" transform="translate(-151.403 -357.814)" fill="#fff"/>
|
|
1393
833
|
</svg>
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
function insertCss(css) {
|
|
1397
|
-
const style = document.createElement('style');
|
|
1398
|
-
style.type = 'text/css';
|
|
1399
|
-
style.innerHTML = css;
|
|
1400
|
-
document.head.appendChild(style);
|
|
1401
|
-
}
|
|
1402
|
-
|
|
1403
|
-
function insertDecoration() {
|
|
1404
|
-
if ( window.location.search.match( /print-pdf/gi ) ) {
|
|
1405
|
-
const backgrounds = document.getElementsByClassName('slide-background');
|
|
1406
|
-
for (let i = 0; i < backgrounds.length; i++) {
|
|
1407
|
-
backgrounds[i].insertAdjacentHTML("afterbegin", decoration_elements);
|
|
1408
|
-
};
|
|
1409
|
-
} else {
|
|
1410
|
-
// for viewing slides
|
|
1411
|
-
const reveal_div = document.querySelectorAll('div.reveal');
|
|
1412
|
-
// TODO better do this loop with "forEach"
|
|
1413
|
-
for (let i = 0; i < reveal_div.length; i++) {
|
|
1414
|
-
reveal_div[i].insertAdjacentHTML("afterbegin", decoration_elements);
|
|
1415
|
-
};
|
|
1416
|
-
//$('#decoration').remove(); // without this the fadeIn/fadeOut below does not work. why is this necessary?
|
|
1417
|
-
};
|
|
1418
|
-
addDecorations();
|
|
1419
|
-
}
|
|
1420
|
-
|
|
1421
|
-
Reveal.on( 'ready', event => {
|
|
1422
|
-
insertCss(black_css);
|
|
1423
|
-
insertCss(monokai_css);
|
|
1424
|
-
insertCss(escience_css);
|
|
1425
|
-
insertDecoration();
|
|
1426
|
-
|
|
1427
|
-
/* set events only after reveal is ready */
|
|
1428
|
-
Reveal.on( 'slidechanged', event => {
|
|
1429
|
-
if (overview_shown == false)
|
|
1430
|
-
{
|
|
1431
|
-
console.log("slide changed");
|
|
1432
|
-
addDecorations();
|
|
1433
|
-
}
|
|
1434
|
-
});
|
|
1435
|
-
Reveal.on( 'overviewshown', event => {
|
|
1436
|
-
overview_shown = true;
|
|
1437
|
-
removeDecorations();
|
|
1438
|
-
});
|
|
1439
|
-
Reveal.on( 'overviewhidden', event => {
|
|
1440
|
-
overview_shown = false;
|
|
1441
|
-
addDecorations();
|
|
1442
|
-
});
|
|
1443
|
-
} );
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
function setLogoStyle(style) {
|
|
1447
|
-
//style must be one of {"logo_color","logo_white","logo_part_white"}
|
|
1448
|
-
|
|
1449
|
-
//unset everything
|
|
1450
|
-
document.getElementById("logo_color").style.opacity = 0;
|
|
1451
|
-
document.getElementById("logo_white").style.opacity = 0;
|
|
1452
|
-
document.getElementById("logo_part_white").style.opacity = 0;
|
|
1453
|
-
|
|
1454
|
-
//set only what we want
|
|
1455
|
-
document.getElementById(style).style.opacity = 1;
|
|
1456
|
-
};
|
|
1457
|
-
var overview_shown = false;
|
|
1458
|
-
function getOpacity(data_state) {
|
|
1459
|
-
var opacity = 0.8;
|
|
1460
|
-
for (let i = 0; i < 11; i++) {
|
|
1461
|
-
if (data_state.includes(i)) { opacity = i/10; console.log("opacity set to " + opacity)}
|
|
1462
|
-
};
|
|
1463
|
-
return opacity
|
|
1464
|
-
};
|
|
1465
|
-
function addDecorations() {
|
|
1466
|
-
console.log("set decorations")
|
|
1467
|
-
let root = document.documentElement;
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
var currentSlide = Reveal.getCurrentSlide();
|
|
1471
|
-
if (currentSlide.contains(currentSlide.querySelector('footer')))
|
|
1472
|
-
{
|
|
1473
|
-
document.getElementById("footer").innerHTML = currentSlide.querySelector('footer').innerHTML;
|
|
1474
|
-
document.getElementById("blue_strip").style.right = 0;
|
|
1475
|
-
console.log("footer (and blue_strip)");
|
|
1476
|
-
} else {
|
|
1477
|
-
document.getElementById("blue_strip").style.right = "-" + document.getElementById("blue_strip").offsetWidth + "px";
|
|
1478
|
-
console.log("no footer");
|
|
1479
|
-
};
|
|
1480
|
-
if ( currentSlide.getAttribute('data-state') )
|
|
1481
|
-
{
|
|
1482
|
-
var data_state = currentSlide.getAttribute('data-state')
|
|
1483
|
-
var opacity = getOpacity(data_state);
|
|
1484
|
-
console.log("DS" + data_state)
|
|
1485
|
-
// pre-set slide designs
|
|
1486
|
-
|
|
1487
|
-
// standard
|
|
1488
|
-
if ( data_state.includes("standard"))
|
|
1489
|
-
{
|
|
1490
|
-
data_state += " logo yellow_flag white_overlay";
|
|
1491
|
-
};
|
|
1492
|
-
|
|
1493
|
-
// two_pane
|
|
1494
|
-
if ( data_state.includes("two_pane"))
|
|
1495
|
-
{
|
|
1496
|
-
data_state += " logo yellow_flag white_overlay blue_pane_right";
|
|
1497
|
-
};
|
|
1498
|
-
|
|
1499
|
-
// about
|
|
1500
|
-
if ( data_state.includes("about"))
|
|
1501
|
-
{
|
|
1502
|
-
data_state += " logo white_overlay blue_pane_left purple_half_circle_top purple_strip_bottom yellow_half_strip";
|
|
1503
|
-
};
|
|
1504
|
-
|
|
1505
|
-
// touch
|
|
1506
|
-
if ( data_state.includes("touch"))
|
|
1507
|
-
{
|
|
1508
|
-
data_state += " logo blue_overlay touch_pane purple_blob right_e_bottom";
|
|
1509
|
-
};
|
|
1510
|
-
|
|
1511
|
-
// title
|
|
1512
|
-
if ( data_state.includes("title"))
|
|
1513
|
-
{
|
|
1514
|
-
data_state += " blue_overlay yellow_flag yellow_strip purple_half_circle_bottom purple_blob right_e_top";
|
|
1515
|
-
};
|
|
1516
|
-
|
|
1517
|
-
// individual elements
|
|
1518
|
-
|
|
1519
|
-
// purple overlay
|
|
1520
|
-
if ( data_state.includes("purple_overlay"))
|
|
1521
|
-
{
|
|
1522
|
-
document.getElementById("purple_overlay").style.opacity = opacity;
|
|
1523
|
-
document.getElementById("purple_overlay").style.transform = "translateY(0)";
|
|
1524
|
-
document.getElementById("logo_color").style.opacity = 0;
|
|
1525
|
-
document.getElementById("logo_white").style.opacity = 0;
|
|
1526
|
-
document.getElementById("logo_part_white").style.opacity = 1;
|
|
1527
|
-
currentSlide.classList.remove("has-light-background");
|
|
1528
|
-
root.style.setProperty("--link-color", "var(--nlesc-yellow)");
|
|
1529
|
-
root.style.setProperty("--link-color-hover", "var(--nlesc-blue)");
|
|
1530
|
-
console.log("purple overlay");
|
|
1531
|
-
} else {
|
|
1532
|
-
document.getElementById("purple_overlay").style.opacity = 0;
|
|
1533
|
-
console.log("no purple overlay");
|
|
1534
|
-
};
|
|
1535
|
-
|
|
1536
|
-
// white overlay
|
|
1537
|
-
if ( data_state.includes("white_overlay"))
|
|
1538
|
-
{
|
|
1539
|
-
document.getElementById("white_overlay").style.opacity = opacity;
|
|
1540
|
-
document.getElementById("white_overlay").style.transform = "translateY(0)";
|
|
1541
|
-
document.getElementById("logo_color").style.opacity = 1;
|
|
1542
|
-
document.getElementById("logo_white").style.opacity = 0;
|
|
1543
|
-
document.getElementById("logo_part_white").style.opacity = 0;
|
|
1544
|
-
currentSlide.classList.add("has-light-background");
|
|
1545
|
-
root.style.setProperty("--link-color", "var(--nlesc-blue)");
|
|
1546
|
-
root.style.setProperty("--link-color-hover", "var(--nlesc-yellow)");
|
|
1547
|
-
console.log("white overlay");
|
|
1548
|
-
} else {
|
|
1549
|
-
document.getElementById("white_overlay").style.opacity = 0;
|
|
1550
|
-
console.log("no white overlay");
|
|
1551
|
-
};
|
|
1552
|
-
|
|
1553
|
-
// black overlay
|
|
1554
|
-
if ( data_state.includes("black_overlay"))
|
|
1555
|
-
{
|
|
1556
|
-
document.getElementById("black_overlay").style.opacity = opacity;
|
|
1557
|
-
document.getElementById("black_overlay").style.transform = "translateY(0)";
|
|
1558
|
-
document.getElementById("logo_color").style.opacity = 0;
|
|
1559
|
-
document.getElementById("logo_white").style.opacity = 0;
|
|
1560
|
-
document.getElementById("logo_part_white").style.opacity = 1;
|
|
1561
|
-
currentSlide.classList.remove("has-light-background");
|
|
1562
|
-
root.style.setProperty("--link-color", "var(--nlesc-yellow)");
|
|
1563
|
-
root.style.setProperty("--link-color-hover", "var(--nlesc-blue)");
|
|
1564
|
-
console.log("black overlay");
|
|
1565
|
-
} else {
|
|
1566
|
-
document.getElementById("black_overlay").style.opacity = 0;
|
|
1567
|
-
console.log("no black overlay");
|
|
1568
|
-
};
|
|
1569
|
-
|
|
1570
|
-
// blue overlay
|
|
1571
|
-
if ( data_state.includes("blue_overlay"))
|
|
1572
|
-
{
|
|
1573
|
-
document.getElementById("blue_overlay").style.opacity = opacity;
|
|
1574
|
-
document.getElementById("blue_overlay").style.transform = "translateY(0)";
|
|
1575
|
-
document.getElementById("logo_color").style.opacity = 0;
|
|
1576
|
-
document.getElementById("logo_white").style.opacity = 1;
|
|
1577
|
-
document.getElementById("logo_part_white").style.opacity = 0;
|
|
1578
|
-
currentSlide.classList.remove("has-light-background");
|
|
1579
|
-
root.style.setProperty("--link-color", "var(--nlesc-yellow)");
|
|
1580
|
-
root.style.setProperty("--link-color-hover", "var(--nlesc-purple)");
|
|
1581
|
-
console.log("blue overlay");
|
|
1582
|
-
} else {
|
|
1583
|
-
document.getElementById("blue_overlay").style.opacity = 0;
|
|
1584
|
-
console.log("no blue overlay");
|
|
1585
|
-
};
|
|
1586
|
-
|
|
1587
|
-
// blue pane right
|
|
1588
|
-
if ( data_state.includes("blue_pane_right"))
|
|
1589
|
-
{
|
|
1590
|
-
document.getElementById("blue_pane_right").style.opacity = 1;
|
|
1591
|
-
document.getElementById("blue_pane_right").style.transform = "translateY(0)";
|
|
1592
|
-
currentSlide.classList.remove("has-dark-background");
|
|
1593
|
-
currentSlide.classList.add("has-light-background");
|
|
1594
|
-
console.log("blue_pane_right");
|
|
1595
|
-
} else {
|
|
1596
|
-
document.getElementById("blue_pane_right").style.opacity = 0;
|
|
1597
|
-
console.log("no blue_pane_right");
|
|
1598
|
-
};
|
|
1599
|
-
|
|
1600
|
-
// blue pane left
|
|
1601
|
-
if ( data_state.includes("blue_pane_left"))
|
|
1602
|
-
{
|
|
1603
|
-
document.getElementById("blue_pane_left").style.opacity = 1;
|
|
1604
|
-
document.getElementById("blue_pane_left").style.transform = "translateY(0)";
|
|
1605
|
-
setLogoStyle("logo_white");
|
|
1606
|
-
currentSlide.classList.remove("has-dark-background");
|
|
1607
|
-
currentSlide.classList.add("has-light-background");
|
|
1608
|
-
console.log("blue_pane_left");
|
|
1609
|
-
} else {
|
|
1610
|
-
document.getElementById("blue_pane_left").style.opacity = 0;
|
|
1611
|
-
console.log("no blue_pane_left");
|
|
1612
|
-
};
|
|
1613
|
-
|
|
1614
|
-
// touch pane
|
|
1615
|
-
if ( data_state.includes("touch_pane"))
|
|
1616
|
-
{
|
|
1617
|
-
document.getElementById("touch_pane").style.opacity = 1;
|
|
1618
|
-
document.getElementById("touch_pane").style.transform = "translateY(0)";
|
|
1619
|
-
setLogoStyle("logo_color");
|
|
1620
|
-
currentSlide.classList.remove("has-light-background");
|
|
1621
|
-
currentSlide.classList.add("has-dark-background");
|
|
1622
|
-
console.log("touch_pane");
|
|
1623
|
-
} else {
|
|
1624
|
-
document.getElementById("touch_pane").style.opacity = 0;
|
|
1625
|
-
console.log("no touch_pane");
|
|
1626
|
-
};
|
|
1627
|
-
|
|
1628
|
-
// logo
|
|
1629
|
-
if ( data_state.includes("logo"))
|
|
1630
|
-
{
|
|
1631
|
-
document.getElementById("logo_color").style.left = 3 + "vw";
|
|
1632
|
-
document.getElementById("logo_part_white").style.left = 3 + "vw";
|
|
1633
|
-
document.getElementById("logo_white").style.left = 3 + "vw";
|
|
1634
|
-
console.log("logo");
|
|
1635
|
-
} else {
|
|
1636
|
-
document.getElementById("logo_color").style.left = -12 + "vw";
|
|
1637
|
-
document.getElementById("logo_part_white").style.left = -12 + "vw";
|
|
1638
|
-
document.getElementById("logo_white").style.left = -12 + "vw";
|
|
1639
|
-
console.log("no logo");
|
|
1640
|
-
};
|
|
1641
|
-
|
|
1642
|
-
// yellow strip
|
|
1643
|
-
if ( data_state.includes("yellow_strip"))
|
|
1644
|
-
{
|
|
1645
|
-
document.getElementById("yellow_strip").style.left = 0;
|
|
1646
|
-
console.log("yellow_strip");
|
|
1647
|
-
} else {
|
|
1648
|
-
document.getElementById("yellow_strip").style.left = -10 + "vw";
|
|
1649
|
-
console.log("no yellow_strip");
|
|
1650
|
-
};
|
|
1651
|
-
|
|
1652
|
-
// yellow flag
|
|
1653
|
-
if ( data_state.includes("yellow_flag"))
|
|
1654
|
-
{
|
|
1655
|
-
document.getElementById("yellow_flag").style.left = 0;
|
|
1656
|
-
console.log("yellow_flag");
|
|
1657
|
-
} else {
|
|
1658
|
-
document.getElementById("yellow_flag").style.left = -10 + "vh";
|
|
1659
|
-
console.log("no yellow_flag");
|
|
1660
|
-
};
|
|
1661
|
-
|
|
1662
|
-
// purple half circle top
|
|
1663
|
-
if ( data_state.includes("purple_half_circle_top"))
|
|
1664
|
-
{
|
|
1665
|
-
document.getElementById("purple_half_circle_top").style.top = 0;
|
|
1666
|
-
setLogoStyle("logo_part_white");
|
|
1667
|
-
console.log("purple_half_circle_top");
|
|
1668
|
-
} else {
|
|
1669
|
-
document.getElementById("purple_half_circle_top").style.top = -17 + "vw";
|
|
1670
|
-
console.log("no purple_half_circle_top");
|
|
1671
|
-
};
|
|
1672
|
-
|
|
1673
|
-
// purple half circle bottom
|
|
1674
|
-
if ( data_state.includes("purple_half_circle_bottom"))
|
|
1675
|
-
{
|
|
1676
|
-
document.getElementById("purple_half_circle_bottom").style.bottom = 0;
|
|
1677
|
-
document.getElementById("yellow_flag").style.bottom = 20 + "vh";
|
|
1678
|
-
console.log("purple_half_circle_bottom");
|
|
1679
|
-
} else {
|
|
1680
|
-
document.getElementById("purple_half_circle_bottom").style.bottom = -10 + "vw";
|
|
1681
|
-
document.getElementById("yellow_flag").style.bottom = 5 + "vh";
|
|
1682
|
-
console.log("no purple_half_circle_bottom");
|
|
1683
|
-
};
|
|
1684
|
-
|
|
1685
|
-
// purple strip bottom
|
|
1686
|
-
if ( data_state.includes("purple_strip_bottom"))
|
|
1687
|
-
{
|
|
1688
|
-
document.getElementById("purple_strip_bottom").style.bottom = 0;
|
|
1689
|
-
console.log("purple_strip_bottom");
|
|
1690
|
-
} else {
|
|
1691
|
-
document.getElementById("purple_strip_bottom").style.bottom = -10 + "vw";
|
|
1692
|
-
console.log("no purple_strip_bottom");
|
|
1693
|
-
};
|
|
1694
|
-
|
|
1695
|
-
// yellow_half_strip
|
|
1696
|
-
if ( data_state.includes("yellow_half_strip"))
|
|
1697
|
-
{
|
|
1698
|
-
document.getElementById("yellow_half_strip").style.bottom = 0;
|
|
1699
|
-
console.log("yellow_half_strip");
|
|
1700
|
-
} else {
|
|
1701
|
-
document.getElementById("yellow_half_strip").style.bottom = -25 + "vw";
|
|
1702
|
-
console.log("no yellow_half_strip");
|
|
1703
|
-
};
|
|
1704
|
-
|
|
1705
|
-
// purple blob
|
|
1706
|
-
if ( data_state.includes("purple_blob"))
|
|
1707
|
-
{
|
|
1708
|
-
document.getElementById("purple_blob").style.top = 0;
|
|
1709
|
-
console.log("purple_blob");
|
|
1710
|
-
} else {
|
|
1711
|
-
document.getElementById("purple_blob").style.top = -50 + "vh";
|
|
1712
|
-
console.log("no purple_blob");
|
|
1713
|
-
};
|
|
1714
|
-
|
|
1715
|
-
// right_e
|
|
1716
|
-
if ( data_state.includes("right_e_top"))
|
|
1717
|
-
{
|
|
1718
|
-
document.getElementById("right_e").style.top = 10 + "vh";
|
|
1719
|
-
document.getElementById("right_e").style.right = 0;
|
|
1720
|
-
console.log("right_e_top");
|
|
1721
|
-
} else if ( data_state.includes("right_e_bottom")){
|
|
1722
|
-
document.getElementById("right_e").style.top = 60 + "vh";
|
|
1723
|
-
document.getElementById("right_e").style.right = 0;
|
|
1724
|
-
console.log("right_e_bottom");
|
|
1725
|
-
} else {
|
|
1726
|
-
document.getElementById("right_e").style.right = -4 + "vw";
|
|
1727
|
-
console.log("no right_e");
|
|
1728
|
-
};
|
|
1729
|
-
|
|
1730
|
-
// clear the background so that the overlays don't interfere
|
|
1731
|
-
// with underlying iframe
|
|
1732
|
-
if ( data_state.includes("clear_background"))
|
|
1733
|
-
{
|
|
1734
|
-
document.getElementById("purple_overlay").style.transform = "translateY(100vh)";
|
|
1735
|
-
document.getElementById("white_overlay").style.transform = "translateY(100vh)";
|
|
1736
|
-
document.getElementById("black_overlay").style.transform = "translateY(100vh)";
|
|
1737
|
-
document.getElementById("blue_overlay").style.transform = "translateY(100vh)";
|
|
1738
|
-
document.getElementById("blue_pane_right").style.transform = "translateY(100vh)";
|
|
1739
|
-
document.getElementById("blue_pane_left").style.transform = "translateY(100vh)";
|
|
1740
|
-
document.getElementById("touch_pane").style.transform = "translateY(100vh)";
|
|
1741
|
-
};
|
|
1742
|
-
}
|
|
1743
|
-
else
|
|
1744
|
-
{
|
|
1745
|
-
console.log("nothing special")
|
|
1746
|
-
};
|
|
1747
|
-
};
|
|
1748
|
-
|
|
1749
|
-
function removeDecorations() {
|
|
1750
|
-
console.log("removeDecorations")
|
|
1751
|
-
document.getElementById("purple_overlay").style.opacity = 0;
|
|
1752
|
-
document.getElementById("white_overlay").style.opacity = 0;
|
|
1753
|
-
document.getElementById("black_overlay").style.opacity = 0;
|
|
1754
|
-
document.getElementById("blue_overlay").style.opacity = 0;
|
|
1755
|
-
document.getElementById("blue_pane_right").style.opacity = 0;
|
|
1756
|
-
document.getElementById("blue_pane_left").style.opacity = 0;
|
|
1757
|
-
document.getElementById("touch_pane").style.opacity = 0;
|
|
1758
|
-
document.getElementById("logo_color").style.left = -12 + "vw";
|
|
1759
|
-
document.getElementById("logo_part_white").style.left = -12 + "vw";
|
|
1760
|
-
document.getElementById("logo_white").style.left = -12 + "vw";
|
|
1761
|
-
document.getElementById("yellow_strip").style.left = -10 + "vw";
|
|
1762
|
-
document.getElementById("yellow_flag").style.left = -10 + "vh";
|
|
1763
|
-
document.getElementById("purple_half_circle_top").style.top = -17 + "vw";
|
|
1764
|
-
document.getElementById("purple_half_circle_bottom").style.bottom = -10 + "vw";
|
|
1765
|
-
document.getElementById("purple_strip_bottom").style.bottom = -10 + "vw";
|
|
1766
|
-
document.getElementById("yellow_half_strip").style.bottom = -25 + "vw";
|
|
1767
|
-
document.getElementById("purple_blob").style.top = -50 + "vh";
|
|
1768
|
-
document.getElementById("right_e").style.right = -4 + "vw";
|
|
1769
|
-
document.getElementById("blue_strip").style.right = "-" + document.getElementById("blue_strip").offsetWidth + "px";
|
|
1770
|
-
};
|
|
1771
|
-
|
|
1772
|
-
}
|
|
834
|
+
</div>`;
|