feat(ui): add accessible tooltips and enforce compact operational typography

This commit is contained in:
Codex
2026-11-11 23:53:26 +03:00
parent 601ca62e9a
commit 59411f4937
18 changed files with 514 additions and 57 deletions
+36 -4
View File
@@ -429,7 +429,8 @@
"Floating header supports arrow-key movement and Shift+arrow resizing. Bounds stay inside the viewport. Resize affordances have no hover decoration.",
"Inspectors inside a Window use its full available content width.",
"End inspectors opt into resizable with an optional initialRect; existing eight edge geometry and keyboard resize are shared with floating windows.",
"Application-owned rect restores modeless window geometry on reopen and external undo/import. onRectCommit reports one completed drag/resize or keyboard step; viewport fitting never overwrites saved geometry."
"Application-owned rect restores modeless window geometry on reopen and external undo/import. onRectCommit reports one completed drag/resize or keyboard step; viewport fitting never overwrites saved geometry.",
"Enforced operational typography: independent md/13px base for UI roots and portals; section/value text md, Description/status/error copy sm/12px, only canonical page/window titles use title/18px. Shared build-time typography contract and catalog example prevent browser-default size regressions."
]
},
{
@@ -467,7 +468,8 @@
"Rectangle, maximized state, visibility, activation and z-order are controlled by the application.",
"resizeIndicator=false hides only the corner glyph; pointer hit area, cursor and keyboard resizing remain available.",
"Use WorkspaceWindow for auxiliary views inside a stage; modal workflows and viewport inspectors continue to use Window.",
"Dragging and resizing remain clamped when the workspace changes size, including when it becomes smaller than the requested minimum."
"Dragging and resizing remain clamped when the workspace changes size, including when it becomes smaller than the requested minimum.",
"Enforced operational typography: independent md/13px base for UI roots and portals; section/value text md, Description/status/error copy sm/12px, only canonical page/window titles use title/18px. Shared build-time typography contract and catalog example prevent browser-default size regressions."
]
},
{
@@ -743,7 +745,8 @@
"Applications supply routes, profile data, stage media and panel content without changing shell geometry.",
"Light panels use the SEO white surface and shadow tokens rather than a dark shell with inverted text.",
"A layout-level save action belongs to ApplicationPanel.utilityActions and is never duplicated inside individual content cards.",
"ApplicationPanel allowFullscreen exposes an owned full-window context; the whole panel and its header move atomically, preserving the renderer and body-portaled inspectors."
"ApplicationPanel allowFullscreen exposes an owned full-window context; the whole panel and its header move atomically, preserving the renderer and body-portaled inspectors.",
"ApplicationPanel establishes md/13px operational typography independent of the host; its page title alone uses title/18px. Semantic section headings remain md; explanatory copy uses Description/sm."
]
},
{
@@ -1192,7 +1195,8 @@
"summary": "Secondary explanatory copy matching SettingsCard descriptions.",
"rules": [
"Use the same inherited family, regular 400 weight, small font token, muted text token and 1.4 line height for explanatory paragraphs. Do not restyle per feature.",
"Use role=status for explanatory pending/result copy. SettingsCard applies the same contract to unclassed body paragraphs as a fallback, without changing headings or controls."
"Use role=status for explanatory pending/result copy. SettingsCard applies the same contract to unclassed body paragraphs as a fallback, without changing headings or controls.",
"Enforced operational typography: independent md/13px base for UI roots and portals; section/value text md, Description/status/error copy sm/12px, only canonical page/window titles use title/18px. Shared build-time typography contract and catalog example prevent browser-default size regressions."
]
},
{
@@ -1385,6 +1389,34 @@
"Optional geometry sets width, height and radius with a 32 × 12 px minimum. At small dimensions the text and padding shrink proportionally; both contrast layers share the same type geometry. Consumer owns header-group offset."
],
"documentation": "../docs/LEVEL_BUTTON.md"
},
{
"id": "tooltip",
"status": "baseline",
"package": "@nodedc/ui-react",
"exports": [
"Tooltip",
"TooltipProps"
],
"domContract": [
"nodedc-tooltip-anchor",
"nodedc-tooltip"
],
"summary": "Neutral non-interactive explanation on hover, focus or touch.",
"behavior": [
"portal to active fullscreen element or body",
"shared viewport clamp and flip",
"hoverable content and focus persistence",
"Escape dismisses tooltip without closing its parent",
"one tooltip at a time",
"scroll/resize reposition",
"reduced-motion fade disabled"
],
"rules": [
"Use focusable for read-only graphics; action triggers own their focus.",
"Content is descriptive, never a menu or interactive form.",
"No new app-local tooltip geometry or layer management."
]
}
]
}