+
{ picture }
- { category.title }
+ { category.title }
)
}
\ No newline at end of file
diff --git a/bfrontend/src/Components/Categories/CategoryView.js b/bfrontend/src/Components/Categories/CategoryView.js
index 5192290..2504afa 100644
--- a/bfrontend/src/Components/Categories/CategoryView.js
+++ b/bfrontend/src/Components/Categories/CategoryView.js
@@ -1,5 +1,6 @@
import CategoryViewLoader from './CategoryViewLoader';
-import CategoryProfile from './CategoryProfile';
+import CategoryProfile from './CategoryProfileLink';
+import Message from '../Messages/Message';
import { useParams } from 'react-router-dom';
import { connect } from 'react-redux'
@@ -13,6 +14,19 @@ function CategoryView({ categories }) {
category = categories.find(x => x._id === id);
}
+ const dummyMessage1 = {
+ author: {
+ username: '__SYSTEM',
+ _id: '5fc69864f15a7c5e504c9a1f'
+ },
+ category: {
+ title: 'alan',
+ _id: 'y8fyerghgh'
+ },
+ content: 'yes hello',
+ _id: 'i8ru354y89ty549ytg'
+ };
+
if (category) {
return (
@@ -20,8 +34,7 @@ function CategoryView({ categories }) {
- In terms of development, the first year of a cat’s life is equal to the first 15 years of a human life. After its second year, a cat is 25 in human years. And after that, each year of a cat’s life is equal to about 7 human years.
- Cats can rotate their ears 180 degrees.
+
The hearing of the average cat is at least five times keener than that of a human adult.
diff --git a/bfrontend/src/Components/Messages/Message.js b/bfrontend/src/Components/Messages/Message.js
new file mode 100644
index 0000000..f7b4336
--- /dev/null
+++ b/bfrontend/src/Components/Messages/Message.js
@@ -0,0 +1,10 @@
+import UserProfileLink from '../Users/UserProfileLink';
+
+export default function Message({ message }) {
+ return (
+
- );
+ return null;
} else {
return (
+
+ { message.content }
+
+ );
+}
\ No newline at end of file
diff --git a/bfrontend/src/Components/Root.js b/bfrontend/src/Components/Root.js
index 19e0415..2c77a17 100644
--- a/bfrontend/src/Components/Root.js
+++ b/bfrontend/src/Components/Root.js
@@ -1,13 +1,10 @@
import { useHistory } from 'react-router-dom';
-import Sidebar from './UI/Sidebar';
export default function Root(props) {
const history = useHistory();
if (props.user) {
- return (
-