Typography

Typography tokens are composite tokens, meaning they are made up of multiple other tokens. This allows us to create a consistent typographic scale across our products.

Guidelines

  • Use the bounding box to align with the grid - The bounding box is the vertical height of the text and is defined by the line height. That value of the line height is critical to make sure text is aligned to the 8px grid of the interface.
  • Use text-crop when a font looks off-centered - Some fonts, such as ABC Favorit requires a little help to look centered. In those cases, apply a text-crop to adjust the line height. These values are available as tokens and are documented below. Hopper Components already make use of these values when necessary.
  • Align text using baseline - When aligning different text boxes together horizontally, use their baselines as a guide instead of their true center for a more harmonious look.
  • Line length should be between 40 to 60 characters - Lines of text that are too short make the eyes strain while long lines make it hard to concentrate. As a way to give users the best reading experience, aim for lines of text between 40 to 60 characters, including spaces. If your text doesn’t fit this rule, review the content length, font size or even information hierarchy.

Tokens

Heading

Headings are used to create a hierarchy of content. They are used to help users scan and understand the content on a page.

SizeValuesPreview
3xl
Font Size
hop-heading-3xl-font-size
2.25rem
Font Weight
hop-heading-3xl-font-weight
680
Line Height
hop-heading-3xl-line-height
1.3333333
Font Family
hop-heading-3xl-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-3xl-top-offset
-0.9375rem
Bottom Offset1
hop-heading-3xl-bottom-offset
-0.5625rem
Aa
2xl
Font Size
hop-heading-2xl-font-size
2rem
Font Weight
hop-heading-2xl-font-weight
580
Line Height
hop-heading-2xl-line-height
1.25
Font Family
hop-heading-2xl-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-2xl-top-offset
-0.6667rem
Bottom Offset1
hop-heading-2xl-bottom-offset
-0.3334rem
Aa
xl
Font Size
hop-heading-xl-font-size
1.75rem
Font Weight
hop-heading-xl-font-weight
680
Line Height
hop-heading-xl-line-height
1.1428571
Font Family
hop-heading-xl-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-xl-top-offset
-0.5rem
Bottom Offset1
hop-heading-xl-bottom-offset
-0.1875rem
Aa
lg
Font Size
hop-heading-lg-font-size
1.5rem
Font Weight
hop-heading-lg-font-weight
680
Line Height
hop-heading-lg-line-height
1.3333333
Font Family
hop-heading-lg-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-lg-top-offset
-0.5625rem
Bottom Offset1
hop-heading-lg-bottom-offset
-0.3125rem
Aa
md
Font Size
hop-heading-md-font-size
1.25rem
Font Weight
hop-heading-md-font-weight
580
Line Height
hop-heading-md-line-height
1.2
Font Family
hop-heading-md-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-md-top-offset
-0.3333rem
Bottom Offset1
hop-heading-md-bottom-offset
-0.125rem
Aa
sm
Font Size
hop-heading-sm-font-size
1.125rem
Font Weight
hop-heading-sm-font-weight
580
Line Height
hop-heading-sm-line-height
1.3333333
Font Family
hop-heading-sm-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-sm-top-offset
-0.375rem
Bottom Offset1
hop-heading-sm-bottom-offset
-0.1875rem
Aa
xs
Font Size
hop-heading-xs-font-size
1rem
Font Weight
hop-heading-xs-font-weight
410
Line Height
hop-heading-xs-line-height
1.5
Font Family
hop-heading-xs-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Top Offset1
hop-heading-xs-top-offset
-0.4166rem
Bottom Offset1
hop-heading-xs-bottom-offset
-0.25rem
Aa

Variations

NameValuePreview
--hop-heading-xs-medium-font-weight
580
Aa

Overline

Used to introduce a headline.

Adding a text-transform of uppercase is necessary in order to render overline as intended by the Design. A letter spacing of 0.24px is also necessary.

ValuesPreview
Font Size
hop-overline-font-size
0.75rem
Font Weight
hop-overline-font-weight
400
Line Height
hop-overline-line-height
1.3333333
Font Family
hop-overline-font-family
'ABC Favorit Mono', Consolas, 'SF Mono', monospace
Top Offset1
hop-overline-top-offset
-0.25rem
Bottom Offset1
hop-overline-bottom-offset
-0.25rem
Aa

Body

Body text is used to communicate the main content of a page.

SizeValuesPreview
2xl
Font Size
hop-body-2xl-font-size
2rem
Font Weight
hop-body-2xl-font-weight
410
Line Height
hop-body-2xl-line-height
1.125
Font Family
hop-body-2xl-font-family
'Inter', Helvetica, Arial, sans-serif
Aa
xl
Font Size
hop-body-xl-font-size
1.75rem
Font Weight
hop-body-xl-font-weight
410
Line Height
hop-body-xl-line-height
1.1428571
Font Family
hop-body-xl-font-family
'Inter', Helvetica, Arial, sans-serif
Aa
lg
Font Size
hop-body-lg-font-size
1.125rem
Font Weight
hop-body-lg-font-weight
410
Line Height
hop-body-lg-line-height
1.3333333
Font Family
hop-body-lg-font-family
'Inter', Helvetica, Arial, sans-serif
Aa
md
Font Size
hop-body-md-font-size
1rem
Font Weight
hop-body-md-font-weight
410
Line Height
hop-body-md-line-height
1.5
Font Family
hop-body-md-font-family
'Inter', Helvetica, Arial, sans-serif
Aa
sm
Font Size
hop-body-sm-font-size
0.875rem
Font Weight
hop-body-sm-font-weight
410
Line Height
hop-body-sm-line-height
1.4285714
Font Family
hop-body-sm-font-family
'Inter', Helvetica, Arial, sans-serif
Aa
xs
Font Size
hop-body-xs-font-size
0.75rem
Font Weight
hop-body-xs-font-weight
410
Line Height
hop-body-xs-line-height
1.3333333
Font Family
hop-body-xs-font-family
'Inter', Helvetica, Arial, sans-serif
Aa

Variations

NameValuePreview
--hop-body-lg-medium-font-weight
505
Aa
--hop-body-lg-semibold-font-weight
590
Aa
--hop-body-lg-bold-font-weight
690
Aa
--hop-body-md-medium-font-weight
505
Aa
--hop-body-md-semibold-font-weight
590
Aa
--hop-body-md-bold-font-weight
690
Aa
--hop-body-sm-medium-font-weight
505
Aa
--hop-body-sm-semibold-font-weight
590
Aa
--hop-body-sm-bold-font-weight
690
Aa
--hop-body-xs-medium-font-weight
505
Aa
--hop-body-xs-semibold-font-weight
590
Aa
--hop-body-xs-bold-font-weight
690
Aa

Accent

Accent text is used to highlight important information on a page.

SizeValuesPreview
lg
Font Size
hop-accent-lg-font-size
3rem
Font Weight
hop-accent-lg-font-weight
580
Line Height
hop-accent-lg-line-height
1.125
Font Family
hop-accent-lg-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Aa
sm
Font Size
hop-accent-sm-font-size
1.125rem
Font Weight
hop-accent-sm-font-weight
580
Line Height
hop-accent-sm-line-height
1.3333333
Font Family
hop-accent-sm-font-family
'ABC Favorit', Helvetica, Arial, sans-serif
Aa
  1. These values are meant to be used in tandem, they have been meticously crafted to trim unwanted blank space in the ABC Favorit typeface, and it's Mono variant. They have been generated using Eight Shape tool and adjusted to fit our needs. You can see how and when to use them in the text-crop section.