import React, { Component } from 'react'; import { Link } from 'react-router-dom'; import senseboxLogo from './sensebox_logo.svg'; import { withRouter } from 'react-router-dom'; import { withStyles } from '@material-ui/core/styles'; import Drawer from '@material-ui/core/Drawer'; import AppBar from '@material-ui/core/AppBar'; import Toolbar from '@material-ui/core/Toolbar'; import List from '@material-ui/core/List'; import Typography from '@material-ui/core/Typography'; import Divider from '@material-ui/core/Divider'; import IconButton from '@material-ui/core/IconButton'; import ListItem from '@material-ui/core/ListItem'; import ListItemIcon from '@material-ui/core/ListItemIcon'; import ListItemText from '@material-ui/core/ListItemText'; import { faBars, faChevronLeft, faBuilding, faIdCard, faEnvelope, faCog, faChalkboardTeacher, faFolderPlus } from "@fortawesome/free-solid-svg-icons"; import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; const styles = (theme) => ({ drawerWidth: { // color: theme.palette.primary.main, width: window.innerWidth < 600 ? '100%' : '240px', borderRight: `1px solid ${theme.palette.primary.main}` }, appBarColor: { backgroundColor: theme.palette.primary.main } }); class Navbar extends Component { constructor(props) { super(props); this.state = { open: false }; } toggleDrawer = () => { this.setState({ open: !this.state.open }); } render(){ return (
senseBox Blockly senseBox-Logo {/^\/tutorial(\/.*$|$)/g.test(this.props.location.pathname) ? Tutorial : null}
Menü
{[{text: 'Tutorials', icon: faChalkboardTeacher, link: "/tutorial"}, {text: 'Tutorial-Builder', icon: faFolderPlus, link: "/tutorial/builder"}, {text: 'Einstellungen', icon: faCog, link: "/settings"}].map((item, index) => ( ))} {[{text: 'Über uns', icon: faBuilding},{text: 'Kontakt', icon: faEnvelope}, {text: 'Impressum', icon: faIdCard}].map((item, index) => ( ))}
); } } export default withStyles(styles, {withTheme: true})(withRouter(Navbar));