zepio/app/theme.js

40 lines
812 B
JavaScript
Raw Normal View History

2018-11-28 14:02:42 -08:00
// @flow
2018-11-28 17:54:08 -08:00
import React from 'react';
import theme from 'styled-theming';
2018-11-28 18:45:37 -08:00
import { ThemeProvider, createGlobalStyle } from 'styled-components';
// $FlowFixMe
import { normalize } from 'polished'; // eslint-disable-line
2018-11-28 14:02:42 -08:00
import { DARK } from './constants/themes';
2018-11-28 17:54:08 -08:00
const appTheme = {
2018-11-28 14:02:42 -08:00
mode: DARK,
fontFamily: 'Open Sans',
colors: {
primary: theme('mode', {
light: '#000',
dark: '#fff',
}),
secondary: theme('mode', {
light: '#fff',
dark: '#000',
}),
2018-11-28 14:02:42 -08:00
},
size: {
title: 18,
paragraph: 12,
},
};
2018-11-28 17:54:08 -08:00
/* eslint-disable react/prop-types */
// $FlowFixMe
export const DoczWrapper = ({ children }) => (
<ThemeProvider theme={appTheme}>
{children()}
</ThemeProvider>
);
2018-11-28 18:45:37 -08:00
export const GlobalStyle = createGlobalStyle`${normalize()}`;
export default appTheme;