From 46c56ab57bc5587b3a38f0e184fad8b76cd39c0b Mon Sep 17 00:00:00 2001 From: Will Manning Date: Wed, 4 Nov 2026 14:43:04 -0500 Subject: [PATCH 01/17] Copy design system v121: one header, footer, and theme for every surface Signed-off-by: Will Manning --- src/styles/vortex-base.css | 2 +- src/styles/vortex-tokens.css | 2 +- src/styles/vortex.css | 483 +++++++++++++--------------- src/vendor/vortex-design/SHA256SUMS | 4 +- src/vendor/vortex-design/theme.d.ts | 11 +- src/vendor/vortex-design/theme.js | 75 ++++- 6 files changed, 297 insertions(+), 280 deletions(-) diff --git a/src/styles/vortex-base.css b/src/styles/vortex-base.css index 69b49384..8ad6a1b7 100644 --- a/src/styles/vortex-base.css +++ b/src/styles/vortex-base.css @@ -1,6 +1,6 @@ /* Vortex design system base, copied by tools/site-styles.mjs. Edit the system, then run tools/site-styles.mjs; do not edit here. - Made by: node tools/site-styles.mjs --sections base,brand,site,blog,tables,focus --faces --vx-face --base + Made by: node tools/site-styles.mjs --sections base,brand,chrome,site,blog,tables,focus --faces --vx-face --base sha256 7f7de2b97b16099662cddb9f80a900a2d8b4fdb967eef65bc47b8e773b540bf6 */ /* Vortex base: a small reset for a site drawn with the system, such as vortex.dev after Tailwind diff --git a/src/styles/vortex-tokens.css b/src/styles/vortex-tokens.css index 2c22e1a6..91f9cf09 100644 --- a/src/styles/vortex-tokens.css +++ b/src/styles/vortex-tokens.css @@ -1,6 +1,6 @@ /* Vortex design system tokens, copied by tools/site-styles.mjs. Edit the system, then run tools/site-styles.mjs; do not edit here. - Made by: node tools/site-styles.mjs --sections base,brand,site,blog,tables,focus --faces --vx-face --base + Made by: node tools/site-styles.mjs --sections base,brand,chrome,site,blog,tables,focus --faces --vx-face --base sha256 8395d1f647be119683c1eab9018b7ce891e3f2b7028a4bea04d78dca58402d9b */ :root, [data-theme="dark"] { --white: #ffffff; diff --git a/src/styles/vortex.css b/src/styles/vortex.css index dd39588d..2b79ea60 100644 --- a/src/styles/vortex.css +++ b/src/styles/vortex.css @@ -1,7 +1,7 @@ -/* Vortex design system components (sections: base, brand, site, blog, tables, focus), copied by tools/site-styles.mjs. +/* Vortex design system components (sections: base, brand, chrome, site, blog, tables, focus), copied by tools/site-styles.mjs. Edit the system, then run tools/site-styles.mjs; do not edit here. - Made by: node tools/site-styles.mjs --sections base,brand,site,blog,tables,focus --faces --vx-face --base - sha256 3847e56718f045c268a1c3ed33bf210dfb2f3aa544be69c3e445e9ac6c07568b */ + Made by: node tools/site-styles.mjs --sections base,brand,chrome,site,blog,tables,focus --faces --vx-face --base + sha256 3c47a0bfdb59156e3c329807e000fc94f039ec34462c8498dc91a4703934f756 */ /* ------------------------------------------------------------------ base */ /* Every component sizes with border-box, so it draws the same under a site's reset or none. */ @@ -87,34 +87,6 @@ main[tabindex="-1"]:focus { color: var(--accent-ink); text-decoration-color: currentColor; } -/* A quiet link in mono: header and footer navigation, feeds, source lines. */ -.vx-nav-link { - display: inline-flex; - align-items: center; - gap: var(--space-4); - color: var(--ink-muted); - text-decoration: none; - white-space: nowrap; - transition: color var(--vx-motion); -} -.vx-nav-link:hover, -.vx-nav-link[aria-current="page"], -.vx-nav-link[aria-current="true"] { - color: var(--ink); -} -.vx-nav-link svg { - width: 16px; - height: 16px; - fill: currentColor; -} -/* A source line: what a figure was read from, and when. */ -.vx-source { - display: inline-flex; - flex-wrap: wrap; - white-space: normal; - align-items: center; - gap: var(--space-4); -} /* Headings take ink, so a page never has to say so. It sits in base, which every site copies. :where() keeps it at no specificity, so any component that colours its own headings wins. */ @@ -239,6 +211,17 @@ main[tabindex="-1"]:focus { .vx-logos-set a:focus-visible img { opacity: 1; } +/* In Light the logos turn ink instead of white, at a little less weight. */ +[data-theme="light"] .vx-logos-set img { filter: brightness(0); opacity: 0.55; } +@media (prefers-color-scheme: light) { + [data-theme="system"] .vx-logos-set img { filter: brightness(0); opacity: 0.55; } +} +[data-theme="light"] .vx-logos-set a.is-soon img { opacity: 0.4; } +[data-theme="light"] .vx-logos-set :is(img:hover, a:focus-visible img) { opacity: 1; } +@media (prefers-color-scheme: light) { + [data-theme="system"] .vx-logos-set a.is-soon img { opacity: 0.4; } + [data-theme="system"] .vx-logos-set :is(img:hover, a:focus-visible img) { opacity: 1; } +} @keyframes vx-marquee { to { transform: translateX(-50%); @@ -276,23 +259,39 @@ main[tabindex="-1"]:focus { } } -/* ------------------------------------------------------------------ site */ -/* The frame: the terminal's dashed rule, 1px wide, 12px on and 4px off, in ink-body. The header - draws it below itself and the footer above itself, on the side that faces the page, and a - .vx-frame box draws it on all four, over the ground, so it can sit on the ASCII mark. Inside a - frame, the tabs' rule is dashed too. */ -:where(.vx-header, .vx-footer, .vx-frame) { - --vx-dash-x: linear-gradient(90deg, var(--ink-body) 12px, transparent 12px); - --vx-dash-y: linear-gradient(180deg, var(--ink-body) 12px, transparent 12px); +/* ------------------------------------------------------------------ chrome */ +/* What every surface shares, so home, the blog, the docs, the Explorer and bench read as one site: + the quiet links, the buttons, the header, the footer, the theme switch, and the 404. Every + surface copies this section. */ +/* A quiet link in mono: header and footer navigation, feeds, source lines. */ +.vx-nav-link { + display: inline-flex; + align-items: center; + gap: var(--space-4); + color: var(--ink-muted); + text-decoration: none; + white-space: nowrap; + transition: color var(--vx-motion); } -.vx-frame { - background-color: var(--ground); - background-image: var(--vx-dash-x), var(--vx-dash-x), var(--vx-dash-y), var(--vx-dash-y); - background-size: 16px 1px, 16px 1px, 1px 16px, 1px 16px; - background-repeat: repeat-x, repeat-x, repeat-y, repeat-y; - background-position: left top, left bottom, left top, right top; +.vx-nav-link:hover, +.vx-nav-link[aria-current="page"], +.vx-nav-link[aria-current="true"] { + color: var(--ink); +} +.vx-nav-link svg { + width: 16px; + height: 16px; + fill: currentColor; +} +/* A source line: what a figure was read from, and when. It is often also a nav link, so it comes + after that rule and wins the tie. */ +.vx-source { + display: inline-flex; + flex-wrap: wrap; + white-space: normal; + align-items: center; + gap: var(--space-4); } -.vx-frame .vx-tabs-list { border-bottom: 0; background: var(--vx-dash-x) left bottom / 16px 1px repeat-x; } .vx-btn { display: inline-flex; align-items: center; @@ -325,74 +324,28 @@ main[tabindex="-1"]:focus { /* Buttons side by side, primary first, wrapping onto a second row on a phone. */ .vx-btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-12); } -/* A 404 or error page: the hero with no bands under it. It takes the height its parent (a flex - column between the header and the footer) leaves, and centres its text in it. With the mark it - takes the homepage hero's two columns, and stacks below 1100px as the hero does. */ -.vx-status { flex: 1 0 auto; display: grid; grid-template-columns: minmax(0, 760px); align-content: center; gap: var(--space-48); padding: var(--space-32) var(--page-pad); } -.vx-status.has-mark { grid-template-columns: minmax(0, 760px) minmax(320px, 1fr); align-content: normal; } -.vx-status-text { display: grid; align-content: center; justify-items: start; gap: var(--space-24); } -.vx-status-text > * { margin: 0; } -/* The homepage's voice: a mono headline (vx-display-mono) and a mono sentence at the standfirst's size. */ -.vx-status-sentence { font: 400 16px/1.6 var(--font-mono); color: var(--ink-body); } -/* The 404's headline is its code: mono at the display size, so the page has one large thing to read. */ -.vx-status-code { font: 500 64px/0.98 var(--font-mono); letter-spacing: -0.04em; color: var(--ink); } -/* The mark's cell has a height to fill. Its host is never taller than 9/10 of the cell's width. */ -.vx-status-mark { position: relative; min-height: 0; container-type: size; } -.vx-status-mark > * { position: absolute; inset: 0; height: min(100cqh, 90cqw); margin: auto 0; } -@media (max-width: 1099px) { - .vx-status.has-mark { grid-template-columns: minmax(0, 1fr); align-content: center; gap: var(--space-24); } - .vx-status-mark { height: 320px; } -} -@media (max-width: 640px) { - .vx-status-mark { height: 240px; } -} - -/* A text field: raised, at control-md, with an edge that turns ink on hover, like the docs' search. - A row holds a field and its button. */ -.vx-field { - appearance: none; - height: var(--control-md); - margin: 0; - padding: 0 var(--space-12); - font: 400 14px/1 var(--font-sans); - color: var(--ink); - background: var(--raised); - border: 1px solid var(--edge); - border-radius: var(--radius-control); - transition: border-color var(--vx-motion); -} -.vx-field::placeholder { color: var(--ink-muted); opacity: 1; } -.vx-field:hover { border-color: var(--ink); } -.vx-field[aria-invalid="true"] { border-color: var(--error-ink); } -.vx-field:disabled { background: transparent; border-color: var(--line); color: var(--ink-muted); cursor: not-allowed; } -/* A compact field, for a pane's head or a toolbar. */ -.vx-field.is-sm { height: var(--control-sm); font-size: 13px; } -.vx-field-row { display: flex; gap: var(--space-8); max-width: 440px; } -.vx-field-row > .vx-field { flex: 1 1 auto; min-width: 0; } -.vx-field-error { margin: var(--space-8) 0 0; color: var(--error-ink); } - -/* The header: the wordmark, then either the site's navigation or the docs' label and search, - then the end group. */ +/* The header: one row, the same on every surface (DECISIONS 35). The wordmark, the site's links, + a surface's own tools (.vx-header-tools, which may be absent), then the end group: the theme + switch, the GitHub button and, on a narrow screen, the Menu. No breakpoint depends on the tools, + so at a given width the shared items look the same and sit in the same place on every surface; + the tools fit themselves into the room between. One solid line rule below it, sticky at the top + of the window. */ .vx-header { + position: sticky; + top: 0; + z-index: 1000; display: flex; align-items: center; gap: var(--space-24); height: 64px; - margin-top: var(--space-16); padding: 0 var(--page-pad); - background-color: var(--ground); - background-image: var(--vx-dash-x); - background-size: 16px 1px; - background-repeat: repeat-x; - background-position: left bottom; - position: relative; -} -.vx-header-start { display: flex; flex-shrink: 0; align-items: center; gap: var(--space-12); } -/* On one row, 32px set the wordmark and the end group apart from the links. */ -@media (min-width: 801px) { - .vx-header-start { padding-right: var(--space-32); } - .vx-header-end { padding-left: var(--space-32); } + background: var(--ground); + border-bottom: 1px solid var(--line); } +/* The sticky header must not cover what takes focus or what a link scrolls to (WCAG 2.4.11). + The header is 64px tall. */ +html:has(.vx-header) { scroll-padding-top: calc(var(--space-64) + var(--space-8)); } +.vx-header-start { display: flex; flex-shrink: 0; align-items: center; } .vx-header-mark { height: 24px; width: auto; display: block; } .vx-header-mark.is-light, [data-theme="light"] .vx-header-mark.is-dark { display: none; } [data-theme="light"] .vx-header-mark.is-light { display: block; } @@ -401,19 +354,27 @@ main[tabindex="-1"]:focus { [data-theme="system"] .vx-header-mark.is-dark { display: none; } [data-theme="system"] .vx-header-mark.is-light { display: block; } } -.vx-header-label { margin: 0; padding-left: var(--space-12); border-left: 1px solid var(--edge); line-height: 16px; } -/* The links follow the wordmark and the end group takes the slack, so the links stay put when the - end group's width changes (the blog's ThemeSwitch). */ .vx-header-nav { display: flex; gap: var(--space-24); } -.vx-header-end { display: flex; align-items: center; gap: var(--space-16); margin-left: auto; } -.vx-header-nav + .vx-header-end { margin-left: auto; } -@media (max-width: 760px) { - .vx-btn-count { display: none; } +/* A surface's tools take the room between the links and the end group, at its right end. */ +.vx-header-tools { display: flex; align-items: center; gap: var(--space-12); min-width: 0; margin-left: auto; } +.vx-header-end { display: flex; flex-shrink: 0; align-items: center; gap: var(--space-16); margin-left: auto; } +.vx-header-tools + .vx-header-end { margin-left: 0; } +/* On one row, 32px set the wordmark and the end group apart from the links and the tools. */ +@media (min-width: 961px) { + .vx-header-start { padding-right: var(--space-32); } + .vx-header-end { padding-left: var(--space-32); } } +/* A search field for the tools, as the docs use it, at control-md on raised. Below 960px its twin, + a search button (.vx-header-search-link) that opens the search page, takes its place. */ +.vx-header-search { position: relative; display: flex; align-items: center; flex: 0 1 320px; min-width: 160px; margin: 0; color: var(--ink-muted); } +.vx-header-search svg { position: absolute; left: var(--space-12); width: 16px; height: 16px; fill: currentColor; pointer-events: none; } +.vx-header-search input { box-sizing: border-box; width: 100%; height: var(--control-md); margin: 0; padding: 0 var(--space-12) 0 calc(var(--space-12) + 16px + var(--space-8)); background: var(--raised); border: 1px solid var(--edge); border-radius: var(--radius-control); color: var(--ink); font: 400 14px/1 var(--font-sans); transition: border-color var(--vx-motion); } +.vx-header-search input:hover { border-color: var(--ink); } +.vx-header-search input::placeholder { color: var(--ink-muted); opacity: 1; } +.vx-header-search-link { display: none; } /* The menu: on a narrow screen the site's links go behind a Menu button at the end of the row, a
, so it opens without scripts. Its panel is a popover under the button, on the ground with - the buttons' solid edge: it covers what is under it, and never reads as one of the page's dashed - frames. */ + the buttons' solid edge, so it covers what is under it. */ .vx-header-menu { display: none; } .vx-header-menu > summary { list-style: none; } .vx-header-menu > summary::-webkit-details-marker { display: none; } @@ -426,7 +387,7 @@ main[tabindex="-1"]:focus { top: calc(100% + var(--space-8)); right: var(--page-pad); display: grid; - width: 200px; + width: 220px; padding: var(--space-4) 0; background: var(--ground); border: 1px solid var(--edge); @@ -434,58 +395,42 @@ main[tabindex="-1"]:focus { } .vx-header-menu-panel .vx-nav-link { display: flex; min-height: 44px; padding: 0 var(--space-16); } .vx-header-menu-panel .vx-nav-link:hover { background: var(--wash); } -/* The site header needs about 790px on one row: the wordmark, five links and the GitHub button - with its count. Below 800px the links go into the menu. With the ThemeSwitch in its end group the - row needs about 900px, so they go below 920px. */ -@media (max-width: 800px) { - .vx-header.has-nav .vx-header-nav { display: none; } - .vx-header.has-nav .vx-header-menu { display: block; } - .vx-header.has-nav .vx-header-end { margin-left: auto; } -} -@media (max-width: 920px) { - .vx-header.has-nav:has(.vx-theme-switch) .vx-header-nav { display: none; } - .vx-header.has-nav:has(.vx-theme-switch) .vx-header-menu { display: block; } - .vx-header.has-nav:has(.vx-theme-switch) .vx-header-end { margin-left: auto; } -} -/* On a phone the row is the wordmark, the GitHub mark, the switch and the menu, closer together. - With the switch the Menu button keeps its icon and drops its word below 480px. */ -@media (max-width: 480px) { - .vx-header { gap: var(--space-16); } - .vx-header-end { gap: var(--space-8); } - .vx-header-end:has(.vx-theme-switch) .vx-header-menu-text { - position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; - } -} -@media (max-width: 640px) { - .vx-header-label, .vx-header-end .is-wide { display: none; } -} -/* With the Menu button, the wordmark, the GitHub button with the repository's name and the button - need about 390px on one row, and about 500px with the switch. So the button drops the name and - keeps its mark below 480px, or 560px with the switch. Its aria-label still names the repository. */ -@media (max-width: 560px) { - .vx-header-end:has(.vx-theme-switch) .vx-header-repo { display: none; } -} -@media (max-width: 480px) { - .vx-header-repo { display: none; } +/* The end group's switch and GitHub button have twin rows in the panel (.vx-header-menu-spill), + which show only when the end group hands them over, below 640px. */ +.vx-header-menu-spill { display: none; } +/* Below 1180px the GitHub button keeps only its mark. Its aria-label still names the repository. */ +@media (max-width: 1180px) { + .vx-header-repo, .vx-header .vx-btn-count { display: none; } +} +/* Below 960px the links go into the Menu, and a search field gives way to its button. */ +@media (max-width: 960px) { + .vx-header-nav, .vx-header-search { display: none; } + .vx-header-menu { display: block; } + .vx-header-search-link { display: inline-flex; } } -/* A display line never strands one word on its last line, and on phones its lines balance. */ -.vx-display { text-wrap: pretty; } -/* On phones it sets at the h1 size, where 64px would take four lines. */ +/* On a phone the row is the wordmark, the tools, and the Menu, whose button keeps its icon: the + switch and the GitHub button move into the Menu's panel, under the links, each on a row with a + solid line rule above it. So the row fits 320px with a surface's tools. */ @media (max-width: 640px) { - .vx-display { font-size: 48px; text-wrap: balance; } + .vx-header { gap: var(--space-12); } + .vx-header-end, .vx-header-tools { gap: var(--space-8); } + .vx-header-end > .vx-theme-switch, .vx-header-end > .vx-header-github { display: none; } + .vx-header-menu-spill { display: flex; align-items: center; justify-content: space-between; gap: var(--space-8); padding: var(--space-8) var(--space-16); border-top: 1px solid var(--line); } + a.vx-header-menu-spill { padding-block: 0; } + .vx-header-menu-text { + position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; + } } +/* The footer: the same on every surface. The LF mark, the small print, and the project's links, + over one solid line rule. */ .vx-footer { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-16) var(--space-24); - margin-bottom: var(--space-16); padding: var(--space-16) var(--page-pad); - background-image: var(--vx-dash-x); - background-size: 16px 1px; - background-repeat: repeat-x; - background-position: left top; + border-top: 1px solid var(--line); font: 400 11px/1.5 var(--font-mono); letter-spacing: 0.02em; /* the one tracked style: small print */ color: var(--ink-muted); @@ -495,59 +440,131 @@ main[tabindex="-1"]:focus { @media (prefers-color-scheme: light) { [data-theme="system"] .vx-footer-mark { filter: invert(1); } } -.vx-footer-text { flex: 1 1 420px; min-width: 0; margin: 0; } +.vx-footer-text { flex: 1 1 420px; min-width: 0; max-width: 72ch; margin: 0; text-wrap: balance; } .vx-footer-credit { white-space: nowrap; } -.vx-footer-nav { display: flex; flex-wrap: wrap; gap: var(--space-8) var(--space-16); } -/* The solid variant, for a tool such as bench, whose own controls and tables sit under the header: - the same header and footer, with solid rules in line, flush to the window's edges, and a rule - only on the side that faces the page. */ -.vx-header.is-solid, .vx-footer.is-solid { --vx-dash-x: linear-gradient(var(--line), var(--line)); } -.vx-header.is-solid { margin-top: 0; background-image: var(--vx-dash-x); background-position: left bottom; } -.vx-footer.is-solid { margin-bottom: 0; background-image: var(--vx-dash-x); background-position: left top; } -/* The tools variant, for a tool such as bench: one sticky row holds the wordmark, the tool's label, - its own controls (.vx-header-tools) and the end group. The site's links are always behind the - Menu button, so the controls have the room. The label can be the page's h1, so it takes no margin. */ -.vx-header.has-tools { position: sticky; top: 0; z-index: 1000; } -/* The sticky header must not cover what takes focus or what a link scrolls to (WCAG 2.4.11). - The header is 64px tall. */ -html:has(.vx-header.has-tools) { scroll-padding-top: calc(var(--space-64) + var(--space-8)); } -/* No divider beside the label: it reads as part of the wordmark. */ -.vx-header.has-tools .vx-header-label { border-left: 0; padding-left: 0; } -.vx-header.has-tools .vx-header-nav { display: none; } -.vx-header.has-tools .vx-header-menu { display: block; } -.vx-header-tools { display: flex; align-items: center; gap: var(--space-12); margin-left: auto; min-width: 0; } -/* The end group's spill items (.vx-header-spill), such as a theme toggle, have a twin row in the - Menu's panel (.vx-header-menu-spill), shown only when the item moves there. */ -.vx-header-menu-panel .vx-header-menu-spill { display: none; } -.vx-header-menu-panel button.vx-nav-link { - appearance: none; - background: none; - border: 0; - width: 100%; - text-align: start; +.vx-footer-nav { display: flex; flex-wrap: wrap; gap: var(--space-8) var(--space-16); margin-left: auto; } +@media (max-width: 640px) { .vx-footer-nav { margin-left: 0; } } + +/* A fieldset, so its margin and minimum width are cleared. Until a script presses a button, the + choice THEME_BOOTSTRAP wrote to data-theme-choice on the root shows pressed. */ +/* The text switch (vx-switch) draws the theme switch's group, with words on its buttons. */ +.vx-theme-switch, +.vx-switch { + display: inline-flex; + gap: 2px; + min-width: 0; + margin: 0; + padding: 2px; + background: var(--raised); + border: 1px solid var(--edge); + border-radius: var(--radius-control); +} +.vx-theme-switch button { + all: unset; + box-sizing: border-box; cursor: pointer; + display: grid; + place-items: center; + width: 26px; + height: 26px; + border-radius: var(--radius-control); + color: var(--ink-muted); + transition: color var(--vx-motion), background-color var(--vx-motion); } -/* Below 960px the row keeps the controls: the label leaves the view but stays the page's heading, - and the GitHub button keeps only its mark. */ -@media (max-width: 960px) { - .vx-header.has-tools .vx-header-label { - display: block; position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; - } - .vx-header.has-tools .vx-header-repo, .vx-header.has-tools .vx-btn-count { display: none; } - .vx-header.has-tools .vx-header-tools { gap: var(--space-8); } +.vx-switch button { + all: unset; + box-sizing: border-box; + cursor: pointer; + height: 26px; + padding: 0 var(--space-12); + border-radius: var(--radius-control); + font: 400 12.5px/26px var(--font-sans); + white-space: nowrap; + color: var(--ink-muted); + transition: color var(--vx-motion), background-color var(--vx-motion); +} +.vx-theme-switch button:hover, +.vx-switch button:hover { color: var(--ink); } +.vx-theme-switch button[aria-pressed="true"], +.vx-switch button[aria-pressed="true"], +:root[data-theme-choice="light"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="light"], +:root[data-theme-choice="dark"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="dark"], +:root[data-theme-choice="system"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="system"] { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); } +/* After the pressed rule, so a press shows on the current choice too. */ +.vx-theme-switch button:active, +.vx-switch button:active { background: var(--edge); } +.vx-theme-switch svg { width: 16px; height: 16px; fill: currentColor; } + +/* A 404 or error page: the hero with no bands under it. It takes the height its parent (a flex + column between the header and the footer) leaves, and centres its text in it. With the mark it + takes the homepage hero's two columns, and stacks below 1100px as the hero does. */ +.vx-status { flex: 1 0 auto; display: grid; grid-template-columns: minmax(0, 760px); align-content: center; gap: var(--space-48); padding: var(--space-32) var(--page-pad); } +.vx-status.has-mark { grid-template-columns: minmax(0, 760px) minmax(320px, 1fr); align-content: normal; } +.vx-status-text { display: grid; align-content: center; justify-items: start; gap: var(--space-24); } +.vx-status-text > * { margin: 0; } +/* The homepage's voice: a mono headline (vx-display-mono) and a mono sentence at the standfirst's size. */ +.vx-status-sentence { font: 400 16px/1.6 var(--font-mono); color: var(--ink-body); } +/* The 404's headline is its code: mono at the display size, so the page has one large thing to read. */ +.vx-status-code { font: 500 64px/0.98 var(--font-mono); letter-spacing: -0.04em; color: var(--ink); } +/* The mark's cell has a height to fill. Its host is never taller than 9/10 of the cell's width. */ +.vx-status-mark { position: relative; min-height: 0; container-type: size; } +.vx-status-mark > * { position: absolute; inset: 0; height: min(100cqh, 90cqw); margin: auto 0; } +@media (max-width: 1099px) { + .vx-status.has-mark { grid-template-columns: minmax(0, 1fr); align-content: center; gap: var(--space-24); } + .vx-status-mark { height: 320px; } } -/* On a phone the spill items move into the Menu's panel, under the links, and the Menu button - keeps only its icon, so the row stays one row down to 320px. */ @media (max-width: 640px) { - .vx-header.has-tools { gap: var(--space-12); } - .vx-header.has-tools .vx-header-end > .vx-header-spill { display: none; } - .vx-header.has-tools .vx-header-menu-spill { - display: flex; align-items: center; gap: var(--space-8); border-top: 1px solid var(--line); - } - .vx-header.has-tools .vx-header-menu-spill svg { width: 16px; height: 16px; flex-shrink: 0; } - .vx-header.has-tools .vx-header-menu-text { - position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; - } + .vx-status-mark { height: 240px; } +} +@media (max-width: 640px) { .vx-status-code { font-size: 48px; } } + +/* ------------------------------------------------------------------ site */ +/* The frame: the terminal's dashed rule, 1px wide, 12px on and 4px off, in ink-body. A .vx-frame + box draws it on all four sides, over the ground, so it can sit on the ASCII mark. It is the + homepage's motif: the header and footer draw a solid line rule on every surface. Inside a frame, + the tabs' rule is dashed too. */ +:where(.vx-frame) { + --vx-dash-x: linear-gradient(90deg, var(--ink-body) 12px, transparent 12px); + --vx-dash-y: linear-gradient(180deg, var(--ink-body) 12px, transparent 12px); +} +.vx-frame { + background-color: var(--ground); + background-image: var(--vx-dash-x), var(--vx-dash-x), var(--vx-dash-y), var(--vx-dash-y); + background-size: 16px 1px, 16px 1px, 1px 16px, 1px 16px; + background-repeat: repeat-x, repeat-x, repeat-y, repeat-y; + background-position: left top, left bottom, left top, right top; +} +.vx-frame .vx-tabs-list { border-bottom: 0; background: var(--vx-dash-x) left bottom / 16px 1px repeat-x; } + +/* A text field: raised, at control-md, with an edge that turns ink on hover, like the docs' search. + A row holds a field and its button. */ +.vx-field { + appearance: none; + height: var(--control-md); + margin: 0; + padding: 0 var(--space-12); + font: 400 14px/1 var(--font-sans); + color: var(--ink); + background: var(--raised); + border: 1px solid var(--edge); + border-radius: var(--radius-control); + transition: border-color var(--vx-motion); +} +.vx-field::placeholder { color: var(--ink-muted); opacity: 1; } +.vx-field:hover { border-color: var(--ink); } +.vx-field[aria-invalid="true"] { border-color: var(--error-ink); } +.vx-field:disabled { background: transparent; border-color: var(--line); color: var(--ink-muted); cursor: not-allowed; } +/* A compact field, for a pane's head or a toolbar. */ +.vx-field.is-sm { height: var(--control-sm); font-size: 13px; } +.vx-field-row { display: flex; gap: var(--space-8); max-width: 440px; } +.vx-field-row > .vx-field { flex: 1 1 auto; min-width: 0; } +.vx-field-error { margin: var(--space-8) 0 0; color: var(--error-ink); } + +/* A display line never strands one word on its last line, and on phones its lines balance. */ +.vx-display { text-wrap: pretty; } +/* On phones it sets at the h1 size, where 64px would take four lines. */ +@media (max-width: 640px) { + .vx-display { font-size: 48px; text-wrap: balance; } } /* The mono headline: tight, as the old terminal set it, and at the h3 size on phones. */ @@ -555,7 +572,6 @@ html:has(.vx-header.has-tools) { scroll-padding-top: calc(var(--space-64) + var( @media (max-width: 640px) { .vx-display-mono { font-size: 28px; } } -@media (max-width: 640px) { .vx-status-code { font-size: 48px; } } /* The results table: every system's figure for each benchmark, in a frame. Vortex's column is Blue, the best figure in each row is underlined, as a model card marks its best score, and the last @@ -664,55 +680,6 @@ html:has(.vx-header.has-tools) { scroll-padding-top: calc(var(--space-64) + var( .vx-bars.is-lg .vx-bar { gap: var(--space-12); font-size: 12.5px; } .vx-bars.is-lg .vx-bar-track { height: 10px; } -/* A fieldset, so its margin and minimum width are cleared. Until a script presses a button, the - choice THEME_BOOTSTRAP wrote to data-theme-choice on the root shows pressed. */ -/* The text switch (vx-switch) draws the theme switch's group, with words on its buttons. */ -.vx-theme-switch, -.vx-switch { - display: inline-flex; - gap: 2px; - min-width: 0; - margin: 0; - padding: 2px; - background: var(--raised); - border: 1px solid var(--edge); - border-radius: var(--radius-control); -} -.vx-theme-switch button { - all: unset; - box-sizing: border-box; - cursor: pointer; - display: grid; - place-items: center; - width: 26px; - height: 26px; - border-radius: var(--radius-control); - color: var(--ink-muted); - transition: color var(--vx-motion), background-color var(--vx-motion); -} -.vx-switch button { - all: unset; - box-sizing: border-box; - cursor: pointer; - height: 26px; - padding: 0 var(--space-12); - border-radius: var(--radius-control); - font: 400 12.5px/26px var(--font-sans); - white-space: nowrap; - color: var(--ink-muted); - transition: color var(--vx-motion), background-color var(--vx-motion); -} -.vx-theme-switch button:hover, -.vx-switch button:hover { color: var(--ink); } -.vx-theme-switch button[aria-pressed="true"], -.vx-switch button[aria-pressed="true"], -:root[data-theme-choice="light"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="light"], -:root[data-theme-choice="dark"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="dark"], -:root[data-theme-choice="system"] .vx-theme-switch:not(:has([aria-pressed="true"])) button[data-choice="system"] { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); } -/* After the pressed rule, so a press shows on the current choice too. */ -.vx-theme-switch button:active, -.vx-switch button:active { background: var(--edge); } -.vx-theme-switch svg { width: 16px; height: 16px; fill: currentColor; } /* ------------------------------------------------------------------ blog */ /* CodeBlock and Callout, as the blog's renderer writes them. The docs draw the same two with @@ -1020,5 +987,5 @@ html:has(.vx-header.has-tools) { scroll-padding-top: calc(var(--space-64) + var( phone menu is a hidden checkbox, so its label shows the checkbox's ring. Rows and segments inside a clipped container draw it inside their edge. */ :is(a, button, input, select, textarea, summary, [tabindex]):focus-visible, -.vx-docs-toggle:focus-visible ~ .vx-docs-header .vx-docs-menu { outline: 2px solid var(--focus-ring); outline-offset: 2px; } +.vx-docs-toggle:focus-visible ~ .vx-header .vx-docs-menu { outline: 2px solid var(--focus-ring); outline-offset: 2px; } :is(.vx-docs-nav a, .vx-docs-nav summary, .vx-docs-toc a, .vx-docs-fold a, .vx-post-row, .vx-tree-node, .vx-tabs-list button, .vx-switch button, .vx-theme-switch button, .vx-table-wrap :is(a, button), .vx-docs-main table.docutils a):focus-visible { outline-offset: -2px; } diff --git a/src/vendor/vortex-design/SHA256SUMS b/src/vendor/vortex-design/SHA256SUMS index af0252cb..df2dfa32 100644 --- a/src/vendor/vortex-design/SHA256SUMS +++ b/src/vendor/vortex-design/SHA256SUMS @@ -10,6 +10,6 @@ dacdc197af6ae4fe546907d9578e36f32343d9ff4112c641a00428c6c28fed2f callout.js c14d5d902bb8e35ff18070d7757dd882177ab2f854cdaa77e3dfa5ea346ea8e5 code-block.js 0c888f22fbce806a23dfa33f8412492781e697d79b03d46f52d7b164a1e68607 cover.d.ts fade12fdb73a1e944d5b12413cedd7310c8a91cf7d9c03e087783ecf58dcfb5b cover.js -f2637460ba584e680f9901515397ff36e1172d3d09951bfeec0f190077542c01 theme.d.ts -78f6d1122dacdbba04c87ad49e9bb7d1f42c463a7013085c4e2f7c5c8e3e128e theme.js +7af6ebb36f8957ec01a16e4a39b5535c2b5a1fa6be696cda9da326eafa337d17 theme.d.ts +ecae164cc7e1084d84bf5d5307ba6bb28a73319c09d115a45e41b30c66b395fe theme.js 61ccfa8f87f6917449750d42b424bcdaf4ba93d273305675628a18ef8253e6da vortex-mark-geometry.js diff --git a/src/vendor/vortex-design/theme.d.ts b/src/vendor/vortex-design/theme.d.ts index 65e6075c..76916501 100644 --- a/src/vendor/vortex-design/theme.d.ts +++ b/src/vendor/vortex-design/theme.d.ts @@ -9,8 +9,15 @@ export type Themeable = readonly string[]; export function isThemeable(path: string, themeable?: Themeable): boolean; export function themeBootstrap(options?: { themeable?: Themeable }): string; export const THEME_BOOTSTRAP: string; -export function readChoice(storage: Pick | null | undefined): ThemeChoice; -export function saveChoice(storage: Pick | null | undefined, choice: ThemeChoice): void; +/** The cookie's choice when it holds one, else storage's, else "system". */ +export function readChoice(storage: Pick | null | undefined, cookie?: string): ThemeChoice; +/** The cookie text: on vortex.dev and its subdomains there, on the host only elsewhere. */ +export function themeCookie(choice: string, hostname: string | undefined, secure: boolean): string | null; +export function saveChoice( + storage: Pick | null | undefined, + choice: ThemeChoice, + options?: { jar?: { cookie: string } | null; hostname?: string; secure?: boolean }, +): void; export function resolveTheme(choice: string, prefersDark: boolean): Theme; export function themeFor(choice: string, prefersDark: boolean, options?: { path?: string; themeable?: Themeable }): Theme; export function applyTheme(choice?: ThemeChoice, options?: { path?: string; themeable?: Themeable }): ThemeChoice; diff --git a/src/vendor/vortex-design/theme.js b/src/vendor/vortex-design/theme.js index e2374e6c..40e54e34 100644 --- a/src/vendor/vortex-design/theme.js +++ b/src/vendor/vortex-design/theme.js @@ -1,8 +1,8 @@ -// The theme choice shared by docs, the blog and the Explorer (and bench once it adopts the -// ThemeSwitch): light, dark or system. -// It lives in localStorage["vx-theme"] and lands on . The default is Dark. -// The choice itself also lands on , so the switch can show it pressed -// before its script runs. +// The theme choice every surface shares (DECISIONS 37): light, dark or system. The default is System. +// It lives in a vx-theme cookie on vortex.dev, so a choice made on the blog holds on docs, bench and +// the Explorer too, and in localStorage["vx-theme"] as a fallback for hosts outside vortex.dev. It +// lands on . The choice itself also lands on , so the switch +// can show it pressed before its script runs. // // A site whose other pages are Dark only passes `themeable`, a list of path prefixes: "/blog" // covers /blog and every page under it. Pages outside the list stay Dark whatever the choice. @@ -10,6 +10,9 @@ const KEY = "vx-theme"; const CHOICES = ["light", "dark", "system"]; const PLAIN_PATH = /^\/[\w.~\/-]*$/; +const DEFAULT = "system"; +const YEAR = 31536000; +const COOKIE = /(?:^|;\s*)vx-theme=([^;]*)/; // "/blog/" and "/blog" are one prefix. "/" stays "/". const trim = (prefix) => (prefix.length > 1 ? prefix.replace(/\/+$/, "") : prefix); @@ -34,9 +37,11 @@ export function themeBootstrap({ themeable } = {}) { list = JSON.stringify(themeable.map(trim)); } return ( - `(function(){var r=document.documentElement,c="dark",t=${list},ok=!t;` + + `(function(){var r=document.documentElement,c="${DEFAULT}",v=null,t=${list},ok=!t;` + 'if(t){var p=location.pathname;for(var i=0;i (typeof document === "undefined" ? null : document); + +/** Writes the choice to storage and to the cookie. `jar` is document by default. */ +export function saveChoice(storage, choice, { jar = page(), hostname = globalThis.location?.hostname, secure = globalThis.location?.protocol === "https:" } = {}) { try { storage?.setItem(KEY, choice); } catch { - // Blocked storage only costs the memory of the choice. + // Blocked storage only costs this origin's copy of the choice. + } + const text = themeCookie(choice, hostname, secure); + try { + if (jar && text) jar.cookie = text; + } catch { + // A blocked cookie only costs the other surfaces' copy. } } @@ -80,10 +107,19 @@ const store = () => { } }; const dark = () => matchMedia("(prefers-color-scheme: dark)"); +const cookies = () => { + try { + return document.cookie; + } catch { + return ""; + } +}; +// Fired on document when a switch changes the choice, so every switch on the page shows it. +const CHANGE = "vx-theme:change"; // Sets data-theme and data-theme-choice from the stored choice. `themeable` and `path` (the // current page's by default) keep a page outside the list Dark. -export function applyTheme(choice = readChoice(store()), { themeable, path = location.pathname } = {}) { +export function applyTheme(choice = readChoice(store(), cookies()), { themeable, path = location.pathname } = {}) { const root = document.documentElement; root.dataset.themeChoice = choice; root.dataset.theme = themeFor(choice, dark().matches, { path, themeable }); @@ -92,26 +128,33 @@ export function applyTheme(choice = readChoice(store()), { themeable, path = loc // Wires a .vx-theme-switch: buttons carry data-choice and aria-pressed. // With { apply: false } it shows the current choice (the bootstrap's data-theme-choice, else the -// theme) without changing it on load. `themeable` is the same list the bootstrap took. Returns a -// function that removes the listeners. +// theme) without changing it on load. `themeable` is the same list the bootstrap took. Every switch +// on the page follows a change made in any of them (the header and its Menu panel both hold one). +// Returns a function that removes the listeners. export function mountThemeSwitch(el, { apply = true, themeable } = {}) { const buttons = [...el.querySelectorAll("button[data-choice]")]; const root = document.documentElement.dataset; - let choice = apply ? applyTheme(undefined, { themeable }) : CHOICES.includes(root.themeChoice) ? root.themeChoice : root.theme === "light" ? "light" : "dark"; + let choice = apply ? applyTheme(undefined, { themeable }) : CHOICES.includes(root.themeChoice) ? root.themeChoice : DEFAULT; const press = () => buttons.forEach((b) => b.setAttribute("aria-pressed", String(b.dataset.choice === choice))); const onClick = (e) => { choice = e.currentTarget.dataset.choice; saveChoice(store(), choice); applyTheme(choice, { themeable }); + document.dispatchEvent(new CustomEvent(CHANGE, { detail: choice })); + }; + const onChange = (e) => { + if (CHOICES.includes(e.detail)) choice = e.detail; press(); }; const onOs = () => choice === "system" && applyTheme(choice, { themeable }); const media = dark(); for (const b of buttons) b.addEventListener("click", onClick); + document.addEventListener(CHANGE, onChange); media.addEventListener("change", onOs); press(); return () => { for (const b of buttons) b.removeEventListener("click", onClick); + document.removeEventListener(CHANGE, onChange); media.removeEventListener("change", onOs); }; } From 6ad0f4e0055bfb91bbd8e9053749487d9d4b797e Mon Sep 17 00:00:00 2001 From: Will Manning Date: Wed, 4 Nov 2026 14:51:22 -0500 Subject: [PATCH 02/17] Give the site and bench one header, footer, 404, favicon, and theme Every surface draws the same header (links, then the theme switch and the GitHub button), with bench's controls in the tools slot between them. The home page gets the switch too, System is the default, and the choice is shared through a vx-theme cookie on vortex.dev. bench drops its own theme toggle and favicon pair and renders the site's footer and 404. Signed-off-by: Will Manning --- REUSE.toml | 3 +- public/bench/favicon.ico | Bin 0 -> 13575 bytes public/bench/icon-dark.png | Bin 4798 -> 0 bytes public/bench/icon-light.png | Bin 4303 -> 0 bytes src/app/(bench)/bench/[...notFound]/page.tsx | 5 +- src/app/(bench)/bench/layout.test.ts | 46 ++++----- src/app/(bench)/bench/layout.tsx | 46 +++------ src/app/(bench)/bench/not-found.tsx | 22 +++++ src/app/(site)/globals.css | 6 ++ src/app/(site)/layout.tsx | 2 +- src/app/(site)/not-found.tsx | 33 +------ src/app/global-not-found.tsx | 5 +- src/bench/components/BenchHeader.tsx | 16 ++- src/bench/components/ThemeToggle.test.tsx | 69 ------------- src/bench/components/ThemeToggle.tsx | 85 ---------------- src/bench/components/Toolbar.tsx | 4 +- src/bench/lib/next-config.test.ts | 2 +- src/bench/lib/scroll-restore.test.ts | 2 +- src/bench/lib/scroll-restore.ts | 4 +- src/bench/lib/server-smoke.test.ts | 23 +++-- src/bench/styles/globals.css | 55 +++++------ src/bench/styles/tokens.test.ts | 4 +- src/components/layout/footer.tsx | 12 +-- src/components/layout/header-nav.tsx | 4 +- src/components/layout/header.tsx | 98 +++++++------------ src/components/not-found/index.tsx | 35 +++++++ src/components/theme-switch/index.tsx | 42 ++++---- src/lib/theme.ts | 82 +++++++++------- tests/unit/layout.test.tsx | 76 +++++++------- tests/unit/route-theme.test.ts | 8 +- tests/unit/theme-switch.test.ts | 67 +++++++++---- tests/unit/theme.test.ts | 45 +++++---- 32 files changed, 389 insertions(+), 512 deletions(-) create mode 100644 public/bench/favicon.ico delete mode 100644 public/bench/icon-dark.png delete mode 100644 public/bench/icon-light.png create mode 100644 src/app/(bench)/bench/not-found.tsx delete mode 100644 src/bench/components/ThemeToggle.test.tsx delete mode 100644 src/bench/components/ThemeToggle.tsx create mode 100644 src/components/not-found/index.tsx diff --git a/REUSE.toml b/REUSE.toml index d6ee6f1c..9be0208a 100644 --- a/REUSE.toml +++ b/REUSE.toml @@ -52,8 +52,7 @@ path = [ "src/assets/vortex_wordmark_dark_theme.svg", "public/bench/Vortex_Black_NoBG.svg", "public/bench/Vortex_White_NoBG.svg", - "public/bench/icon-dark.png", - "public/bench/icon-light.png", + "public/bench/favicon.ico", ] SPDX-FileCopyrightText = "Copyright the Vortex contributors" SPDX-License-Identifier = "CC-BY-4.0" diff --git a/public/bench/favicon.ico b/public/bench/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..744a7734d7d626932d664e29fbc194b189c70056 GIT binary patch literal 13575 zcmV+iHTcQ^00962000000096X0P!>c02TlM0EtjeM-2)Z3IG5A4M|8uQUCw}00001 z00;&E003NasAd2F00D1uPE-NUqIa4A05q#fL_t(|+U=bQ^i@^$$1e(wsYr?9lo4Xi zri4R+AvmB(NGJ{@ND7&dh9+3KWQC$B#GtV(!vq{sN*r)P<{zjlNX#;pi6E$mmVyJK z2;R=;zI%S%-{bv$@0@$@d+!c=uk~I3`p0{}_s%=}+LLhYFu7xJB5a@R7oM{=Z%Bzjm&|bpJg^D-84h z7Ju_7g?$uuSJ+;D7BR7St%dLCZ56usjyF?ThtLQ9 zXI`K%*^e4}C>*G;oBv(K#B%TOgw97Q^j8??hwQ8UC#;(>eC&TWBA2oLcRtcz12M7O z+}#O{`}lYDI)$|gn=>B?sfiJ^zqkbN7*J~S+ZRfIw%ZPctBx=!p0mrd^xZt zD;1_G3{mLlubr4!DxJQgfA^iK@UFra;^fBI;;-4$elA1~1F^&#+3rIWt_(Q6ICDH; zEuZq&_E1Mkj$#S2Hvau}il5}#A`V;8$Y7PiJqo@3wHFhsx>27$TH$(y#R{K@b5griFp_Lgld7RB*5i9@9p9NG&N2FXDnW@4?y z@iTi6EK<1G5$ds6Bgws9PNDTx96#HYgIRu#U>Di;V$BsgD?H>Bdf~-M@&THypd8a; z-9p?TpLUSKc&E^iB2JM{@Y_#t3hY9$oEUe&%bkLlhB$!$AZjw$Dd;hXWz@D&=%g@1 z;WOFv0%z;?qy_6QVj=`+ZHZR-@oD-oTLc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mXQ4s|2?^@U+e!Z{^sFMK|8ON+}+b@{{sZ-!IiqIx$Xb} N002ovPDHLkV1mt45_|vv literal 0 HcmV?d00001 diff --git a/public/bench/icon-dark.png b/public/bench/icon-dark.png deleted file mode 100644 index 43199fc40725b4ecee55744e173e53e810a00ff3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4798 zcmV;v5<%^WP)004R> z004l5008;`004mK004C`008P>0026e000+ooVrmw00002VoOIv0RM-N%)bBt5=%)$ zK~#9!?OiRH>r53s`5vBU>%KbTh@*}=iXteAVjXo9MNt$*W#u}GVo?;gDArLFMG;&- zS6pzpF4tw%i%6PgX3k6|ZGJBub?!uANB6$P+py&Z~&C3y~BV94Y51^Y^ZblfF6*&)}8zB!*pbZ)>arE1wT^dV2 zIX{4I2I#M)pFAwOF@_db_yD>c75xCZ5f$xyIV!rhKsy|DM8j3l{ilvEL`C-qXsG{p z`=O#Ssv|u6RiDTLW6W`3=CMK@VK*?-8$Ev^Kx2d{)_A8g{f*pwD;#wTG>8Zj3h1X) zLlpd59YZ{(XYy%A-_3sTIfv5~__+h19l|s1>1!hLY3K{vJbRKL0T5!8+0ruq&1JQm zUBOG9+et7PI(1A64#^V{g-%k?9L4qd{>>0myklwmdd-r}U5CZ_-P4)>Q!VF>I(}n9ACd}7zg3AqU^WPmLpo9B1HtY&X-WV?! zYhSy{=mK?q&D{d+W;S*OdT~+II7z>GyW?{_1d@dUA(re{zX!jDOdf@Dg2L?}Rn+oV zuv48H%TJjjQY&WX(Pc=gTdac{=;48O!gLj6p!t_^|kMJzN5DdQ15<3ZoW4`aJDtcP^-9_ynt{ucL zgQq2XovLw@%8CIx>KADcHc#DB_>#6kMLd< zkiTD`in~m6yxyatF~*w~x&U6$La}7OkaWGYZ^O^n;Z(Ss#HeeS?Y>Q@-}6f--oRbK7D-tMTJ?4njU}rcQs@@a=O49pf5M~_X2yuMlJFh| z!%VqBkG1tAeTZRmm3j*eB$eSa>Kb|3dv|^yCV~r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dn_7Hzg{bH5<3!q?TvvdP9QnUg_=XfT=24Qv;YyXI}~x5V*k zea^BoR4I_moS!K}hB$P-3Tc?r!GR8+yrP9}W?qpnkbNDLW5rN%W7P_(DvM^x-TkG{ z<88cx$0ig>MCR7Y@N$vf)J(#nS@gcXbQd-$G+lHt@=S1?f!fq;0lcINLBd?3VYB4! z)mA?17c!ayt%X3$r)JKJAtO>?2}?@bDo&S?dOAsNw*6u!^|?Mdb=MaYO7 z_})p#q8HpNTdnTRAq##+sqm1IIZs)UzBLlr10fr5JD+P+4PO%6;9)hqPalM)V-*Tn z5OZo|4jzY(LUPwdTJ@CYD1Er&;PXr(=CfpOB}rm!8^3QXWEOsdLId^p+hRVRtmH_@ z9Gf#~lEhNc1jQvcSH1cav|n^(1{H3|l316Q5R}h^I6_d_PT9z!V#AC(EE)MTdO7}6 zRo6b5g~bKVt0^0LBgvUq%p(a1&sUBAM9bque^Ws2(y0~Fq^WW4JKZqb0%fKKI9+igk;xEmzYKGCDlulTr7#I=MFZ`xsR>?2{=Lzlhc?2ZG`0(~4s; zOCn;t!-qR|<=k&Nc#SK5!oRS7DI?bwI;!hYOvkkF6~7|D6<6GcZ4ua?p#xZ0k8(4t zp_8I7V}zeanE~1}#T$z_ojb^KPspRk`(Vyc?TZ@eYv>;)t+UK3_>8VPtI^=H3hUQuH+oOBi3Ma#&r)=mu{*8}{u|vF9FU!ELlu?iS?}GdPykJHFw+_=nCH`9HS<1dwAHAL#%9002ovPDHLkV1i0DK)(P0 diff --git a/src/app/(bench)/bench/[...notFound]/page.tsx b/src/app/(bench)/bench/[...notFound]/page.tsx index b9bb9e75..b5bbd934 100644 --- a/src/app/(bench)/bench/[...notFound]/page.tsx +++ b/src/app/(bench)/bench/[...notFound]/page.tsx @@ -6,9 +6,8 @@ import { notFound } from 'next/navigation'; /** * Every bench URL no other bench route matches. The app has two root layouts, * and an unmatched URL gets the marketing site's 404 (src/app/global-not-found.tsx). - * This route keeps bench's unmatched paths out of the site's 404. bench has no - * not-found.tsx, so Next.js answers with its default 404 document: it carries - * bench's metadata, but not bench's layout, header, or `lang`. + * This route keeps bench's unmatched paths out of the site's 404: they get + * bench's not-found.tsx, the same 404 body in bench's layout. */ export default function UnmatchedBenchPath(): never { notFound(); diff --git a/src/app/(bench)/bench/layout.test.ts b/src/app/(bench)/bench/layout.test.ts index 83c3d723..c1c07a36 100644 --- a/src/app/(bench)/bench/layout.test.ts +++ b/src/app/(bench)/bench/layout.test.ts @@ -18,8 +18,7 @@ vi.mock('@/styles/vortex.css', () => ({})); // The site's footer, as a stand-in that shows the props bench gives it. Each page renders the // header (BenchHeader), because the filter dropdown takes the page's data. vi.mock('@/components/layout/footer', () => ({ - Footer: ({ origin, solid }: { origin: string; solid: boolean }) => - createElement('footer', { 'data-origin': origin, 'data-solid': String(solid) }), + Footer: ({ origin }: { origin: string }) => createElement('footer', { 'data-origin': origin }), })); // next/font is a build step; its classes set the design system's --vx-face-* variables. vi.mock('@/lib/fonts', () => ({ FONT_CLASSES: 'face-sans face-mono' })); @@ -31,13 +30,18 @@ vi.mock('next/headers', () => ({ headers: async () => requestHeaders })); const html = renderToStaticMarkup(await RootLayout({ children: createElement('main') })); /** Load the layout's markup in a browser-like document, scripts on or off. */ -function load(runScripts: boolean, theme?: string): Document { +function load(runScripts: boolean, theme?: string, cookie?: string): Document { return new JSDOM(`${html}`, { url: 'https://bench.vortex.dev/', ...(runScripts ? { runScripts: 'dangerously' as const } : {}), beforeParse(window) { + // jsdom has no matchMedia: an OS set to Dark. + Object.assign(window, { matchMedia: () => ({ matches: true }) }); if (theme !== undefined) { - window.localStorage.setItem('bench-theme', theme); + window.localStorage.setItem('vx-theme', theme); + } + if (cookie !== undefined) { + window.document.cookie = cookie; } }, }).window.document; @@ -51,10 +55,15 @@ describe('RootLayout', () => { expect(load(true).documentElement.classList.contains('no-js')).toBe(false); }); - it('still applies a stored theme before first paint', () => { - const doc = load(true, 'dark'); + it('applies a stored theme before first paint', () => { + const doc = load(true, 'light'); expect(doc.documentElement.classList.contains('js')).toBe(true); - expect(doc.documentElement.dataset.theme).toBe('dark'); + expect(doc.documentElement.dataset.theme).toBe('light'); + }); + + // The choice made on vortex.dev, the docs or the Explorer holds here (design system DECISIONS 37). + it('applies the choice that the vortex.dev cookie shares before storage', () => { + expect(load(true, 'dark', 'vx-theme=light').documentElement.dataset.theme).toBe('light'); }); it("self-hosts the system's faces, as the site does, with no request to Google Fonts", () => { @@ -63,7 +72,8 @@ describe('RootLayout', () => { }); it('follows the OS until a reader chooses a theme', () => { - expect(load(true).documentElement.dataset.theme).toBe('system'); + expect(load(true).documentElement.dataset.theme).toBe('dark'); + expect(load(true).documentElement.dataset.themeChoice).toBe('system'); expect(load(false).documentElement.dataset.theme).toBe('system'); }); }); @@ -80,9 +90,9 @@ describe("the layout's skip link", () => { }); describe("the layout's frame", () => { - it("puts every page above the site's footer, pointed at the site, with a solid rule", () => { + it("puts every page above the site's one footer, pointed at the site", () => { expect(html).toMatch( - /
<\/main>