frontend/src/components/App.tsx

31 lines
720 B
TypeScript
Raw Normal View History

import React, { useState, useContext } from 'react';
2020-08-20 18:14:28 +02:00
import Topbar from './Topbar';
import { Transfer } from './Transfer';
import { Scheduler } from './Scheduler';
2020-08-17 23:56:34 +02:00
import { Rightbar } from './Rightbar';
import styled from 'styled-components';
const Wrapper = styled.div`
display: flex;
height: calc(100vh - 80px);
`;
export const App = () => {
const [isOpenTransfer, setOpenTransfer] = useState(false);
const handleTransfer = () => {
setOpenTransfer(!isOpenTransfer);
};
return (
<>
<Topbar handleTransfer={handleTransfer} />
<Transfer isOpen={isOpenTransfer} handleClose={handleTransfer} />
<Wrapper>
<Scheduler />
2020-08-17 23:56:34 +02:00
<Rightbar />
</Wrapper>
</>
);
};