UNPKG

apeman-react-jumbotron

Version:
41 lines (33 loc) 843 B
/** * Text of jumbotron * @class ApJumbotronText */ 'use strict' import React, {Component, PropTypes as types} from 'react' import classnames from 'classnames' import {shallowEqual} from 'asobj' /** @lends ApJumbotronText */ class ApJumbotronText extends Component { render () { const s = this let { props } = s return ( <p className={ classnames('ap-jumbotron-text', props.className) } style={ Object.assign({}, props.style) }> { props.children } </p> ) } shouldComponentUpdate (nextProps, nextState) { const s = this let { props, state } = s return !shallowEqual(props, nextProps) || !shallowEqual(state, nextState) } } Object.assign(ApJumbotronText, { // -------------------- // Specs // -------------------- propTypes: {} }) export default ApJumbotronText