This repository has been archived on 2022-09-16. You can view files and clone it, but cannot push or open issues/pull-requests.
tlaternet-templates/src/lib/scss/_fonts.scss

47 lines
1.2 KiB
SCSS
Raw Normal View History

2022-07-30 17:51:04 +01:00
@use "~/node_modules/@fontsource/nunito/scss/mixins" as Nunito;
@use "~/node_modules/@fontsource/arimo/scss/mixins" as Arimo;
2022-06-21 12:16:33 +01:00
$weights: 300, 400, 500, 600, 700;
2018-04-07 18:04:46 +01:00
2022-06-21 12:16:33 +01:00
@each $weight in $weights {
@include Nunito.fontFace(
$weight: $weight,
$display: auto,
$style: normal,
2022-06-24 10:48:36 +01:00
$fontDir: "npm:@fontsource/nunito/files"
2022-06-21 12:16:33 +01:00
);
@include Nunito.fontFace(
$weight: $weight,
$display: auto,
$style: italic,
2022-06-24 10:48:36 +01:00
$fontDir: "npm:@fontsource/nunito/files"
2022-06-21 12:16:33 +01:00
);
2018-04-07 18:04:46 +01:00
}
2022-06-21 12:16:33 +01:00
@include Arimo.fontFace(
$weight: 400,
$display: auto,
$style: normal,
2022-06-24 10:48:36 +01:00
$fontDir: "npm:@fontsource/arimo/files"
2022-06-21 21:57:42 +01:00
);
// Hack *does* come with its own CSS, but it's broken and hasn't seen
// a release since https://github.com/source-foundry/Hack/issues/467
// was resolved.
2022-08-01 21:43:50 +01:00
$variants: regular 400 normal, bold 700 normal, italic 400 italic,
2022-06-21 21:57:42 +01:00
bolditalic 700 italic;
@each $name, $weight, $style in $variants {
@font-face {
font-family: "Hack";
2022-08-01 21:43:50 +01:00
src: url("npm:hack-font/build/web/fonts/hack-#{$name}-subset.woff2?sha=3114f1256")
format("woff2"),
url("npm:hack-font/build/web/fonts/hack-#{$name}-subset.woff?sha=3114f1256")
format("woff");
2022-06-21 21:57:42 +01:00
font-weight: $weight;
font-style: $style;
}
}