// widgets/Card/Card.tsx import { Link } from "react-router-dom"; import styles from "./Card.module.scss"; import { classNames } from "@/shared/lib/classNames/classNames"; import type { CardData } from "@/widgets/CardList/types"; interface CardProps { data: CardData & { variant?: "lab" | "news" | "project" }; } export const Card = ({ data }: CardProps) => { const { id, name, previewText, preview, link, variant = "lab" } = data; return ( {preview ? ( {name} ) : (
)}

{name}

{previewText && variant === "lab" && (

{previewText}

)} {variant === "lab" && (
Перейти ⟶
)}
); };