- refactored fetching NPED Category

This commit is contained in:
2025-10-14 08:50:06 +01:00
parent 666b90d078
commit 7121809a9e
4 changed files with 12 additions and 18 deletions

View File

@@ -5,8 +5,6 @@ type InfoBarprops = {
obj: SightingType;
};
const InfoBar = ({ obj }: InfoBarprops) => {
const isNPEDHitD = obj?.metadata?.npedJSON?.["NPED CATEGORY"] === "D";
return (
<div className="flex items-center gap-3 text-xs bg-neutral-900 px-2 py-1 rounded justify-between">
<div className="flex items-center gap-3 text-xs">
@@ -18,13 +16,7 @@ const InfoBar = ({ obj }: InfoBarprops) => {
</div>
</div>
<div className="min-w-14 opacity-80 ">
{isNPEDHitD ? (
<span className="text-amber-500 font-semibold">NPED HIT CAT D</span>
) : (
""
)}
</div>
<div className="min-w-14 opacity-80 "></div>
</div>
);
};