import type { AgentDetail } from './types'

interface AgentStatsBarProps {
  agent: AgentDetail
}

export function AgentStatsBar({ agent }: AgentStatsBarProps) {
  return (
    <div className="grid grid-cols-5 gap-4 mb-6">
      <div className="bg-white border border-gray-200 rounded-lg p-4">
        <div className="text-sm text-gray-500">Aktive Sessions</div>
        <div className="text-2xl font-bold text-gray-900">{agent.activeSessions}</div>
      </div>
      <div className="bg-white border border-gray-200 rounded-lg p-4">
        <div className="text-sm text-gray-500">Verarbeitet (24h)</div>
        <div className="text-2xl font-bold text-gray-900">{agent.totalProcessed.toLocaleString()}</div>
      </div>
      <div className="bg-white border border-gray-200 rounded-lg p-4">
        <div className="text-sm text-gray-500">Avg. Antwortzeit</div>
        <div className="text-2xl font-bold text-gray-900">{agent.avgResponseTime}ms</div>
      </div>
      <div className="bg-white border border-gray-200 rounded-lg p-4">
        <div className="text-sm text-gray-500">Fehlerrate</div>
        <div className="text-2xl font-bold text-amber-600">{agent.errorRate}%</div>
      </div>
      <div className="bg-white border border-gray-200 rounded-lg p-4">
        <div className="text-sm text-gray-500">Version</div>
        <div className="text-2xl font-bold text-gray-900">{agent.version}</div>
      </div>
    </div>
  )
}
