frontend/src/components/Transfer/index.tsx

53 lines
1.4 KiB
TypeScript
Raw Normal View History

2020-06-01 16:26:58 +02:00
import React from "react";
import Modal from "@material-ui/core/Modal";
import "./index.scss";
interface TransferProps {
2020-06-03 15:43:11 +02:00
handleClose: (e: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
2020-06-01 16:26:58 +02:00
isOpen: boolean;
}
2020-06-03 15:43:11 +02:00
interface TransferState {}
2020-06-01 16:26:58 +02:00
export default class Transfer extends React.Component<
TransferProps,
TransferState
> {
constructor(props: TransferProps) {
super(props);
this.handleClose = this.handleClose.bind(this);
}
handleClose(e: React.MouseEvent<HTMLButtonElement, MouseEvent>) {
2020-06-03 15:43:11 +02:00
this.props.handleClose(e);
2020-06-01 16:26:58 +02:00
}
render() {
return (
<div>
<Modal
2020-06-03 15:43:11 +02:00
className="wrapper"
open={this.props.isOpen}
2020-06-01 16:26:58 +02:00
onClose={this.handleClose}
aria-labelledby="simple-modal-title"
aria-describedby="simple-modal-description"
>
2020-06-03 15:43:11 +02:00
<div className="transfer">
2020-06-09 16:27:32 +02:00
<div className="transfer__give">
<div className="transfer__text">Oddam</div>
<input className="transfer__input"></input>
</div>
<div className="transfer__receive">
<div className="transfer__text">Przyjmę</div>
<input className="transfer__input"></input>
</div>
<div className="transfer__proposition"></div>
<button className="transfer__add">chuj</button>
2020-06-03 15:43:11 +02:00
</div>
2020-06-01 16:26:58 +02:00
</Modal>
</div>
);
}
}