diff options
Diffstat (limited to 'client')
-rw-r--r-- | client/src/sass/include/_fonts.scss | 61 |
1 files changed, 19 insertions, 42 deletions
diff --git a/client/src/sass/include/_fonts.scss b/client/src/sass/include/_fonts.scss index 46cd37971..dd1cbadb3 100644 --- a/client/src/sass/include/_fonts.scss +++ b/client/src/sass/include/_fonts.scss | |||
@@ -1,46 +1,23 @@ | |||
1 | $FontPathSourceSansPro: '~npm-font-source-sans-pro/fonts'; | 1 | $FontPathSourceSansPro: '~npm-font-source-sans-pro/fonts'; |
2 | $basePath: '#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro'; | ||
2 | 3 | ||
3 | @font-face { | 4 | @mixin fontface($name, $path, $weight: null, $style: null, $exts: woff2) { |
4 | font-family: 'Source Sans Pro'; | 5 | $src: null; |
5 | font-weight: 400; | 6 | @each $ext in $exts { |
6 | font-style: normal; | 7 | $src: append($src, url(quote($path + "." + $ext)) format(quote($ext)), comma); |
7 | font-stretch: normal; | 8 | } |
8 | font-display: swap; | 9 | @font-face { |
9 | src: url('#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro-Regular.ttf.woff2') format('woff2'), | 10 | font-family: quote($name); |
11 | font-weight: $weight; | ||
12 | font-style: $style; | ||
13 | font-stretch: normal; | ||
14 | font-display: swap; | ||
15 | src: $src; | ||
16 | } | ||
10 | } | 17 | } |
11 | 18 | ||
12 | @font-face { | 19 | @include fontface('Source Sans Pro', '#{$basePath}-Regular.ttf', 400, normal); |
13 | font-family: 'Source Sans Pro'; | 20 | @include fontface('Source Sans Pro', '#{$basePath}-It.ttf', 400, italic); |
14 | font-weight: 400; | 21 | @include fontface('Source Sans Pro', '#{$basePath}-Semibold.ttf', 600, normal); |
15 | font-style: italic; | 22 | @include fontface('Source Sans Pro', '#{$basePath}-SemiboldIt.ttf', 600, italic); |
16 | font-stretch: normal; | 23 | @include fontface('Source Sans Pro', '#{$basePath}-Bold.ttf', 700, normal); \ No newline at end of file |
17 | font-display: swap; | ||
18 | src: url('#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro-It.ttf.woff2') format('woff2'), | ||
19 | } | ||
20 | |||
21 | @font-face { | ||
22 | font-family: 'Source Sans Pro'; | ||
23 | font-weight: 600; | ||
24 | font-style: normal; | ||
25 | font-stretch: normal; | ||
26 | font-display: swap; | ||
27 | src: url('#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro-Semibold.ttf.woff2') format('woff2'), | ||
28 | } | ||
29 | |||
30 | @font-face { | ||
31 | font-family: 'Source Sans Pro'; | ||
32 | font-weight: 600; | ||
33 | font-style: italic; | ||
34 | font-stretch: normal; | ||
35 | font-display: swap; | ||
36 | src: url('#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro-SemiboldIt.ttf.woff2') format('woff2'), | ||
37 | } | ||
38 | |||
39 | @font-face { | ||
40 | font-family: 'Source Sans Pro'; | ||
41 | font-weight: 700; | ||
42 | font-style: normal; | ||
43 | font-stretch: normal; | ||
44 | font-display: swap; | ||
45 | src: url('#{$FontPathSourceSansPro}/WOFF2/TTF/SourceSansPro-Bold.ttf.woff2') format('woff2'), | ||
46 | } \ No newline at end of file | ||