From 5736050b0c9878825a51b5b69f75811de62e1309 Mon Sep 17 00:00:00 2001
From: Pinapelz <yukais@pinapelz.com>
Date: Mon, 27 Nov 2023 02:07:30 -0800
Subject: make channel-card name link to channel

---
 src/components/channel-card.tsx | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

(limited to 'src/components/channel-card.tsx')

diff --git a/src/components/channel-card.tsx b/src/components/channel-card.tsx
index 599c48a..839cde6 100644
--- a/src/components/channel-card.tsx
+++ b/src/components/channel-card.tsx
@@ -3,6 +3,7 @@ import { CardTitle, CardHeader, CardContent, Card } from "@/components/ui/card"
 import { Badge } from "@/components/ui/badge"
 
 interface ChannelCardProps {
+  channel_id: string
   name: string
   avatarUrl: string
   subscriberCount: number
@@ -14,7 +15,7 @@ interface ChannelCardProps {
 }
 
 export function ChannelCard(props: ChannelCardProps) {
-  const { name, avatarUrl, subscriberCount, videoCount, suborg, nextMilestone, nextMilestoneDays, nextMilestoneDate } = props
+  const { channel_id, name, avatarUrl, subscriberCount, videoCount, suborg, nextMilestone, nextMilestoneDays, nextMilestoneDate } = props
   return (
     <Card className="w-[500px] shadow-lg rounded-lg overflow-hidden mt-4 py-4">
       <CardHeader>
@@ -24,7 +25,7 @@ export function ChannelCard(props: ChannelCardProps) {
             <AvatarFallback>PR</AvatarFallback>
           </Avatar>
           <div>
-            <CardTitle>{name}</CardTitle>
+           <a className="hover:underline" href={`https://youtube.com/channel/${channel_id}`}><CardTitle>{name}</CardTitle></a>
             <Badge variant="secondary">{suborg}</Badge>
           </div>
         </div>
-- 
cgit v1.2.3

