From 211c4e25974454c76fed27d271ee7d9906c88dcd Mon Sep 17 00:00:00 2001 From: Alex Windett Date: Mon, 20 Feb 2017 13:14:44 +0000 Subject: [PATCH] fixing style errors from updated constant names --- frontend/src/components/article/index.js | 3 +-- frontend/src/components/breadcrumb/index.js | 2 +- frontend/src/components/navigation/org.js | 6 +++--- ui/src/components/base/global.js | 4 ++-- ui/src/components/base/index.js | 10 +++++++--- ui/src/shared/composers/typography.js | 10 ++++++++-- 6 files changed, 22 insertions(+), 13 deletions(-) diff --git a/frontend/src/components/article/index.js b/frontend/src/components/article/index.js index 80e3b68a..5b5f7ca2 100644 --- a/frontend/src/components/article/index.js +++ b/frontend/src/components/article/index.js @@ -2,7 +2,7 @@ const Styled = require('styled-components'); const constants = require('@ui/shared/constants'); const { - colors, + // colors, breakpoints } = constants; @@ -12,7 +12,6 @@ const { // Main Contonent Wrapper Styles module.exports = styled.article` - background-color: ${colors.base.grey}; padding: 2rem; ${breakpoints.large` diff --git a/frontend/src/components/breadcrumb/index.js b/frontend/src/components/breadcrumb/index.js index 06e1315b..d0493bd4 100644 --- a/frontend/src/components/breadcrumb/index.js +++ b/frontend/src/components/breadcrumb/index.js @@ -29,7 +29,7 @@ const { // Main Contonent Wrapper Styles const StyledDiv = styled.div` - border-bottom: solid ${remcalc(1)} ${colors.base.greyDark}; + border-bottom: solid ${remcalc(1)} ${colors.base.grey}; padding: ${remcalc(30)} 0; margin-bottom: ${remcalc(21)}; `; diff --git a/frontend/src/components/navigation/org.js b/frontend/src/components/navigation/org.js index 5e0c169b..30ea213f 100644 --- a/frontend/src/components/navigation/org.js +++ b/frontend/src/components/navigation/org.js @@ -33,7 +33,7 @@ const { const StyledNav = styled.div` background-color: #f2f2f2; - border-bottom: ${remcalc(1)} solid ${colors.base.greyDark}; + border-bottom: ${remcalc(1)} solid ${colors.base.grey}; & ul { height: ${remcalc(60)}; @@ -46,12 +46,12 @@ const NavigationLinkContainer = styled.div` position: relative; padding: ${remcalc(11)} ${remcalc(12)} ${remcalc(12)}; color: ${colors.base.secondaryDark}; - border: ${remcalc(1)} solid ${colors.base.greyDark}; + border: ${remcalc(1)} solid ${colors.base.grey}; height: ${remcalc(24)}; background-color: #f2f2f2; &.active { - background-color: ${colors.base.grey}; + background-color: ${colors.base.background}; border-bottom: solid ${remcalc(1)} ${colors.base.grey}; } `; diff --git a/ui/src/components/base/global.js b/ui/src/components/base/global.js index 8c4ae6e1..b8923b5b 100644 --- a/ui/src/components/base/global.js +++ b/ui/src/components/base/global.js @@ -17,13 +17,13 @@ const fonts = [ style: 'normal' }, { - family: 'LibreFranklin', + family: 'LibreFranklin-Semi-Bold', filename: 'librefranklin-semibold-webfont', weight: '600', style: 'normal' }, { - family: 'LibreFranklin', + family: 'LibreFranklin-Bold', filename: 'librefranklin-bold-webfont', weight: '700', style: 'normal' diff --git a/ui/src/components/base/index.js b/ui/src/components/base/index.js index 102a11df..bc0408a6 100644 --- a/ui/src/components/base/index.js +++ b/ui/src/components/base/index.js @@ -1,4 +1,5 @@ const constants = require('../../shared/constants'); +const typography = require('../../shared/composers/typography'); const Styled = require('styled-components'); @@ -11,11 +12,14 @@ const { } = Styled; module.exports = styled.div` - font-family: 'LibreFranklin', sans-serif; font-size: 1rem; line-height: 1.5; - color: ${colors.fonts.regular}; - background-color: #FFFFFF; + background-color: ${colors.base.background}; + + ${typography.libreFranklin} + ${typography.bodyColor} + ${typography.regular} + `; module.exports.global = require('./global'); diff --git a/ui/src/shared/composers/typography.js b/ui/src/shared/composers/typography.js index e732e33d..aecba6cd 100644 --- a/ui/src/shared/composers/typography.js +++ b/ui/src/shared/composers/typography.js @@ -9,10 +9,16 @@ const { css } = Styled; -module.export = { - libreFranklin: css` +module.exports = { + libreFranklin: ` font-family: 'LibreFranklin', Helvetica, sans-serif; `, + libreFranklinSemiBold: ` + font-family: 'LibreFranklin-Semi-Bold', Helvetica, sans-serif; + `, + libreFranklinBold: ` + font-family: 'LibreFranklin-Bold', Helvetica, sans-serif; + `, bold: css` font-weight: 600; `,