From 2bc8f7b03ed78896f62e307bbd54e006d81e143e Mon Sep 17 00:00:00 2001 From: yuancheng Date: Tue, 21 Jul 2026 15:43:26 +0800 Subject: [PATCH] Left-align log-table headers to match their left-aligned data cells Last Heard (and other log-style tables sharing this pattern) render every with align="left", but headers inherit the sitewide table { text-align: center; } with nothing overriding it - so the caption drifts toward the middle of wide columns (most visible on Target) while the actual data underneath hugs the left edge. Looks like a column-boundary misalignment at a glance, but it's a text-align mismatch; measured actual cell boundaries and they line up exactly. Scoped via a new .log-table class rather than changing table th sitewide, since ~90% of the dashboard's other tables intentionally keep centered cells (only 6-7 files use align="left" data cells). --- css/pistar-css-mini.php | 5 +++++ css/pistar-css.php | 12 ++++++++++++ mmdvmhost/lh.php | 2 +- 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/css/pistar-css-mini.php b/css/pistar-css-mini.php index b377569..a24e6b4 100644 --- a/css/pistar-css-mini.php +++ b/css/pistar-css-mini.php @@ -614,6 +614,11 @@ table th { border-bottom: 2px solid var(--accent); } +/* See css/pistar-css.php for why this is scoped to .log-table only. */ +table.log-table th { + text-align: left; +} + table tr:nth-child(even) { background: var(--table-even); } diff --git a/css/pistar-css.php b/css/pistar-css.php index 163f6c8..5a9b2da 100644 --- a/css/pistar-css.php +++ b/css/pistar-css.php @@ -757,6 +757,18 @@ table th { border-bottom: 2px solid var(--accent); } +/* Log-style tables (Last Heard, Local TX, D-Star activity lists) render + every data cell with align="left"; headers inherit the sitewide + `table { text-align: center; }` though, so the caption visually + drifts away from its column's actual left-aligned content - most + noticeable on wide columns like Target. Left-align just these + headers rather than changing text-align sitewide, since the vast + majority of the dashboard's other tables (config grids, status + tables) intentionally keep centered cells. */ +table.log-table th { + text-align: left; +} + table tr:nth-child(even) { background: var(--table-even); } diff --git a/mmdvmhost/lh.php b/mmdvmhost/lh.php index cb6babd..882c5c3 100644 --- a/mmdvmhost/lh.php +++ b/mmdvmhost/lh.php @@ -57,7 +57,7 @@ if ($callsignLookupSvc == "QRZ") { $callsignLookupUrl = "https://www.qrz.com/db/ ?> - +
()Time in time zone Transmitted Mode