Guidelines
Typography
loseta ships type tokens, not a prose plugin. Components pick from the same scale; long-form prose stays consumer CSS.
typography class to install.Type scale
| Token | Size | Use |
|---|---|---|
--text-4xl | 2.25rem | Marketing display |
--text-3xl | 1.875rem | Page titles |
--text-2xl | 1.5rem | Section titles |
--text-xl | 1.25rem | Subsections |
--text-lg | 1.125rem | Questionnaire legends |
--text-base | 1rem | Long-form body and mobile inputs |
--text-sm | 0.875rem | Component text and menu items |
--text-xs | 0.75rem | Labels, metadata and badges |
Every token has a paired line height token: --text-sm pairs with--text-sm--line-height. Use the pair; do not set a size and leave the line height at the browser default.
Specimen
Build with native CSS
A registry of components, not a runtime
The base scale keeps long-form reading comfortable. Interface text uses the smaller sizes so controls stay compact.
Secondary text uses --muted-foreground and --text-sm.
Metadata label
Fonts
The reset reads --font-sans for body text and --font-monofor code and keyboard hints. Both fall back to the platform UI and monospace stacks, so a project without font tokens still renders correctly. The docs use Inter; the registry does not ship a font file.
:root {
--font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;
--font-mono: "JetBrains Mono", ui-monospace, monospace;
}Interface rules
- UI text defaults to
--text-sm. Inputs and textareas use--text-basebelow48remand--text-smabove it, so mobile Safari does not zoom on focus. - Card, dialog and alert-dialog titles use
--text-base; alert, popover, empty and field titles use--text-sm. - Badges, keyboard hints, tooltips and navigation descriptions use
--text-xs. Menu headings and listbox group labels use the same size. - Questionnaires use
--text-lgfor the question legend and--text-smfor descriptions and choices. - Keep long-form prose near a 65–75 character measure; use your own prose layer.
Prose is consumer CSS
The registry styles component anatomy. It does not ship a .prose class, heading margins for articles or an automatic vertical rhythm. Use your site's prose styles or a content plugin, and keep the registry tokens for size and color.
/* Site prose, not registry CSS */
.prose :is(h2, h3) {
margin-block-start: 2em;
font-size: var(--text-2xl);
line-height: var(--text-2xl--line-height);
}Code and keys
Code uses --font-mono. Inline code inherits the surrounding size; the.code-block component owns block code and its line-height. Keyboard hints use .kbd.
Press ⌘K to open the command menu.