Skip to content

Commit

Permalink
a to Link
Browse files Browse the repository at this point in the history
  • Loading branch information
TyHil committed Nov 17, 2024
1 parent 3d646fc commit f1454ee
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/components/building.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { ArrowForwardIos } from '@mui/icons-material';
import { Card, Typography } from '@mui/material';
import tailwindTheme from 'src/../tailwind.config';
import Link from 'next/link';

export type BuildingCardProps = {
name: string;
Expand All @@ -16,8 +17,8 @@ export default function Building(props: BuildingCardProps) {
green: 'Efficient',
};
return (
<a href={`/building/${props.id}`}>
<Card className="m-5 flex flex-row items-center justify-between rounded-lg bg-white p-5">
<Link className="m-5" href={`/building/${props.id}`}>
<Card className="flex flex-row items-center justify-between rounded-lg bg-white p-5">
<div>
<div className="flex flex-row items-center">
<Typography variant="h6" fontWeight={700}>
Expand All @@ -41,6 +42,6 @@ export default function Building(props: BuildingCardProps) {
</div>
<ArrowForwardIos />
</Card>
</a>
</Link>
);
}

0 comments on commit f1454ee

Please sign in to comment.