-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Sidebar 스타일 및 이벤트 구현, router 개선
- Loading branch information
1 parent
86682fd
commit 4eac812
Showing
9 changed files
with
77 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,36 @@ | ||
import { ReactElement } from 'react'; | ||
import { useNavigate } from 'react-router-dom'; | ||
import styled from 'styled-components'; | ||
|
||
import Button from '../components/Button'; | ||
|
||
import Home from '../images/Home.svg'; | ||
import Table from '../images/Table.svg'; | ||
|
||
const Wrapper = styled.div` | ||
height: 100vh; | ||
background: #fcfcfc; | ||
box-shadow: 2px 0px 4px rgba(0, 0, 0, 0.25); | ||
text-align: center; | ||
`; | ||
|
||
const Menubar = (): ReactElement => { | ||
return <Wrapper>menu</Wrapper>; | ||
const navigate = useNavigate(); | ||
|
||
const goHome = (): void => { | ||
navigate('/'); | ||
}; | ||
|
||
const goTable = (): void => { | ||
navigate('/table'); | ||
}; | ||
|
||
return ( | ||
<Wrapper> | ||
<Button context={<img src={Home} />} margin={'30px 0 0 0'} onClick={goHome} /> | ||
<Button context={<img src={Table} />} margin={'30px 0 0 0'} onClick={goTable} /> | ||
</Wrapper> | ||
); | ||
}; | ||
|
||
export default Menubar; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.