Files
breakpilot-lehrer/website/app/admin/unity-bridge/_components/StatusBadge.tsx
Benjamin Admin 0b37c5e692 [split-required] Split website + studio-v2 monoliths (Phase 3 continued)
Website (14 monoliths split):
- compliance/page.tsx (1,519 → 9), docs/audit (1,262 → 20)
- quality (1,231 → 16), alerts (1,203 → 10), docs (1,202 → 11)
- i18n.ts (1,173 → 8 language files)
- unity-bridge (1,094 → 12), backlog (1,087 → 6)
- training (1,066 → 8), rag (1,063 → 8)
- Deleted index_original.ts (4,899 LOC dead backup)

Studio-v2 (5 monoliths split):
- meet/page.tsx (1,481 → 9), messages (1,166 → 9)
- AlertsB2BContext.tsx (1,165 → 5 modules)
- alerts-b2b/page.tsx (1,019 → 6), korrektur/archiv (1,001 → 6)

All existing imports preserved. Zero new TypeScript errors.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-24 17:52:36 +02:00

40 lines
1.2 KiB
TypeScript

'use client'
import type { BridgeStatus } from './types'
export function StatusBadge({ status, error }: { status: BridgeStatus | null; error: string | null }) {
if (error) {
return (
<div className="flex items-center gap-2 px-3 py-1.5 bg-red-100 text-red-800 rounded-full text-sm font-medium">
<span className="w-2 h-2 bg-red-500 rounded-full animate-pulse" />
Offline
</div>
)
}
if (!status) {
return (
<div className="flex items-center gap-2 px-3 py-1.5 bg-gray-100 text-gray-600 rounded-full text-sm font-medium">
<span className="w-2 h-2 bg-gray-400 rounded-full animate-pulse" />
Verbinde...
</div>
)
}
if (status.is_compiling) {
return (
<div className="flex items-center gap-2 px-3 py-1.5 bg-yellow-100 text-yellow-800 rounded-full text-sm font-medium">
<span className="w-2 h-2 bg-yellow-500 rounded-full animate-pulse" />
Kompiliert...
</div>
)
}
return (
<div className="flex items-center gap-2 px-3 py-1.5 bg-green-100 text-green-800 rounded-full text-sm font-medium">
<span className="w-2 h-2 bg-green-500 rounded-full" />
Online - Port 8090
</div>
)
}