A local-first multi-agent app development platform, built on PenguinHarness
feat(ui): W1a — theme typefaces (Primer Mona Sans, Console IBM Plex Sans) and Primer's neutral grays (#894)
Yaowei Zheng05f16a612231
diff --git a/THIRD-PARTY-NOTICES.md b/THIRD-PARTY-NOTICES.mdindex c97e1d5b..c91cc749 100644--- a/THIRD-PARTY-NOTICES.md+++ b/THIRD-PARTY-NOTICES.md@@ -136,21 +136,6 @@ unmodified out of the `@fontsource/ibm-plex-sans-condensed` npm package.Source: <https://fontsource.org/fonts/ibm-plex-sans-condensed> — the`@fontsource/ibm-plex-sans-condensed` version resolved in `pnpm-lock.yaml`.-## Commit Mono fonts — `commit-mono-*.woff2` in the web assets--Present wherever the Web App ships: every release archive, the desktop application, the assets the-server serves, and the npm server package's `web-dist/`.--Commit Mono at weights 400 and 700, one latin file each. The web build copies the files unmodified-out of the `@fontsource/commit-mono` npm package.--**License: SIL Open Font License 1.1.** The full text ships in every build as-`fonts-licenses/commit-mono.txt`, mirrored from the package's `LICENSE` into-`packages/ui/src/fonts/LICENSES/commit-mono.txt`.--Source: <https://fontsource.org/fonts/commit-mono> — the `@fontsource/commit-mono` version resolved-in `pnpm-lock.yaml`.-## Noto Sans SC fonts — `noto-sans-sc-*.woff2` in the web assetsPresent wherever the Web App ships: every release archive, the desktop application, the assets thediff --git a/changelog/unreleased/2026-09-30-console-typeface.md b/changelog/unreleased/2026-09-30-console-typeface.mdnew file mode 100644index 00000000..a168c191--- /dev/null+++ b/changelog/unreleased/2026-09-30-console-typeface.md@@ -0,0 +1,18 @@+# Console reads in IBM Plex Sans and sets code in JetBrains Mono++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`+- **PR:** [#894](https://github.com/Prism-Shadow/penguin-harness/pull/894)++[中文版](2026-09-30-console-typeface.zh.md)++Console (极客) had set its whole interface in Commit Mono (navigation, buttons, labels, headings and settings) and kept IBM Plex Sans for message text, the composer and Session titles. Following the owner's decision, IBM Plex Sans became Console's main face everywhere, and JetBrains Mono replaced Commit Mono as its monospaced face. Console's colours, text sizes, spacing and square shapes stayed as they were.++## Details++- Navigation, buttons, labels, settings, headings and page titles took IBM Plex Sans, with Noto Sans SC for Chinese as before. The selected navigation row is still marked in bold.+- Monospace stayed only on code and on deliberately technical marks, all now set in JetBrains Mono: code blocks and inline code, a notice's status tag (`[ OK ]`, `[WARN]`, `[FAIL]`, `[INFO]`, `[NOTE]`), the uppercase label and the block progress bar of a step in the agent's work, and chart axis labels. A step's duration and step count stay monospaced; the description beside a tool step took the sans, as in the other themes.+- **Fonts** in Settings → Appearance: a chosen Latin face now changes Console's whole interface, as it does under Primer and Frost. Before, it changed only Console's reading text.+- Commit Mono is no longer bundled. Its font files, its licence text and its entry on the Credits page were removed, so a build is about 95 KB smaller. JetBrains Mono was already bundled for Primer and Frost, so no font was added, and the Credits page lists Console among the themes that use it.+- The gallery's Fonts (字体) page shows JetBrains Mono in Console's row of the default-faces table.diff --git a/changelog/unreleased/2026-09-30-console-typeface.zh.md b/changelog/unreleased/2026-09-30-console-typeface.zh.mdnew file mode 100644index 00000000..69fa5aef--- /dev/null+++ b/changelog/unreleased/2026-09-30-console-typeface.zh.md@@ -0,0 +1,18 @@+# 极客主题(Console)改用 IBM Plex Sans,代码改用 JetBrains Mono++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`+- **PR:** [#894](https://github.com/Prism-Shadow/penguin-harness/pull/894)++[English](2026-09-30-console-typeface.md)++极客主题(Console)此前整个界面都用 Commit Mono(导航、按钮、标签、标题与设置皆然),只有消息正文、输入框与会话标题用 IBM Plex Sans。按产品负责人的决定,IBM Plex Sans 成为极客主题各处的主字体,等宽字体由 Commit Mono 改为 JetBrains Mono。极客主题的配色、字号、间距与直角造型保持不变。++## 细节++- 导航、按钮、标签、设置、各级标题与页面标题改用 IBM Plex Sans,中文仍为 Noto Sans SC。选中的导航行仍以粗体标出。+- 等宽字体只留在代码与刻意的技术标记上,并统一改用 JetBrains Mono:代码块与行内代码、通知的状态标签(`[ OK ]`、`[WARN]`、`[FAIL]`、`[INFO]`、`[NOTE]`)、工作步骤的大写标签与块状进度条,以及统计图的坐标轴刻度。步骤的耗时与步数仍为等宽;工具步骤旁的说明文字改用无衬线字体,与其他主题一致。+- 设置 → 外观中的**字体**:所选英文字体现在作用于极客主题的整个界面,与通用、白领一致;此前只改变极客主题的阅读文字。+- 不再打包 Commit Mono:其字体文件、许可文本与「版权信息」页中的条目均已移除,构建产物因此约小 95 KB。JetBrains Mono 此前已为通用与白领打包,因此没有新增字体;「版权信息」页把极客列为使用它的主题之一。+- 画廊的「字体」页随之在默认字体表的极客一行显示 JetBrains Mono。diff --git a/changelog/unreleased/2026-09-30-primer-neutral-grays.md b/changelog/unreleased/2026-09-30-primer-neutral-grays.mdnew file mode 100644index 00000000..45342e8c--- /dev/null+++ b/changelog/unreleased/2026-09-30-primer-neutral-grays.md@@ -0,0 +1,16 @@+# Primer's blacks, whites and grays become pure neutral++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`++[中文版](2026-09-30-primer-neutral-grays.zh.md)++In light mode, Primer (通用), the default theme, had used Tailwind's stock gray scale. That scale has a slate tint (hue about 264), which made its blacks and grays look off. Following the owner's reference, the zero-chroma grays of turborepo.dev (Vercel's Geist), Primer's blacks, whites and grays became pure neutral, with zero hue, in both modes. Every gray stayed on its step, and only the tint was removed.++## Details++- In light mode, the gray scale behind Primer's tokens and the Web App's `gray-*` classes moved to Tailwind's `neutral` scale, step for step: `gray-50` went from `#f9fafb` to `#fafafa`, `gray-200` from `#e5e7eb` to `#e5e5e5`, `gray-500` from `#6a7282` to `#737373` and `gray-900` from `#101828` to `#171717`, and the other steps followed. The sidebar fill, the lines, and the body, muted and subtle inks changed with it.+- Primer's own accent, which the "Theme's own" swatch paints, went from `#111827` to `#171717` in light mode and from `#f3f4f6` to `#f5f5f5` in dark mode. Its hover, pressed, wash and outline colours, and its label ink in dark mode, moved to the matching neutral steps.+- The focus ring and the scrollbar thumb had kept a faint blue tint. Both were made neutral in both modes.+- Dark mode's grays were already neutral, and their values and contrast stayed the same. The status tones, the chart colours and the five accent presets did not change.diff --git a/changelog/unreleased/2026-09-30-primer-neutral-grays.zh.md b/changelog/unreleased/2026-09-30-primer-neutral-grays.zh.mdnew file mode 100644index 00000000..0c714887--- /dev/null+++ b/changelog/unreleased/2026-09-30-primer-neutral-grays.zh.md@@ -0,0 +1,16 @@+# 通用主题(Primer)的黑白灰改为纯中性色++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`++[English](2026-09-30-primer-neutral-grays.md)++默认主题通用(Primer)的浅色此前使用 Tailwind 自带的 gray 灰阶。这套灰阶带有石板蓝色偏(色相约 264),黑色与灰色因此看起来发偏。按产品负责人给出的参考(turborepo.dev 所用的 Vercel Geist 零彩度灰),通用主题的黑、白、灰在浅色与深色下都改为色相为零的纯中性色。每一级灰都保持原来的档位,只去掉了色偏。++## 细节++- 浅色下,通用主题的令牌与 Web App 的 `gray-*` 类名所依托的灰阶整条改为 Tailwind 的 `neutral` 灰阶,逐级对应:`gray-50` 由 `#f9fafb` 改为 `#fafafa`,`gray-200` 由 `#e5e7eb` 改为 `#e5e5e5`,`gray-500` 由 `#6a7282` 改为 `#737373`,`gray-900` 由 `#101828` 改为 `#171717`,其余各级同样处理。侧栏底色、各级线条,以及正文、次要与再次要墨色随之改变。+- 通用主题自带的强调色(「随主题」色块所画的颜色)在浅色下由 `#111827` 改为 `#171717`,在深色下由 `#f3f4f6` 改为 `#f5f5f5`。其悬停、按下、淡底与描边各色,以及深色下的标签墨色,都改为对应的中性色阶。+- 焦点环与滚动条滑块原先还带一点蓝调,在两种明暗下都改为中性色。+- 深色的灰阶本来就是中性色,取值与对比度保持不变。状态色调、图表配色与五个强调色预设均未改动。diff --git a/changelog/unreleased/2026-09-30-primer-typeface.md b/changelog/unreleased/2026-09-30-primer-typeface.mdnew file mode 100644index 00000000..6b2ce33c--- /dev/null+++ b/changelog/unreleased/2026-09-30-primer-typeface.md@@ -0,0 +1,17 @@+# Primer, the default theme, takes GitHub Primer's typefaces++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`++[中文版](2026-09-30-primer-typeface.zh.md)++Primer (通用), the default theme, had set its text in the platform's system fonts. It switched to the typefaces GitHub Primer uses: Mona Sans for Latin text, JetBrains Mono for code and Noto Sans SC as its CJK face, each placed ahead of the system fonts it used before, which stay behind them as the fallback. Primer's text sizes and spacing stayed as they were. Its grays changed separately, in [Primer's blacks, whites and grays become pure neutral](2026-09-30-primer-neutral-grays.md).++## Details++- The interface, reading text and headings took Mona Sans; code blocks, inline code and other monospaced text took JetBrains Mono; the CJK face became Noto Sans SC, ahead of PingFang SC and Microsoft YaHei.+- All three faces were already bundled — Mona Sans for the font pairing, JetBrains Mono for Frost, Noto Sans SC for Console — so the build gained no font files. A Primer session began downloading Mona Sans, JetBrains Mono and the Noto Sans SC slices its Chinese text touches.+- **Fonts** in Settings → Appearance still replaces the Latin face and the CJK face; under Primer, "Theme default" came to mean Mona Sans and Noto Sans SC.+- The Credits page listed Primer among the themes that use Mona Sans, JetBrains Mono and Noto Sans SC.+- The gallery's Fonts (字体) page showed the new faces: in Primer's row of the default-faces table and in Primer's specimens.diff --git a/changelog/unreleased/2026-09-30-primer-typeface.zh.md b/changelog/unreleased/2026-09-30-primer-typeface.zh.mdnew file mode 100644index 00000000..30815201--- /dev/null+++ b/changelog/unreleased/2026-09-30-primer-typeface.zh.md@@ -0,0 +1,17 @@+# 默认主题通用(Primer)改用 GitHub Primer 的字体++- **Date:** 2026-09-30+- **Type:** feature+- **Scope:** `ui`, `web`, `ui-gallery`++[English](2026-09-30-primer-typeface.md)++默认主题通用(Primer)此前使用平台的系统字体,现改用 GitHub Primer 所用的字体:英文为 Mona Sans,代码为 JetBrains Mono,CJK 字体为 Noto Sans SC;三者各自排在原先的系统字体之前,系统字体留作兜底。通用主题的字号与间距保持不变;灰阶另行调整,见[通用主题(Primer)的黑白灰改为纯中性色](2026-09-30-primer-neutral-grays.zh.md)。++## 细节++- 界面、正文与标题改用 Mona Sans;代码块、行内代码及其他等宽文本改用 JetBrains Mono;CJK 字体改为 Noto Sans SC,排在 PingFang SC 与 Microsoft YaHei 之前。+- 这三款字体此前均已打包(Mona Sans 供字体组合选用,JetBrains Mono 属白领,Noto Sans SC 属极客),构建产物没有新增字体文件。通用主题的会话开始下载 Mona Sans、JetBrains Mono,以及其中文文本用到的 Noto Sans SC 分片。+- 设置 → 外观中的**字体**仍可分别替换英文与中文字体;在通用主题下,「随主题」即指 Mona Sans 与 Noto Sans SC。+- 「版权信息」页把通用列为使用 Mona Sans、JetBrains Mono 与 Noto Sans SC 的主题之一。+- 画廊的「字体」页随之显示新字体:默认字体表中通用一行,以及通用主题的字样。diff --git a/packages/ui-gallery/src/foundations/typography.tsx b/packages/ui-gallery/src/foundations/typography.tsxindex 0f60c084..44b05446 100644--- a/packages/ui-gallery/src/foundations/typography.tsx+++ b/packages/ui-gallery/src/foundations/typography.tsx@@ -1,8 +1,9 @@/*** Foundations › Type: the role scale from h1 to caption, prose, the chrome line and code, each set* in its own role tokens, English and Chinese side by side — the step between rungs, the heading- * weights, Console's mono chrome against its sans prose, and where a Latin face hands over to its- * CJK fallback, all at a glance. `prose` is the reading face; `ui` is the chrome face `body` sets.+ * weights, the chrome face against the reading face (one family in every theme today, two names a+ * theme may set apart), and where a Latin face hands over to its CJK fallback, all at a glance.+ * `prose` is the reading face; `ui` is the chrome face `body` sets.*/import type { CSSProperties } from "react";import { useGallery } from "../state";diff --git a/packages/ui-gallery/test/color.test.ts b/packages/ui-gallery/test/color.test.tsindex 9faf6046..aa81d90f 100644--- a/packages/ui-gallery/test/color.test.ts+++ b/packages/ui-gallery/test/color.test.ts@@ -17,8 +17,8 @@ describe("colour maths", () => {const black = parseCssColor("#000000")!;expect(contrastRatio(white, black)).toBeCloseTo(21, 5);expect(contrastRatio(black, white)).toBeCloseTo(21, 5);- // Tailwind gray-500 on white: the app's muted text.- expect(contrastRatio(parseCssColor("#6a7282")!, white)).toBeCloseTo(4.83, 1);+ // Tailwind neutral-500 on white: Primer's muted text.+ expect(contrastRatio(parseCssColor("#737373")!, white)).toBeCloseTo(4.74, 1);expect(wcagGrade(7.1)).toBe("AAA");expect(wcagGrade(4.5)).toBe("AA");expect(wcagGrade(3.2)).toBe("AA large");diff --git a/packages/ui/package.json b/packages/ui/package.jsonindex f75cf74e..557546ab 100644--- a/packages/ui/package.json+++ b/packages/ui/package.json@@ -37,7 +37,6 @@"@fontsource-variable/jetbrains-mono": "^5.3.0","@fontsource-variable/mona-sans": "^5.3.0","@fontsource-variable/noto-sans-sc": "^5.3.0",- "@fontsource/commit-mono": "^5.3.0","@fontsource/ibm-plex-sans-condensed": "^5.3.0"},"devDependencies": {diff --git a/packages/ui/scripts/sync-font-licenses.mjs b/packages/ui/scripts/sync-font-licenses.mjsindex c96a17c1..a818f722 100644--- a/packages/ui/scripts/sync-font-licenses.mjs+++ b/packages/ui/scripts/sync-font-licenses.mjs@@ -2,8 +2,7 @@* Mirrors the licence text of every font package @prismshadow/penguin-ui depends on into* `src/fonts/LICENSES/<package>.txt` — verbatim except for whitespace: line endings become LF,* trailing spaces go and the file ends in one newline, because the repository stores text as LF- * (.gitattributes) and a CRLF original (Commit Mono's) would otherwise read as drift after every- * checkout.+ * (.gitattributes) and a CRLF original would otherwise read as drift after every checkout.** The texts are checked in so the licence a build ships is reviewable in the diff that changes a* font, and so the `penguinUi()` Vite plugin can emit them beside the fontsdiff --git a/packages/ui/src/boot.ts b/packages/ui/src/boot.tsindex 6673d1d4..4359b965 100644--- a/packages/ui/src/boot.ts+++ b/packages/ui/src/boot.ts@@ -94,9 +94,8 @@ export interface FontOption {/*** The Latin faces, only those the app already bundles (`fonts/*.css`). They replace the reading- * and chrome sans (`--ui-font-sans`, which `--ui-font-ui` follows in Primer and Frost); a- * theme's mono face is never replaced — Console's chrome stays mono, its identity, and a- * pairing only changes what Console reads in.+ * and chrome sans (`--ui-font-sans`, which every theme's `--ui-font-ui` follows); a theme's mono+ * face is never replaced — code and the marks a theme sets in mono keep it.*/export const FONT_LATIN_OPTIONS = [{ id: "theme", label: "Theme default" },@@ -141,7 +140,6 @@ export const BUNDLED_FONT_FAMILIES = {MiSans: "MiSans","Noto Sans SC": "Noto Sans SC Variable","JetBrains Mono": "JetBrains Mono Variable",- "Commit Mono": "Commit Mono",} as const;export type BundledFontName = keyof typeof BUNDLED_FONT_FAMILIES;@@ -150,7 +148,7 @@ export const SYSTEM_FONT = "System";export type ThemeFontName = BundledFontName | typeof SYSTEM_FONT;export interface ThemeFonts {- /** The reading / UI sans (`--ui-font-sans`); Console's chrome is its mono face on top of it. */+ /** The reading and chrome sans (`--ui-font-sans`, which `--ui-font-ui` follows). */readonly latin: ThemeFontName;/** `--ui-font-cjk`. */readonly cjk: ThemeFontName;@@ -164,9 +162,9 @@ export interface ThemeFonts {* first (`System` = a stack that names no bundled family).*/export const THEME_FONTS: Readonly<Record<ThemeId, ThemeFonts>> = {- github: { latin: SYSTEM_FONT, cjk: SYSTEM_FONT, mono: SYSTEM_FONT },+ github: { latin: "Mona Sans", cjk: "Noto Sans SC", mono: "JetBrains Mono" },modern: { latin: "MiSans", cjk: "MiSans", mono: "JetBrains Mono" },- geek: { latin: "IBM Plex Sans", cjk: "Noto Sans SC", mono: "Commit Mono" },+ geek: { latin: "IBM Plex Sans", cjk: "Noto Sans SC", mono: "JetBrains Mono" },};// ---------------------------------------------------------------------------diff --git a/packages/ui/src/fonts/LICENSES/commit-mono.txt b/packages/ui/src/fonts/LICENSES/commit-mono.txtdeleted file mode 100644index 5cb48f81..00000000--- a/packages/ui/src/fonts/LICENSES/commit-mono.txt+++ /dev/null@@ -1,90 +0,0 @@-This Font Software is licensed under the SIL Open Font License, Version 1.1.-This license is copied below, and is also available with a FAQ at:-http://scripts.sil.org/OFL--------------------------------------------------------------SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007--------------------------------------------------------------PREAMBLE-The goals of the Open Font License (OFL) are to stimulate worldwide-development of collaborative font projects, to support the font creation-efforts of academic and linguistic communities, and to provide a free and-open framework in which fonts may be shared and improved in partnership-with others.--The OFL allows the licensed fonts to be used, studied, modified and-redistributed freely as long as they are not sold by themselves. The-fonts, including any derivative works, can be bundled, embedded,-redistributed and/or sold with any software provided that any reserved-names are not used by derivative works. The fonts and derivatives,-however, cannot be released under any other type of license. The-requirement for fonts to remain under this license does not apply-to any document created using the fonts or their derivatives.--DEFINITIONS-"Font Software" refers to the set of files released by the Copyright-Holder(s) under this license and clearly marked as such. This may-include source files, build scripts and documentation.--"Reserved Font Name" refers to any names specified as such after the-copyright statement(s).--"Original Version" refers to the collection of Font Software components as-distributed by the Copyright Holder(s).--"Modified Version" refers to any derivative made by adding to, deleting,-or substituting -- in part or in whole -- any of the components of the-Original Version, by changing formats or by porting the Font Software to a-new environment.--"Author" refers to any designer, engineer, programmer, technical-writer or other person who contributed to the Font Software.--PERMISSION & CONDITIONS-Permission is hereby granted, free of charge, to any person obtaining-a copy of the Font Software, to use, study, copy, merge, embed, modify,-redistribute, and sell modified and unmodified copies of the Font-Software, subject to the following conditions:--1) Neither the Font Software nor any of its individual components,-in Original or Modified Versions, may be sold by itself.--2) Original or Modified Versions of the Font Software may be bundled,-redistributed and/or sold with any software, provided that each copy-contains the above copyright notice and this license. These can be-included either as stand-alone text files, human-readable headers or-in the appropriate machine-readable metadata fields within text or-binary files as long as those fields can be easily viewed by the user.--3) No Modified Version of the Font Software may use the Reserved Font-Name(s) unless explicit written permission is granted by the corresponding-Copyright Holder. This restriction only applies to the primary font name as-presented to the users.--4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font-Software shall not be used to promote, endorse or advertise any-Modified Version, except to acknowledge the contribution(s) of the-Copyright Holder(s) and the Author(s) or with their explicit written-permission.--5) The Font Software, modified or unmodified, in part or in whole,-must be distributed entirely under this license, and must not be-distributed under any other license. The requirement for fonts to-remain under this license does not apply to any document created-using the Font Software.--TERMINATION-This license becomes null and void if any of the above conditions are-not met.--DISCLAIMER-THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT-OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE-COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,-INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL-DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING-FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM-OTHER DEALINGS IN THE FONT SOFTWARE.diff --git a/packages/ui/src/fonts/README.md b/packages/ui/src/fonts/README.mdindex 15a4dde4..35bd80e8 100644--- a/packages/ui/src/fonts/README.md+++ b/packages/ui/src/fonts/README.md@@ -8,32 +8,32 @@ fetched from a CDN, so the desktop build renders offline.| theme | sans (reading) | ui (chrome) | mono | CJK || --- | --- | --- | --- | --- |-| Primer `github` | Mona Sans Variable (from W1a; system stack until then) | = sans | JetBrains Mono Variable behind the system mono stack (W1a) | Noto Sans SC Variable (W1a) |+| Primer `github` | Mona Sans Variable | = sans | JetBrains Mono Variable | Noto Sans SC Variable || Frost `modern` | **MiSans** 400 / 500 | = sans | JetBrains Mono Variable | MiSans (the same family) |-| Console `geek` | IBM Plex Sans Variable | Commit Mono 400 / 700 | Commit Mono 400 / 700 | Noto Sans SC Variable |+| Console `geek` | IBM Plex Sans Variable | = sans | JetBrains Mono Variable | Noto Sans SC Variable |Two faces per theme since the theme identities (2026-09-19): `--ui-font-ui` is the chrome's face(`body` sets it; navigation, controls, labels, headings, badges, tables) and `--ui-font-sans` the-reading face (message text, prose, the composer's input opt in with `font-sans`). Primer and Frost-point both at one family; Console sets its chrome in Commit Mono and reads in Plex Sans. The display-face is the chrome face everywhere: Console's h1 is the mono bold, and IBM Plex Sans Condensed 600-(the old uppercase h1) stays declared in `geek.css` but unnamed until its dependency is dropped.+reading face (message text, prose, the composer's input opt in with `font-sans`). Every theme points+both at one family; Console set its chrome in a mono face until 2026-09-30, and now keeps mono for+code and a few technical marks (the status-line tags, a step's label and block bar, chart axis+labels). The display face is the chrome face everywhere: Console's h1 is the Plex Sans bold, and IBM+Plex Sans Condensed 600 (the old uppercase h1) stays declared in `geek.css` but unnamed until its+dependency is dropped.| family | files | source | licence || --- | --- | --- | --- || Mona Sans Variable | `github.css`: latin + latin-ext | `@fontsource-variable/mona-sans` | OFL-1.1 |-| JetBrains Mono Variable | `github.css`: latin + latin-ext (Frost names the same faces) | `@fontsource-variable/jetbrains-mono` | OFL-1.1 |+| JetBrains Mono Variable | `github.css`: latin + latin-ext (Frost and Console name the same faces) | `@fontsource-variable/jetbrains-mono` | OFL-1.1 || MiSans | `modern.css` → `misans/misans.css`: Regular as 400 and Medium as 500, 99 `unicode-range` slices each | vendored: `scripts/build-misans.py` cuts them from Xiaomi's official package | MiSans Font Intellectual Property License Agreement || IBM Plex Sans Variable | `geek.css`: latin + latin-ext | `@fontsource-variable/ibm-plex-sans` | OFL-1.1 || IBM Plex Sans Condensed | `geek.css`: 600, latin + latin-ext | `@fontsource/ibm-plex-sans-condensed` | OFL-1.1 |-| Commit Mono | `geek.css`: 400 and 700, one latin file each | `@fontsource/commit-mono` | OFL-1.1 || Noto Sans SC Variable | `cjk.css`: fontsource's own sheet, 101 `unicode-range` slices | `@fontsource-variable/noto-sans-sc` | OFL-1.1 |Why these faces: Mona Sans is GitHub's product face. MiSans gives Frost one family for Latin andChinese, so a zh line sits in the same face as the English around it; no other face on the shortlist-has Chinese. Commit Mono, the face opencode.ai and e2b.dev ship, is Console's chrome — navigation,-controls, labels, headings — and its code face; IBM Plex Sans keeps Console's reading text-proportional, which a monospaced paragraph is not.+has Chinese. IBM Plex Sans is Console's main face, chrome and reading text alike, and JetBrains+Mono, the code face the three themes share, sets its code and its technical marks.Frost ships two MiSans weights and no more, so `themes/modern.css` turns off weight synthesis: a 600or 700 request renders in Medium instead of a synthesized bold, which smears Han strokes. Frost's@@ -46,8 +46,8 @@ Font files and font declarations cost differently:- **Files.** A browser fetches a font file only when an element's `font-family` names its familyand its text falls inside the face's `unicode-range`. Each theme file names only its ownfamilies, so a session downloads its theme's faces and nothing else, and only the slices its text- touches; Primer names no bundled family in W0 and downloads none. The consumers' Vite configs- never inline a font (`build.assetsInlineLimit`), so every slice stays a file of its own.+ touches. The consumers' Vite configs never inline a font (`build.assetsInlineLimit`), so every+ slice stays a file of its own.- **Declarations.** `index.css` declares every theme's faces unconditionally, so all of them arerules in the app's main stylesheet and every session downloads them, Primer's included: about94 KB of the stylesheet's 122 KB gzipped, most of it the `unicode-range` lists of MiSans's 198@@ -59,9 +59,9 @@ each language; Playwright network log, identical in light and dark):| theme | English page | Chinese page || --- | --- | --- |-| Primer (W0: system fonts) | 0 files | 0 files |+| Primer | not measured since it took its bundled faces (2026-09-30) | not measured || Frost | 5 files, 92.6 KB (MiSans 3 + 1 slices, JetBrains Mono) | 27 files, 627 KB (MiSans 16 + 10 slices, JetBrains Mono) |-| Console | 4 files, 121.7 KB (Plex Sans, Condensed 600, Commit Mono 400, 1 Noto slice for a symbol) | 17 files, 893 KB (14 Noto slices, the three Latin faces) |+| Console | not measured since it took JetBrains Mono (2026-09-30) | not measured |## Bytes in `dist/`@@ -77,8 +77,7 @@ gallery), because the offline desktop app needs them all:| JetBrains Mono Variable | 2 | 55,600 || IBM Plex Sans Variable | 2 | 76,676 || IBM Plex Sans Condensed 600 | 2 | 35,860 |-| Commit Mono 400 / 700 | 2 | 95,432 |-| **total** | **309** | **9,091,684** |+| **total** | **307** | **8,996,252** |MiSans covers the characters of Noto's slice partition plus its own other non-ideograph characters.The roughly 15,500 rare ideographs outside that partition are not shipped (they would add 2.46 MB perdiff --git a/packages/ui/src/fonts/cjk.css b/packages/ui/src/fonts/cjk.cssindex 65773293..6bfc7e68 100644--- a/packages/ui/src/fonts/cjk.css+++ b/packages/ui/src/fonts/cjk.css@@ -1,9 +1,9 @@/**- * Console's CJK face, and Primer's from W1a (Frost's is MiSans, and Primer stays on the system CJK- * stack until W1a): Noto Sans SC, variable `wght` 100–900, OFL-1.1 — fontsource's own stylesheet- * imported as-is. It declares the family "Noto Sans SC Variable" as 101 `unicode-range` slices (97- * Han / punctuation / symbol slices plus latin, latin-ext, cyrillic and vietnamese), about 4.5 MB- * in all; a page whose theme names the family downloads only the slices its text touches.+ * Primer's and Console's CJK face (Frost's is MiSans): Noto Sans SC, variable `wght` 100–900,+ * OFL-1.1 — fontsource's own stylesheet imported as-is. It declares the family "Noto Sans SC+ * Variable" as 101 `unicode-range` slices (97 Han / punctuation / symbol slices plus latin,+ * latin-ext, cyrillic and vietnamese), about 4.5 MB in all; a page whose theme names the family+ * downloads only the slices its text touches.** A stack that names Noto names a Latin face first, so ASCII never reaches Noto's latin slice;* that slice and the cyrillic / vietnamese ones only answer text the Latin face cannot.diff --git a/packages/ui/src/fonts/credits.ts b/packages/ui/src/fonts/credits.tsindex c868aea3..10a164ce 100644--- a/packages/ui/src/fonts/credits.ts+++ b/packages/ui/src/fonts/credits.ts@@ -14,7 +14,6 @@ import { THEME_IDS } from "../tokens";import type { ThemeId } from "../tokens";import { THEME_FONTS } from "../boot";import type { BundledFontName } from "../boot";-import commitMono from "./LICENSES/commit-mono.txt?raw";import ibmPlexSans from "./LICENSES/ibm-plex-sans.txt?raw";import ibmPlexSansCondensed from "./LICENSES/ibm-plex-sans-condensed.txt?raw";import jetbrainsMono from "./LICENSES/jetbrains-mono.txt?raw";@@ -78,8 +77,8 @@ export const FONT_CREDITS: readonly FontCredit[] = [licenseText: ibmPlexSans,},{- // Declared in `fonts/geek.css` and named by no theme since Console's h1 moved to the mono- // bold; its files still ship until the dependency is dropped, so it is still credited.+ // Declared in `fonts/geek.css` and named by no theme since Console's uppercase condensed h1+ // went; its files still ship until the dependency is dropped, so it is still credited.id: "ibm-plex-sans-condensed",family: "IBM Plex Sans Condensed",themes: [],@@ -87,14 +86,6 @@ export const FONT_CREDITS: readonly FontCredit[] = [licenseTitle: OFL,licenseText: ibmPlexSansCondensed,},- {- id: "commit-mono",- family: "Commit Mono",- themes: namedBy("Commit Mono"),- source: "@fontsource/commit-mono",- licenseTitle: OFL,- licenseText: commitMono,- },{id: "noto-sans-sc",family: "Noto Sans SC",diff --git a/packages/ui/src/fonts/geek.css b/packages/ui/src/fonts/geek.cssindex a0ba293e..b275bb8a 100644--- a/packages/ui/src/fonts/geek.css+++ b/packages/ui/src/fonts/geek.css@@ -1,18 +1,15 @@/*** Console (`geek`) Latin faces, all OFL-1.1:- * - IBM Plex Sans (the reading face), variable `wght`, latin + latin-ext —+ * - IBM Plex Sans (the chrome and reading face), variable `wght`, latin + latin-ext —* @fontsource-variable/ibm-plex-sans- * - Commit Mono (the chrome face and the code face), static 400 and 700 — @fontsource/commit-mono.- * Fontsource builds it as a single `latin` file with no `unicode-range`, so none is declared here- * either: the browser loads the file for any chrome or mono text and falls back per missing- * glyph.* - IBM Plex Sans Condensed, static 600, latin + latin-ext — @fontsource/ibm-plex-sans-condensed.- * Declared but no longer named by the theme: the uppercase condensed h1 gave way to the mono- * chrome's bold h1. A declared face nobody names is never downloaded; drop the dependency and+ * Declared but no longer named by the theme: the uppercase condensed h1 gave way to the chrome+ * face's bold h1. A declared face nobody names is never downloaded; drop the dependency and* these two rules with the next install.*- * Only `themes/geek.css` names these families, so no other theme ever downloads them. The- * `url()`s are relative to this file on purpose — see `index.css`.+ * Console's mono face, JetBrains Mono, is Primer's and Frost's too, declared once in+ * `github.css`. Only `themes/geek.css` names the families here, so no other theme ever downloads+ * them. The `url()`s are relative to this file on purpose — see `index.css`.*/@font-face {@@ -64,21 +61,3 @@U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}--@font-face {- font-family: "Commit Mono";- font-style: normal;- font-display: swap;- font-weight: 400;- src: url("../../node_modules/@fontsource/commit-mono/files/commit-mono-latin-400-normal.woff2")- format("woff2");-}--@font-face {- font-family: "Commit Mono";- font-style: normal;- font-display: swap;- font-weight: 700;- src: url("../../node_modules/@fontsource/commit-mono/files/commit-mono-latin-700-normal.woff2")- format("woff2");-}diff --git a/packages/ui/src/fonts/github.css b/packages/ui/src/fonts/github.cssindex e84e151a..dbad9462 100644--- a/packages/ui/src/fonts/github.css+++ b/packages/ui/src/fonts/github.css@@ -3,10 +3,9 @@* latin-ext slices only, from @fontsource-variable/mona-sans and* @fontsource-variable/jetbrains-mono (OFL-1.1).*- * Declared ahead of use: Primer stays on the system font stack until the W1a polish names these- * families in `themes/github.css`. A declared face that no `font-family` names is never- * downloaded, so until then they cost bundle bytes only. The `url()`s are relative to this file on- * purpose — see `index.css`.+ * `themes/github.css` puts them first in its sans and mono stacks (Primer's CJK face, Noto Sans+ * SC, is `cjk.css`); Frost and Console name the same JetBrains Mono faces, declared once here.+ * The `url()`s are relative to this file on purpose — see `index.css`.*/@font-face {diff --git a/packages/ui/src/fonts/index.css b/packages/ui/src/fonts/index.cssindex 59db057f..6e14d502 100644--- a/packages/ui/src/fonts/index.css+++ b/packages/ui/src/fonts/index.css@@ -3,9 +3,9 @@** A browser fetches a font FILE only when some element's `font-family` names its family and the* text falls inside the face's `unicode-range`. Each theme file under `themes/` names only its own- * families, so a session downloads the active theme's faces and nothing else: Frost's MiSans- * slices and JetBrains Mono, or Console's Latin faces and the Noto Sans SC slices its CJK text- * touches; Primer names no bundled family in W0 and downloads none. The DECLARATIONS are another+ * families, so a session downloads the active theme's faces and nothing else: Primer's Mona Sans+ * and JetBrains Mono or Console's Latin faces, each with the Noto Sans SC slices its CJK text+ * touches, or Frost's MiSans slices and JetBrains Mono. The DECLARATIONS are another* matter: every theme's faces are declared unconditionally here, so these rules sit in the app's* main stylesheet and every session downloads them (about 94 KB gzipped, most of it MiSans's and* Noto's `unicode-range` lists). That cost was accepted on 2026-09-18 over loading each theme's@@ -16,12 +16,12 @@** | theme | sans (reading) | ui (chrome) | mono | CJK |* | --------------- | ---------------------------------- | ---------------------- | ----------------------------- | ---------------------------- |- * | Primer `github` | Mona Sans Variable (W1a) | = sans | JetBrains Mono Variable (W1a) | Noto Sans SC Variable (W1a) |+ * | Primer `github` | Mona Sans Variable | = sans | JetBrains Mono Variable | Noto Sans SC Variable |* | Frost `modern` | MiSans 400 / 500 | = sans | JetBrains Mono Variable | MiSans (the same family) |- * | Console `geek` | IBM Plex Sans Variable | Commit Mono 400 / 700 | Commit Mono 400 / 700 | Noto Sans SC Variable |+ * | Console `geek` | IBM Plex Sans Variable | = sans | JetBrains Mono Variable | Noto Sans SC Variable |*- * The display face is the chrome face in every theme (Console's h1 is the mono bold); IBM Plex- * Sans Condensed stays declared in `geek.css` until its dependency is dropped.+ * The display face is the chrome face in every theme (Console's h1 is the Plex Sans bold); IBM+ * Plex Sans Condensed stays declared in `geek.css` until its dependency is dropped.** Every face but MiSans is SIL Open Font License 1.1 and arrives through a fontsource package,* whose licence text `scripts/sync-font-licenses.mjs` mirrors into `LICENSES/`. MiSans has nodiff --git a/packages/ui/src/fonts/modern.css b/packages/ui/src/fonts/modern.cssindex 83cedad6..99e44c47 100644--- a/packages/ui/src/fonts/modern.css+++ b/packages/ui/src/fonts/modern.css@@ -7,8 +7,8 @@* Font Intellectual Property License Agreement (`LICENSES/misans.txt`). The software must credit* MiSans (the Web App does, in the account menu), may not adapt the font, and never offers it for* download on its own.- * - JetBrains Mono (mono): the variable face Primer also names, declared once in `github.css`, so- * Frost's mono adds no bytes.+ * - JetBrains Mono (mono): the variable face Primer and Console also name, declared once in+ * `github.css`, so Frost's mono adds no bytes.** Only `themes/modern.css` names MiSans, so only a Frost session downloads its slices, and only the* slices its text touches. Frost uses weights 400 and 500 alone; its theme turns weight synthesisdiff --git a/packages/ui/src/hooks.ts b/packages/ui/src/hooks.tsindex 4d6ff19e..3eba80f4 100644--- a/packages/ui/src/hooks.ts+++ b/packages/ui/src/hooks.ts@@ -79,7 +79,7 @@* progress slot — and stays a plain row under Primer. Frost adds nothing around the row — no* fill, border, ring or halo, the way Codex and macOS show work in progress — and lets a soft* highlight in the accent's hue sweep across the label; at rest nothing is added. Console- * renders a transcript: the label in the chrome face at the small rung, uppercase and tracked,+ * renders a transcript: the label in the mono face at the small rung, uppercase and tracked,* muted once done and full ink while running, the detail muted, no box around the row and no* fill that moves between rest, hover, open and stuck (a hover changes the ink alone), and a* hatched block bar in the progress slot while the step runs; a step in a work group hangs off@@ -91,7 +91,7 @@* components had one look. A notice names its tone; Primer keeps the host's own strip, Frost* floats a soft card on the overlay surface with the tone as one small dot of its ink, Console* prints a console status line — a bracketed tone tag (`[INFO]`, `[ OK ]`, `[WARN]`, `[FAIL]`,- * `[NOTE]`) in the tone's ink and the chrome face, the message in the reading face, nothing+ * `[NOTE]`) in the tone's ink and the mono face, the message in the reading face, nothing* round it. A chart names its parts;* Primer keeps the host's drawing, Frost draws soft low-chroma series, translucent bars with no* outline, round joins, caps and points and a fading area, Console draws thin soliddiff --git a/packages/ui/src/testing/deslop.ts b/packages/ui/src/testing/deslop.tsindex d523e101..66627582 100644--- a/packages/ui/src/testing/deslop.ts+++ b/packages/ui/src/testing/deslop.ts@@ -1163,10 +1163,22 @@ const cssUppercaseCheck: Check = (analysis) =>: [],);-/** Rule 16: a hook recipe (`.ui-*`) setting a mono `font-family`. */+/**+ * Marks a recipe may set in the mono face because they are technical on purpose (user decision,+ * 2026-09-30, when Console's chrome moved to a sans and kept mono for these alone): a+ * `.ui-activity` step's label and progress bar, the transcript's capitals and its block bar; a+ * `.ui-notice` tag drawn in `::before`, a console status line's `[ OK ]`; and the text of a+ * `.ui-chart`, a plot's axis labels. A detail slot, a frame's head or a notice's message is+ * not one of them.+ */+const MONO_MARKS =+ /\.ui-activity\b[^,]*\[data-slot="(?:label|progress)"\]|\.ui-notice\b[^,\s]*::before|\.ui-chart\b[^,]*\btext\b/;++/** Rule 16: a hook recipe (`.ui-*`) setting a mono `font-family`, off the marks above. */const cssHookMonoCheck: Check = (analysis) =>declarations(analysis).flatMap(({ rule, decl }) =>/\.ui-[a-z]/.test(fullSelector(rule)) &&+ !MONO_MARKS.test(fullSelector(rule)) &&decl.name === "font-family" &&/--ui-font-mono|monospace/.test(decl.value)? [{ line: decl.line, found: `${rule.selector} { font-family: ${decl.value} }` }]diff --git a/packages/ui/src/theme.css b/packages/ui/src/theme.cssindex 243ecf1d..fde67c63 100644--- a/packages/ui/src/theme.css+++ b/packages/ui/src/theme.css@@ -409,7 +409,7 @@Two recipes are the same in every theme and so live here once, reading tokens: the eyebrow isthe h6 rung (a theme says what the rung is — Primer's small tracked capitals, Frost's- sentence case, Console's tracked mono capitals — and may add its ink in its own rule), and+ sentence case, Console's tracked capitals — and may add its ink in its own rule), andthe display title takes the emphasis ink, the near-white a dark theme keeps for its headingsover a calmer body ink. A theme file's own `.ui-eyebrow` / `.ui-display` rules come later inthe layer and add to these. */@@ -489,10 +489,10 @@}/* The user's font pairing (boot.ts, `FONT_LATIN_OPTIONS` / `FONT_CJK_OPTIONS`): a chosen Latin- face replaces the reading sans — `--ui-font-ui` follows it in Primer and Frost, and Console's- chrome stays in its mono face, which no pairing touches — and a chosen CJK face replaces- `--ui-font-cjk`, which every theme's sans stack reads for Han (the mono stacks that read it- follow too: Han inside code takes the chosen face, the Latin code face stays). No attribute is+ face replaces the sans — every theme's chrome face (`--ui-font-ui`) reads it, and the mono+ face, which no pairing touches, stays — and a chosen CJK face replaces `--ui-font-cjk`, which+ every theme's sans stack reads for Han (the mono stacks that read it follow too: Han inside+ code takes the chosen face, the Latin code face stays). No attribute isthe theme's own choice, declared in its theme file. Only faces the app bundles are listed, soa choice never names a family the page cannot load; the Latin stacks keep the CJK face aheadof the generic fallbacks, and a Latin face first, so ASCII always renders in the chosen face.diff --git a/packages/ui/src/themes/geek.css b/packages/ui/src/themes/geek.cssindex b0e1a26f..81e44b15 100644--- a/packages/ui/src/themes/geek.css+++ b/packages/ui/src/themes/geek.css@@ -1,17 +1,17 @@/**- * Console (`geek`) — mono chrome, as plain as a terminal. Navigation, controls, labels,- * headings, badges and tables are set in Commit Mono; only reading text (message bubbles,- * assistant prose, the composer's input) stays in IBM Plex Sans. Paper-white light and warm- * near-black dark with no fill on a card or a row (a card is the page), one accent — black and- * white by default, the interface orange and five terminal hues as presets — square corners- * everywhere, no shadow anywhere, hairlines only where they carry structure, a+ * Console (`geek`) — as plain as a terminal. The interface and its reading text are set in IBM+ * Plex Sans; JetBrains Mono is kept for code and for the marks that are technical on purpose —+ * the status-line tags, a step's label and block bar, a chart's axis labels. Paper-white light+ * and warm near-black dark with no fill on a card or a row (a card is the page), one accent —+ * black and white by default, the interface orange and five terminal hues as presets — square+ * corners everywhere, no shadow anywhere, hairlines only where they carry structure, a* ruled full-bleed window, a standalone frame a plain hairline box, the selected navigation row* set in the bold cut, a block caret, motion that jumps in steps, and the agent's work rendered* as a transcript — `└` steps, mono capitals, a hatched block bar. References: opencode.ai (the- * mono chrome, the paper and the warm black, the ruled column, the underline tabs, the calm- * dark), e2b.dev (the orange, the square shapes, the stepped signals), claude.dev's blog (the- * tree, the progress line, the near-boxless dark) and a Linux console (the owner's ask of- * 2026-09-29: as minimal as possible, no decoration).+ * paper and the warm black, the ruled column, the underline tabs, the calm dark), e2b.dev (the+ * orange, the square shapes, the stepped signals), claude.dev's blog (the tree, the progress+ * line, the near-boxless dark) and a Linux console (the owner's ask of 2026-09-29: as minimal as+ * possible, no decoration).** Status of each group:* - Light is opencode's paper (`#fdfcfc` page, `rgb(29 29 31)` ink, `rgb(100 98 98)` muted),@@ -29,17 +29,21 @@* ruled word, never a coloured shape), tuned so every tone reads at 4.5:1 as text on the page* and 3:1 as a mark on every surface; the line and the solid fill of a tone are its ink,* declared once; dark danger is lifted to `#ff5252` so it reads on the warm black.- * - Fonts: Commit Mono (400 / 700, the face opencode and e2b.dev ship) for the chrome and for- * code — one stack, the chrome face reads the data face — IBM Plex Sans for reading, Noto Sans- * SC behind both for Han (`fonts/geek.css`). The Plex Sans Condensed face the old uppercase h1- * used is still declared and no longer named here; drop its dependency with the next install.+ * - Fonts (owner's call, 2026-09-30): IBM Plex Sans is the main face — navigation, controls,+ * labels, headings and reading text alike — and JetBrains Mono the mono face, with Noto Sans+ * SC behind both for Han (`fonts/geek.css`; JetBrains Mono is declared once for every theme in+ * `fonts/github.css`). The mono face is kept for code and for the few marks that are technical+ * on purpose, each named in its recipe below; everywhere else the sans takes over from the+ * monospaced chrome (Commit Mono) the theme had before. The Plex Sans Condensed face the old+ * uppercase h1 used is still declared and no longer named here; drop its dependency with the+ * next install.* - Radius is 0 everywhere, badges, counters, avatars and controls included (`--ui-radius-pill`* and `--ui-radius-control` are 0). State dots and the switch knob stay round and the switch* track stays a pill: those components use Tailwind's literal `rounded-full`, which no token* re-points.* - Density and type are Console's own: a 0.225rem space unit (10% under Tailwind's 0.25rem, so- * every `h-8` and `px-2` shrinks with it) and a 0.8125rem body rung. Medium weight is 400 —- * Commit Mono has no 500 — so emphasis in the chrome is colour, and strong is the 700 cut.+ * every `h-8` and `px-2` shrinks with it) and a 0.8125rem body rung. Medium weight is 400 and+ * strong the 700 cut: the recipes emphasise with colour, not with a middle weight.* - Lines and fills (2026-09-29): a rule is drawn only where it carries structure, and a fill* nowhere but a hover. The window's columns are ruled off each other and a standalone frame* keeps a plain hairline box (the earlier TUI head — the title standing in the top rule — was@@ -220,10 +224,9 @@--ui-shell-radius: 0px;--ui-shell-shadow: 0 0 #0000;- /* Structure: a tree indents two characters of the mono face per level (1rem at the 13px- body) from the row inset, and its connector rules take the emphasis line so `└` reads on- paper and on the warm black alike; a field is a table row with a 10rem label column and- three quarters of a rem before the value. */+ /* Structure: a tree indents 1rem per level from the row inset, and its connector rules take+ the emphasis line so `└` reads on paper and on the warm black alike; a field is a table row+ with a 10rem label column and three quarters of a rem before the value. */--ui-tree-inset: 0.625rem;--ui-tree-indent: 1rem;--ui-tree-guide: var(--ui-line-emphasis);@@ -238,21 +241,21 @@--ui-switch-knob-line: rgb(0 0 0 / 0.1);/* Typography — families. Latin face first, so ASCII always renders in the theme's face; the- chrome is the mono face — one stack, read by both names — with Noto behind it for Han, and- reading text is Plex Sans. */+ chrome and reading text share Plex Sans — the chrome reads the sans by name, so a chosen+ Latin face reaches it as in every theme — with Noto behind it for Han, and JetBrains Mono+ is the code face. */--ui-font-cjk: "Noto Sans SC Variable", "PingFang SC", "Microsoft YaHei";--ui-font-sans:"IBM Plex Sans Variable", var(--ui-font-cjk), ui-sans-serif, system-ui, sans-serif;--ui-font-mono:- "Commit Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",+ "JetBrains Mono Variable", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",var(--ui-font-cjk), monospace;- --ui-font-ui: var(--ui-font-mono);+ --ui-font-ui: var(--ui-font-sans);--ui-font-display: var(--ui-font-ui);- /* Typography — scale and roles: a 13px body at the 16px root (Commit Mono is wide), 12px- small and caption, 16px reading text; headings in the chrome face at 700, sentence case,- no tracking — mono needs none — and the h6 group label uppercase with letter-spacing, the- one eyebrow rung. */+ /* Typography — scale and roles: a 13px body at the 16px root, 12px small and caption, 16px+ reading text; headings in the chrome face at 700, sentence case, no tracking, and the h6+ group label uppercase with letter-spacing, the one eyebrow rung. */--ui-text-body-size: 0.8125rem;--ui-text-body-lh: 1.5;--ui-text-small-size: 0.75rem;@@ -502,8 +505,8 @@color: var(--ui-fg-muted);}- /* The page's one display title: the chrome face at its bold cut, sentence case, no tracking —- opencode's h1. Han glyphs need a little more leading than the Latin bold. */+ /* The page's one display title: the chrome face at its bold cut, sentence case, no tracking.+ Han glyphs need a little more leading than the Latin bold. */:root[data-theme="geek"] .ui-display {font-family: var(--ui-font-ui);font-weight: 700;@@ -600,7 +603,10 @@}/* The selected navigation row — a nav entry or the open session — is marked quietly: thebold cut over the host's own selected fill, no glyph (a first pass hung an accent `>` before- it; the owner asked for it to go). Mono bold keeps the row's advance, so nothing moves. */+ it; the owner asked for it to go). The bold cut is wider than the regular, but a row's label+ starts the row and is the last thing in its flow (a trailing mark is positioned), so it+ grows only toward the row's free end, and a label that fills the row truncates a little+ earlier; nothing else in the row moves. */:root[data-theme="geek"] .ui-shell [data-slot="nav"] [aria-current="page"] {font-weight: var(--ui-weight-strong);}@@ -687,15 +693,16 @@/* Work in progress, as a transcript (claude.dev's tree and progress line): the row is no box —no border, no corner, no shadow, and the rule a list draws above it goes with the border —- its label is the chrome face at the small rung, uppercase and tracked like an eyebrow, muted+ its label is the mono face at the small rung, uppercase and tracked like an eyebrow, mutedonce the step is done and the body ink while it runs (the danger ink when it failed), the- detail (a path, an argument preview, a duration) is muted, and while the step runs the- progress slot draws a hatched block bar: a dotted track of `░` under a shaded fill of `▓`- that advances a block at a time and starts over — indeterminate, because a step has no- percentage. The host hides the slot; the recipe shows it. A step in a work group hangs off- the `└` its tree row draws, so no connector is added here. The slots are found anywhere- inside the row (a card nests them in its own button). Under reduced motion the bar holds- one fill. */+ detail (a path, an argument preview, a duration) is muted in the host's own face (the host+ sets a duration or a step count in mono and a description in the sans), and while the step+ runs the progress slot draws a hatched block bar in the mono face: a dotted track of `░`+ under a shaded fill of `▓` that advances a block at a time and starts over — indeterminate,+ because a step has no percentage. The host hides the slot; the recipe shows it. A step in a+ work group hangs off the `└` its tree row draws, so no connector is added here. The slots+ are found anywhere inside the row (a card nests them in its own button). Under reduced+ motion the bar holds one fill. */:root[data-theme="geek"] .ui-activity {border-color: transparent;border-radius: 0;@@ -718,7 +725,7 @@color: var(--ui-fg);}:root[data-theme="geek"] .ui-activity [data-slot="label"] {- font-family: var(--ui-font-ui);+ font-family: var(--ui-font-mono);font-size: var(--ui-text-small-size);font-weight: var(--ui-weight-body);letter-spacing: var(--ui-tracking-label);@@ -732,7 +739,6 @@color: var(--ui-tone-danger-fg);}:root[data-theme="geek"] .ui-activity [data-slot="detail"] {- font-family: var(--ui-font-ui);font-size: var(--ui-text-small-size);color: var(--ui-fg-muted);}@@ -740,7 +746,7 @@position: relative;display: inline-block;vertical-align: middle;- font-family: var(--ui-font-ui);+ font-family: var(--ui-font-mono);font-size: var(--ui-text-small-size);line-height: 1;letter-spacing: 0;@@ -810,13 +816,15 @@}/* A notice is a status line, the way a console prints one: a bracketed tone tag in the tone's- ink — `[ OK ]`, `[WARN]`, `[FAIL]` — in the chrome face at the start, the message beside it+ ink — `[ OK ]`, `[WARN]`, `[FAIL]` — in the mono face at the start, the message beside itin the reading face, nothing round it, painted in the page's own colour (quiet on the page,opaque where a toast floats over content). The tag stands out of the flow — absolutely atthe row's inset, the host padded for it — because a host lays its body and actions out as a- flex row, and a tag in the flow would be a third item pushing the body to the middle. A- toast is the same line inside one hairline, so it has an edge where it floats. (Two earlier- passes — a coloured left rule, then a solid tone block — were decoration and went.) */+ flex row, and a tag in the flow would be a third item pushing the body to the middle. Every+ tag is six characters, so in the mono face all five are one width, and the fixed 4rem+ column holds each of them with room to spare. A toast is the same line inside one hairline,+ so it has an edge where it floats. (Two earlier passes — a coloured left rule, then a solid+ tone block — were decoration and went.) */:root[data-theme="geek"] .ui-notice {position: relative;padding-inline-start: calc(4rem + var(--ui-row-px));@@ -842,7 +850,7 @@display: flex;align-items: center;color: var(--_tone-fg);- font-family: var(--ui-font-ui);+ font-family: var(--ui-font-mono);font-size: var(--ui-text-small-size);font-weight: var(--ui-weight-strong);}@@ -860,7 +868,7 @@}/* Charts are drawn like a terminal plot: a dashed grid on crisp pixels, axis labels in the- chrome face as tracked capitals, 1px lines with hard joins and ends, square points, and+ mono face as tracked capitals, 1px lines with hard joins and ends, square points, andthin solid bars outlined in the ink (the tokens say so; an earlier stripe hatch wasdecoration and went). The chart primitives write every colour, width, radius and opacitythe tokens hold; the recipe owns only what a token cannot: dashes, joins and caps, pixel@@ -883,7 +891,7 @@/* The axis part is both the tick text and the axis-break marks: the face rules reach the textalone, so a line never picks up a font. */:root[data-theme="geek"] .ui-chart text:is([data-part="axis"], [data-part="label"]) {- font-family: var(--ui-font-ui);+ font-family: var(--ui-font-mono);letter-spacing: var(--ui-tracking-label);text-transform: uppercase;}diff --git a/packages/ui/src/themes/github.css b/packages/ui/src/themes/github.cssindex 81af8ecd..325388a9 100644--- a/packages/ui/src/themes/github.css+++ b/packages/ui/src/themes/github.css@@ -1,12 +1,16 @@/*** Primer (`github`) — the default theme. Reference: github.com and primer.style.*- * W0 status: every LIGHT value is the app's CURRENT computed value, so adopting the token layer- * moves no pixel there — system font stacks, stock Tailwind gray, emerald / amber / red status- * tones, the 6px control radius, Tailwind's stock shadow recipes and the 3px gray focus ring.- * Values the app had no equivalent for (the `done` and `info` tones, diff surfaces, glass, the- * type and density roles) are proposals in the same palette, consumed by nothing yet. The Primer- * unification — Mona Sans + Noto, one border grey, Primer's tone hues — lands as W1a.+ * W0 status: the LIGHT values are the app's own look — emerald / amber / red status tones, the+ * 6px control radius, Tailwind's stock shadow recipes and the 3px gray focus ring — with two+ * changes made on purpose since. The typefaces are GitHub Primer's own since 2026-09-30 (Mona+ * Sans, JetBrains Mono and Noto Sans SC in place of the system stacks). And the blacks, whites+ * and grays are pure neutral since the same day: Tailwind's stock gray carries a slate tint (hue+ * about 264, chroma up to 0.034) that made them read off to the owner, whose reference was the+ * zero-chroma grays of Vercel's Geist (turborepo.dev). So the light bridge is Tailwind's+ * `neutral` scale at the same rungs, and the accent is the neutral near-black. Values the app+ * had no equivalent for (the `done` and `info` tones, diff surfaces, glass, the type and density+ * roles) are proposals in the same palette, consumed by nothing yet.** Dark is no longer the app's white-on-pure-black inversion (user decision, 2026-09-29): the* canvas lifts to #121212, the body ink sits at about 12:1 with the muted ink at 6:1 and the@@ -39,19 +43,22 @@@layer ui-theme {:root,:root[data-theme="github"] {- /* ---- Gray bridge: stock Tailwind v4 gray ---- */+ /* ---- Gray bridge: Tailwind v4's `neutral` scale, zero chroma. Every `gray-*` class the app+ spells lands on the same rung it always did, only without the slate tint, and every token+ below that reads a gray (lines, inks, the sidebar's muted fill) follows it. The rungs hold+ the light floors: 900 on white is 17.9:1, 500 on the 50 fill 4.53:1. ---- */--color-white: var(--ui-surface);- --color-gray-50: oklch(98.5% 0.002 247.839);- --color-gray-100: oklch(96.7% 0.003 264.542);- --color-gray-200: oklch(92.8% 0.006 264.531);- --color-gray-300: oklch(87.2% 0.01 258.338);- --color-gray-400: oklch(70.7% 0.022 261.325);- --color-gray-500: oklch(55.1% 0.027 264.364);- --color-gray-600: oklch(44.6% 0.03 256.802);- --color-gray-700: oklch(37.3% 0.034 259.733);- --color-gray-800: oklch(27.8% 0.033 256.848);- --color-gray-900: oklch(21% 0.034 264.665);- --color-gray-950: oklch(13% 0.028 261.692);+ --color-gray-50: oklch(98.5% 0 0); /* #fafafa */+ --color-gray-100: oklch(97% 0 0); /* #f5f5f5 */+ --color-gray-200: oklch(92.2% 0 0); /* #e5e5e5 */+ --color-gray-300: oklch(87% 0 0); /* #d4d4d4 */+ --color-gray-400: oklch(70.8% 0 0); /* #a1a1a1 */+ --color-gray-500: oklch(55.6% 0 0); /* #737373 */+ --color-gray-600: oklch(43.9% 0 0); /* #525252 */+ --color-gray-700: oklch(37.1% 0 0); /* #404040 */+ --color-gray-800: oklch(26.9% 0 0); /* #262626 */+ --color-gray-900: oklch(20.5% 0 0); /* #171717 */+ --color-gray-950: oklch(14.5% 0 0); /* #0a0a0a *//* ---- Colour — surfaces ---- */--ui-canvas: #ffffff;@@ -75,13 +82,14 @@--ui-line-emphasis: var(--color-gray-300);--ui-divider: var(--color-gray-200);- /* ---- Colour — accent (neutral: near-black on white) ---- */- --ui-accent: #111827;- --ui-accent-hover: #1f2937;- --ui-accent-active: #374151;+ /* ---- Colour — accent (neutral: near-black on white). The ink's own rung, neutral-900, with+ 800 and 700 as hover and active: the same steps the slate accent took from its scale ---- */+ --ui-accent: #171717;+ --ui-accent-hover: #262626;+ --ui-accent-active: #404040;--ui-accent-fg: #ffffff;- --ui-accent-muted: rgb(17 24 39 / 0.08);- --ui-accent-line: rgb(17 24 39 / 0.4);+ --ui-accent-muted: rgb(23 23 23 / 0.08);+ --ui-accent-line: rgb(23 23 23 / 0.4);/* ---- Colour — semantic tones ----Ink on a tint and a solid fill's label clear 4.5:1 (badge text is the 700 step, as the app's@@ -121,10 +129,10 @@/* ---- Charts: the series palette in its roles (violet, amber, sky, rose, emerald, fuchsia,then teal and orange from the employee palette). Amber, sky, emerald, teal and orange sitat their 600 steps — the steps the app's dark series already used — since their 500s read- at 2.2–2.9:1 on white (lifted 2026-09-30, the one Primer change of the theme work; violet,- rose and fuchsia clear 3:1 at 500). The reference curve is amber like the second series;- the token-kind blues and today's geometry — bars at 60% of their band with square tops,- 2px lines joined straight, 2.5px points, a 10% fill under a line. ---- */+ at 2.2–2.9:1 on white (lifted 2026-09-30 to clear the floor; violet, rose and fuchsia clear+ 3:1 at 500). The reference curve is amber like the second series; the token-kind blues and+ today's geometry — bars at 60% of their band with square tops, 2px lines joined straight,+ 2.5px points, a 10% fill under a line. ---- */--ui-chart-1: oklch(60.6% 0.25 292.717); /* violet-500 */--ui-chart-2: oklch(66.6% 0.179 58.318); /* amber-600 */--ui-chart-3: oklch(58.8% 0.158 241.966); /* sky-600 */@@ -215,17 +223,21 @@--ui-switch-knob-on: var(--ui-accent-fg);--ui-switch-knob-line: var(--color-gray-500);- /* ---- Typography — families: the system stacks the app ships today; chrome and reading text- share the one face. The sans stack reads the CJK face where the app's stack names the two- system CJK faces, so the computed list is the same and a chosen CJK face reaches it. ---- */+ /* ---- Typography — families: GitHub Primer's faces (Mona Sans, JetBrains Mono for code,+ Noto Sans SC for Han), each in front of the system stack the app shipped before, which+ stays behind it as the fallback; chrome and reading text share the one face. Latin first,+ then the CJK face, then the system stack — the order every theme keeps — so Han text+ renders in Noto Sans SC (or the chosen CJK face, through `--ui-font-cjk`) on every+ platform rather than in whichever system face carries CJK glyphs. ---- */--ui-font-sans:- ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, var(--ui-font-cjk), sans-serif;+ "Mona Sans Variable", var(--ui-font-cjk), ui-sans-serif, system-ui, -apple-system, "Segoe UI",+ Roboto, sans-serif;--ui-font-ui: var(--ui-font-sans);--ui-font-mono:- ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New",- monospace;+ "JetBrains Mono Variable", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,+ "Liberation Mono", "Courier New", monospace;--ui-font-display: var(--ui-font-sans);- --ui-font-cjk: "PingFang SC", "Microsoft YaHei";+ --ui-font-cjk: "Noto Sans SC Variable", "PingFang SC", "Microsoft YaHei";/* ---- Typography — scale and roles: Tailwind's stock text-sm / text-xs rungs, which is whatthe app's classes render today (theme.css bridges `text-sm` and `text-xs` to these). The two@@ -358,13 +370,13 @@--ui-icon-join: round;/* ---- Focus, selection and scrollbar ---- */- --ui-focus-ring: 3px solid rgb(107 114 128 / 0.4);+ --ui-focus-ring: 3px solid rgb(115 115 115 / 0.4); /* neutral-500 */--ui-focus-ring-offset: 2px;--ui-focus-ring-input: 0 0 0 2px color-mix(in oklab, var(--color-gray-400) 30%, transparent);--ui-selection-bg: rgb(0 0 0 / 0.1);--ui-scrollbar-w: thin;- --ui-scrollbar-thumb: rgb(60 64 67 / 0.28);- --ui-scrollbar-thumb-hover: rgb(60 64 67 / 0.45);+ --ui-scrollbar-thumb: rgb(64 64 64 / 0.28); /* neutral-700 */+ --ui-scrollbar-thumb-hover: rgb(64 64 64 / 0.45);--ui-scrollbar-track: transparent;--ui-scrollbar-visibility: auto;}@@ -421,13 +433,14 @@--ui-line-emphasis: var(--color-gray-700);--ui-divider: var(--color-gray-800);- /* ---- Colour — accent (neutral: light gray with dark text) ---- */- --ui-accent: #f3f4f6;- --ui-accent-hover: #e5e7eb;- --ui-accent-active: #d1d5db;- --ui-accent-fg: #111827;- --ui-accent-muted: rgb(243 244 246 / 0.12);- --ui-accent-line: rgb(243 244 246 / 0.4);+ /* ---- Colour — accent (neutral: light gray with dark text): neutral-100, with 200 and 300+ as hover and active and the light accent's neutral-900 as its label ---- */+ --ui-accent: #f5f5f5;+ --ui-accent-hover: #e5e5e5;+ --ui-accent-active: #d4d4d4;+ --ui-accent-fg: #171717;+ --ui-accent-muted: rgb(245 245 245 / 0.12);+ --ui-accent-line: rgb(245 245 245 / 0.4);/* ---- Colour — semantic tones: 400 ink on the 950/40 tints the app's dark notices use; thesolid fills and their labels are the light ones ---- */@@ -476,8 +489,8 @@/* ---- Selection and scrollbar ---- */--ui-selection-bg: rgb(255 255 255 / 0.18);- --ui-scrollbar-thumb: rgb(232 234 237 / 0.2);- --ui-scrollbar-thumb-hover: rgb(232 234 237 / 0.35);+ --ui-scrollbar-thumb: rgb(229 229 229 / 0.2); /* neutral-200 */+ --ui-scrollbar-thumb-hover: rgb(229 229 229 / 0.35);}/*@@ -489,10 +502,10 @@* agent's work, a plain dim behind a dialog, a streaming reply under the host's own pulsing* caret glyph — so no recipe is written for those, and none may* be until a Primer polish wave changes that look on purpose (the 2026-09-30 lift of the light- * chart steps and the knob's hairline was such a change, made in tokens, not recipes). The- * two rules every theme shares (the eyebrow on the h6 rung,- * the display title in the emphasis ink) live in theme.css and are what the app's group labels- * and page titles already draw: 11px semibold tracked capitals, and the body ink in light.+ * chart steps, the knob's hairline and the neutral grays were such changes, made in tokens,+ * not recipes). The two rules every theme shares (the eyebrow on the h6 rung, the display+ * title in the emphasis ink) live in theme.css and are what the app's group labels and page+ * titles already draw: 11px semibold tracked capitals, and the body ink in light.*/}diff --git a/packages/ui/src/tokens.ts b/packages/ui/src/tokens.tsindex 368f99d8..cbe8c7f7 100644--- a/packages/ui/src/tokens.ts+++ b/packages/ui/src/tokens.ts@@ -26,11 +26,11 @@** Two faces, not one: `--ui-font-ui` is the chrome's face (navigation, controls, labels, headings,* badges, tables — `body` reads it), `--ui-font-sans` the reading face (message text, prose, the- * composer's input, which opt in with `font-sans`). Primer and Frost point both at one family;- * Console sets the chrome in a monospaced face and keeps reading text in a sans. Every sans- * stack reads `--ui-font-cjk` for Han, so the user's font pairing (boot.ts, `data-font-latin` /- * `data-font-cjk`, resolved in `theme.css`'s `ui-font` layer) replaces the sans and the CJK face- * under any theme and leaves the mono face alone.+ * composer's input, which opt in with `font-sans`). Every theme points the chrome at its sans+ * today (Console's chrome was monospaced until 2026-09-30); the two names stay so a theme can+ * set them apart. Every sans stack reads `--ui-font-cjk` for Han, so the user's font pairing+ * (boot.ts, `data-font-latin` / `data-font-cjk`, resolved in `theme.css`'s `ui-font` layer)+ * replaces the sans and the CJK face under any theme and leaves the mono face alone.** Dark mode is calmer than a white-on-black inversion, but not dim: `--ui-fg` is the body ink* at roughly 84% white (about 12:1 on the page surfaces, never under 11:1 — the owner found a@@ -135,10 +135,11 @@ export const ACCENT_PRESET_IDS: readonly AccentPreset[] = [* mode, spelled as the theme file spells it, so a picker can paint the "theme's own" swatch* without a stylesheet probe (a test holds each value equal to the CSS). Primer's and Console's* are monochrome — the ink in light, a near-white in dark — so that swatch shows black or white- * rather than a hue; Frost's is its green.+ * rather than a hue; Primer's are zero-chroma neutrals (2026-09-30), not the slate of Tailwind's+ * stock gray. Frost's is its green.*/export const THEME_OWN_ACCENTS: OwnAccents = {- github: { light: "#111827", dark: "#f3f4f6" },+ github: { light: "#171717", dark: "#f5f5f5" },modern: { light: "#006838", dark: "#4aa45c" },geek: { light: "#1d1d1f", dark: "#f4f2f2" },};diff --git a/packages/ui/test/deslop.test.ts b/packages/ui/test/deslop.test.tsindex 7dee0efb..8811c984 100644--- a/packages/ui/test/deslop.test.ts+++ b/packages/ui/test/deslop.test.ts@@ -145,11 +145,11 @@ describe("theme values the rules reach", () => {// §2.4: a theme may uppercase its h1 (through .ui-display) and h6, the group-label rung// (through .ui-eyebrow); nothing between is uppercased. Headings are set in the theme's chrome// face (`--ui-font-ui`), its reading face or its display face — never in `--ui-font-mono`, the- // DATA face, and never in a literal monospace stack. Console's chrome face is itself- // monospaced (user decision, 2026-09-19), and that is the one door: a heading rung reaches a- // mono face only by reading `--ui-font-ui`, so a theme that wants mono titles says so once,- // in the face, and a component still never writes `font-mono` on a label (rule 16). The- // reading face stays proportional in every theme: prose is not set in mono.+ // DATA face, and never in a literal monospace stack. A theme may set its chrome face in a+ // monospaced family (Console did from 2026-09-19 to 2026-09-30), and that is the one door: a+ // heading rung reaches a mono face only by reading `--ui-font-ui`, so a theme that wants mono+ // titles says so once, in the face, and a component still never writes `font-mono` on a label+ // (rule 16). The reading face stays proportional in every theme: prose is not set in mono.const themes = THEME_IDS.map((id) => {const rel = `themes/${id}.css`;const path = join(SRC_DIR, rel);@@ -486,6 +486,15 @@ describe("the rule checks, on known shapes", () => {expect(found("t.css", ".x .ui-frame > [data-slot=head] { font-family: var(--ui-font-mono); }"),).toEqual(["16:.x .ui-frame > [data-slot=head] { font-family: var(--ui-font-mono) }"]);+ // The technical marks may take the mono face; the text beside them may not.+ expect(+ found(+ "t.css",+ ".x .ui-notice::before { font-family: var(--ui-font-mono); }\n" ++ '.x .ui-activity [data-slot="label"] { font-family: var(--ui-font-mono); }\n' ++ '.x .ui-activity [data-slot="detail"] { font-family: var(--ui-font-mono); }',+ ),+ ).toEqual(['16:.x .ui-activity [data-slot="detail"] { font-family: var(--ui-font-mono) }']);expect(found("page-header.tsx",diff --git a/packages/ui/test/token-contract.test.ts b/packages/ui/test/token-contract.test.tsindex 09daef31..cae77654 100644--- a/packages/ui/test/token-contract.test.ts+++ b/packages/ui/test/token-contract.test.ts@@ -36,12 +36,15 @@ import {} from "../src/tokens";import type { ThemeId } from "../src/tokens";import {+ GRAY_STEPS,accentProblems,analyzeFile,analyzeThemeFile,contractProblems,darkRepeats,matchesPolicyPath,+ modeDeclarations,+ parseColor,parseCssRules,scanSourceRoots,stripCssComments,@@ -442,26 +445,73 @@ describe("the integration revision of the contract (2026-09-29)", () => {}});- it("keeps Primer's light ink, faces and switch as today's, and moves only its dark", () => {+ it("keeps Primer's light ink, lines and switch on today's rungs, and moves only its dark", () => {const primer = THEMES.find((theme) => theme.id === DEFAULT_THEME_ID);if (primer === undefined || primer.status !== "filled") throw new Error("Primer is filled");const light = primer.analysis.modes.light;- expect(light.get("--ui-fg")).toBe("var(--color-gray-900)");- expect(light.get("--ui-switch-track")).toBe("var(--color-gray-200)");+ // The rungs are the ones the app always drew; the bridge under them went neutral (below).+ const rungs: Readonly<Record<string, string>> = {+ "--ui-surface-muted": "var(--color-gray-50)",+ "--ui-fg": "var(--color-gray-900)",+ "--ui-fg-muted": "var(--color-gray-500)",+ "--ui-fg-subtle": "var(--color-gray-400)",+ "--ui-line": "var(--color-gray-200)",+ "--ui-line-muted": "var(--color-gray-100)",+ "--ui-line-emphasis": "var(--color-gray-300)",+ "--ui-switch-track": "var(--color-gray-200)",+ };+ for (const [name, value] of Object.entries(rungs)) expect(light.get(name), name).toBe(value);expect(light.get("--ui-switch-knob")).toBe("#ffffff");- // The sans stack reads the CJK face where it named the two system faces: the same list.+ // The faces are GitHub Primer's (2026-09-30): the sans stack reads the CJK face where it+ // named the two system CJK faces, and those two stay behind Noto as its fallback.expect(light.get("--ui-font-sans")).toContain("var(--ui-font-cjk)");- expect(light.get("--ui-font-cjk")).toBe('"PingFang SC", "Microsoft YaHei"');+ expect(light.get("--ui-font-cjk")).toBe(+ '"Noto Sans SC Variable", "PingFang SC", "Microsoft YaHei"',+ );// Dark lifts off pure black and calms the body ink: the ramp, not the app's #000.const dark = primer.analysis.modes.dark;expect(dark.get("--color-gray-950")).not.toBe("#000000");expect(dark.get("--color-gray-100")).not.toBe(light.get("--color-gray-100"));});+ it("keeps Primer's grays and its own accent pure neutral in both modes", () => {+ // The owner found the slate tint of Tailwind's stock gray (hue about 264) read off, and took+ // the zero-chroma grays of Vercel's Geist as the reference (2026-09-30): light re-points the+ // bridge to Tailwind's `neutral` scale at the same rungs, dark was a neutral ramp already, and+ // the accent family is the neutral near-black in light and near-white in dark. A value is+ // neutral when its three channels agree; the oklch conversion leaves a rounding hair.+ const primer = THEMES.find((theme) => theme.id === DEFAULT_THEME_ID);+ if (primer === undefined || primer.status !== "filled") throw new Error("Primer is filled");+ const tinted = (value: string | undefined): boolean => {+ const color = value === undefined ? null : parseColor(value);+ if (color === null) return true;+ return Math.max(color.r, color.g, color.b) - Math.min(color.r, color.g, color.b) > 0.5;+ };+ const accent = [+ "--ui-accent",+ "--ui-accent-hover",+ "--ui-accent-active",+ "--ui-accent-fg",+ "--ui-accent-muted",+ "--ui-accent-line",+ ];+ for (const mode of THEME_MODES) {+ const values = modeDeclarations(primer.analysis, mode);+ const names = [...GRAY_STEPS.map((step) => `--color-gray-${step}`), ...accent];+ const off = names.filter((name) => tinted(values.get(name)));+ expect(+ off.map((name) => `${name}: ${values.get(name)}`),+ mode,+ ).toEqual([]);+ }+ expect(primer.analysis.modes.light.get("--color-gray-900")).toBe("oklch(20.5% 0 0)");+ expect(THEME_OWN_ACCENTS.github).toEqual({ light: "#171717", dark: "#f5f5f5" });+ });+it("resolves the font pairing in theme.css's ui-font layer, for every face the lists offer", () => {// Every chosen face has a rule; a Latin choice sets the reading sans (and keeps the CJK face// in its stack), a CJK choice sets the CJK face; no pairing rule touches the mono or the- // chrome face directly — Console's mono chrome is its identity, not a reading preference.+ // chrome face directly — the chrome reaches a choice through the sans it reads.const rules = parseCssRules(read("theme.css")).filter((rule) =>/data-font-(?:latin|cjk)=/.test(rule.selector),);@@ -486,15 +536,14 @@ describe("the integration revision of the contract (2026-09-29)", () => {expect(rule.declarations.map((d) => d.name)).not.toContain("--ui-font-ui");}// A chosen face reaches every theme: each sans stack reads the CJK face, and the chrome- // face is the sans (Primer, Frost) or the mono (Console), never a third stack.+ // face is the sans in every theme — Console's too, since it left its mono chrome+ // (2026-09-30) — so a chosen Latin face reaches the chrome as well as the reading text.for (const theme of THEMES) {if (theme.status !== "filled") continue;for (const mode of THEME_MODES) {const values = new Map([...theme.analysis.modes.light, ...theme.analysis.modes[mode]]);expect(values.get("--ui-font-sans"), `${theme.id} ${mode}`).toContain("var(--ui-font-cjk)");- expect(["var(--ui-font-sans)", "var(--ui-font-mono)"], `${theme.id} ${mode}`).toContain(- values.get("--ui-font-ui"),- );+ expect(values.get("--ui-font-ui"), `${theme.id} ${mode}`).toBe("var(--ui-font-sans)");}}});@@ -565,7 +614,7 @@ describe("the chart style tokens (round 7)", () => {});it("keeps Primer at today's geometry, and its palette at the steps that read on white", () => {- // The one Primer change of the theme work (2026-09-30): amber, sky, emerald, teal and orange+ // A Primer change of the theme work (2026-09-30): amber, sky, emerald, teal and orange// move from their 500 steps (2.2–2.9:1 on white) to the 600 steps the app's dark series// already used; violet, rose and fuchsia clear 3:1 at 500 and stay.const primer = THEMES.find((theme) => theme.id === DEFAULT_THEME_ID);@@ -716,6 +765,28 @@ describe("the themes' own faces (round 6)", () => {}});+ it("sets Console in Plex Sans, and the mono face only on code and technical marks", () => {+ // The owner's call (2026-09-30): IBM Plex Sans is Console's main face, chrome included, and+ // JetBrains Mono (in place of Commit Mono) is kept for code — `code` / `pre` in theme.css —+ // and for the marks that are technical on purpose. No other Console recipe names it.+ expect(THEME_FONTS.geek).toEqual({+ latin: "IBM Plex Sans",+ cjk: "Noto Sans SC",+ mono: "JetBrains Mono",+ });+ const mono = parseCssRules(read("themes/geek.css"))+ .filter((rule) =>+ rule.declarations.some((d) => d.name === "font-family" && /--ui-font-mono/.test(d.value)),+ )+ .map((rule) => rule.selector);+ expect(mono).toEqual([+ ':root[data-theme="geek"] .ui-activity [data-slot="label"]',+ ':root[data-theme="geek"] .ui-activity[data-state="running"] [data-slot="progress"]',+ ':root[data-theme="geek"] .ui-notice::before',+ ':root[data-theme="geek"] .ui-chart text:is([data-part="axis"], [data-part="label"])',+ ]);+ });+it("offers the pairing's faces under the same names", () => {for (const option of [...FONT_LATIN_OPTIONS, ...FONT_CJK_OPTIONS]) {if (option.id === "theme" || option.id === "system") continue;diff --git a/packages/web/public/workflow-ui.css b/packages/web/public/workflow-ui.cssindex a2c615c6..5f6a93dc 100644--- a/packages/web/public/workflow-ui.css+++ b/packages/web/public/workflow-ui.css@@ -17,13 +17,13 @@:root {color-scheme: light;--wf-bg: #ffffff;- --wf-surface: var(--color-gray-50, #f9fafb);- --wf-fg: var(--color-gray-900, #111827);- --wf-muted: var(--color-gray-500, #6b7280);- --wf-border: var(--color-gray-200, #e5e7eb);- --wf-hover: var(--color-gray-100, #f3f4f6);- --wf-accent: var(--accent-bg, #111827);- --wf-accent-fg: var(--accent-fg, #ffffff);+ --wf-surface: var(--color-gray-50, #fafafa);+ --wf-fg: var(--color-gray-900, #171717);+ --wf-muted: var(--color-gray-500, #737373);+ --wf-border: var(--color-gray-200, #e5e5e5);+ --wf-hover: var(--color-gray-100, #f5f5f5);+ --wf-accent: var(--ui-accent, #171717);+ --wf-accent-fg: var(--ui-accent-fg, #ffffff);--wf-radius: 6px;--wf-font: var(--font-app-sans,@@ -44,23 +44,23 @@@media (prefers-color-scheme: dark) {:root:not(.light) {color-scheme: dark;- --wf-bg: var(--color-gray-950, #000000);- --wf-surface: var(--color-gray-900, #0d0d0d);- --wf-fg: var(--color-gray-100, #f3f4f6);- --wf-muted: var(--color-gray-400, #9ca3af);- --wf-border: var(--color-gray-700, #303030);- --wf-hover: var(--color-gray-800, #1f1f1f);+ --wf-bg: var(--color-gray-950, #121212);+ --wf-surface: var(--color-gray-900, #1a1a1a);+ --wf-fg: var(--color-gray-100, #f5f5f5);+ --wf-muted: var(--color-gray-400, #a1a1a1);+ --wf-border: var(--color-gray-700, #333333);+ --wf-hover: var(--color-gray-800, #262626);}}:root.dark {color-scheme: dark;- --wf-bg: var(--color-gray-950, #000000);- --wf-surface: var(--color-gray-900, #0d0d0d);- --wf-fg: var(--color-gray-100, #f3f4f6);- --wf-muted: var(--color-gray-400, #9ca3af);- --wf-border: var(--color-gray-700, #303030);- --wf-hover: var(--color-gray-800, #1f1f1f);+ --wf-bg: var(--color-gray-950, #121212);+ --wf-surface: var(--color-gray-900, #1a1a1a);+ --wf-fg: var(--color-gray-100, #f5f5f5);+ --wf-muted: var(--color-gray-400, #a1a1a1);+ --wf-border: var(--color-gray-700, #333333);+ --wf-hover: var(--color-gray-800, #262626);}body {diff --git a/packages/web/src/features/terminal/terminal-view.tsx b/packages/web/src/features/terminal/terminal-view.tsxindex 15845419..3c1b9eaf 100644--- a/packages/web/src/features/terminal/terminal-view.tsx+++ b/packages/web/src/features/terminal/terminal-view.tsx@@ -64,9 +64,9 @@ export type TerminalStatus = "connecting" | "ready" | "exited" | "error";/*** The screen's own palette, one per appearance. Two things matter here.*- * The surface colours are the app's, not a terminal's: `#000000`/`#ffffff` are the body- * tones (the default theme, `themes/github.css` in @prismshadow/penguin-ui, overrides the- * neutral gray scale to pure black in dark mode), and the selection matches its `::selection`. A panel docked inside the app that brought its+ * The surface colours are the app's, not a terminal's: `#121212`/`#ffffff` are the default+ * theme's canvas (`themes/github.css` in @prismshadow/penguin-ui) and its neutral ink, and the+ * selection matches its `::selection`. A panel docked inside the app that brought its* own charcoal along read as a foreign window sitting on top of it.** The sixteen ANSI slots are NOT the app's palette and must not be: programs pick them by@@ -76,10 +76,10 @@ export type TerminalStatus = "connecting" | "ready" | "exited" | "error";* VGA-bright and unreadable on white.*/const DARK_THEME = {- background: "#000000",- foreground: "#f3f4f6",- cursor: "#f3f4f6",- cursorAccent: "#000000",+ background: "#121212",+ foreground: "#f5f5f5",+ cursor: "#f5f5f5",+ cursorAccent: "#121212",selectionBackground: "rgba(255, 255, 255, 0.18)",black: "#000000",red: "#cd3131",@@ -101,8 +101,8 @@ const DARK_THEME = {const LIGHT_THEME = {background: "#ffffff",- foreground: "#111827",- cursor: "#111827",+ foreground: "#171717",+ cursor: "#171717",cursorAccent: "#ffffff",selectionBackground: "rgba(0, 0, 0, 0.12)",black: "#000000",diff --git a/packages/web/src/features/workflows/workflow-tabs.tsx b/packages/web/src/features/workflows/workflow-tabs.tsxindex 4a4786c1..1f952dfc 100644--- a/packages/web/src/features/workflows/workflow-tabs.tsx+++ b/packages/web/src/features/workflows/workflow-tabs.tsx@@ -96,7 +96,7 @@ const FRAME_REVEAL_TIMEOUT_MS = 4000;const TAB_BASE ="relative h-9 shrink-0 border-b-2 px-3 text-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-gray-400";-const TAB_ACTIVE = "border-[var(--accent-bg)] font-medium text-gray-900 dark:text-gray-100";+const TAB_ACTIVE = "border-accent font-medium text-gray-900 dark:text-gray-100";const TAB_IDLE ="border-transparent text-gray-500 hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-200";diff --git a/packages/web/src/lib/workflow-theme.ts b/packages/web/src/lib/workflow-theme.tsindex fa1af988..bf8d7338 100644--- a/packages/web/src/lib/workflow-theme.ts+++ b/packages/web/src/lib/workflow-theme.ts@@ -15,14 +15,14 @@ export const WORKFLOW_THEME_HREF = "/workflow-ui.css";/*** Custom properties copied from the app's root to the frame's. The gray scale is Tailwind's- * (`@theme` in styles.css, with the dark overrides), the accent pair and font stack are the- * app's own; every one is read RESOLVED, so light/dark and the chosen accent are already+ * (`@theme` in styles.css, with the dark overrides), the accent pair (the theme's `--ui-accent` tokens) and font stack are+ * the app's own; every one is read RESOLVED, so light/dark and the chosen accent are already* applied and the frame needs none of that logic.*/export const WORKFLOW_THEME_VARS = ["--font-app-sans",- "--accent-bg",- "--accent-fg",+ "--ui-accent",+ "--ui-accent-fg","--color-gray-50","--color-gray-100","--color-gray-200",diff --git a/packages/web/test/avatar.test.ts b/packages/web/test/avatar.test.tsindex 918c016d..d38e23b2 100644--- a/packages/web/test/avatar.test.ts+++ b/packages/web/test/avatar.test.ts@@ -112,9 +112,10 @@ function tileOver(h: number, surface: [number, number, number]): [number, numberconst hexRgb = (s: string) =>[1, 3, 5].map((i) => parseInt(s.slice(i, i + 2), 16) / 255) as [number, number, number];-// App surfaces the tile sits on: light = white / gray-50 rows / gray-100 hover;-// dark = the default theme's true-neutral overrides (penguin-ui themes/github.css: gray-900/800/700).-const LIGHT_SURFACES = ["#ffffff", "#f9fafb", "#f3f4f6"].map(hexRgb);+// App surfaces the tile sits on: light = white / gray-50 rows / gray-100 hover, which the+// default theme bridges to Tailwind's zero-chroma neutral scale (penguin-ui themes/github.css);+// dark = that theme's true-neutral overrides (gray-900/800/700).+const LIGHT_SURFACES = ["#ffffff", "#fafafa", "#f5f5f5"].map(hexRgb);const DARK_SURFACES = ["#0d0d0d", "#1f1f1f", "#303030"].map(hexRgb);/** Saturation/lightness actually emitted by avatarTile (parsed so this test can't drift from the implementation). */diff --git a/packages/web/test/workflow-theme.test.ts b/packages/web/test/workflow-theme.test.tsindex 51417eba..620d6771 100644--- a/packages/web/test/workflow-theme.test.ts+++ b/packages/web/test/workflow-theme.test.ts@@ -18,7 +18,7 @@ const appRoot = (classes: string[], fontSize: string) => ({describe("workflow theme", () => {it("reads the resolved appearance rather than recomputing it", () => {const values: Record<string, string> = {- "--accent-bg": " #2563eb ",+ "--ui-accent": " #2563eb ","--color-gray-950": "#000","--color-gray-100": "",};@@ -26,7 +26,7 @@ describe("workflow theme", () => {expect(theme.dark).toBe(true);expect(theme.fontSize).toBe("16px");// Trimmed, and a property the app does not define is not stamped as an empty value.- expect(theme.vars).toEqual({ "--accent-bg": "#2563eb", "--color-gray-950": "#000" });+ expect(theme.vars).toEqual({ "--ui-accent": "#2563eb", "--color-gray-950": "#000" });});it("stamps light explicitly, so the app's choice beats the system preference", () => {@@ -38,12 +38,12 @@ describe("workflow theme", () => {const theme: WorkflowTheme = {dark: true,fontSize: "16px",- vars: { "--accent-bg": "#2563eb" },+ vars: { "--ui-accent": "#2563eb" },};applyWorkflowTheme(doc.document, theme);applyWorkflowTheme(doc.document, theme);expect(doc.classes).toEqual({ dark: true, light: false });- expect(doc.properties).toEqual({ "--accent-bg": "#2563eb" });+ expect(doc.properties).toEqual({ "--ui-accent": "#2563eb" });expect(doc.root.style.fontSize).toBe("16px");expect(doc.links).toEqual([{ rel: "stylesheet", href: WORKFLOW_THEME_HREF }]);diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex b9a29bb0..e57f7be1 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -496,9 +496,6 @@ importers:'@fontsource-variable/noto-sans-sc':specifier: ^5.3.0version: 5.3.0- '@fontsource/commit-mono':- specifier: ^5.3.0- version: 5.3.0'@fontsource/ibm-plex-sans-condensed':specifier: ^5.3.0version: 5.3.0@@ -1322,9 +1319,6 @@ packages:'@fontsource-variable/[email protected]':resolution: {integrity: sha512-lNar1dF7Ik/lHNPo/7JWG0TolXY29LtsqYgMvEysooZ5bsO9uH4shJmRrwyJ3PjyTPljhpMJEK0jDuLSU4vJ1w==}- '@fontsource/[email protected]':- resolution: {integrity: sha512-Bs+zlEWHDgk/cCVWEMJJaA7LbBU3Ixi5Zums+SSwMKdm2N7RJ4P7jCJTwsMHRt5WFiXYB0tu0q9HMfkn0YsLsQ==}-'@fontsource/[email protected]':resolution: {integrity: sha512-fQyBpwbkguP4azjq7Cw8h/J3C/d8MFAzXOiSoFxyKCUK4x0XKrWEh3tGdTxhDM0HctVRQilQo1zGoyxDHLm5jQ==}@@ -5323,8 +5317,6 @@ snapshots:'@fontsource-variable/[email protected]': {}- '@fontsource/[email protected]': {}-'@fontsource/[email protected]': {}'@google/[email protected]([email protected])':