"use client"; import { Card, Group, Text, Badge, Box } from "@mantine/core"; import { useState } from "react"; import type { AlbumTheme } from "@/lib/themes"; import type { Track } from "@/lib/ListTypes"; import { useHash } from "@mantine/hooks"; interface TrackCardProps { track: Track; index: number; theme: AlbumTheme; } export default function TrackCard({ track, index, theme }: TrackCardProps) { const [isHovered, setIsHovered] = useState(false); const [_hash, setHash] = useHash(); return ( setHash(`trackModal_${track.id}`)} className="backdrop-blur-sm transition-all duration-300" style={{ background: isHovered ? theme.card.backgroundHover : theme.card.background, border: `1px solid ${isHovered ? theme.border.light : theme.card.border}`, cursor: "pointer", // transform: isHovered ? "translateY(-2px)" : "translateY(0)", boxShadow: isHovered ? `0 8px 24px ${theme.primary.DEFAULT}30` : "none", }} onMouseEnter={() => setIsHovered(true)} onMouseLeave={() => setIsHovered(false)} > {index + 1} {track.label} {track.studioUrl && ( Studio )} {track.emilyLive && ( Emily Live )} {track.lpLive && ( LP Live )} {track.duration} ); }