Skip to content

Commit

Permalink
dev: format
Browse files Browse the repository at this point in the history
  • Loading branch information
k11q authored and khrnchn committed Dec 29, 2024
1 parent 18ba19c commit f9d04f4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions components/ui/institution-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -277,11 +277,11 @@ const InstitutionCard = forwardRef<HTMLDivElement, Institution & {isClosest?: bo
onClick={() => navigateToItem(category, slugify(name))}
>
<CardContent className="flex flex-col items-center gap-2 p-4 h-full">
{isClosest && (
<div className="absolute top-2 left-2 bg-yellow-500 dark:bg-yellow-400 text-black p-1 px-2 rounded-full text-xs font-semibold">
Closest to you{distanceToCurrentUserInMeter && distanceToCurrentUserInMeter > 1000 ? ` • ${(distanceToCurrentUserInMeter / 1000).toFixed(2)} KM` : ` • ${distanceToCurrentUserInMeter} M`}
</div>
)}
{isClosest && (
<div className="absolute top-2 left-2 bg-yellow-500 dark:bg-yellow-400 text-black p-1 px-2 rounded-full text-xs font-semibold">
Closest to you{distanceToCurrentUserInMeter && distanceToCurrentUserInMeter > 1000 ? ` • ${(distanceToCurrentUserInMeter / 1000).toFixed(2)} KM` : ` • ${distanceToCurrentUserInMeter} M`}
</div>
)}
<div className="flex flex-col items-center gap-1 mb-2 w-full">
<motion.div>
<Image
Expand Down

0 comments on commit f9d04f4

Please sign in to comment.