From bed2212850328bcdd181bb97e131447d907584d7 Mon Sep 17 00:00:00 2001 From: Waters Church Date: Sun, 13 Sep 2026 14:10:39 -0400 Subject: [PATCH] Admin: a folded card's readout shares its row with Configure Folded, the status readout took a full line and Configure sat alone beneath it. The readout now moves into the bottom row beside the button, the button staying bottom-right even when a long readout wraps; opening the card puts the readout back above the form, where it was. Co-Authored-By: Claude Fable 5.1 --- public/admin/admin.css | 5 +++-- public/admin/admin.js | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/public/admin/admin.css b/public/admin/admin.css index 2e14ff9..e895423 100644 --- a/public/admin/admin.css +++ b/public/admin/admin.css @@ -298,7 +298,7 @@ details.field-group > summary.field-group-title:hover { color: var(--text); } /* the card's one action row: status on the left, Configure / Apply on the right */ .module-actions { display: flex; - align-items: center; + align-items: flex-end; /* the button stays bottom-right when a readout wraps */ gap: 10px; margin-top: 10px; } @@ -306,7 +306,8 @@ details.field-group > summary.field-group-title:hover { color: var(--text); } .module-name.is-toggle:hover, .module-name.is-toggle:focus-visible { color: var(--accent); outline: none; } .module-actions .admin-status { flex: 1; margin-top: 0; } -.module-actions .btn { margin-left: auto; } +.module-actions .module-status { flex: 0 1 auto; min-width: 0; margin-top: 0; } +.module-actions .btn { flex: none; margin-left: auto; } .admin-status { min-height: 16px; font-size: 12px; color: var(--muted); margin-top: 8px; } .admin-status.error { color: var(--danger); } diff --git a/public/admin/admin.js b/public/admin/admin.js index e95589d..ff771cc 100644 --- a/public/admin/admin.js +++ b/public/admin/admin.js @@ -600,6 +600,10 @@ function buildModuleCard(mod) { status.hidden = !open; save.textContent = open ? 'Apply' : 'Configure'; save.className = open ? 'btn primary' : 'btn'; + // Folded, the readout shares the bottom row with Configure instead of + // taking a line of its own; open, it goes back above the form. + if (open) card.insertBefore(healthEl, mountError); + else actions.insertBefore(healthEl, status); try { sessionStorage.setItem(openKey, open ? '1' : '0'); } catch { /* fine */ } }; let wasOpen = false;