import type { Tutorial } from "@/lib/tutorials"; import Link from "next/link"; import { DifficultyBadge } from "./DifficultyBadge"; interface TutorialCardProps { tutorial: Tutorial; } export function TutorialCard({ tutorial }: TutorialCardProps) { return (
{/* Terminal header */}
~/tutos/{tutorial.slug}
{/* Content */}
{tutorial.category.name}

{tutorial.title}

{tutorial.excerpt}

{new Date(tutorial.date).toLocaleDateString( "fr-FR", { day: "numeric", month: "short", year: "numeric", } )} {tutorial.readTime && ( {tutorial.readTime} )}
{/* Hover prompt */}
Commencer la lecture
); }