diff --git a/src/app/reducers/cameraSettingsReducer.ts b/src/app/reducers/cameraSettingsReducer.ts index d464ed1..d5307ec 100644 --- a/src/app/reducers/cameraSettingsReducer.ts +++ b/src/app/reducers/cameraSettingsReducer.ts @@ -3,6 +3,13 @@ import type { CameraSettings, CameraSettingsAction } from "../../utils/types"; export const initialState: CameraSettings = { mode: 0, imageSize: { width: 1280, height: 960 }, + regionPainter: { + paintedCells: [], + regions: [ + { name: "Region 1", brushColour: "#FF0000", cells: [] }, + { name: "Region 2", brushColour: "#00FF00", cells: [] }, + ], + }, }; export const cameraSettingsReducer = (state: CameraSettings, action: CameraSettingsAction) => { diff --git a/src/features/setup/components/platePatch/PlatePatchSetup.tsx b/src/features/setup/components/platePatch/PlatePatchSetup.tsx index b029e2a..48b765d 100644 --- a/src/features/setup/components/platePatch/PlatePatchSetup.tsx +++ b/src/features/setup/components/platePatch/PlatePatchSetup.tsx @@ -1,32 +1,39 @@ +import CardHeader from "../../../../components/CardHeader"; import Card from "../../../../components/ui/Card"; -import TimeStampBadge from "../../../../components/ui/TimeStampBadge"; -import NumberPlate from "../../../dashboard/components/platePatch/NumberPlate"; import { useSightingList } from "../../../dashboard/hooks/useSightingList"; const PlatePatchSetup = () => { const { sightingList, isLoading } = useSightingList(); - const firstFourSightings = sightingList?.slice(0, 4); if (isLoading) return <>Loading...; - return ( - + +
+ + + + + + + + + + + + {sightingList?.map((sighting) => ( + + + + + + + ))} + +
VRMSeen CountSeenPlate
{sighting.vrm}{sighting.seenCount}{sighting.timeStamp} + +
+
); }; diff --git a/src/utils/types.ts b/src/utils/types.ts index 9e5c09f..a8177b2 100644 --- a/src/utils/types.ts +++ b/src/utils/types.ts @@ -55,6 +55,10 @@ export type NpedJSON = { export type CameraSettings = { mode: number; imageSize: { width: number; height: number }; + regionPainter: { + paintedCells: { x: number; y: number }[]; + regions: { name: string; brushColour: string; cells: { x: number; y: number }[] }[]; + }; }; export type CameraSettingsAction = | {