import React from 'react'; import { Scenario } from '../types'; import { Mic, MessageSquare, Trash2 } from 'lucide-react'; import Tooltip from './Tooltip'; interface ScenarioCardProps { scenario: Scenario; onSelect: (scenario: Scenario, mode: 'text' | 'voice') => void; onDelete?: (id: string) => void; } const ScenarioCard: React.FC = ({ scenario, onSelect, onDelete }) => { const getDifficultyColor = (diff: string) => { switch (diff) { case 'Beginner': return 'bg-teal-50 text-teal-800 border-teal-100'; case 'Intermediate': return 'bg-amber-50 text-amber-800 border-amber-100'; case 'Advanced': return 'bg-rose-50 text-rose-800 border-rose-100'; default: return 'bg-slate-50 text-slate-800 border-slate-100'; } }; const difficultyExplanations: Record = { 'Beginner': 'Low-stakes environment with highly structured feedback and clear cognitive distortions.', 'Intermediate': 'Moderate social friction requiring nuanced responses and identifying subtle distortions.', 'Advanced': 'High-trigger environment with resistant AI personas to test deep emotional regulation.' }; return (
{onDelete && ( )}
{scenario.difficulty} {!onDelete && ( {scenario.category} )}

{scenario.title}

{scenario.description}

{scenario.cbtFocus.map(focus => ( {focus} ))}
); }; export default React.memo(ScenarioCard);