Per the 2026-11-05 owner ruling, the chat wears ProseTypography's faces: Valkyrie OT B for agent prose/thinking, Concourse OT Book for the user capsule and composer, UbuntuMono NFM for the mono voice. DesignTokens gains valkyrie/concourse/ubuntuMono constructors (Font.custom falls back to system faces when absent), and SessionTranscriptView's lineSpacings are recalibrated to each face's natural line box to hold the CSS leading ratios. AGENTS.md updated to match.
64 lines
2.7 KiB
Swift
64 lines
2.7 KiB
Swift
//
|
|
// DesignTokens.swift
|
|
// Museion
|
|
//
|
|
// Visual tokens from the design contract (ref/Web-Prototype/museion-workspace.html, #17).
|
|
//
|
|
|
|
import SwiftUI
|
|
|
|
/// Colors, radii, and column geometry extracted from the export's `:root`
|
|
/// and workspace grid. Light-only on purpose — the export defines one palette.
|
|
/// #89 calibration (2026-10-09): two-color world, deliberately departed from
|
|
/// the export — page (edit+read+cards share it) vs background (chrome/focus).
|
|
/// Values are live-calibrated with Alexander, not contract-fixed.
|
|
enum DesignTokens {
|
|
static let background = Color(red: 0xFA / 255, green: 0xF9 / 255, blue: 0xF3 / 255)
|
|
static let surface = Color(red: 0xFF / 255, green: 0xFE / 255, blue: 0xFB / 255)
|
|
static let foreground = Color(red: 0x1A / 255, green: 0x19 / 255, blue: 0x16 / 255)
|
|
static let muted = Color(red: 0x6B / 255, green: 0x69 / 255, blue: 0x64 / 255)
|
|
static let border = Color(red: 0xE8 / 255, green: 0xE5 / 255, blue: 0xDF / 255)
|
|
static let accent = Color(red: 0xC9 / 255, green: 0x64 / 255, blue: 0x42 / 255)
|
|
/// #153 map settle / #154 contract: the SOLE palette exception — the
|
|
/// semantic ready-green of the mentor header's ready dot. Never a style
|
|
/// color; it means "engine healthy".
|
|
static let readyGreen = Color(red: 0x36 / 255, green: 0x66 / 255, blue: 0x4F / 255)
|
|
|
|
static let radius: CGFloat = 10
|
|
|
|
/// #135 (prototype `.vC`): the Settings sidebar column and the detail
|
|
/// form's max width.
|
|
static let settingsSidebarWidth: CGFloat = 190
|
|
static let settingsFormWidth: CGFloat = 480
|
|
|
|
/// The workspace grid: rail | posts library | editor | mentor (grid-template-columns
|
|
/// `56px 232px minmax(420px, 1fr) 356px`). Editor min (420) has no enforcement
|
|
/// yet — the editor column arrives with #19.
|
|
static let railWidth: CGFloat = 56
|
|
static let libraryWidth: CGFloat = 232
|
|
static let mentorWidth: CGFloat = 356
|
|
|
|
/// The serif display face maps to the system serif design (export stack:
|
|
/// Iowan Old Style / Charter / Georgia); mono to the system monospaced.
|
|
static let serif: Font.Design = .serif
|
|
static let mono: Font.Design = .monospaced
|
|
|
|
/// The conversation surface's faces (owner ruling, 2026-11-05): the chat
|
|
/// wears the editor's typography (ProseTypography) — Valkyrie OT B the
|
|
/// prose voice (agent turns, thinking), Concourse OT Book the user
|
|
/// capsule/composer sans, UbuntuMono NFM the quiet mono voice. PostScript
|
|
/// names mirror ProseTypography; Font.custom falls back to system faces
|
|
/// if a name ever goes missing.
|
|
static func valkyrie(_ size: CGFloat) -> Font {
|
|
Font.custom("ValkyrieOTBRegular", size: size)
|
|
}
|
|
|
|
static func concourse(_ size: CGFloat) -> Font {
|
|
Font.custom("ConcourseOT3Book", size: size)
|
|
}
|
|
|
|
static func ubuntuMono(_ size: CGFloat) -> Font {
|
|
Font.custom("UbuntuMonoNFM", size: size)
|
|
}
|
|
}
|