diff --git a/src/components/CourseCard.tsx b/src/components/CourseCard.tsx index 3abebda30..ac4ca8fe8 100644 --- a/src/components/CourseCard.tsx +++ b/src/components/CourseCard.tsx @@ -1,9 +1,11 @@ 'use client'; import { Course } from '@/store/atoms'; -import PercentageComplete from './PercentageComplete'; import { useRouter } from 'next/navigation'; import Link from 'next/link'; import { Button } from './ui/button'; +import { Card, CardContent } from "@/components/ui/card"; +import { motion } from "framer-motion"; +import { MessageCircle, PlayCircle } from "lucide-react"; export const CourseCard = ({ course, @@ -14,54 +16,63 @@ export const CourseCard = ({ }) => { const router = useRouter(); const imageUrl = course.imageUrl ? course.imageUrl : 'banner_placeholder.png'; + const percentage = course.totalVideos !== undefined ? Math.ceil(((course.totalVideosWatched ?? 0) / course?.totalVideos) * 100) : 0; + return ( -