The design of the clock in one page: monochrome, one character grid, bold and dim. Read from the code, offline, reusable. One style, four media: the terminal, the resume, the CV and the presentation, each in its own fold below.
Theme: · · ·
| use case | medium | size | density | folds |
|---|---|---|---|---|
| Terminal | character grid, web view | 13px/1.15 | whole frame, fixed height | tabs, no folds |
| Resume | web page + A4 print / PDF | 13px/1.5 · 9.5pt | one page | entries (open in print) |
| CV | A4 print / PDF, long web page | 13px/1.5 · 9.5pt | many pages, year column | sections (open in print) |
| Presentation | 16:9 deck, fullscreen, PDF handout | 2.2cqw = 28px at 1280 | one idea per slide | speaker notes |
All four share the Terminal rules and tokens: only text, bold and dim; no colour, no icons, no filled buttons; › · ↳ … as glyphs; every action has a key. The folds below only say what changes for that medium. A fold is a heading with › (closed) or ↓ (open); the keys are e expand all and c collapse all, and print or PDF always opens everything.
History (h). The mouse only sends the key the keyboard has. Every action has a key.›. Look at a similar panel first.body_lines - 2 lines: every mode keeps the same frame height. Show all items, not only the selected one.…, and make the limit a setting.esc leaves it, then q quits.Currently: Offline, with a way to the setting that changes it.| role | terminal | web view (clock serve) |
|---|---|---|
| text | the terminal's default foreground | color: var(--fg) |
| bold | SGR 1 | font-weight: bold |
| dim | SGR 2 | opacity: .6 |
| reverse | SGR 7 (active row / running state only) | .rv { color: var(--bg); background: var(--fg) } |
| frame | rich ROUNDED, border_style="dim" | the same box characters |
| token | dark | light | use |
|---|---|---|---|
--bg | #0b0b0b | #fafafa | page background |
--fg | #ddd | #111 | text |
--btn | #1d1f23 | #eee | web nav buttons (filled: a known deviation) |
--bd | #333 | #ccc | borders |
--on-bg | #e8e8e8 | #111 | active control background |
--on-fg | #111 | #fff | active control text |
--bar | rgba(18,19,22,.97) | rgba(250,250,250,.97) | bottom bar |
--in | #111 | #fff | inputs |
E-ink devices: pre, pre * { color:#000 !important; background:none !important; font-weight:600 } and .rv { background:#000; color:#fff }.
ui-monospace, Menlo, Consolas, monospace (screenshots: Fira Code, then the system monospace).13px/1.15, auto-fit to the screen (6–120 px). Layout is in character cells, never pixels.system-ui, sans-serif, 14px.The clock draws time with a 3 × 5 block font, every cell doubled horizontally, two spaces between glyphs. Live, from the same table:
██████ ██ ██████ ██████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██████ ██████ ██████ ██ ██ ██ ██ ██ ██ ██████ ██ ██████ ██████ ██
██████ ██████ ██████ ██████ ██████
██ ██ ██ ██ ██ ██ ██
██████ ██████ ██ ██████ ██████
██ ██ ██ ██ ██ ██ ██
██████ ██████ ██ ██████ ██████ ██████ ██████
██ ██ ██ ██
██ ██ ██████
██ ██ ██ ██
██████ ██ {
"0": ["███", "█ █", "█ █", "█ █", "███"],
"1": [" █", " █", " █", " █", " █"],
"2": ["███", " █", "███", "█ ", "███"],
"3": ["███", " █", "███", " █", "███"],
"4": ["█ █", "█ █", "███", " █", " █"],
"5": ["███", "█ ", "███", " █", "███"],
"6": ["███", "█ ", "███", "█ █", "███"],
"7": ["███", " █", " █", " █", " █"],
"8": ["███", "█ █", "███", "█ █", "███"],
"9": ["███", "█ █", "███", " █", "███"],
":": [" ", "█", " ", "█", " "],
"O": ["███", "█ █", "█ █", "█ █", "███"],
"F": ["███", "█ ", "███", "█ ", "█ "],
" ": [" ", " ", " ", " ", " "]
}
╭───────────────────╮ │ │ │ ██ ███ ██ ███ │ │ █ █ █ █ █ █ █ │ │ █ █ █ █ █ █ │ │ █ █ █ █ █ █ █ │ │ ███ ███ ███ ███ │ │ │ │ terminalclock │ │ │ ╰───────────────────╯
logo.txt · logo.svg · digit-font.json
Only these. Do not add decoration (no emoji, no icon fonts).
| glyph | code point | meaning | example |
|---|---|---|---|
| › | U+203A | selection marker in lists; prompt of a text box | › Sachsen |
| ▏ | U+258F | text cursor inside a text box (bold) | › Dresden▏ |
| · | U+00B7 | separator between facts on one line, and in hints | enter saves · esc cancels |
| … | U+2026 | a clipped line or path (never let a line run past the frame) | …/node_modules/.bin/mapscii |
| █ | U+2588 | the big digits, and filled cells | ███ |
| ─ │ ╭ ╮ ╰ ╯ | U+2500… | the rounded panel frame (rich ROUNDED), dim | ╭──╮ |
| ← ↑ → ↓ | U+2190… | key hints and the direction of a change | ↑↓ pick |
| ◀ ▶ | U+25C0 U+25B6 | back / next in the footer (dim) | ◀ back next ▶ |
| ± | U+00B1 | adjust by an amount | ±10 s |
| — | U+2014 | an empty value | — |
| ☰ | U+2630 | a list a reminder belongs to | ☰ Shopping 2/5 |
| ↳ | U+21B3 | a line that belongs to the one above (command line output) | ↳ Call mum |
╭─ CLOCK ────────╮
│ │
│ 12:34:56 │
│ │
╰────────────────╯Panel(box=ROUNDED, border_style="dim", padding=(1, 4))
version 0.4.16 python 3.12.3 config ~/.config/terminalclock daemon running
dim right-aligned label, plain value
Dresden
› Dülmen
Dortmundnever colour; the row may also be bold
Journey lookup (l) History (h) Back (esc)
not filled, not reversed; the mouse sends the same key
Map start — latitude,longitude ┌──────────────────────────────┐ │ › 51.05,13.74▏ │ └──────────────────────────────┘ enter saves · esc cancels
every key is text; esc leaves, then q quits
Currently: Offline · sachsen Change in Settings (s)
say what is true now, with the way to change it
enter opens MapSCII · g Organic Maps · s settings · a/z zoom · arrows pan · q quits
mapscii · …/.local/share/terminalclock/mapscii/node_modules/.bin/mapscii A very long line is clipped at the frame with an ellipsi…
| key | tab | |
|---|---|---|
| 1 | clock | |
| 2 | stopwatch | |
| 3 | timer | |
| 4 | alarm | |
| 5 | settings | |
| 6 | about | |
| 7 | calendar | add-on |
| 8 | prayer | add-on |
| 9 | weather | add-on |
| 0 | reminders | add-on |
| - | media | add-on |
| ! | commute | add-on |
| @ | dictionary | add-on |
| # | browser | add-on |
| $ | pyshell | add-on |
| & | agents | add-on |
| * | find | add-on |
| ~ | recent folders | add-on |
| + | encyclopedia | add-on |
| = | maps | add-on |
tab/shift+tab cycle, q/esc quit, space start / pause, r reset, l lap, arrows adjust.
Light to dense. One character per tone; braille uses the 2 × 4 dots of a cell instead.
| ascii | .:-=+*#%@ |
| blocks | ░▒▓█ |
| dots | ·:•● |
| fine | .'`^\",:;Il!i><~+_-?][}{1)(|/tfjrxnuvczXYUJCLQ0OZmwqpdbkhao*#MW&8%B@$ |
| braille | ⠁⠃⠇⡇⣇⣧⣷⣿ |
Copy what you need into another project. Nothing here depends on terminalclock.
/* terminalclock look: monochrome, one monospace grid. Tokens are the ones `clock serve` uses. */
:root{--bg:#0b0b0b;--fg:#ddd;--bd:#333}
:root[data-theme=light]{--bg:#fafafa;--fg:#111;--bd:#ccc}
body{background:var(--bg);color:var(--fg);font:13px/1.15 ui-monospace,Menlo,Consolas,monospace}
.tc-screen{white-space:pre} /* a character grid: never wrap */
.tc-bold{font-weight:700} /* terminal bold */
.tc-dim{opacity:.6} /* terminal dim */
.tc-rv{color:var(--bg);background:var(--fg)} /* terminal reverse: the active row only, never a button */
.tc-select:before{content:"\203A "} /* the selection marker */
.tc-cursor:after{content:"\258F";font-weight:700}
.tc-sep:before{content:" \00B7 "} /* separator between facts */
/* a shortcut is text with its key in brackets: "History (h)". No filled buttons, no colour. */
// Big block digits exactly as the clock draws them: every cell doubled, two spaces between glyphs.
function tcBigText(s, blinkOff) {
const rows = ['', '', '', '', ''];
for (const ch of s) {
let g = FONT[ch] || FONT[' '];
if (ch === ':' && blinkOff) g = [' ', ' ', ' ', ' ', ' '];
for (let i = 0; i < 5; i++) rows[i] += [...g[i]].map(c => c + c).join('') + ' ';
}
const r = rows.map(x => x.slice(0, -2)), w = Math.max(...r.map(x => x.length));
return r.map(x => x.padEnd(w)).join('\n');
}
// FONT = the "Digit font" JSON above ({"0": ["███","█ █",...], ":": [" ","█"," ","█"," "], ...})
from rich.box import ROUNDED
from rich.panel import Panel
from rich.table import Table
from rich.text import Text
from rich.style import Style
# the frame: rounded, dim, 1 line / 4 columns of air; content centred as one block (Align.center(Group(...)))
frame = Panel(body, box=ROUNDED, border_style="dim", padding=(1, 4), expand=True)
# a table row: dim right-aligned label, plain value (the About page)
t = Table.grid(padding=(0, 2))
t.add_column(style="dim", no_wrap=True, justify="right")
t.add_column(no_wrap=True)
t.add_row("version", "0.4.16")
# a list: the selection is marked with the arrow, never with colour
row = Text(("› " if selected else " ") + label, no_wrap=True, overflow="ellipsis")
# a shortcut: plain text with its key in brackets; the mouse sends the same key as the keyboard
button = Text(" History (h) ", style=Style(meta={"act": {"k": "h"}}))
# the one hint line in the footer, and the only emphasis: bold and dim
hint = Text("enter saves · esc cancels", style="dim", no_wrap=True)
title = Text("Currently: ", style="dim") + Text("Offline", style="bold")
bold ESC[1m ... ESC[22m
dim ESC[2m ... ESC[22m
reverse ESC[7m ... ESC[27m (active row only)
reset ESC[0m
no 30-37 / 38;5 / 38;2 colour codes anywhere
--btn background, 8px radius): the terminal rule "no filled buttons" is for the terminal panels.reverse is used to show the active or selected row in the settings, alarm, timer and stopwatch lists and for running states (14 places in clock.sh). New panels should mark the selection with ›.bold cyan on wide terminals (one place in tmaps.py): the only colour in the clock's own panels.clock setup, install.sh warnings) and in tools/off-grid by default: those are command-line tools, not panels (offgrid-maps.py --mono follows this sheet).Label (key) and every action has a key.› selection.…; limit is a setting.body_lines - 2).Currently: …).The Terminal rules applied to a page people read on screen and print. Reference implementation in this repo: index.html + resume.css + resume.js (data in _data/*.json). The PDF is the browser's print of the same page: one layout, not two.
@page size). Order: name and contacts, Education, Experience, Projects, Skills; newest first.h2 with a single bottom rule. Entry = bold name and dim role on the left, dim place and dates right-aligned.options.show_languages and options.languages_as_list in _data/personal.json (or RESUME_LANGS=0|1, RESUME_LANGS_LIST=0|1 per build). As a list they sit on one dim Tech: a · b line under the text instead of after the title. Strict line limit: options.max_line_chars (default 90, or RESUME_MAX_CHARS): skills, Tech lines and languages wrap to a new line between items, never mid-item; web uses --limit in ch.↳; a bold title, then the dim tags after ·, then one plain paragraph. Three lines of text per detail at most.·.·. Write the visible address, not a word like "email me".auto (follows the visitor's system, live), dark, light, e-ink; entries fold (↓ open, › closed); one dim hint line with the keys. Print: forced black on white, everything open, hint and theme line hidden, no entry split across pages, a heading never ends a page.| element | screen | |
|---|---|---|
| body | 13px/1.5, monospace stack of the Terminal, max-width: 96ch | 9.5pt/1.35, page margin 14mm |
name h1 | 24px bold | 20pt |
section h2 | 16px, rule var(--bd) | 11.5pt, break-after: avoid |
| dim | opacity: .6 | opacity: .6 |
| colours | --bg --fg --bd from Tokens above; auto = no data-theme attribute and a prefers-color-scheme rule | --bg:#fff --fg:#000 --bd:#999 whatever the theme |
| e-ink | #fff / #000, font-weight: 600 | n/a |
Motius GmbH München, Germany Tech Specialist · FunKI 2022 - Present ↳ Channel Estimation · Python MATLAB Implemented least-squares and MMSE estimators …
↓ Motius GmbH (open: header + detail lines) Tech Specialist · FunKI ↳ Channel Estimation … › Fraunhofer IIS (closed: header only) Research Assistant · Positioning
Languages Python · MATLAB · C++ · C Technologies Linux · Embedded C · Web of Things
expand all (e) · collapse all (c) · theme (t) · print (p) · source/* Resume: the terminalclock style sheet (STYLESHEET.html, section "Resume") applied to
the web page and its print/PDF output. Monochrome: text, bold, dim. No icons, no colour,
no filled buttons. Themes: auto (follows the visitor's system, live; the default), dark,
light, e-ink. No data-theme attribute = auto. Print is always black on white. */
:root {
--bg: #0b0b0b;
--fg: #ddd;
--bd: #333;
color-scheme: dark;
}
@media (prefers-color-scheme: light) {
:root:not([data-theme]) {
--bg: #fafafa;
--fg: #111;
--bd: #ccc;
color-scheme: light;
}
}
:root[data-theme="light"] {
--bg: #fafafa;
--fg: #111;
--bd: #ccc;
color-scheme: light;
}
:root[data-theme="eink"] {
--bg: #fff;
--fg: #000;
--bd: #000;
color-scheme: light;
}
* {
box-sizing: border-box;
}
html,
body {
margin: 0;
background: var(--bg);
color: var(--fg);
}
body {
font:
13px/1.5 ui-monospace,
Menlo,
Consolas,
"DejaVu Sans Mono",
monospace;
padding: 28px 6vw 80px;
}
:root[data-theme="eink"] body {
font-weight: 600;
}
main {
max-width: 96ch;
margin: 0 auto;
}
a {
color: inherit;
text-decoration: none;
border-bottom: 1px solid var(--bd);
}
a:hover {
border-bottom-color: var(--fg);
}
.dim {
opacity: 0.6;
}
.b {
font-weight: 700;
}
h1 {
font-size: 24px;
margin: 0 0 4px;
}
h2 {
font-size: 16px;
margin: 30px 0 8px;
border-bottom: 1px solid var(--bd);
padding-bottom: 4px;
}
header p {
margin: 2px 0;
}
.sep:before {
content: " \00B7 ";
}
/* entry: bold name + dim line left, dim place + dates right */
.entry {
display: grid;
grid-template-columns: 1fr auto;
gap: 0 18px;
margin: 10px 0 2px;
}
.entry .r {
text-align: right;
opacity: 0.6;
}
.entry .sub {
opacity: 0.6;
}
/* foldable entries: summary is the entry header, the marker is a glyph from the guide */
details.job {
margin: 0;
}
details.job > summary {
list-style: none;
cursor: pointer;
position: relative;
}
details.job > summary::-webkit-details-marker {
display: none;
}
details.job > summary:before {
content: "\203A";
position: absolute;
left: -2.2ch;
top: 0;
font-weight: 700;
}
details.job[open] > summary:before {
content: "\2193";
}
/* detail lines belong to the entry above: ↳ */
ul.items {
list-style: none;
margin: 2px 0 6px;
padding: 0;
}
ul.items li {
padding-left: 2ch;
text-indent: -2ch;
margin: 3px 0;
max-width: 90ch;
}
ul.items li:before {
content: "\21B3 ";
opacity: 0.6;
}
.tag,
.langs {
opacity: 0.6;
}
.langs {
display: block;
max-width: calc(var(--limit, 90) * 1ch);
}
.tag:before {
content: " \00B7 ";
}
p.desc {
margin: 2px 0 8px;
max-width: 90ch;
}
/* publications: [n] in dim, newest first; the abstract folds */
ol.pubs {
list-style: none;
margin: 6px 0;
padding: 0;
counter-reset: pub;
}
ol.pubs li {
counter-increment: pub;
position: relative;
padding-left: 5ch;
margin: 10px 0;
max-width: 90ch;
}
ol.pubs li:before {
content: "[" counter(pub) "]";
position: absolute;
left: 0;
opacity: 0.6;
}
details.abs {
margin: 2px 0 0;
}
details.abs > summary {
list-style: none;
cursor: pointer;
opacity: 0.6;
}
details.abs > summary::-webkit-details-marker {
display: none;
}
details.abs > summary:before {
content: "\203A ";
}
details.abs[open] > summary:before {
content: "\2193 ";
}
/* skills: the About pattern, dim right-aligned label + plain value */
/* strict line limit (--limit characters, personal.json options.max_line_chars): lists wrap between items */
.it {
white-space: nowrap;
}
.rows {
display: grid;
grid-template-columns: max-content minmax(0, 1fr);
gap: 2px 2ch;
margin: 6px 0;
max-width: calc(var(--limit, 90) * 1ch);
}
.rows dt {
text-align: right;
opacity: 0.6;
}
.rows dd {
margin: 0;
}
/* shortcuts are text with the key in brackets; one dim hint line */
button.link {
background: none;
border: 0;
color: inherit;
font: inherit;
cursor: pointer;
padding: 0;
text-decoration: underline;
}
button.link[aria-pressed="true"] {
font-weight: 700;
}
button.link[aria-pressed="true"]:before {
content: "\203A ";
}
.hint {
margin-top: 44px;
opacity: 0.6;
font-size: 12px;
}
.hint button.link {
opacity: 1;
}
@media (max-width: 640px) {
body {
padding: 20px 5vw 60px;
}
.entry {
grid-template-columns: 1fr;
}
.entry .r {
text-align: left;
}
}
@media print {
@page {
size: A4;
margin: 14mm;
}
:root:root,
:root[data-theme] {
--bg: #fff;
--fg: #000;
--bd: #999;
color-scheme: light;
}
body {
padding: 0;
font-size: 9.5pt;
line-height: 1.35;
font-weight: 400;
}
main {
max-width: none;
}
h1 {
font-size: 20pt;
}
h2 {
font-size: 11.5pt;
margin: 12pt 0 4pt;
break-after: avoid;
}
.hint,
.themes {
display: none;
}
details.job > summary:before {
content: none;
}
.entry {
grid-template-columns: 1fr auto;
}
.entry .r {
text-align: right;
}
.entry,
ul.items li,
details.job,
ol.pubs li {
break-inside: avoid;
}
details.abs > summary:before {
content: none;
}
a {
border: 0;
}
}
/* controls that need JavaScript (theme, fold-all, print) are hidden without it; the page itself,
its folds (<details>) and the auto dark/light theme (a CSS media query) work without */
.jsonly {
display: none;
}
.js .jsonly {
display: revert;
}
<details class="job" open>
<summary>
<div class="entry">
<div><span class="b">Company</span><br><span class="sub">Role<span class="sep"></span>Team</span></div>
<div class="r">City, Country<br>2022 - Present</div>
</div>
</summary>
<ul class="items">
<li><span class="b">Detail title</span><span class="tag">Python MATLAB</span><br>One plain paragraph.</li>
</ul>
</details>
<dl class="rows"><dt>Languages</dt><dd>Python<span class="sep"></span>C++</dd></dl>--bg --fg --bd, bold and dim; no colour anywhere, also not in links or tags.auto).Everything in Resume applies (tokens, glyphs, entries, links, themes, keys); the CV only adds length. Same resume.css plus the block in the kit below.
2019 - 2022, an open one 2022 - Present. Detail lines are marked ↳ as in the resume, four lines of text at most.[n] in dim from [1] at the top, newest first (ol.pubs in resume.css); the abstract is a fold (details.abs). Your own name is bold; the venue, year and DOI are one dim line.16mm 14mm. A running header Name · Curriculum Vitae top left and n/N bottom right, both dim and 8pt, from page 1 on. An entry is never split and a heading never ends a page.| element | value |
|---|---|
| body, headings, dim, colours | as Resume |
| year column | 12ch, dim, right-aligned, white-space: nowrap |
| gap between rows | 10px (screen) · 6pt (print) |
| publication hang | padding-left: 5ch; text-indent: -5ch |
| running header / footer | 8pt, dim, @page margin boxes (Chromium 131+; other browsers print without) |
2022 - Present Motius GmbH, München Tech Specialist · FunKI ↳ Channel Estimation · Python MATLAB 2019 - 2022 Fraunhofer IIS, Nürnberg Research Assistant · Positioning
[3] S. U. Ali, A. Author. Title of the paper. Venue, 2024 · doi:10.0000/xxxx [2] A. Author, S. U. Ali. Another title. Venue, 2023
Sheikh Usman Ali · Curriculum Vitae 2/3
/* CV = resume.css (which already has the [n] publication list and the folding abstract) plus: a year column and a running header. */
.cv-rows{display:grid;grid-template-columns:12ch 1fr;gap:10px 2ch;margin:6px 0}
.cv-rows dt{text-align:right;opacity:.6;white-space:nowrap}
.cv-rows dd{margin:0}
.cv-rows dd .sub{opacity:.6}
details.sec{margin:0} /* a CV section that folds on the web */
details.sec>summary{list-style:none;cursor:pointer}
details.sec>summary h2{display:inline-block;width:100%}
@media print{
@page{size:A4;margin:16mm 14mm 18mm;
@top-left{content:"Sheikh Usman Ali \00B7 Curriculum Vitae";font:8pt ui-monospace,monospace;opacity:.6}
@bottom-right{content:counter(page) "/" counter(pages);font:8pt ui-monospace,monospace;opacity:.6}}
.cv-rows>*{break-inside:avoid}
details.sec>summary:before{content:none}
}<details class="sec" open>
<summary><h2>Experience</h2></summary>
<dl class="cv-rows">
<dt>2022 - Present</dt>
<dd><span class="b">Company</span>, City<br><span class="sub">Role<span class="sep"></span>Team</span>
<ul class="items"><li><span class="b">Detail</span><span class="tag">Python</span><br>Plain paragraph.</li></ul></dd>
</dl>
</details>
<ol class="pubs">
<li><span class="b">Title</span><br><span class="b">S. U. Ali</span>, A. Author<br><span class="dim">Venue, 2024.</span>
<details class="abs"><summary>abstract</summary><p class="desc">Text.</p></details></li>
</ol>The Terminal rules on a slide: one frame, one idea, only text, bold and dim. Try the deck below (click it, then ← →, n notes, f fullscreen).
╭──────────────────────────────╮ │ │ │ Title in one line │ │ Name · Place · 2026 │ │ │ ╰──────────────────────────────╯
source or unit, one dim line
· · ·
→ steps through the points before the next slide, the current one bold with ›, the others dim; nothing is hidden. Two levels at most, the second marked ↳.tcBigText, see Digit font) with a dim unit line under it. ◀ back next ▶ left, n/N right. Keys: ← → / space / backspace, f fullscreen, n notes, t theme, p print.auto follows the laptop but pick one explicitly before projecting. Print is black on white.n and never printed; the PDF handout is slides only, one per landscape page.24px at 1280 wide, no more than two levels, no auto-advance.| element | at 1280 × 720 | unit used |
|---|---|---|
title h1 | 48px bold | 3.8cqw |
| body | 28px, line-height 1.3 | 2.2cqw |
| source, frame, big-digit rows | 20px dim | 1.6cqw |
| footer, notes | 16 to 19px dim | 1.3 to 1.5cqw |
| safe margin | 64px sides, 76px bottom | 5cqw / 6cqw |
| colours | --bg --fg --bd as Tokens above; print forces #fff / #000 | |
/* Presentation: a 16:9 deck. Needs --bg --fg --bd from the Tokens table. Sizes are container
units, so the same slide is 28px text at 1280 wide and scales to any screen or projector. */
.sl-deck {
position: relative;
aspect-ratio: 16/9;
container-type: inline-size;
overflow: hidden;
background: var(--bg);
color: var(--fg);
border: 1px solid var(--bd);
outline: 0;
}
.sl {
position: absolute;
inset: 0;
box-sizing: border-box;
display: none;
flex-direction: column;
justify-content: center;
padding: 5cqw 5cqw 6cqw;
font:
2.2cqw/1.3 ui-monospace,
Menlo,
Consolas,
"DejaVu Sans Mono",
monospace;
}
.sl.on {
display: flex;
}
.sl h1 {
font-size: 3.8cqw;
line-height: 1.15;
margin: 0 0 0.7em;
}
.sl p {
margin: 0 0 0.6em;
max-width: 40ch;
}
.sl .dim,
.sl .src {
opacity: 0.6;
}
.sl .src {
font-size: 1.6cqw;
}
.sl ul {
list-style: none;
margin: 0;
padding: 0;
}
.sl li {
position: relative;
padding-left: 2ch;
margin: 0.3em 0;
opacity: 0.6;
} /* every point stays visible */
.sl li.now {
opacity: 1;
font-weight: 700;
}
.sl li.now:before {
content: "\203A";
position: absolute;
left: 0;
} /* the current point */
.sl pre {
margin: 0;
font-size: 1.6cqw;
line-height: 1;
white-space: pre;
} /* frames and big digits */
.sl pre.sl-frame {
font-size: 2.2cqw;
line-height: 1.1;
} /* the title slide frame: bars connect */
.sl-foot {
position: absolute;
left: 5cqw;
right: 5cqw;
bottom: 2cqw;
display: flex;
justify-content: space-between;
opacity: 0.6;
font-size: 1.3cqw;
}
.sl-notes {
display: none;
position: absolute;
left: 5cqw;
right: 5cqw;
bottom: 5cqw;
border: 1px solid var(--bd);
background: var(--bg);
padding: 1cqw 1.5cqw;
font-size: 1.5cqw;
}
.sl-deck.notes .sl-notes {
display: block;
} /* n toggles; never printed */
@media print {
@page {
size: 1280px 720px;
margin: 0;
}
.sl-deck {
aspect-ratio: auto;
border: 0;
overflow: visible;
background: #fff;
color: #000;
container-type: normal;
}
.sl {
display: flex !important;
position: relative;
width: 1280px;
height: 720px;
break-after: page;
font-size: 28px;
--bg: #fff;
--fg: #000;
--bd: #999;
}
.sl h1 {
font-size: 48px;
}
.sl .src {
font-size: 20px;
}
.sl pre {
font-size: 20px;
}
.sl pre.sl-frame {
font-size: 28px;
}
.sl-foot {
font-size: 16px;
}
.sl li {
opacity: 1;
}
.sl li.now {
font-weight: 400;
}
.sl li.now:before {
content: none;
} /* handout: every point plain */
.sl-notes {
display: none !important;
}
}// tcDeck(root): root = .sl-deck holding .sl sections. Keys while it has focus:
// → space next point, then next slide ← backspace back f fullscreen n speaker notes
// Lists reveal one point at a time: the current <li> is bold with ›, the others stay dim.
function tcDeck(root) {
const s = [...root.querySelectorAll(".sl")];
let i = 0,
k = 0;
const pts = () => [...s[i].querySelectorAll("li")];
const mark = () => pts().forEach((x, j) => x.classList.toggle("now", j === k));
s.forEach((x, n) => {
const no = x.querySelector(".no");
if (no) no.textContent = n + 1 + "/" + s.length;
});
const go = (n, end) => {
i = Math.max(0, Math.min(s.length - 1, n));
s.forEach((x, j) => x.classList.toggle("on", j === i));
k = end ? Math.max(0, pts().length - 1) : 0;
mark();
};
const next = () => (k < pts().length - 1 ? (k++, mark()) : go(i + 1));
const back = () => (k > 0 ? (k--, mark()) : go(i - 1, true));
root.tabIndex = 0;
root.addEventListener("keydown", (e) => {
if (e.key === "ArrowRight" || e.key === " ") next();
else if (e.key === "ArrowLeft" || e.key === "Backspace") back();
else if (e.key === "f")
document.fullscreenElement ? document.exitFullscreen() : root.requestFullscreen();
else if (e.key === "n") root.classList.toggle("notes");
else return;
e.preventDefault();
});
go(0);
return { next, back };
}<div class="sl-deck" id="deck">
<section class="sl">
<pre class="sl-frame">╭──────────────────────────────╮
│ │
│ Title in one line │
│ Name · Place · 2026 │
│ │
╰──────────────────────────────╯</pre>
<div class="sl-foot"><span>◀ back next ▶</span><span class="no"></span></div>
</section>
<section class="sl">
<h1>One idea per slide</h1>
<ul><li>The first point</li><li class="now">The point being made</li><li>The next point</li></ul>
<div class="sl-notes">Notes: say the source here. Not printed.</div>
<div class="sl-foot"><span>◀ back next ▶</span><span class="no"></span></div>
</section>
<section class="sl">
<pre id="bignum"></pre>
<p class="src">source or unit, one dim line</p>
<div class="sl-foot"><span>◀ back next ▶</span><span class="no"></span></div>
</section>
</div>›, the rest stay visible.