Typography

The Typography component provides a reusable pattern for typography in the interface.

Variant

In this case, variant is set to h1 and element parameter is left untouched. This results in a <p> element that looks like h5 element.

Variant h1

Element

When the parameter element is set and the variant element is not, the result is a p element that looks like a <h1> element.

Element h1

Heading Variants

Standard HTML heading levels from h1 to h6. These are semantic elements that define the document structure and hierarchy.

Variant: h1

Variant: h2

Variant: h3

Variant: h4

Variant: h5
Variant: h6

Display Variants

Large display text variants including headline, title, and subtitle. These are used for prominent text that needs visual emphasis.

Variant: headline
Variant: title
Variant: subtitle

Body Text Variants

Standard body text variants including body, paragraph (p), and bold. These are the primary text styles for content.

Variant: body. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit auctor dui, a efficitur ligula. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.

Variant: p. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit auctor dui, a efficitur ligula. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.

Variant: bold. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit auctor dui, a efficitur ligula. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.

Variant: lead. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec suscipit auctor dui, a efficitur ligula. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.

Small Text Variants

Smaller text variants including caption, byline, and meta. These are used for secondary information and annotations.

Variant: caption
Variant: meta

Specialized Variants

Specialized text variants for specific use cases such as marketing and email content.

Variant: marketing

API

Parameter Default Description
p What element the markup will use.
false Headings (h1, h2...) can only be set to other headings. If left empty it will default to the given element.
The content
false Upgrade element to h1 (from h3 and above), if seen first on page.
true If a heading should be based off of the context its in.

CSS API

Variable Default Type Values Description
var(--font-family-base) font - Controls the base typeface used by body, paragraph, lead, small text, and non-heading variants that inherit the base family.
var(--font-family-heading) font - Controls the typeface used by variants that explicitly switch to the heading family.
var(--font-weight-normal) select 100, 200, 300, 400, 500, 600 Controls the default font weight for variants that keep the base weight.
var(--font-weight-medium) select 400, 500, 600, 700 Controls the shared medium emphasis used by title and lead variants.
var(--font-weight-bold) select 600, 700, 800, 900 Controls the heavier emphasis used by bold and marketing variants.
var(--font-weight-heading) select 400, 500, 600, 700, 800, 900 Controls the default weight used by heading level variants h1 through h6.
var(--line-height-base) range - Controls the reading line height for variants that keep the base line height.
var(--line-height-heading) range - Controls the shared line height for heading-style variants.
var(--letter-spacing-base) range - Controls the default tracking for variants that inherit the base letter spacing.
var(--letter-spacing-heading) range - Controls the tracking for heading-style variants that use the heading spacing scale.
var(--space) range - Controls the vertical spacing inserted between adjacent heading-style variants.
var(--font-size-90) range - Controls caption, byline, and meta text sizes.
var(--font-size-200) range - Controls the shared size used by lead text and the smaller heading level h6.
var(--font-size-300) range - Controls the default size used by h5 headings.
var(--font-size-400) range - Controls the shared size used by subtitle and h4 variants.
var(--font-size-500) range - Controls the shared size used by title and h3 variants.
var(--font-size-600) range - Controls the shared size used by headline and h2 variants.
var(--font-size-700) range - Controls the default size used by h1 headings.
var(--font-size-800) range - Controls the default size used by the marketing variant.
1 range - Scales regular body and paragraph text locally without changing the shared type scale.
1 range - Scales the bold variant locally without changing other text styles.
1 range - Scales lead text locally without changing the shared lead token.
1 range - Scales caption text locally without changing the shared small-text token.
1 range - Scales byline text locally without changing the shared small-text token.
1 range - Scales meta text locally without changing the shared small-text token.
1 range - Scales email text locally without changing the shared body size.
1 range - Scales h1 locally for one placement without changing the global h1 scale.
1 range - Scales h2 locally for one placement without changing the global h2 scale.
1 range - Scales h3 locally for one placement without changing the global h3 scale.
1 range - Scales h4 locally for one placement without changing the global h4 scale.
1 range - Scales h5 locally for one placement without changing the global h5 scale.
1 range - Scales h6 locally for one placement without changing the global h6 scale.
1 range - Scales the headline variant locally without changing the shared display scale.
1 range - Scales the title variant locally without changing the shared display scale.
1 range - Scales the subtitle variant locally without changing the shared display scale.
1 range - Scales the marketing variant locally without changing the shared display scale.