diff --git a/src/components/CreateModal/CreateModal.jsx b/src/components/CreateModal/CreateModal.jsx
index edab641..566d3c8 100644
--- a/src/components/CreateModal/CreateModal.jsx
+++ b/src/components/CreateModal/CreateModal.jsx
@@ -151,6 +151,8 @@ export default function CreateModal({
name: "",
description: "",
itemDate: "",
+ isResolved: false,
+ isHelped: null,
});
setUploadImg("");
setActiveStep(0);
@@ -172,6 +174,8 @@ export default function CreateModal({
name: "",
description: "",
itemDate: "",
+ isResolved: false,
+ isHelped: null,
});
setUploadImg("");
setActiveStep(0);
@@ -545,6 +549,8 @@ export default function CreateModal({
name: "",
description: "",
itemDate: "",
+ isResolved: false,
+ isHelped: null,
});
setUploadImg("");
onClose();
diff --git a/src/components/Home/Home.jsx b/src/components/Home/Home.jsx
index 81c6b45..21319e2 100644
--- a/src/components/Home/Home.jsx
+++ b/src/components/Home/Home.jsx
@@ -85,6 +85,8 @@ export default function Home() {
name: "",
description: "",
itemDate: "",
+ isResolved: false,
+ isHelped: null
});
const [isEdit, setIsEdit] = useState(false);
@@ -133,7 +135,7 @@ export default function Home() {
};
getData();
}, []);
-
+
window.onresize = () => {
setScreenWidth(window.screen.width);
};
diff --git a/src/components/ImageContainer/ImageContainer.jsx b/src/components/ImageContainer/ImageContainer.jsx
new file mode 100644
index 0000000..8b0dd6c
--- /dev/null
+++ b/src/components/ImageContainer/ImageContainer.jsx
@@ -0,0 +1,27 @@
+import { Image, Flex, Text } from "@chakra-ui/react";
+
+export default function ImageContainer({ image, isresolved }) {
+ return (
+
+ {isresolved &&
+ RETURNED
+ This item has been returned.
+ }
+
+
+ );
+}
diff --git a/src/components/InfoModal/InfoModal.jsx b/src/components/InfoModal/InfoModal.jsx
index f0bee46..ef26b3e 100644
--- a/src/components/InfoModal/InfoModal.jsx
+++ b/src/components/InfoModal/InfoModal.jsx
@@ -8,7 +8,6 @@ import {
Text,
Stack,
useColorModeValue,
- Image,
Modal,
ModalOverlay,
ModalContent,
@@ -20,6 +19,7 @@ import { formatDate } from "../../utils";
import { UserAuth } from "../../context/AuthContext";
import DataContext from "../../context/DataContext";
import axios from "axios";
+import ImageContainer from "../ImageContainer/ImageContainer";
export default function InfoModal({ setData, isOpen, onClose, props }) {
const [showEmail, setShowEmail] = useState(false);
@@ -52,7 +52,6 @@ export default function InfoModal({ setData, isOpen, onClose, props }) {
}
const formattedDate = formatDate(new Date(props.date));
-
return (
-
+
+
+ {/*
+
+ RESOLVED
+
+
+ */}
{
const newItem = {
@@ -159,6 +162,8 @@ export default function Map({
date: date.toISOString(),
itemDate: newAddedItem.itemDate,
id: item.data.id,
+ isResolved: newAddedItem.isResolved,
+ isHelped: newAddedItem.isHelped,
};
setData((prev) => [...prev, newItem]);
setPosition(centerPosition);
@@ -170,6 +175,8 @@ export default function Map({
name: "",
description: "",
itemDate: "",
+ isResolved: false,
+ isHelped: null,
});
setIsCreate(!isCreate);
setUploadImg("");
@@ -221,8 +228,8 @@ export default function Map({
},
});
- return (position.lat !== centerPosition[0] &&
- position.lng !== centerPosition[1]) ? (
+ return position.lat !== centerPosition[0] &&
+ position.lng !== centerPosition[1] ? (