@tolokoban/impress 0.13.0 → 0.20.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 +103 -7
- package/dist/impress.js +1079 -63
- package/dist/styles.js +52 -1
- package/package.json +1 -1
package/dist/styles.js
CHANGED
|
@@ -19,6 +19,7 @@ export const defaultTheme = {
|
|
|
19
19
|
ink: "#222222",
|
|
20
20
|
muted: "#7A8899",
|
|
21
21
|
subtitle: "#FFD8B0",
|
|
22
|
+
sectionHighlight: "#FF9F43",
|
|
22
23
|
white: "#FFFFFF",
|
|
23
24
|
quoteBackground: "#F1F4F8",
|
|
24
25
|
promptBackground: "#DCEBFF",
|
|
@@ -125,7 +126,18 @@ function masterStyles(master) {
|
|
|
125
126
|
},
|
|
126
127
|
[`${master}-subtitle`]: {
|
|
127
128
|
family: "presentation",
|
|
128
|
-
graphic: {
|
|
129
|
+
graphic: {
|
|
130
|
+
"draw:stroke": "none",
|
|
131
|
+
"draw:fill": "solid",
|
|
132
|
+
"draw:fill-color": "#000000",
|
|
133
|
+
"draw:opacity": "55%",
|
|
134
|
+
"draw:textarea-vertical-align": "middle",
|
|
135
|
+
"fo:padding-left": "0.8cm",
|
|
136
|
+
"fo:padding-right": "0.8cm",
|
|
137
|
+
...shrink,
|
|
138
|
+
},
|
|
139
|
+
// Bullets of the hierarchy box of section slides.
|
|
140
|
+
bullets: { ...bullets, color: "{colors.sectionHighlight}", indent: 1.2 },
|
|
129
141
|
paragraph: { "fo:text-align": "center" },
|
|
130
142
|
text: { ...sans, "fo:font-size": "{sizes.subtitle}pt", "fo:color": "{colors.subtitle}" },
|
|
131
143
|
},
|
|
@@ -297,6 +309,12 @@ const defaultStyles = {
|
|
|
297
309
|
text: { ...mono, "fo:font-size": "{sizes.code}pt", "fo:color": "{colors.ink}" },
|
|
298
310
|
},
|
|
299
311
|
Image: { family: "graphic", parent: "standard", graphic: { "draw:stroke": "none", "draw:fill": "none" } },
|
|
312
|
+
/** `----`: horizontal rule. */
|
|
313
|
+
Separateur: {
|
|
314
|
+
family: "graphic",
|
|
315
|
+
parent: "standard",
|
|
316
|
+
graphic: { "draw:stroke": "solid", "svg:stroke-color": "{colors.muted}", "svg:stroke-width": "0.03cm" },
|
|
317
|
+
},
|
|
300
318
|
"Tableau-cadre": { family: "graphic", parent: "standard", graphic: { "draw:stroke": "none", "draw:fill": "none" } },
|
|
301
319
|
/** `@layout columns ...`: column headings and column text. */
|
|
302
320
|
"Colonne-titre": {
|
|
@@ -377,10 +395,43 @@ export const defaultStyle = {
|
|
|
377
395
|
dashes: {
|
|
378
396
|
Tirets: { "draw:style": "rect", "draw:dots1": "1", "draw:dots1-length": "0.2cm", "draw:distance": "0.15cm" },
|
|
379
397
|
},
|
|
398
|
+
boxes: {
|
|
399
|
+
/** No `color`: black or white, whichever is more readable on the background. */
|
|
400
|
+
info: {
|
|
401
|
+
background: "{colors.quoteBackground}",
|
|
402
|
+
border: "0.03cm solid {colors.primary}",
|
|
403
|
+
radius: "0.3cm",
|
|
404
|
+
shadow: "0.1cm 0.1cm 0.3cm {colors.muted} 30%",
|
|
405
|
+
padding: "0.4cm 0.6cm",
|
|
406
|
+
},
|
|
407
|
+
warning: {
|
|
408
|
+
background: "{colors.accent}",
|
|
409
|
+
color: "{colors.white}",
|
|
410
|
+
border: "none",
|
|
411
|
+
radius: "0.3cm",
|
|
412
|
+
shadow: "0.1cm 0.1cm 0.3cm {colors.muted} 30%",
|
|
413
|
+
padding: "0.4cm 0.6cm",
|
|
414
|
+
},
|
|
415
|
+
/** Monospace text, e.g. a terminal output inside another box. */
|
|
416
|
+
terminal: {
|
|
417
|
+
background: "#1E1E1E",
|
|
418
|
+
border: "none",
|
|
419
|
+
radius: "0.15cm",
|
|
420
|
+
shadow: "none",
|
|
421
|
+
padding: "0.25cm 0.4cm",
|
|
422
|
+
margin: "0.1cm 0cm",
|
|
423
|
+
font: "mono",
|
|
424
|
+
size: "{sizes.code}pt",
|
|
425
|
+
},
|
|
426
|
+
},
|
|
380
427
|
spanStyles: {
|
|
381
428
|
T_b: { "fo:font-weight": "bold" },
|
|
382
429
|
T_i: { "fo:font-style": "italic" },
|
|
383
430
|
T_bi: { "fo:font-weight": "bold", "fo:font-style": "italic" },
|
|
384
431
|
T_code: mono,
|
|
432
|
+
/** Strikethrough: `~~text~~`. Nested around the other span styles, so it combines with them. */
|
|
433
|
+
T_s: { "style:text-line-through-style": "solid", "style:text-line-through-type": "single" },
|
|
434
|
+
/** Highlighted section in the hierarchy box of a section slide. */
|
|
435
|
+
T_section: { "fo:font-weight": "bold", "fo:color": "{colors.sectionHighlight}" },
|
|
385
436
|
},
|
|
386
437
|
};
|