From b246cdbc44c09bd2a1519861924cb0d63e71d39b Mon Sep 17 00:00:00 2001 From: Yee Jia Wei Date: Sat, 16 Dec 2023 12:05:19 +0800 Subject: [PATCH] change link icon to component --- components/LinkCard.tsx | 28 ++++------------------------ 1 file changed, 4 insertions(+), 24 deletions(-) diff --git a/components/LinkCard.tsx b/components/LinkCard.tsx index d530813..8591f22 100644 --- a/components/LinkCard.tsx +++ b/components/LinkCard.tsx @@ -17,6 +17,7 @@ import unescapeString from "@/lib/client/unescapeString"; import LinkActions from "@/components/LinkViews/LinkComponents/LinkActions"; import LinkDate from "@/components/LinkViews/LinkComponents/LinkDate"; import LinkCollection from "@/components/LinkViews/LinkComponents/LinkCollection"; +import LinkIcon from "@/components/LinkViews/LinkComponents/LinkIcon"; type Props = { link: LinkIncludingShortenedCollectionAndTags; @@ -65,30 +66,9 @@ export default function LinkCard({link, count, className}: Props) { onClick={() => link.url && window.open(link.url || "", "_blank")} className="flex flex-col justify-between cursor-pointer h-full w-full gap-1 p-3" > - {link.url && url ? ( - { - const target = e.target as HTMLElement; - target.style.display = "none"; - }} - /> - ) : link.type === "pdf" ? ( - - ) : link.type === "image" ? ( - - ) : undefined} +
+ +

{count + 1}