Skip to content

Instantly share code, notes, and snippets.

@stevetrask
Created November 27, 2017 12:56
Show Gist options
  • Save stevetrask/a5c6595f9e8d14cebfa707a56a9e64d1 to your computer and use it in GitHub Desktop.
Save stevetrask/a5c6595f9e8d14cebfa707a56a9e64d1 to your computer and use it in GitHub Desktop.
@mixin font-face($family, $filename, $font-weight: normal, $font-style: normal) {
@font-face {
font-family: "#{$family}";
src: url("/wp-content/themes/starkers/fonts/bookmania/#{$filename}.eot?#iefix") format("embedded-opentype"), url("/wp-content/themes/officialwatches/fonts/starkers/#{$filename}.woff") format("woff"), url("/wp-content/themes/starkers/fonts/#{$filename}.ttf") format("truetype");
font-weight: $font-weight;
font-style: $font-style;
}
}
@include font-face("bookmania", "bookmania-light", $font-weight: 100);
@include font-face("bookmania", "bookmania-regular");
@include font-face("bookmania", "bookmania-regular-italic", $font-style: italic);
@include font-face("bookmania", "bookmania-semibold", $font-weight: bold);
@include font-face("bookmania", "bookmania-semibold-italic", $font-weight: bold, $font-style: italic);
@include font-face("bookmania", "bookmania-bold", $font-weight: 900);
@include font-face("bookmania", "bookmania-bold-italic", $font-style: italic, $font-weight: 900);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment