frontend/src/App.tsx

39 lines
805 B
TypeScript
Raw Normal View History

2020-06-03 15:43:11 +02:00
import React, { useState } from "react";
import TopBar from "./components/TopBar/";
import Transfer from "./components/Transfer/";
2020-05-24 18:32:11 +02:00
import "./App.scss";
function App() {
2020-06-03 15:43:11 +02:00
const [isOpen, setOpen] = useState(false);
const [text, setText] = useState("");
return (
<div className="App">
<TopBar
textChangeHandler={(e) => {
setText(e.target.value);
}}
2020-06-03 18:15:51 +02:00
handleTransfer={(e) => {
2020-06-03 15:43:11 +02:00
setOpen(!isOpen);
}}
2020-06-03 18:15:51 +02:00
handleLanguage={(e)=>{
alert("chuj1");
}}
handleProfile={(e)=>{
alert("chuj2");
}}
2020-06-03 15:43:11 +02:00
isOpen={isOpen}
/>
<Transfer
isOpen={isOpen}
handleClose={(e) => {
setOpen(!isOpen);
}}
/>
<h1>{text}</h1>
</div>
);
}
export default App;