package file→ .shtukbase/packages/keer-ui/library/styles/typography.css
library/styles/typography.css
191 lines, 6.7 KB.
- /*
- * Text styles of the design code (section 4.2 of the “Design” standard).
- *
- * Size, weight, line height and letter spacing are set here once; in blocks and screens
- * text is styled only with these classes. The values come from tokens.css (the type/scale scale).
- * Each @utility is a separate block: the comment “Where to use: …” right above it, in one line;
- * the styles are read by machine from this markup.
- */
- /* Where to use: the page heading: PageHeader (h1) only. */
- @utility text-page-title {
- font-size: var(--ds-font-heading-1-size);
- line-height: var(--ds-line-heading-1);
- font-weight: var(--ds-font-weight-semibold);
- letter-spacing: var(--ds-letter-spacing-page-title);
- }
- /* Where to use: the heading of a page section outside a card: SectionHeader (h2). */
- @utility text-section-title {
- font-size: var(--ds-font-heading-4-size);
- line-height: var(--ds-line-heading-4);
- font-weight: var(--ds-font-weight-semibold);
- }
- /* Where to use: the heading of a card and a dialog: CardTitle, DialogTitle. */
- @utility text-card-title {
- font-size: var(--ds-font-heading-5-size);
- line-height: var(--ds-line-heading-5);
- font-weight: var(--ds-font-weight-semibold);
- }
- /* Where to use: a large number: an amount, a count, an indicator. */
- @utility text-metric {
- font-size: var(--ds-font-heading-1-size);
- line-height: var(--ds-line-heading-1);
- font-weight: var(--ds-font-weight-semibold);
- font-variant-numeric: tabular-nums;
- }
- /* Where to use: the main text: paragraphs, table cells, inputs. */
- @utility text-body {
- font-size: var(--ds-font-ui-size);
- line-height: var(--ds-line-ui);
- font-weight: var(--ds-font-weight-regular);
- }
- /* Where to use: emphasis in text: a title in a row, a menu item, a button. */
- @utility text-body-strong {
- font-size: var(--ds-font-ui-size);
- line-height: var(--ds-line-ui);
- font-weight: var(--ds-font-weight-medium);
- }
- /* Where to use: the caption of a form field: Label, FieldLabel. */
- @utility text-label {
- font-size: var(--ds-font-ui-size);
- line-height: var(--ds-line-ui-label);
- font-weight: var(--ds-font-weight-medium);
- }
- /* Where to use: a short muted caption above a field in a dense form: FieldLabel and FieldTitle with the muted variant. */
- @utility text-field-label {
- font-size: calc(var(--ds-font-ui-small-size) + 0.5px);
- line-height: var(--ds-line-ui-small);
- font-weight: var(--ds-font-weight-regular);
- color: var(--muted-foreground);
- }
- /* Where to use: metadata and notes: time, source, a hint under a field. */
- @utility text-caption {
- font-size: var(--ds-font-ui-small-size);
- line-height: var(--ds-line-ui-small);
- font-weight: var(--ds-font-weight-regular);
- color: var(--muted-foreground);
- }
- /* Where to use: the title of a list row in a card: a task, an entry for confirmation, a regular task. */
- @utility text-row-title {
- font-size: var(--ds-font-row-size);
- line-height: var(--ds-line-row);
- font-weight: var(--ds-font-weight-semibold);
- letter-spacing: var(--ds-letter-spacing-title);
- }
- /* Where to use: the text of a list row: a description under the title, a task example, a choice option. */
- @utility text-row {
- font-size: var(--ds-font-row-size);
- line-height: var(--ds-line-row);
- font-weight: var(--ds-font-weight-regular);
- }
- /* Where to use: a short badge and a choice of several: Badge, StatusBadge, the choice of a function under the request line. */
- @utility text-chip {
- font-size: var(--ds-font-chip-size);
- line-height: var(--ds-line-chip);
- font-weight: var(--ds-font-weight-medium);
- }
- /* Where to use: a side menu item: SidebarMenuButton. */
- @utility text-nav {
- font-size: var(--ds-font-nav-size);
- line-height: var(--ds-line-nav);
- font-weight: var(--ds-font-weight-book);
- }
- /* Where to use: the chosen item of the side menu: the same font size, denser (SidebarMenuButton). */
- @utility text-nav-strong {
- font-size: var(--ds-font-nav-size);
- line-height: var(--ds-line-nav);
- font-weight: var(--ds-font-weight-strong);
- }
- /* Where to use: the product name in the header of the side panel: AppShell. */
- @utility text-brand {
- font-size: var(--ds-font-brand-size);
- line-height: var(--ds-line-brand);
- font-weight: var(--ds-font-weight-semibold);
- letter-spacing: var(--ds-letter-spacing-brand);
- }
- /* Where to use: the user name in the footer of the side panel: AppShell. */
- @utility text-account {
- font-size: var(--ds-font-account-size);
- line-height: var(--ds-line-account);
- font-weight: var(--ds-font-weight-strong);
- }
- /* Where to use: the field of the request line: the main input of the screen. */
- @utility text-composer {
- font-size: var(--ds-font-composer-size);
- line-height: var(--ds-line-composer);
- font-weight: var(--ds-font-weight-regular);
- letter-spacing: var(--ds-letter-spacing-title);
- }
- /* Where to use: a caption above a value and a group heading in a menu. */
- @utility text-overline {
- font-family: var(--ds-overline-font);
- font-size: var(--ds-overline-size);
- line-height: var(--ds-line-ui-small);
- font-weight: var(--ds-font-weight-medium);
- letter-spacing: var(--ds-overline-tracking);
- text-transform: uppercase;
- color: var(--ds-text-tertiary);
- }
- /* Where to use: codes and numbers: a tax id, an article number, a purchase number. */
- @utility text-code {
- font-family: var(--ds-font-mono);
- font-size: var(--ds-font-code-size);
- line-height: var(--ds-line-code);
- font-weight: var(--ds-font-weight-regular);
- }
- /* Where to use: a table header: TableHead. */
- @utility text-table-head {
- font-family: var(--ds-database-header-font);
- font-size: var(--ds-database-header-size);
- line-height: var(--ds-line-ui-small);
- font-weight: var(--ds-database-header-weight);
- letter-spacing: var(--ds-database-header-tracking);
- text-transform: var(--ds-database-header-transform);
- color: var(--ds-database-header-ink);
- }
- /* Where to use: the assistant voice: a conclusion, a summary, an outcome. */
- @utility text-voice {
- font-family: var(--ds-font-serif);
- font-size: var(--ds-font-voice-size);
- line-height: var(--ds-line-voice);
- font-weight: var(--ds-font-weight-regular);
- letter-spacing: var(--ds-letter-spacing-title);
- }
- /* Where to use: a heading in the assistant voice on the screen: the story about the assistant at sign-in (from md:). */
- @utility text-voice-title {
- font-family: var(--ds-font-serif);
- font-size: var(--ds-font-page-title-size);
- line-height: var(--ds-line-page-title);
- font-weight: var(--ds-font-weight-regular);
- letter-spacing: var(--ds-letter-spacing-title);
- }
- /* Where to use: the same heading in the assistant voice in a narrow window. */
- @utility text-voice-heading {
- font-family: var(--ds-font-serif);
- font-size: var(--ds-font-heading-2-size);
- line-height: var(--ds-line-heading-2);
- font-weight: var(--ds-font-weight-regular);
- letter-spacing: var(--ds-letter-spacing-title);
- }