Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Move @font-face declarations from vars to type
  • Loading branch information
tobiasahlin committed Mar 9, 2021
commit 13c49b6c524a77f21cd51c053c42115e213ce39c
25 changes: 0 additions & 25 deletions src/marketing/support/variables.scss
Original file line number Diff line number Diff line change
@@ -1,30 +1,5 @@
$marketing-font-path: "/fonts/" !default;

// Type
@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-normal;
src: local("Inter"), local("Inter-Regular"), url("#{$marketing-font-path}Inter-Regular.woff") format("woff");
font-display: swap;
}

@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-semibold;
src: local("Inter Medium"), local("Inter-Medium"), url("#{$marketing-font-path}Inter-Medium.woff") format("woff");
font-display: swap;
}

@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-bold;
src: local("Inter Bold"), local("Inter-Bold"), url("#{$marketing-font-path}Inter-Bold.woff") format("woff");
font-display: swap;
}

$font-mktg: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol" !default;

// Builds upon @primer/css/support/variables/typography.scss
Expand Down
26 changes: 25 additions & 1 deletion src/marketing/type/typography.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
// Headings
// Type
@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-normal;
src: local("Inter"), local("Inter-Regular"), url("#{$marketing-font-path}Inter-Regular.woff") format("woff");
font-display: swap;
}

@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-semibold;
src: local("Inter Medium"), local("Inter-Medium"), url("#{$marketing-font-path}Inter-Medium.woff") format("woff");
font-display: swap;
}

@font-face {
font-family: Inter;
font-style: normal;
font-weight: $font-weight-bold;
src: local("Inter Bold"), local("Inter-Bold"), url("#{$marketing-font-path}Inter-Bold.woff") format("woff");
font-display: swap;
}

// Headings
.h000-mktg,
.h00-mktg,
.h0-mktg,
Expand Down