diff --git a/src/components/MainCointainer.jsx b/src/components/MainCointainer.jsx index 7cf9a8d..dd16058 100644 --- a/src/components/MainCointainer.jsx +++ b/src/components/MainCointainer.jsx @@ -153,7 +153,6 @@ class PersistentDrawerLeft extends React.Component { render() { const { classes, theme, loading, account, enableEthereum, location: { pathname, search } } = this.props const { open } = this.state - console.log(this.props) const isHome = pathname === "/" const queryParams = queryString.parse(search) diff --git a/src/components/base/BreadCrumb.jsx b/src/components/base/BreadCrumb.jsx new file mode 100644 index 0000000..b759425 --- /dev/null +++ b/src/components/base/BreadCrumb.jsx @@ -0,0 +1,36 @@ +import React from 'react' +import PropTypes from 'prop-types' +import { withStyles } from '@material-ui/core/styles' +import { Link } from 'react-router-dom' +import classnames from 'classnames' + +const styles = theme => ({ + theme, + main: { + color: '#939BA1' + }, + link: { + textDecoration: 'none', + color: '#939BA1' + } +}) + +function BreadCrumb({ classes, className, trail }){ + const trailString = trail ? ` > ${trail.join(' > ')}` : '' + return ( +
+ + All projects + + {{trailString}} +
+ ) +} + +BreadCrumb.propTypes = { + classes: PropTypes.object.isRequired, + className: PropTypes.string, + trail: PropTypes.array +} + +export default withStyles(styles)(BreadCrumb) diff --git a/src/components/projects/CreateProject.jsx b/src/components/projects/CreateProject.jsx index 3423a1e..c5e962b 100644 --- a/src/components/projects/CreateProject.jsx +++ b/src/components/projects/CreateProject.jsx @@ -17,6 +17,7 @@ import { convertTokenAmountUsd } from '../../utils/prices' import { setMediaType } from '../../utils/project' import MediaView from '../base/MediaView' import { isVideo } from '../../utils/images' +import BreadCrumb from '../base/BreadCrumb' const { addProject } = LiquidPledging.methods @@ -237,9 +238,10 @@ const SubmissionSection = ({ classes, history }) => { return (
-
- {'All projects and delegates > Create new'} -
+ {manifest &&
-
- {`All projects > ${manifest.title}`} -
+ {manifest && manifest.title}