UNPKG

apeman-react-toast

Version:
56 lines (43 loc) 942 B
/** * Warn toast. * @constructor ApWarnToast */ "use strict"; import React, {PropTypes as types} from 'react'; import classnames from 'classnames'; import ApToast from './ap_toast'; /** @lends ApWarnToast */ let ApWarnToast = React.createClass({ //-------------------- // Specs //-------------------- propTypes: { message: types.string, duration: types.number, icon: types.string }, mixins: [], statics: {}, getInitialState() { return { items: '' }; }, getDefaultProps() { return { message: null, duration: 2000, icon: 'fa fa-warning' }; }, render() { let s = this, state = s.state, props = s.props; return ( <ApToast className="ap-warn-toast" {...props}/> ) } }); module.exports = ApWarnToast;