From 9e52d5b623517cb754ce781fe44ff65d6974360b Mon Sep 17 00:00:00 2001 From: Karina Kwiatek Date: Wed, 26 Oct 2022 10:57:55 +0200 Subject: [PATCH] Use Lexend 300 as 400 --- app/javascript/styles/_variables.scss | 2 +- app/javascript/styles/application.scss | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/app/javascript/styles/_variables.scss b/app/javascript/styles/_variables.scss index 1f784d56..afc864c4 100644 --- a/app/javascript/styles/_variables.scss +++ b/app/javascript/styles/_variables.scss @@ -1,6 +1,6 @@ // Font settings $lexend-font-path: "~@fontsource/lexend/files"; -$lexend-weights: 400, 500, 600; +$lexend-weights: 500, 600; $fa-font-path: "~font-awesome/fonts"; $font-family-sans-serif: "Lexend", "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif; diff --git a/app/javascript/styles/application.scss b/app/javascript/styles/application.scss index 57944071..b5765b62 100644 --- a/app/javascript/styles/application.scss +++ b/app/javascript/styles/application.scss @@ -32,6 +32,19 @@ ); } +// Using Lexend Light (300) as Regular (400) as Regular is quite thick. +@each $subset, $unicodeRangeValues in Lexend.$unicodeMap { + @font-face { + font-family: Lexend; + font-style: normal; + font-display: swap; + font-weight: 400; + src: url("#{Lexend.$fontDir}/lexend-#{$subset}-300-normal.woff2") format("woff2"), + url("#{Lexend.$fontDir}/lexend-all-300-normal.woff") format("woff"); + unicode-range: $unicodeRangeValues; + } +} + /** OVERRIDES ----------------------------------------------