feat: a paper mode on randogoth.com, as a prompt command
Light mode is a remap of the sixteen EGA slots, not a second stylesheet. Every rule in bbs.css already goes through those variables, so the whole board inverts by redefining them and nothing below has to know. Warm greys on sepia, monochrome. Not an EGA palette and not pretending to be one: the amber-on-paper end of the same machine. Tones are picked by contrast ratio against the ground rather than by eye, and the ordering of the sixteen is preserved, so what was recessive stays recessive: --dgrey quiet, --blue chrome, --yellow the hotkeys, --lred the loudest thing on screen. Freed from EGA fidelity, --dgrey is lifted to 4.5:1 rather than the 2.7:1 its counterpart sits at on black. The switch is a command, not a button, because a board had no widgets. It names where it is going, so it reads [L]ight on a dark screen and [D]ark on a light one and the key moves with the label. L and D were the only two letters free across all 71 pages. It is injected by bbs.js rather than written into the template, so a reader without JS is not offered a switch that cannot work. The logo takes a second set of ramps: on paper presence is ink rather than light, so they run pale to dark and the feet stay the lightest step, which keeps the weight where the dark version puts it. The session's ramp index is shared, so the two themes are the same draw rendered two ways. Dark stays the default and the no-JS result. The preference is in localStorage rather than sessionStorage, since it is a preference and not a welcome screen, and it is applied from <head> before first paint. Also fixes a hardcoded #000 on the guestbook form, which would have been a black box on paper. Verified in a browser: 70 pages and 321 frame rows still exactly 80 columns, the command flips both ways, the ramp follows, and the choice survives a navigation. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
c97fcb249b
commit
f761709c68
3 changed files with 119 additions and 13 deletions
|
|
@ -26,6 +26,42 @@
|
|||
--lred: #ff5555; --lmagenta: #ff55ff; --yellow: #ffff55; --white: #ffffff;
|
||||
}
|
||||
|
||||
/* ── paper ──────────────────────────────────────────────────────────────
|
||||
* Light mode is a remap of the sixteen slots above, not a second stylesheet.
|
||||
* Every rule in this file goes through those variables, so the whole board
|
||||
* inverts by redefining them and nothing below needs to know.
|
||||
*
|
||||
* Warm greys on sepia, monochrome: this is not an EGA palette and does not
|
||||
* pretend to be one. It is the amber-on-paper end of the same machine. The
|
||||
* tones are picked by contrast ratio against the ground rather than by eye,
|
||||
* and the ordering of the sixteen is preserved, so what was recessive in the
|
||||
* dark theme stays recessive here: --dgrey is quiet, --blue is chrome,
|
||||
* --yellow carries the hotkeys, --lred is the loudest thing on the screen.
|
||||
*
|
||||
* Unlike the dark palette these are allowed to depart from EGA fidelity, so
|
||||
* --dgrey is lifted to 4.5:1 rather than left at the 2.7:1 its counterpart
|
||||
* sits at on black.
|
||||
*/
|
||||
[data-theme="light"] {
|
||||
color-scheme: light;
|
||||
--black: #f4ecdc; /* 1.0 the paper */
|
||||
--blue: #a0917c; /* 2.6 frames and rules */
|
||||
--brown: #887a64; /* 3.6 section marks */
|
||||
--lblue: #a0917c; /* 2.6 */
|
||||
--dgrey: #756b5b; /* 4.5 dates, numbers, the sysline */
|
||||
--green: #6a6053; /* 5.2 quote rule */
|
||||
--cyan: #655c50; /* 5.6 list bullets */
|
||||
--magenta: #655c50; /* 5.6 */
|
||||
--red: #534d43; /* 7.1 */
|
||||
--lgreen: #534d43; /* 7.1 code, counts, quoted text */
|
||||
--grey: #47423a; /* 8.5 body */
|
||||
--lcyan: #38342e; /* 10.5 links and the lightbar */
|
||||
--lmagenta:#38342e; /* 10.5 */
|
||||
--yellow: #2b2824; /* 12.5 headings, hotkeys, the address */
|
||||
--white: #1e1c19; /* 14.5 emphasis */
|
||||
--lred: #121210; /* 16.0 new */
|
||||
}
|
||||
|
||||
html { background: var(--black); }
|
||||
body {
|
||||
margin: 0; padding: 0;
|
||||
|
|
@ -183,7 +219,7 @@ a:visited { color: var(--lcyan); }
|
|||
.gb-row label { display: inline-block; width: 10ch; color: var(--dgrey); }
|
||||
.gb-row label.second { width: auto; padding: 0 1ch 0 3ch; }
|
||||
.gb-form input, .gb-form textarea {
|
||||
font: inherit; background: #000; color: var(--white);
|
||||
font: inherit; background: var(--black); color: var(--white);
|
||||
border: 1px solid var(--blue); outline: 0; padding: 0 1ch; }
|
||||
.gb-form input { width: 22ch; }
|
||||
.gb-form textarea { width: 58ch; vertical-align: top; resize: vertical; line-height: 1.4; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue