Last active
August 29, 2015 14:07
-
-
Save lewismcarey/613fa4c8c31bcd27fcc7 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h1>Font Face Zen</h1> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---- | |
// Sass (v3.4.4) | |
// Compass (v1.0.1) | |
// ---- | |
$fonts: | |
('AdelleSansRegular', 'adellesans-light', 'normal', '300' ), | |
('AdelleSansRegular', 'adellesans-regular', 'normal', '400' ), | |
('AdelleSansRegular', 'adellesans-semibold', 'normal', '700' ), | |
('AdelleSansRegular', 'adellesans-thin', 'normal', '100' ), | |
('AdelleSansRegular', 'adellesans-thinitalic', 'italic', '100'); | |
@each $family, $face, $style, $weight in $fonts { | |
@font-face { | |
font-family: #{$family}; | |
src: url('assets/css/fonts/#{$face}.eot'); | |
src: url('assets/css/fonts/#{$face}.eot?#iefix') format('embedded-opentype'), | |
url('assets/css/fonts/#{$face}.woff') format('woff'), | |
url('assets/css/fonts/#{$face}.ttf') format('truetype'); | |
font-weight: #{$weight}; | |
font-style: #{$style}; | |
/* Usage: @extend %#{$face}; */ | |
} | |
// Placeholder Class (see usage) | |
%#{$face} { | |
font-family: #{$family}; | |
font-weight: #{$weight}; | |
font-style: #{$style}; | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; | |
text-rendering: optimizelegibility; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@font-face { | |
font-family: AdelleSansRegular; | |
src: url("assets/css/fonts/adellesans-light.eot"); | |
src: url("assets/css/fonts/adellesans-light.eot?#iefix") format("embedded-opentype"), url("assets/css/fonts/adellesans-light.woff") format("woff"), url("assets/css/fonts/adellesans-light.ttf") format("truetype"); | |
font-weight: 300; | |
font-style: normal; | |
/* Usage: @extend %adellesans-light; */ | |
} | |
@font-face { | |
font-family: AdelleSansRegular; | |
src: url("assets/css/fonts/adellesans-regular.eot"); | |
src: url("assets/css/fonts/adellesans-regular.eot?#iefix") format("embedded-opentype"), url("assets/css/fonts/adellesans-regular.woff") format("woff"), url("assets/css/fonts/adellesans-regular.ttf") format("truetype"); | |
font-weight: 400; | |
font-style: normal; | |
/* Usage: @extend %adellesans-regular; */ | |
} | |
@font-face { | |
font-family: AdelleSansRegular; | |
src: url("assets/css/fonts/adellesans-semibold.eot"); | |
src: url("assets/css/fonts/adellesans-semibold.eot?#iefix") format("embedded-opentype"), url("assets/css/fonts/adellesans-semibold.woff") format("woff"), url("assets/css/fonts/adellesans-semibold.ttf") format("truetype"); | |
font-weight: 700; | |
font-style: normal; | |
/* Usage: @extend %adellesans-semibold; */ | |
} | |
@font-face { | |
font-family: AdelleSansRegular; | |
src: url("assets/css/fonts/adellesans-thin.eot"); | |
src: url("assets/css/fonts/adellesans-thin.eot?#iefix") format("embedded-opentype"), url("assets/css/fonts/adellesans-thin.woff") format("woff"), url("assets/css/fonts/adellesans-thin.ttf") format("truetype"); | |
font-weight: 100; | |
font-style: normal; | |
/* Usage: @extend %adellesans-thin; */ | |
} | |
@font-face { | |
font-family: AdelleSansRegular; | |
src: url("assets/css/fonts/adellesans-thinitalic.eot"); | |
src: url("assets/css/fonts/adellesans-thinitalic.eot?#iefix") format("embedded-opentype"), url("assets/css/fonts/adellesans-thinitalic.woff") format("woff"), url("assets/css/fonts/adellesans-thinitalic.ttf") format("truetype"); | |
font-weight: 100; | |
font-style: italic; | |
/* Usage: @extend %adellesans-thinitalic; */ | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h1>Font Face Zen</h1> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment