Borders > Typography
Borders offer really complex typography options in a relatively simple way. You start out with two main fonts that you can choose and set, one for headings & one for body, however, you can mix these fonts and play with their sizes in almost any section.
Main typography
As written above, you can choose two different font families that will be used in your store, one for headings, one for body. You can choose fonts from Shopify's curated font lists and set a generic base size, line height & letter spacing. Our theme features responsive fonts, meaning that you don't set a fixed value for your fonts, but a base size from which the theme will make certain calculations in order to reduce font sizes as the screen becomes smaller.
Section headings
The next panel related to typography is the section headings one, which controls the style for all of your section's heading. This is a really important area, because it is the one which appears most on your store. You can choose what font you want to utilise for this area, the text size, line height (again, based on your base line height), the font style (bold or italic).
You can also change the padding and choose to show slider navigation elements inside the heading area.
One note on slider navigation elements - if the option is checked, even if your section doesn't have a title, the navigation will appear at the top of the section. And don't forget that on mobile devices it will appear at the bottom of the section, no matter what you choose here.
Page titles
Also really important, you can choose how page titles appear through the store. This refers to the main title of all pages (collection, blog, article, customer, etc.) except the product page. The product page has it's own settings to set the typography of the title.
Buttons & forms
Slightly related to typography, you can choose how your buttons & forms will look like, by editing the corder radius of these elements, choosing a custom border size for buttons (forms are limited to 1px) and also make all text inside buttons uppercase.
Typography inside sections
You might notice that in some sections you have more or less the same amount of options in order to tweak your typography to a desired level.
This allows you to further use different text styles in different areas of your store.
Adding your own font
1. Use the @font-face declaration (add your own font files)
{%- liquid assign headings_font = settings.headings_font assign body_font = settings.body_font -%} {%- unless headings_font.system? -%} <link rel="preload" href="{{ headings_font | font_url }}" as="font" type="font/woff2" crossorigin> {%- endunless -%} {%- unless body_font.system? -%} <link rel="preload" href="{{ body_font | font_url }}" as="font" type="font/woff2" crossorigin> {%- endunless -%}
{%- liquid echo headings_font | font_face: font_display: 'swap' assign headings_font_bold = headings_font | font_modify: 'weight', '+200' if headings_font_bold == blank assign headings_font_bold = headings_font | font_modify: 'weight', '700' endif echo headings_font_bold | font_face: font_display: 'swap' if settings.section_title_italic assign headings_font_italic = headings_font | font_modify: 'style', 'italic' echo headings_font_italic | font_face: font_display: 'swap' endif echo body_font | font_face: font_display: 'swap' assign body_font_bold = body_font | font_modify: 'weight', '+200' if body_font_bold == blank assign body_font_bold = body_font | font_modify: 'weight', '700' endif echo body_font_bold | font_face: font_display: 'swap' -%}
@font-face { font-family: "MyFont"; src: url('Your_font_link_URL') format("woff2"); }
Replace the font family names and url's with valid names and valid url's of the fonts you've uploaded.
Now that your font is ready to be loaded, you need to modify the font variables. Go down again, and search for the code snippet below.
/* Font variables */ --font-stack-headings: {{ headings_font.family }}, {{ headings_font.fallback_families }}; --font-weight-headings: {{ headings_font.weight }}; {%- if headings_font_bold -%} --font-weight-headings-bold: {{ headings_font_bold.weight }}; {%- else -%} --font-weight-headings-bold: 700; {%- endif -%} --font-style-headings: {{ headings_font.style }}; --font-stack-body: {{ body_font.family }}, {{ body_font.fallback_families }}; --font-weight-body: {{ body_font.weight }}; {%- if body_font_bold -%} --font-weight-body-bold: {{ body_font_bold.weight }}; {%- else -%} --font-weight-body-bold: 700; {%- endif -%} --font-style-body: {{ body_font.style }};
--font-stack-headings: "MyFont", sans-serif; --font-weight-headings: 400; --font-weight-headings-bold: 700; --font-style-headings: normal; --font-stack-body: "MyFont", sans-serif; --font-weight-body: 400; --font-weight-body-bold: 700; --font-style-body: normal;
2. Use Google FontsCopy link
<link href="https://fonts.googleapis.com/css?family=Poiret+One" rel="stylesheet">