From a127077bde7739a38f3bb2d4d59790c150bb8886 Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Wed, 9 Jan 2019 15:28:50 -0600 Subject: [PATCH] Lift font SCSS partials to theme root This means that themes which include `light/css/_base.scss` (currently Dark and Status) won't be forced to have Light's font-faces included. This only really matters for Status, which uses different fonts throughout. --- res/themes/status/css/_fonts.scss | 15 +++++++++++++++ res/themes/status/css/_status.scss | 16 ---------------- res/themes/status/css/status.scss | 1 + 3 files changed, 16 insertions(+), 16 deletions(-) create mode 100644 res/themes/status/css/_fonts.scss diff --git a/res/themes/status/css/_fonts.scss b/res/themes/status/css/_fonts.scss new file mode 100644 index 00000000..e53b4638 --- /dev/null +++ b/res/themes/status/css/_fonts.scss @@ -0,0 +1,15 @@ +@font-face { + font-family:PostGrotesk-Medium; + src:url('https://status.im/fonts/PostGrotesk-Medium.eot'); + src:url('https://status.im/fonts/PostGrotesk-Medium.eot?#iefix') format("embedded-opentype"),url('https://status.im/fonts/PostGrotesk-Medium.woff') format("woff"),url('https://status.im/fonts/PostGrotesk-Medium.svg#PostGrotesk-Medium') format("svg"); + font-weight: 400; + font-style: normal; +} + +@font-face { + font-family:PostGrotesk-Book; + src:url('https://status.im/fonts/PostGrotesk-Book.eot'); + src:url('https://status.im/fonts/PostGrotesk-Book.eot?#iefix') format("embedded-opentype"),url('https://status.im/fonts/PostGrotesk-Book.woff') format("woff"),url('https://status.im/fonts/PostGrotesk-Book.svg#PostGrotesk-Book') format("svg"); + font-weight: 400; + font-style: normal; +} diff --git a/res/themes/status/css/_status.scss b/res/themes/status/css/_status.scss index 0b935248..afca5ac0 100644 --- a/res/themes/status/css/_status.scss +++ b/res/themes/status/css/_status.scss @@ -1,19 +1,3 @@ -@font-face { - font-family:PostGrotesk-Medium; - src:url('https://status.im/fonts/PostGrotesk-Medium.eot'); - src:url('https://status.im/fonts/PostGrotesk-Medium.eot?#iefix') format("embedded-opentype"),url('https://status.im/fonts/PostGrotesk-Medium.woff') format("woff"),url('https://status.im/fonts/PostGrotesk-Medium.svg#PostGrotesk-Medium') format("svg"); - font-weight: 400; - font-style: normal; -} - -@font-face { - font-family:PostGrotesk-Book; - src:url('https://status.im/fonts/PostGrotesk-Book.eot'); - src:url('https://status.im/fonts/PostGrotesk-Book.eot?#iefix') format("embedded-opentype"),url('https://status.im/fonts/PostGrotesk-Book.woff') format("woff"),url('https://status.im/fonts/PostGrotesk-Book.svg#PostGrotesk-Book') format("svg"); - font-weight: 400; - font-style: normal; -} - // We deliberately prioritise Arial over Helvetica here due to diacritic problems (see _base.scss) // N.B. that the status.im website uses: // font-family:PostGrotesk-Book,-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif; diff --git a/res/themes/status/css/status.scss b/res/themes/status/css/status.scss index b4f65900..52113fe8 100644 --- a/res/themes/status/css/status.scss +++ b/res/themes/status/css/status.scss @@ -1,3 +1,4 @@ +@import "_fonts.scss"; @import "../../../../node_modules/matrix-react-sdk/res/themes/light/css/_base.scss"; @import "_status.scss"; @import "../../../../node_modules/matrix-react-sdk/res/css/_components.scss";