The look from the server's tokens, pinned; the frame and bar follow the page's theme
ui/tokens.css is no longer a hand copy that drifts: scripts/fetch-tokens.sh takes the server's tokens.css at a git ref and tokens.lock.json pins it, as fetch-cli.sh does for the CLI. build.rs reads the two themes' --bg and --border out of it, so no colour is written in Rust. The content view reports the page's theme by a navigation the app refuses (llembas-theme:<name>), and the window, the title bar and the first-run page are painted in it and remember it. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
12 files changed
+994
-59
No files matched your search
+43
-19
@@ -1,6 +1,12 @@
|
||||
/* The first-run page. Tokens in tokens.css. */
|
||||
/* The first-run page. Every colour, size and space is a token from tokens.css (the server's,
|
||||
fetched by scripts/fetch-tokens.sh); the one value of this page's own is the card's width. */
|
||||
* { box-sizing: border-box; }
|
||||
|
||||
:root {
|
||||
/* The card's widest: a layout fact of this page, not a token the server has. */
|
||||
--card-max: 40rem;
|
||||
}
|
||||
|
||||
html, body { margin: 0; min-height: 100%; }
|
||||
|
||||
body {
|
||||
@@ -10,7 +16,7 @@ body {
|
||||
padding: var(--sp-4);
|
||||
background: var(--bg);
|
||||
color: var(--ink);
|
||||
font: var(--text-base) / 1.6 var(--font-body);
|
||||
font: var(--text-base) / var(--leading-normal) var(--font-body);
|
||||
}
|
||||
|
||||
.card {
|
||||
@@ -19,15 +25,26 @@ body {
|
||||
gap: var(--sp-6);
|
||||
padding: var(--sp-8);
|
||||
background: var(--surface);
|
||||
border: 1px solid var(--border);
|
||||
border: var(--border-w) solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
box-shadow: var(--shadow-card);
|
||||
box-shadow: var(--shadow-block-lg);
|
||||
}
|
||||
|
||||
.brand { display: grid; grid-template-columns: 40px 1fr; gap: var(--sp-3); align-items: center; }
|
||||
h1 { margin: 0; font: 600 var(--text-xl) / 1.2 var(--font-ui); }
|
||||
.brand { display: grid; grid-template-columns: var(--sp-10) 1fr; gap: var(--sp-3); align-items: center; }
|
||||
.brand img { width: var(--sp-10); height: var(--sp-10); }
|
||||
h1 { margin: 0; font: 600 var(--text-xl) / var(--leading-tight) var(--font-ui); }
|
||||
h1 b { color: var(--leaf); font-weight: 700; }
|
||||
h2 { margin: 0 0 var(--sp-3); font: 600 var(--text-sm) / 1.2 var(--font-ui); letter-spacing: 0.08em; color: var(--accent); }
|
||||
/* A section's heading, in brackets as on the server's screens: `[ SERVER ]`. The brackets are
|
||||
drawn here so the words alone are what gets translated. */
|
||||
h2 {
|
||||
margin: 0 0 var(--sp-3);
|
||||
font: 600 var(--text-sm) / var(--leading-tight) var(--font-ui);
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
color: var(--accent);
|
||||
}
|
||||
h2::before { content: "[ "; }
|
||||
h2::after { content: " ]"; }
|
||||
p { margin: 0; }
|
||||
.muted { color: var(--ink-muted); font-size: var(--text-sm); }
|
||||
|
||||
@@ -43,14 +60,17 @@ label, .label { font: var(--text-sm) / 1.4 var(--font-ui); color: var(--ink-mute
|
||||
input {
|
||||
height: var(--control-h);
|
||||
min-width: 0;
|
||||
padding: 0 var(--sp-3);
|
||||
padding: 0 var(--control-px);
|
||||
font: var(--text-base) var(--font-ui);
|
||||
color: var(--ink);
|
||||
background: var(--bg);
|
||||
border: 1px solid var(--border-strong);
|
||||
border: var(--border-w) solid var(--border-strong);
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
input:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
|
||||
input:focus-visible, .btn:focus-visible {
|
||||
outline: var(--outline-w) solid var(--accent);
|
||||
outline-offset: var(--outline-w);
|
||||
}
|
||||
|
||||
.btn {
|
||||
height: var(--control-h);
|
||||
@@ -58,9 +78,9 @@ input:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outl
|
||||
font: 600 var(--text-sm) var(--font-ui);
|
||||
color: var(--ink);
|
||||
background: var(--surface);
|
||||
border: 1px solid var(--border-strong);
|
||||
border: var(--border-w) solid var(--border-strong);
|
||||
border-radius: var(--radius);
|
||||
box-shadow: var(--press) var(--press) 0 rgba(0, 0, 0, 0.45);
|
||||
box-shadow: var(--shadow-block);
|
||||
cursor: pointer;
|
||||
}
|
||||
.btn:hover { background: var(--surface-hover); }
|
||||
@@ -87,9 +107,9 @@ input:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outl
|
||||
gap: var(--sp-2);
|
||||
align-items: center;
|
||||
min-height: var(--control-h);
|
||||
padding: 0 0 0 var(--sp-3);
|
||||
padding: 0 0 0 var(--control-px);
|
||||
background: var(--bg);
|
||||
border: 1px solid var(--border);
|
||||
border: var(--border-w) solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
.folders .path {
|
||||
@@ -101,8 +121,12 @@ input:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outl
|
||||
font: var(--text-sm) var(--font-ui);
|
||||
}
|
||||
.folders .path bdi { direction: ltr; unicode-bidi: isolate; }
|
||||
.folders .btn { height: calc(var(--control-h) - 2px); box-shadow: none; border-width: 0 0 0 1px; }
|
||||
.folders .empty { padding: var(--sp-3); color: var(--warning); font-size: var(--text-sm); }
|
||||
.folders .btn {
|
||||
height: calc(var(--control-h) - 2 * var(--border-w));
|
||||
box-shadow: none;
|
||||
border-width: 0 0 0 var(--border-w);
|
||||
}
|
||||
.folders .empty { padding: var(--control-px); color: var(--warning); font-size: var(--text-sm); }
|
||||
|
||||
.settings-grid {
|
||||
display: grid;
|
||||
@@ -118,12 +142,12 @@ input:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outl
|
||||
select {
|
||||
height: var(--control-h);
|
||||
min-width: 0;
|
||||
padding: 0 var(--sp-2);
|
||||
padding: 0 var(--control-px-sm);
|
||||
font: var(--text-sm) var(--font-ui);
|
||||
color: var(--ink);
|
||||
background: var(--bg);
|
||||
border: 1px solid var(--border-strong);
|
||||
border: var(--border-w) solid var(--border-strong);
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
.check { display: flex; align-items: center; gap: var(--sp-2); color: var(--ink); }
|
||||
.check input { width: 1.1rem; height: 1.1rem; margin: 0; accent-color: var(--accent); }
|
||||
.check input { width: var(--check-size); height: var(--check-size); margin: 0; accent-color: var(--accent); }
|
||||
Reference in new issue
Block a user