Skip to content

Commit

Permalink
Change default logo font to reduce number of unique fonts, improve pe…
Browse files Browse the repository at this point in the history
…rformance

Most stores will update a logo image, so having a unique font just for the text logo is a waste of performance in the browser.

Changing logo font to one of the existing fonts to reduce download and lookups of fonts.
  • Loading branch information
bookernath committed Nov 20, 2018
1 parent e2cbbe4 commit e1e457e
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -2,6 +2,7 @@

## Draft
- Remove unnecessary API call to get cookie notification status [#1380](https://github.com/bigcommerce/cornerstone/pull/1380)
- Remove extra font only used for textual store logo. [#1375](https://github.com/bigcommerce/cornerstone/pull/1375)

## 2.6.0 (2018-11-05)
- Add support for Card Management: List, Delete, Edit, Add and Default Payment Method [#1376](https://github.com/bigcommerce/cornerstone/pull/1376)
Expand Down
5 changes: 2 additions & 3 deletions assets/scss/layouts/header/_header.scss
Expand Up @@ -120,7 +120,7 @@
font-family: $fontFamily-hero;
font-size: $fontSize-logo-small; // 1
font-weight: stencilFontWeight("logo-font");
letter-spacing: remCalc(5px);
letter-spacing: remCalc(2px);
margin-left: auto;
margin-right: auto;
overflow: hidden;
Expand All @@ -131,7 +131,6 @@

@include breakpoint("small") {
font-size: $fontSize-logo-medium;
letter-spacing: remCalc(9px);
padding-bottom: 0;
padding-top: 0;
}
Expand All @@ -140,7 +139,7 @@
display: inline;
font-size: $fontSize-logo-large;
margin-left: 0;
margin-right: -(remCalc(9px)); // 3
margin-right: -(remCalc(2px)); // 3
max-width: none;
overflow: auto;
white-space: normal;
Expand Down
2 changes: 1 addition & 1 deletion config.json
Expand Up @@ -78,7 +78,7 @@
"logo-position": "center",
"logo_size": "250x100",
"logo_fontSize": 28,
"logo-font": "Google_Oswald_300",
"logo-font": "Google_Montserrat_400",
"brand_size": "190x250",
"gallery_size": "300x300",
"productgallery_size": "500x659",
Expand Down
10 changes: 10 additions & 0 deletions schema.json
Expand Up @@ -514,6 +514,16 @@
"label": "Logo font family",
"id": "logo-font",
"options": [
{
"group": "Montserrat",
"label": "Montserrat",
"value": "Google_Montserrat_400"
},
{
"group": "Roboto",
"label": "Roboto",
"value": "Google_Roboto_400"
},
{
"group": "Oswald",
"label": "Oswald",
Expand Down

0 comments on commit e1e457e

Please sign in to comment.