diff --git a/src/Routes/Home.js b/src/Routes/Home.js
index 731786f..eef8182 100644
--- a/src/Routes/Home.js
+++ b/src/Routes/Home.js
@@ -9,6 +9,8 @@ import '../css/Home.css';
export default class RouterHome extends React.Component {
render() {
+ // this.props.changeBackground()
+
return (
diff --git a/src/Routes/Vegetable.js b/src/Routes/Vegetable.js
index d2354f1..531d413 100644
--- a/src/Routes/Vegetable.js
+++ b/src/Routes/Vegetable.js
@@ -9,7 +9,8 @@ import {
CarouselItem,
CarouselControl,
CarouselIndicators,
- CarouselCaption
+ Breadcrumb,
+ BreadcrumbItem
} from 'reactstrap';
import {
NotificationContainer,
@@ -17,6 +18,7 @@ import {
} from 'react-notifications';
import Api from '../Components/Api';
import MapItem from '../Components/Map';
+import strToSlug from '../StrToSlug';
export default class RouterVegetable extends React.Component {
constructor(props) {
@@ -29,7 +31,13 @@ export default class RouterVegetable extends React.Component {
name: '',
Vegetables: []
},
- item: {},
+ item: {
+ name: null,
+ Type: {
+ id: null,
+ name: null
+ }
+ },
activeIndex: 0
};
@@ -96,8 +104,12 @@ export default class RouterVegetable extends React.Component {
-
- » {this.state.item.name}
+
+
+ {this.state.item.Type.name}
+ {this.state.item.name}
+
+
diff --git a/src/StrToSlug.js b/src/StrToSlug.js
index aeeefb9..9b2df12 100644
--- a/src/StrToSlug.js
+++ b/src/StrToSlug.js
@@ -1,4 +1,7 @@
export default (string) => {
+ if (!string) {
+ return ''
+ }
let str = string;
str = str.replace(/^\s+|\s+$/g, ''); // trim
str = str.toLowerCase();
diff --git a/src/css/index.css b/src/css/index.css
index 1956de3..c0a839a 100644
--- a/src/css/index.css
+++ b/src/css/index.css
@@ -48,4 +48,13 @@ body {
/* width:50%;
float:left;
display:inline; */
+}
+
+.no-padding {
+ padding: 0;
+}
+
+.center {
+ display: flex;
+ justify-content: center;
}
\ No newline at end of file