You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
488 B
29 lines
488 B
6 years ago
|
import React from 'react'
|
||
|
import PropTypes from 'prop-types'
|
||
|
import { Text as BaseText } from 'rebass'
|
||
|
|
||
|
/**
|
||
|
* @render react
|
||
|
* @name Text
|
||
|
* @example
|
||
|
* <Text>Some text</Text>
|
||
|
*/
|
||
|
class Text extends React.PureComponent {
|
||
|
static displayName = 'Text'
|
||
|
|
||
|
static propTypes = {
|
||
|
children: PropTypes.node
|
||
|
}
|
||
|
|
||
|
render() {
|
||
|
const { children } = this.props
|
||
|
return (
|
||
|
<BaseText fontSize="m" {...this.props}>
|
||
|
{children}
|
||
|
</BaseText>
|
||
|
)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
export default Text
|