From 91b91cd4890fb5f496d970b1bbd8bbfa3b20eaf4 Mon Sep 17 00:00:00 2001 From: Ivo Oskamp Date: Thu, 1 Jan 2026 17:54:06 +0100 Subject: [PATCH] Auto-commit local changes before build (2026-01-01 17:54:06) --- .last-branch | 2 +- .../src/templates/main/run_checks.html | 14 ++++++++++++++ docs/changelog.md | 7 +++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/.last-branch b/.last-branch index db6f598..41fca5a 100644 --- a/.last-branch +++ b/.last-branch @@ -1 +1 @@ -v20260101-13-run-checks-select-all-indeterminate-state-fix +v20260101-14-run-checks-select-all-indeterminate-stuck-dash-fix diff --git a/containers/backupchecks/src/templates/main/run_checks.html b/containers/backupchecks/src/templates/main/run_checks.html index 2518511..56d0e82 100644 --- a/containers/backupchecks/src/templates/main/run_checks.html +++ b/containers/backupchecks/src/templates/main/run_checks.html @@ -389,6 +389,14 @@ function statusClass(status) { selectAll.indeterminate = false; selectAll.checked = !!checked; + // Some browsers can keep rendering the indeterminate UI even after + // setting it to false when the click default action runs afterwards. + // Re-assert the header state on the next tick. + setTimeout(function () { + selectAll.indeterminate = false; + selectAll.checked = !!checked; + }, 0); + updateButtons(); } @@ -423,6 +431,12 @@ function statusClass(status) { // Fully control header checkbox behavior to prevent indeterminate state from getting stuck. selectAll.addEventListener('click', toggleHeaderSelection, true); + // If the browser applies a late default toggle, force the visual state + // back to whatever the row selection actually is. + selectAll.addEventListener('change', function () { + refreshSelectAll(); + }, true); + selectAll.addEventListener('keydown', function (e) { // Space/Enter should behave the same as a click. if (e.key === ' ' || e.code === 'Space' || e.key === 'Enter') { diff --git a/docs/changelog.md b/docs/changelog.md index d6dc80c..cd44692 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -201,6 +201,13 @@ - Ensured that after clearing all selected rows, the “Select all” checkbox can again be used to select all rows normally. - Improved synchronization between individual row selection and the global “Select all” checkbox state. +--- + +## v20260101-14-run-checks-select-all-indeterminate-stuck-dash-fix + +- Fixed an issue on the Run Checks page where the “Select all” checkbox could remain visually stuck in the indeterminate (`-`) state after clearing the current selection. +- Ensured the header checkbox state is re-synced after the click/change cycle so it correctly reflects the row selection state. + ================================================================================================================================================ ## v0.1.14