'use client'; import Link from 'next/link'; interface ProjectCardProps { workspaceId: string; projectId: string; name: string; framework?: string | null; appUrl?: string | null; description?: string | null; } const FRAMEWORK_ICON: Record = { next: '▲', react: '⚛', vue: 'V', svelte: 'S', angular: 'A', nuxt: 'N', }; export function ProjectCard({ workspaceId, projectId, name, framework, appUrl, description }: ProjectCardProps) { const icon = framework ? (FRAMEWORK_ICON[framework.toLowerCase()] ?? '◻') : '◻'; return (
{ (e.currentTarget as HTMLElement).style.boxShadow = '0 4px 16px rgba(0,0,0,0.08)'; (e.currentTarget as HTMLElement).style.borderColor = 'rgba(0,0,0,0.12)'; }} onMouseLeave={e => { (e.currentTarget as HTMLElement).style.boxShadow = 'none'; (e.currentTarget as HTMLElement).style.borderColor = 'rgba(0,0,0,0.07)'; }} >
{icon}
{name}
{appUrl && (

{appUrl}

)} {description && (

{description}

)}
Open canvas →
); }