Files
clarity-helper/components/VoiceSession/VoiceHeader.tsx
T
John Remillard a4946ed04d feat: Add character names to scenarios and UI
Introduces `characterName` to the `Scenario` type, enabling AI personas to be explicitly named. This change also updates the `ScenarioCard` component to display the character name and adds foundational support for potential future scenario deletion functionality. The README has been updated with a new AI Studio link.
2026-03-04 11:43:39 -05:00

29 lines
1.1 KiB
TypeScript

import React from 'react';
import { PhoneOff, Flag } from 'lucide-react';
interface VoiceHeaderProps {
title: string;
onExit: () => void;
onFinish: () => void;
}
const VoiceHeader: React.FC<VoiceHeaderProps> = ({ title, onExit, onFinish }) => (
<div className="p-8 flex justify-between items-center relative z-10">
<div className="flex items-center gap-4">
<button onClick={onExit} className="p-3 bg-white/5 hover:bg-white/10 rounded-2xl text-white/50 hover:text-white transition-all">
<PhoneOff size={20} />
</button>
<div>
<h2 className="text-white font-bold text-lg">{title}</h2>
<p className="text-teal-400 text-[10px] font-black uppercase tracking-widest">Active Roleplay Session</p>
</div>
</div>
<button onClick={onFinish} className="bg-teal-600 hover:bg-teal-700 text-white px-6 py-2.5 rounded-xl text-[10px] font-black uppercase tracking-widest transition-all shadow-lg shadow-teal-900/40 flex items-center gap-2">
<Flag size={14} /> Finish
</button>
</div>
);
export default React.memo(VoiceHeader);