UNPKG

517 BJavaScriptView Raw
1import React, { Component } from 'react'
2import PropTypes from 'prop-types'
3import { ThemeProvider } from 'styled-components'
4import theme from './theme'
5
6export default class ROATheme extends Component {
7 render () {
8 return (
9 <ThemeProvider theme={theme} {...this.props}>
10 {this.props.children}
11 </ThemeProvider>
12 )
13 }
14}
15
16ROATheme.propTypes = {
17 children: PropTypes.oneOfType([
18 PropTypes.array,
19 PropTypes.object,
20 PropTypes.string
21 ]).isRequired
22}
23
24export { theme, ROATheme }