Skip to content

Commit f9b81f2

Browse files
fix: pr review changes
1 parent 10908cf commit f9b81f2

File tree

2 files changed

+14
-72
lines changed

2 files changed

+14
-72
lines changed

src/components/Layer2ProductCard.tsx

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
import { StaticImageData } from "next/image"
2-
import Image from "next/image"
3-
import Link from "next/link"
42
import { useTranslation } from "next-i18next"
5-
import { RiExternalLinkLine } from "react-icons/ri"
63

74
import { Card, CardContent, CardFooter, CardHeader } from "@/components/ui/card"
85

9-
import { Button } from "./ui/button"
6+
import { Button } from "./ui/buttons/Button"
7+
import InlineLink from "./ui/Link"
8+
import { TwImage } from "./Image"
109

1110
export type Layer2ProductCardProps = {
1211
children?: React.ReactNode
@@ -38,12 +37,12 @@ const Layer2ProductCard = ({
3837
const { t } = useTranslation("page-layer-2")
3938

4039
return (
41-
<Card className="text-foreground flex flex-col justify-between rounded-md border-0 p-2 shadow-lg transition-transform duration-100 hover:scale-[1.02] dark:bg-background-medium">
40+
<Card className="flex flex-col justify-between rounded-md border-0 p-2 shadow-lg transition-transform duration-100 hover:scale-[1.02] dark:bg-background-medium">
4241
<div
4342
className="mb-4 flex min-h-[200px] items-center justify-center border-b"
4443
style={{ backgroundColor: background }}
4544
>
46-
<Image
45+
<TwImage
4746
src={image}
4847
alt={alt}
4948
width={100}
@@ -72,47 +71,46 @@ const Layer2ProductCard = ({
7271

7372
<div className="space-y-1">
7473
{bridge && (
75-
<Link
74+
<InlineLink
7675
href={bridge}
7776
className="block text-primary underline hover:text-primary/80"
7877
>
7978
{name} {t("layer-2-bridge")}
80-
</Link>
79+
</InlineLink>
8180
)}
8281

8382
{ecosystemPortal && (
84-
<Link
83+
<InlineLink
8584
href={ecosystemPortal}
8685
className="block text-primary underline hover:text-primary/80"
8786
>
8887
{name} {t("layer-2-ecosystem-portal")}
89-
</Link>
88+
</InlineLink>
9089
)}
9190

9291
{tokenLists && (
93-
<Link
92+
<InlineLink
9493
href={tokenLists}
9594
className="block text-primary underline hover:text-primary/80"
9695
>
9796
{name} {t("layer-2-token-lists")}
98-
</Link>
97+
</InlineLink>
9998
)}
10099
</div>
101100
</CardContent>
102101

103102
<CardFooter className="mt-2 p-2">
104103
{url && (
105104
<Button
106-
variant={"default"}
107105
asChild
108106
className="w-full rounded-sm hover:text-white hover:shadow-[4px_4px_4px_rgba(147,51,234,0.25)] dark:bg-primary-action dark:hover:bg-primary/90 dark:hover:shadow-[4px_4px_4px_rgba(0,0,0,0.9)]"
109107
>
110-
<Link
108+
<InlineLink
111109
href={url}
112110
className="flex items-center gap-0 text-lg text-white no-underline"
113111
>
114-
{t("layer-2-explore")} {name} <RiExternalLinkLine />
115-
</Link>
112+
{t("layer-2-explore")} {name}
113+
</InlineLink>
116114
</Button>
117115
)}
118116
</CardFooter>

src/components/ui/button.tsx

Lines changed: 0 additions & 56 deletions
This file was deleted.

0 commit comments

Comments
 (0)