diff --git a/src/app/find-properties/[[...opa_id]]/page.tsx b/src/app/find-properties/[[...opa_id]]/page.tsx
index fa18a00b..7aad81ac 100644
--- a/src/app/find-properties/[[...opa_id]]/page.tsx
+++ b/src/app/find-properties/[[...opa_id]]/page.tsx
@@ -108,22 +108,22 @@ const MapPage = ({ params }: MapPageProps) => {
const linkedProperty = featuresInView.find(
(feature) =>
- feature.properties.OPA_ID.toString() ===
+ feature.properties.opa_id.toString() ===
linkedPropertyRef?.current?.toString()
);
if (
linkedProperty &&
- linkedProperty.properties.OPA_ID !== selectedProperty?.properties.OPA_ID
+ linkedProperty.properties.opa_id !== selectedProperty?.properties.opa_id
) {
setSelectedProperty(linkedProperty);
linkedPropertyRef.current = null;
}
- }, [featuresInView, selectedProperty?.properties.OPA_ID]);
+ }, [featuresInView, selectedProperty?.properties.opa_id]);
useEffect(() => {
if (!selectedProperty) return;
- const opa_id = selectedProperty.properties.OPA_ID;
+ const opa_id = selectedProperty.properties.opa_id;
history.replaceState(null, "", `/find-properties/${opa_id}`);
}, [selectedProperty]);
@@ -312,10 +312,10 @@ const MapPage = ({ params }: MapPageProps) => {
onPress={updateSmallScreenMode}
startContent={
smallScreenMode === "map" ? (
-
+
) : (
-
- )
+
+ )
}
/>
diff --git a/src/components/PropertyCard.tsx b/src/components/PropertyCard.tsx
index 534bbbfd..a8f7bd73 100644
--- a/src/components/PropertyCard.tsx
+++ b/src/components/PropertyCard.tsx
@@ -21,10 +21,10 @@ function getPriorityClass(priorityLevel: string) {
}
const PropertyCard = ({ feature, setSelectedProperty }: PropertyCardProps) => {
- const { address, guncrime_density, tree_canopy_gap, priority_level, OPA_ID } =
+ const { address, guncrime_density, tree_canopy_gap, priority_level, opa_id } =
feature.properties;
- const image = `https://storage.googleapis.com/cleanandgreenphl/${OPA_ID}.jpg`;
+ const image = `https://storage.googleapis.com/cleanandgreenphl/${opa_id}.jpg`;
const formattedAddress = toTitleCase(address);
const priorityClass = getPriorityClass(priority_level);
diff --git a/src/components/PropertyDetailSection.tsx b/src/components/PropertyDetailSection.tsx
index d483bf1a..c87039f4 100644
--- a/src/components/PropertyDetailSection.tsx
+++ b/src/components/PropertyDetailSection.tsx
@@ -209,12 +209,12 @@ const PropertyDetailSection: FC = ({
{({ properties }) => (
{
setSelectedProperty(
items.find(
(item) =>
- properties?.OPA_ID === item?.properties?.OPA_ID
+ properties?.opa_id === item?.properties?.opa_id
) || null
);
}}
diff --git a/src/components/SidePanelControlBar.tsx b/src/components/SidePanelControlBar.tsx
index dd2abd10..1398c488 100644
--- a/src/components/SidePanelControlBar.tsx
+++ b/src/components/SidePanelControlBar.tsx
@@ -2,11 +2,7 @@
import React, { FC, useRef } from "react";
import { BarClickOptions } from "@/app/find-properties/[[...opa_id]]/page";
-import {
- BookmarkSimple,
- DownloadSimple,
- Funnel
-} from "@phosphor-icons/react";
+import { BookmarkSimple, DownloadSimple, Funnel } from "@phosphor-icons/react";
import { ThemeButton } from "./ThemeButton";
import { useFilter } from "@/context/FilterContext";
import { getPropertyIdsFromLocalStorage } from "@/utilities/localStorage";
@@ -39,7 +35,7 @@ const SearchBarComponent: FC = ({
let filterCount = Object.keys(appFilter).length;
if (shouldFilterSavedProperties) {
- // Exclude OPA_ID from filterCount, which counts OPA_ID as a filter by default
+ // Exclude opa_id from filterCount, which counts opa_id as a filter by default
filterCount--;
}
@@ -50,14 +46,14 @@ const SearchBarComponent: FC = ({
setShouldFilterSavedProperties(false);
dispatch({
type: "SET_DIMENSIONS",
- property: "OPA_ID",
+ property: "opa_id",
dimensions: [],
});
} else {
setShouldFilterSavedProperties(true);
dispatch({
type: "SET_DIMENSIONS",
- property: "OPA_ID",
+ property: "opa_id",
dimensions: [...propertyIds],
});
}
diff --git a/src/components/SinglePropertyDetail.tsx b/src/components/SinglePropertyDetail.tsx
index ff93fa62..016b6dba 100644
--- a/src/components/SinglePropertyDetail.tsx
+++ b/src/components/SinglePropertyDetail.tsx
@@ -74,7 +74,7 @@ const SinglePropertyDetail = ({
? JSON.parse(localStorageData)
: {};
- const propertyId = parsedLocalStorageData.opa_ids[OPA_ID];
+ const propertyId = parsedLocalStorageData.opa_ids[opa_id];
propertyId
? setIsPropertySavedToLocalStorage(true)
: setIsPropertySavedToLocalStorage(false);
@@ -99,10 +99,10 @@ const SinglePropertyDetail = ({
total_due,
tree_canopy_gap,
zipcode,
- OPA_ID,
+ opa_id,
phs_partner_agency,
} = properties;
- const image = `https://storage.googleapis.com/cleanandgreenphl/${OPA_ID}.jpg`;
+ const image = `https://storage.googleapis.com/cleanandgreenphl/${opa_id}.jpg`;
const atlasUrl = `https://atlas.phila.gov/${address}`;
const priorityClass = getPriorityClass(priority_level);
@@ -118,7 +118,7 @@ const SinglePropertyDetail = ({
let newLocalCache: PropertyIdLocalStorage = {
...localCache,
};
- newLocalCache.opa_ids[OPA_ID] = OPA_ID;
+ newLocalCache.opa_ids[opa_id] = opa_id;
newLocalCache.count++;
localStorage.setItem("opa_ids", JSON.stringify(newLocalCache));
};
@@ -126,7 +126,7 @@ const SinglePropertyDetail = ({
const removePropertyIdFromLocalStorage = (
localStorageData: PropertyIdLocalStorage
) => {
- delete localStorageData.opa_ids[OPA_ID];
+ delete localStorageData.opa_ids[opa_id];
localStorageData.count--;
localStorage.setItem("opa_ids", JSON.stringify(localStorageData));
};
@@ -154,7 +154,7 @@ const SinglePropertyDetail = ({
? JSON.parse(localStorageData)
: {};
- if (parsedLocalStorageData.opa_ids[OPA_ID]) {
+ if (parsedLocalStorageData.opa_ids[opa_id]) {
removePropertyIdFromLocalStorage(parsedLocalStorageData);
setIsPropertySavedToLocalStorage(false);
dispatchFilterAction(parsedLocalStorageData);
@@ -168,7 +168,7 @@ const SinglePropertyDetail = ({
if (data.count === 0) {
dispatch({
type: "SET_DIMENSIONS",
- property: "OPA_ID",
+ property: "opa_id",
dimensions: [],
});
setShouldFilterSavedProperties(false);
@@ -177,7 +177,7 @@ const SinglePropertyDetail = ({
let propertyIds = getPropertyIdsFromLocalStorage();
dispatch({
type: "SET_DIMENSIONS",
- property: "OPA_ID",
+ property: "opa_id",
dimensions: [...propertyIds],
});
}
@@ -231,7 +231,7 @@ const SinglePropertyDetail = ({
onMouseEnter={() => setHover(true)}
onMouseLeave={() => setHover(false)}
onFocus={() => setHover(true)}
- onBlur={() => setHover(false) }
+ onBlur={() => setHover(false)}
/>
@@ -251,7 +251,8 @@ const SinglePropertyDetail = ({
placement="top"
content="Street View"
classNames={{
- content: "bg-gray-900 rounded-[14px] text-white relative top-[5px]",
+ content:
+ "bg-gray-900 rounded-[14px] text-white relative top-[5px]",
}}
>