soapbox/app/styles/fonts.scss

171 wiersze
6.1 KiB
SCSS
Czysty Zwykły widok Historia

2020-06-10 01:17:37 +00:00
// Roboto Regular
2020-03-27 20:59:38 +00:00
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 400;
font-style: normal;
src: url('../fonts/roboto/roboto-regular-400.eot?#iefix');
src: url('../fonts/roboto/roboto-regular-400.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-regular-400.woff2') format('woff2'),
url('../fonts/roboto/roboto-regular-400.woff') format('woff'),
url('../fonts/roboto/roboto-regular-400.ttf') format('truetype'),
url('../fonts/roboto/roboto-regular-400.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Roboto Regular Italic
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 400;
font-style: italic;
src: url('../fonts/roboto/roboto-regular-italic-400.eot?#iefix');
src: url('../fonts/roboto/roboto-regular-italic-400.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-regular-italic-400.woff2') format('woff2'),
url('../fonts/roboto/roboto-regular-italic-400.woff') format('woff'),
url('../fonts/roboto/roboto-regular-italic-400.ttf') format('truetype'),
url('../fonts/roboto/roboto-regular-italic-400.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Roboto Light
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 300;
font-style: normal;
src: url('../fonts/roboto/roboto-light-300.eot?#iefix');
src: url('../fonts/roboto/roboto-light-300.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-light-300.woff2') format('woff2'),
url('../fonts/roboto/roboto-light-300.woff') format('woff'),
url('../fonts/roboto/roboto-light-300.ttf') format('truetype'),
url('../fonts/roboto/roboto-light-300.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Roboto Light Italic
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 300;
font-style: italic;
src: url('../fonts/roboto/roboto-light-italic-300.eot?#iefix');
src: url('../fonts/roboto/roboto-light-italic-300.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-light-italic-300.woff2') format('woff2'),
url('../fonts/roboto/roboto-light-italic-300.woff') format('woff'),
url('../fonts/roboto/roboto-light-italic-300.ttf') format('truetype'),
url('../fonts/roboto/roboto-light-italic-300.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Roboto Bold
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 700;
font-style: normal;
src: url('../fonts/roboto/roboto-bold-700.eot?#iefix');
src: url('../fonts/roboto/roboto-bold-700.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-bold-700.woff2') format('woff2'),
url('../fonts/roboto/roboto-bold-700.woff') format('woff'),
url('../fonts/roboto/roboto-bold-700.ttf') format('truetype'),
url('../fonts/roboto/roboto-bold-700.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Roboto Bold Italic
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Roboto';
font-weight: 700;
font-style: italic;
src: url('../fonts/roboto/roboto-bold-italic-700.eot?#iefix');
src: url('../fonts/roboto/roboto-bold-italic-700.eot?#iefix') format('embedded-opentype'),
url('../fonts/roboto/roboto-bold-italic-700.woff2') format('woff2'),
url('../fonts/roboto/roboto-bold-italic-700.woff') format('woff'),
url('../fonts/roboto/roboto-bold-italic-700.ttf') format('truetype'),
url('../fonts/roboto/roboto-bold-italic-700.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// Montserrat Extra Bold
// Used for all bold number, scoreboard, count displays
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'Montserrat';
font-weight: 800;
font-style: normal;
src: url('../fonts/montserrat/montserrat-extra-bold-800.eot?#iefix');
src: url('../fonts/montserrat/montserrat-extra-bold-800.eot?#iefix') format('embedded-opentype'),
url('../fonts/montserrat/montserrat-extra-bold-800.woff2') format('woff2'),
url('../fonts/montserrat/montserrat-extra-bold-800.woff') format('woff'),
url('../fonts/montserrat/montserrat-extra-bold-800.ttf') format('truetype'),
url('../fonts/montserrat/montserrat-extra-bold-800.svg') format('svg');
}
2020-03-27 20:59:38 +00:00
// OpenDyslexic
@font-face {
font-family: 'OpenDyslexic';
src: url('../fonts/OpenDyslexic/OpenDyslexic-Regular.woff2') format('woff2');
}
@font-face {
font-family: 'OpenDyslexic';
2020-04-11 19:52:41 +00:00
font-weight: bold;
src: url('../fonts/OpenDyslexic/OpenDyslexic-Bold.woff2') format('woff2');
2020-03-27 20:59:38 +00:00
}
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'OpenDyslexic';
font-weight: bold;
font-style: italic;
src: url('../fonts/OpenDyslexic/OpenDyslexic-Bold-Italic.woff2') format('woff2');
2020-03-27 20:59:38 +00:00
}
@font-face {
2020-04-11 19:52:41 +00:00
font-family: 'OpenDyslexic';
font-style: italic;
src: url('../fonts/OpenDyslexic/OpenDyslexic-Italic.woff2') format('woff2');
2020-03-27 20:59:38 +00:00
}
// TYPEOGRAPHY MIXINS
// declare the font family using these shortcuts
2020-05-29 00:58:37 +00:00
@mixin font-roboto {font-family: 'Roboto', Arial, sans-serif !important;}
@mixin font-montserrat {font-family: 'Montserrat', Arial, sans-serif !important;}
2020-03-27 20:59:38 +00:00
// Declare font weights as a numerical value in rendered output
// Prevents certain browsers which do not play nice with "light, medium" textual declarations
// Numeical values always work more consistently across browsers
// Each font-weight is linked with the @font-face declaration to the actual font file
@mixin font-weight($weight) {
2020-04-11 19:52:41 +00:00
@if $weight == 'light' {font-weight: 300;}
@if $weight == 'normal' {font-weight: 400;}
@if $weight == 'medium' {font-weight: 500;}
@if $weight == 'bold' {font-weight: 700;}
@if $weight == 'extrabold' {font-weight: 800;}
}
2020-03-27 20:59:38 +00:00
// Use these mixins to define font-size and line-height
// html and body declaration allows developer to pass px value as argument
// Rendered css will default to "rem" and fall back to "px" for unsupported browsers
@mixin font-size($size) {
2020-04-11 19:52:41 +00:00
$rem: ($size / 10);
$px: $size;
font-size: #{$px + "px"};
font-size: #{$rem + "rem"};
}
2020-03-27 20:59:38 +00:00
@mixin line-height($size) {
2020-04-11 19:52:41 +00:00
$rem: ($size / 10);
$px: $size;
line-height: #{$px + "px"};
line-height: #{$rem + "rem"};
}
2020-03-27 20:59:38 +00:00
2020-06-10 01:14:18 +00:00
// Soapbox icon font
2020-03-27 20:59:38 +00:00
@font-face {
2020-06-10 01:14:18 +00:00
font-family: 'soapbox';
src: url('../fonts/soapbox/soapbox.eot?pryg6i');
src: url('../fonts/soapbox/soapbox.eot?pryg6i#iefix') format('embedded-opentype'),
url('../fonts/soapbox/soapbox.ttf?pryg6i') format('truetype'),
url('../fonts/soapbox/soapbox.woff?pryg6i') format('woff'),
url('../fonts/soapbox/soapbox.svg?pryg6i#soapbox') format('svg');
2020-03-27 20:59:38 +00:00
font-weight: normal;
font-style: normal;
}
2020-05-29 00:58:37 +00:00
.fa-users::before {
font-family: 'ForkAwesome';
2020-04-11 19:52:41 +00:00
content: '\f0c0';
2020-03-27 20:59:38 +00:00
}
2020-05-29 00:58:37 +00:00
.fa-fediverse::before {
2020-06-10 01:14:18 +00:00
font-family: 'soapbox' !important;
2020-03-27 20:59:38 +00:00
content: "\e901";
}