From 07df1f79dbb7a2404852c6dc42b9a41d97c9ea49 Mon Sep 17 00:00:00 2001 From: Dominik Horn Date: Thu, 27 Feb 2020 18:50:37 +0100 Subject: [PATCH] cleanup route drawer code + rendering #10 * remove underline from links * remove dead code * remove unused imports --- .../general/navigation/RouteDrawer.tsx | 28 ++++++------------- 1 file changed, 8 insertions(+), 20 deletions(-) diff --git a/packages/frontend/src/components/general/navigation/RouteDrawer.tsx b/packages/frontend/src/components/general/navigation/RouteDrawer.tsx index b8d626e..e2da278 100644 --- a/packages/frontend/src/components/general/navigation/RouteDrawer.tsx +++ b/packages/frontend/src/components/general/navigation/RouteDrawer.tsx @@ -1,19 +1,17 @@ -import * as React from 'react'; import { - SwipeableDrawer, createStyles, - makeStyles, - Theme, List, - Divider, ListItem, ListItemIcon, ListItemText, + makeStyles, + SwipeableDrawer, + Theme, } from '@material-ui/core'; -import InboxIcon from '@material-ui/icons/MoveToInbox'; -import MailIcon from '@material-ui/icons/Mail'; -import { APP_ROUTES, getLinkDisplayNameForPage, getLinkForPage } from '../../../util/approutes'; +import * as React from 'react'; import { Link } from 'react-router-dom'; +import { APP_ROUTES, getLinkDisplayNameForPage, getLinkForPage } from '../../../util/approutes'; +import h from '../../../util/history'; export interface RouteDrawerProps { readonly isOpen: boolean; @@ -39,22 +37,12 @@ export const RouteDrawer = (props: RouteDrawerProps) => {
{APP_ROUTES.map(route => ( - + h.push(getLinkForPage(route))}> {route.icon && {route.icon}} - - - + ))} - {/** TODO: bellow is testing code */} - {/* - {['Inbox', 'Starred', 'Send email', 'Drafts'].map((text, index) => ( - - {index % 2 === 0 ? : } - - - ))} */}
);