Skip to content

Commit

Permalink
fix: better font support fix #27 (#35)
Browse files Browse the repository at this point in the history
* fix: better font support fix #27

* fix: add fonts

* fix: remove old font files
  • Loading branch information
maehr authored Feb 26, 2024
1 parent 557ad28 commit 69345e9
Show file tree
Hide file tree
Showing 14 changed files with 18 additions and 23 deletions.
5 changes: 3 additions & 2 deletions _data/theme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,9 @@ bootswatch: # leave blank or comment out for plain bootstrap
base-font-size: 1em
text-color: "#191919"
link-color: "#0d6efd"
base-font-family: "Euclid Circular B" # comment out for bootstrap defaults. e.g. Roboto
font-cdn: # add font stylesheet, e.g. <link href="https://fonts.googleapis.com/css?family=Roboto&display=swap" rel="stylesheet">
base-font-family: "'Euclid Circular B', sans-serif;" # comment out for bootstrap defaults. e.g. Roboto
font-cdn: "<link rel='preload' href='/assets/fonts/EuclidCircularB-Regular-WebS.woff2' as='font' type='font/woff2' crossorigin><link rel='preload' href='/assets/fonts/EuclidCircularB-Medium-WebS.woff2' as='font' type='font/woff2' crossorigin><link rel='preload' href='/assets/fonts/EuclidCircularB-Semibold-WebS.woff2' as='font' type='font/woff2' crossorigin>
" # add font stylesheet, e.g. <link href="https://fonts.googleapis.com/css?family=Roboto&display=swap" rel="stylesheet">

# THEME ICONS [optional!]
# default icons can be overridden or new icons can be added using "icons" object
Expand Down
36 changes: 15 additions & 21 deletions _sass/_custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,25 @@
*/

@font-face {
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Regular.woff2') format('woff2'),
url('/assets/fonts/EuclidCircularB-Regular.woff') format('woff'),
url('/assets/fonts/EuclidCircularB-Regular.otf') format('opentype');
font-style: normal;
font-weight: 400;
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Regular-WebS.woff2') format('woff2');
font-style: normal;
font-weight: 400;
}

@font-face {
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Medium.woff2') format('woff2'),
url('/assets/fonts/EuclidCircularB-Medium.woff') format('woff'),
url('/assets/fonts/EuclidCircularB-Medium.otf') format('opentype');
font-style: normal;
font-weight: 500;
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Medium-WebS.woff2') format('woff2');
font-style: normal;
font-weight: 500;
}

@font-face {
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Semibold.woff2') format('woff2'),
url('/assets/fonts/EuclidCircularB-Semibold.woff') format('woff'),
url('/assets/fonts/EuclidCircularB-Semibold.otf') format('opentype');
font-style: normal;
font-weight: 600;
font-display: swap;
font-family: 'Euclid Circular B';
src: url('/assets/fonts/EuclidCircularB-Semibold-WebS.woff2') format('woff2');
font-style: normal;
font-weight: 600;
}
Binary file added assets/fonts/EuclidCircularB-Medium-WebS.woff2
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Medium.otf
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Medium.woff
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Medium.woff2
Binary file not shown.
Binary file added assets/fonts/EuclidCircularB-Regular-WebS.woff2
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Regular.otf
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Regular.woff
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Regular.woff2
Binary file not shown.
Binary file added assets/fonts/EuclidCircularB-Semibold-WebS.woff2
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Semibold.otf
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Semibold.woff
Binary file not shown.
Binary file removed assets/fonts/EuclidCircularB-Semibold.woff2
Binary file not shown.

0 comments on commit 69345e9

Please sign in to comment.