feat: introduce mathematical type scale with single-source-of-truth typography tokens

Define a major-third (1.25) type scale as CSS custom properties in the tokens
layer (--text-2xs through --text-5xl), along with line-height (--leading-*),
font-weight (--font-*), and letter-spacing (--tracking-*) tokens. Migrate all
28 core CSS files from ad-hoc values to token references with clamp()-based
responsive scaling for headings. Add TypographyTokenContractTest to enforce
token-only usage via grep-based assertions.

Task run: UI-TYPOGRAPHY-SCALE-001

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-22 15:47:55 +01:00
parent cf8c59d3f8
commit e145b7d089
30 changed files with 390 additions and 146 deletions

View File

@@ -3,9 +3,9 @@
background: var(--app-sidebar-background-color);
--app-sidebar-gap: 0.5rem;
--app-sidebar-item-gap: 10px;
--app-sidebar-title-size: 10px;
--app-sidebar-summary-size: 12px;
--app-sidebar-tenant-size: 14px;
--app-sidebar-title-size: 10px; /* icon-font metric — intentional px */
--app-sidebar-summary-size: var(--text-xs);
--app-sidebar-tenant-size: var(--text-sm);
--app-sidebar-titlebar-height: 30px;
--app-sidebar-border-width: 2px;
--app-sidebar-summary-max-width: 142px;
@@ -37,7 +37,7 @@
}
.app-sidebar-group.app-sidebar-admin-group details summary i {
font-size: 10px;
font-size: 10px; /* icon-font metric — intentional px */
position: relative;
top: -4px;
margin-right: 3px;
@@ -100,8 +100,8 @@
}
.app-sidebar-tenant-name {
font-weight: 600;
font-size: 17px;
font-weight: var(--font-semibold);
font-size: var(--text-base);
color: var(--app-contrast);
text-align: left;
overflow: hidden;
@@ -126,7 +126,7 @@
background: transparent;
color: var(--app-muted-color);
padding: 0.25rem;
font-size: 0.9rem;
font-size: var(--text-sm);
cursor: pointer;
margin-bottom: 0;
}