diff --git a/controller/internal/web/templates/monitoring.html b/controller/internal/web/templates/monitoring.html
index eb5ff8e..61e3c41 100644
--- a/controller/internal/web/templates/monitoring.html
+++ b/controller/internal/web/templates/monitoring.html
@@ -1,14 +1,6 @@
{{define "monitoring"}}
{{template "layout_start" .}}
-
-
@@ -183,6 +175,8 @@
// --- Chart options for line charts with LINEAR x-axis ---
function chartOpts(yLabel, beginAtZero) {
+ var now = Date.now();
+ var defaultRangeMs = parseRangeMs('1h');
return {
responsive: true,
maintainAspectRatio: false,
@@ -198,8 +192,14 @@
callbacks: {
title: function(items) {
if (!items.length) return '';
- // parsed.x is the ms timestamp on a linear axis
- return formatTimestamp(items[0].parsed.x);
+ var raw = items[0].raw;
+ if (raw && typeof raw === 'object' && raw.x) {
+ return formatTimestamp(raw.x);
+ }
+ if (items[0].parsed && items[0].parsed.x) {
+ return formatTimestamp(items[0].parsed.x);
+ }
+ return '';
}
}
}
@@ -207,6 +207,8 @@
scales: {
x: {
type: 'linear',
+ min: now - defaultRangeMs,
+ max: now,
grid: {color: 'rgba(48,54,61,0.5)'},
ticks: {
color: '#8b949e',
diff --git a/controller/internal/web/templates/style.css b/controller/internal/web/templates/style.css
index 33c531e..8f5137f 100644
--- a/controller/internal/web/templates/style.css
+++ b/controller/internal/web/templates/style.css
@@ -1506,26 +1506,32 @@ a.stat-card:hover {
}
.sysinfo-grid {
display: grid;
- grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
- gap: .5rem;
+ grid-template-columns: 1fr 1fr;
+ gap: 0;
}
.sysinfo-row {
display: flex;
justify-content: space-between;
- align-items: center;
- padding: .35rem .5rem;
+ align-items: baseline;
+ padding: .5rem .75rem;
border-bottom: 1px solid rgba(48, 54, 61, 0.3);
font-size: .9rem;
+ gap: 1rem;
}
.sysinfo-row:last-child { border-bottom: none; }
.sysinfo-label {
color: var(--text-secondary);
font-weight: 500;
+ white-space: nowrap;
+ flex-shrink: 0;
}
.sysinfo-value {
color: var(--text-primary);
font-family: 'JetBrains Mono', monospace;
font-size: .85rem;
+ font-weight: 600;
+ text-align: right;
+ word-break: break-word;
}
.charts-grid {
display: grid;
@@ -1540,6 +1546,8 @@ a.stat-card:hover {
border-radius: 8px;
padding: .75rem;
border: 1px solid rgba(48, 54, 61, 0.5);
+ min-width: 0;
+ overflow: hidden;
}
.chart-box-half {
flex: 1;
@@ -1556,10 +1564,17 @@ a.stat-card:hover {
.chart-wrap {
position: relative;
height: 180px;
+ overflow: hidden;
+ max-width: 100%;
+}
+.chart-wrap canvas {
+ max-width: 100%;
}
.chart-wrap-bar {
position: relative;
height: 250px;
+ overflow: hidden;
+ max-width: 100%;
}
.container-charts-row {
display: flex;