import { Card, CardContent, CardHeader } from '@/components/ui/card'; import { cn } from '@/lib/utils'; import { Link, usePage } from '@inertiajs/react'; import ButtonGradientPrimary from '../button-gradient-primary'; import { Avatar, AvatarFallback, AvatarImage } from '../ui/avatar'; import { Progress } from '../ui/progress'; interface Props { course: Course; watch_history: WatchHistory; completion: CourseCompletion; className?: string; } const CourseCard7 = ({ course, watch_history, completion, className }: Props) => { const { props } = usePage(); const { translate } = props as any; const { frontend, button } = translate; return ( {course.title} { const target = e.target as HTMLImageElement; target.src = '/assets/images/blank-image.jpg'; }} />
IM

{course.instructor.user.name}

{course.title}

{frontend.progress} {completion?.completion ?? 0}%

{watch_history && ( {button.continue} )}
); }; export default CourseCard7;