From b67ac03161018dd9d87026b92b590c8e22890489 Mon Sep 17 00:00:00 2001 From: Pinapelz Date: Thu, 20 Jun 2024 20:19:34 -0700 Subject: show total viewcount on personal page channel card --- src/components/channel-card.tsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/components') diff --git a/src/components/channel-card.tsx b/src/components/channel-card.tsx index 839cde6..b66a6e0 100644 --- a/src/components/channel-card.tsx +++ b/src/components/channel-card.tsx @@ -8,6 +8,7 @@ interface ChannelCardProps { avatarUrl: string subscriberCount: number videoCount: number + viewCount: number suborg: string nextMilestone: string nextMilestoneDays: string @@ -15,7 +16,7 @@ interface ChannelCardProps { } export function ChannelCard(props: ChannelCardProps) { - const { channel_id, name, avatarUrl, subscriberCount, videoCount, suborg, nextMilestone, nextMilestoneDays, nextMilestoneDate } = props + const { channel_id, name, avatarUrl, subscriberCount, videoCount, viewCount, suborg, nextMilestone, nextMilestoneDays, nextMilestoneDate } = props return ( @@ -33,12 +34,16 @@ export function ChannelCard(props: ChannelCardProps) {
Subscribers - {subscriberCount.toLocaleString()} + {Number(subscriberCount).toLocaleString()}
Videos {videoCount}
+
+ View Count + {Number(viewCount).toLocaleString()} +
Next Milestone {Number(nextMilestone).toLocaleString()} -- cgit v1.2.3