lbry-desktop/ui/js/component/modal-page.js

22 lines
524 B
JavaScript
Raw Normal View History

2017-06-06 23:19:12 +02:00
import React from "react";
import ReactModal from "react-modal";
2017-04-01 08:51:15 +02:00
2017-05-17 10:10:25 +02:00
export class ModalPage extends React.Component {
render() {
2017-04-01 08:51:15 +02:00
return (
2017-06-06 23:19:12 +02:00
<ReactModal
onCloseRequested={this.props.onAborted || this.props.onConfirmed}
{...this.props}
className={(this.props.className || "") + " modal-page"}
overlayClassName="modal-overlay"
>
2017-04-01 08:51:15 +02:00
<div className="modal-page__content">
{this.props.children}
</div>
</ReactModal>
);
}
2017-05-17 10:10:25 +02:00
}
2017-05-19 18:17:19 +02:00
2017-06-06 06:21:55 +02:00
export default ModalPage;