From 717367252ca1458bba2c0a3058ae3e3bfb5d84be Mon Sep 17 00:00:00 2001 From: hsiegeln <37154749+hsiegeln@users.noreply.github.com> Date: Mon, 23 Mar 2026 21:51:44 +0100 Subject: [PATCH] fix: align AgentInstance page with mock design - Chart headers: add current value meta text (CPU %, memory MB, TPS, error rate, thread count) matching mock layout - Bottom section: 2-column grid with log placeholder (left) and timeline events (right) matching mock layout - Timeline header: show "Timeline" + event count like mock - Remove duplicate EmptyState placeholder Co-Authored-By: Claude Opus 4.6 (1M context) --- .../AgentInstance/AgentInstance.module.css | 28 ++++++++++ ui/src/pages/AgentInstance/AgentInstance.tsx | 56 +++++++++++++------ 2 files changed, 67 insertions(+), 17 deletions(-) diff --git a/ui/src/pages/AgentInstance/AgentInstance.module.css b/ui/src/pages/AgentInstance/AgentInstance.module.css index 92016bc8..d98a791b 100644 --- a/ui/src/pages/AgentInstance/AgentInstance.module.css +++ b/ui/src/pages/AgentInstance/AgentInstance.module.css @@ -145,3 +145,31 @@ color: var(--text-primary); margin-bottom: 12px; } + +.chartMeta { + font-size: 11px; + font-weight: 500; + color: var(--text-muted); + font-family: var(--font-mono); +} + +.bottomSection { + display: grid; + grid-template-columns: 1fr 1fr; + gap: 14px; + margin-bottom: 20px; +} + +.eventCount { + font-size: 11px; + font-weight: 500; + color: var(--text-muted); + font-family: var(--font-mono); +} + +.emptyEvents { + padding: 20px; + text-align: center; + font-size: 12px; + color: var(--text-muted); +} diff --git a/ui/src/pages/AgentInstance/AgentInstance.tsx b/ui/src/pages/AgentInstance/AgentInstance.tsx index 83df9f58..3578269a 100644 --- a/ui/src/pages/AgentInstance/AgentInstance.tsx +++ b/ui/src/pages/AgentInstance/AgentInstance.tsx @@ -200,54 +200,76 @@ export default function AgentInstance() { )} -
Performance
-
CPU Usage
+
+
CPU Usage
+
{cpuPct != null ? `${(cpuPct * 100).toFixed(0)}% current` : ''}
+
{cpuSeries ? : }
-
Memory Heap
+
+
Memory (Heap)
+
{heapUsed != null && heapMax != null ? `${(heapUsed / (1024 * 1024)).toFixed(0)} MB / ${(heapMax / (1024 * 1024)).toFixed(0)} MB` : ''}
+
{heapSeries ? : }
-
Throughput
+
+
Throughput
+
{agent?.tps != null ? `${agent.tps.toFixed(1)} msg/s` : ''}
+
{throughputSeries - ? + ? : }
-
Error Rate
+
+
Error Rate
+
{agent?.errorRate != null ? `${(agent.errorRate * 100).toFixed(1)}%` : ''}
+
{errorSeries - ? + ? : }
-
Thread Count
+
+
Thread Count
+ {threadSeries &&
{threadSeries[0].data[threadSeries[0].data.length - 1]?.y.toFixed(0)} active
} +
{threadSeries - ? + ? : }
-
GC Pauses
+
+
GC Pauses
+
{gcSeries ? : }
- {feedEvents.length > 0 && ( -
-
Events
- -
- )} +
+ + +
+
+ Timeline + {feedEvents.length} events +
+ {feedEvents.length > 0 + ? + :
No events in the selected time range.
} +
+
- ); }