diff options
author | Ashutosh Bishnoi <mail2bishnoi@gmail.com> | 2021-05-24 14:47:57 +0530 |
---|---|---|
committer | Ashutosh Bishnoi <mail2bishnoi@gmail.com> | 2021-05-24 14:47:57 +0530 |
commit | 81ad6a0e5c8ed4f35ccac0cd271b8923e686c060 (patch) | |
tree | a7207018677d99e91e3ce55a535cb48ae88afe7b /modern/src/components/reports | |
parent | 10b8e1d6f4ed63c43da2cd71bf21f34b31071cd1 (diff) | |
download | trackermap-web-81ad6a0e5c8ed4f35ccac0cd271b8923e686c060.tar.gz trackermap-web-81ad6a0e5c8ed4f35ccac0cd271b8923e686c060.tar.bz2 trackermap-web-81ad6a0e5c8ed4f35ccac0cd271b8923e686c060.zip |
Resolved some comments on the reports
Diffstat (limited to 'modern/src/components/reports')
-rw-r--r-- | modern/src/components/reports/ReportNavbar.js | 16 | ||||
-rw-r--r-- | modern/src/components/reports/ReportSidebar.js | 9 |
2 files changed, 8 insertions, 17 deletions
diff --git a/modern/src/components/reports/ReportNavbar.js b/modern/src/components/reports/ReportNavbar.js index 93c01a06..674db3a4 100644 --- a/modern/src/components/reports/ReportNavbar.js +++ b/modern/src/components/reports/ReportNavbar.js @@ -1,16 +1,9 @@ import React from 'react'; -import { AppBar, Toolbar, Typography, List, ListItem, ListItemText, ListItemIcon, Divider, Drawer, makeStyles, IconButton, Hidden } from '@material-ui/core'; - +import { AppBar, Toolbar, Typography, IconButton } from '@material-ui/core'; import MenuIcon from '@material-ui/icons/Menu'; import t from '../../common/localization'; -const useStyles = makeStyles(theme => ({ - menuButton: { - } -})); -const ReportNavbar = ({ openDrawer, setOpenDrawer, reportName }) => { - - const classes = useStyles(); +const ReportNavbar = ({ openDrawer, setOpenDrawer }) => { return ( <AppBar position="fixed" color="inherit"> @@ -19,12 +12,11 @@ const ReportNavbar = ({ openDrawer, setOpenDrawer, reportName }) => { color="inherit" aria-label="open drawer" edge="start" - onClick={() => setOpenDrawer(!openDrawer)} - className={classes.menuButton}> + onClick={() => setOpenDrawer(!openDrawer)}> <MenuIcon /> </IconButton> <Typography variant="h6" noWrap> - {t('reportTitle')} / {reportName} + {t('reportTitle')} </Typography> </Toolbar> </AppBar> diff --git a/modern/src/components/reports/ReportSidebar.js b/modern/src/components/reports/ReportSidebar.js index e42c36ee..a71ac4b1 100644 --- a/modern/src/components/reports/ReportSidebar.js +++ b/modern/src/components/reports/ReportSidebar.js @@ -1,8 +1,8 @@ import React from 'react'; -import { AppBar, Toolbar, Typography, List, ListItem, ListItemText, ListItemIcon, Divider, Drawer, makeStyles, IconButton, Hidden } from '@material-ui/core'; -import { Link, useHistory, useLocation } from 'react-router-dom'; +import { List, ListItem, ListItemText, ListItemIcon } from '@material-ui/core'; +import { Link, useLocation } from 'react-router-dom'; -const ReportNavbar = ({ routes, setReportName }) => { +const ReportNavbar = ({ routes }) => { const location = useLocation(); @@ -15,8 +15,7 @@ const ReportNavbar = ({ routes, setReportName }) => { key={`${route}${index}`} button to={route.href} - selected={route.href === location.pathname} - onClick={() => setReportName(route.name)}> + selected={route.href === location.pathname}> <ListItemIcon> {route.icon} </ListItemIcon> |