colouring-montreal/app/src/frontend/info-box.js

24 lines
706 B
JavaScript
Raw Normal View History

2018-09-13 15:41:42 -04:00
import React, { Fragment } from 'react';
const InfoBox = (props) => (
<Fragment>
{
(props.msg || props.children)?
2019-05-27 11:39:16 -04:00
(
<div className="alert alert-info" role="alert">
{
(typeof props.msg === 'string' || props.msg instanceof String)?
props.msg
: 'Enjoy the colouring! Usual service should resume shortly.'
}
{
props.children
}
</div>
) : null
2018-09-13 15:41:42 -04:00
}
</Fragment>
);
export default InfoBox;