lbry-desktop/ui/js/component/notice.js
Alex Liebowitz 3749e0393a Reward: add error handling
Also adds Notice component
2017-04-17 09:46:51 -04:00

25 lines
No EOL
621 B
JavaScript

import React from 'react';
import lbry from '../lbry.js';
import {Link} from '../component/link.js';
import {FileActions} from '../component/file-actions.js';
import {Thumbnail, TruncatedText, CreditAmount} from '../component/common.js';
export const Notice = React.createClass({
propTypes: {
isError: React.PropTypes.bool,
},
getDefaultProps: function() {
return {
isError: false,
};
},
render: function() {
return (
<section className={'notice' + (this.props.isError ? ' notice--error' : '')}>
{this.props.children}
</section>
);
},
});
export default Notice;