import React from 'react'; import { Box, Text } from 'ink'; import Spinner from 'ink-spinner'; import { MonitorState } from './types.js'; interface SystemStatusProps { state: MonitorState; } export function SystemStatus({ state }: SystemStatusProps) { const { loading, daemonOnline, stats, apiUrl } = state; return ( ◈ SYSTEM Daemon {loading ? SYNCING : daemonOnline ? ● ONLINE : ○ OFFLINE } API {apiUrl.replace('https://', '').substring(0, 22)} Tasks {stats.completed} /{stats.total} done Active {stats.active} Blocked {stats.blocked} 🧬 HIVE MIND Antidotes {state.hiveStats?.total_antidotes || 0} Fortress {state.hiveStats?.fortress_rules || 0} Trust {(state.hiveStats?.average_trust_score || 0).toFixed(0)} ); }