diff --git a/src/components/CameraSettings/CameraSettingFields.tsx b/src/components/CameraSettings/CameraSettingFields.tsx
index 3f88cf9..95d56b9 100644
--- a/src/components/CameraSettings/CameraSettingFields.tsx
+++ b/src/components/CameraSettings/CameraSettingFields.tsx
@@ -130,7 +130,7 @@ const CameraSettingFields = ({
diff --git a/src/components/HistoryList/AlertItem.tsx b/src/components/HistoryList/AlertItem.tsx
index abc4119..f744d4a 100644
--- a/src/components/HistoryList/AlertItem.tsx
+++ b/src/components/HistoryList/AlertItem.tsx
@@ -4,6 +4,10 @@ import SightingModal from "../SightingModal/SightingModal";
import InfoBar from "../SightingsWidget/InfoBar";
import { useState } from "react";
import HotListImg from "/Hotlist_Hit.svg";
+import { useAlertHitContext } from "../../context/AlertHitContext";
+import NPED_CAT_A from "/NPED_Cat_A.svg";
+import NPED_CAT_B from "/NPED_Cat_B.svg";
+import NPED_CAT_C from "/NPED_Cat_C.svg";
type AlertItemProps = {
item: SightingType;
@@ -11,8 +15,12 @@ type AlertItemProps = {
const AlertItem = ({ item }: AlertItemProps) => {
const [isModalOpen, setIsModalOpen] = useState(false);
+ const { dispatch } = useAlertHitContext();
const motionAway = (item?.motion ?? "").toUpperCase() === "AWAY";
const isHotListHit = item?.metadata?.hotlistMatches?.Hotlist0 === true;
+ const isNPEDHitA = item?.metadata?.npedJSON?.["NPED CATEGORY"] === "A";
+ const isNPEDHitB = item?.metadata?.npedJSON?.["NPED CATEGORY"] === "B";
+ const isNPEDHitC = item?.metadata?.npedJSON?.["NPED CATEGORY"] === "C";
const handleClick = () => {
setIsModalOpen(true);
@@ -21,35 +29,63 @@ const AlertItem = ({ item }: AlertItemProps) => {
const closeModal = () => {
setIsModalOpen(false);
};
+
+ const handleDelete = () => {
+ dispatch({ type: "REMOVE", payload: item });
+ };
return (
- <>
-
No Alert results
diff --git a/src/components/SessionForm/HitSearchCard.tsx b/src/components/SessionForm/HitSearchCard.tsx index e25fdd3..c2c6b85 100644 --- a/src/components/SessionForm/HitSearchCard.tsx +++ b/src/components/SessionForm/HitSearchCard.tsx @@ -32,7 +32,7 @@ const SessionCard = () => {