Compare commits

..

No commits in common. "65bfbe812a5af7990e088f5cc72eeaedc9d5e58d" and "fe9d7293d0681d1e3153dd1d9c872463bb1fdd29" have entirely different histories.

3 changed files with 7 additions and 37 deletions

View File

@ -1 +1 @@
v20260101-10-run-checks-shift-multiselect-last-row-checkbox-fix v20260101-09-run-checks-shift-multiselect-range-highlight-fix

View File

@ -425,9 +425,6 @@ table.addEventListener('click', function (e) {
// Use the remembered pre-click state to avoid double toggling in some browsers // Use the remembered pre-click state to avoid double toggling in some browsers
var preChecked = (lastMouseDownCb === t ? lastMouseDownChecked : t.checked); var preChecked = (lastMouseDownCb === t ? lastMouseDownChecked : t.checked);
var targetChecked = !preChecked; var targetChecked = !preChecked;
// Some browsers may still reconcile the default checkbox toggle after this handler.
// Apply the intended state now and once more on the next tick to ensure the clicked
// checkbox remains in-sync with the highlighted range.
t.checked = targetChecked; t.checked = targetChecked;
// Reset mousedown tracking once we've consumed it // Reset mousedown tracking once we've consumed it
@ -441,38 +438,20 @@ table.addEventListener('click', function (e) {
var start = startRow ? rows.indexOf(startRow) : -1; var start = startRow ? rows.indexOf(startRow) : -1;
var end = endRow ? rows.indexOf(endRow) : -1; var end = endRow ? rows.indexOf(endRow) : -1;
var lo = -1;
var hi = -1;
if (start !== -1 && end !== -1) { if (start !== -1 && end !== -1) {
lo = Math.min(start, end); var lo = Math.min(start, end);
hi = Math.max(start, end); var hi = Math.max(start, end);
} for (var i = lo; i <= hi; i++) {
var cb = rows[i].querySelector('.rc_row_cb');
function applyRangeCheckedState() { if (cb) cb.checked = targetChecked;
// Always re-assert the clicked checkbox state.
t.checked = targetChecked;
if (lo !== -1 && hi !== -1) {
for (var i = lo; i <= hi; i++) {
var cb = rows[i].querySelector('.rc_row_cb');
if (cb) cb.checked = targetChecked;
}
} }
} }
applyRangeCheckedState();
if (window.getSelection) { if (window.getSelection) {
try { window.getSelection().removeAllRanges(); } catch (err) {} try { window.getSelection().removeAllRanges(); } catch (err) {}
} }
// Ensure the final visual state matches the final checkbox state. updateButtons();
// If the browser applies a late default toggle reconciliation, this second
// pass keeps both the checkmarks and row highlights correct.
setTimeout(function () {
applyRangeCheckedState();
updateButtons();
}, 0);
lastCheckedCb = t; lastCheckedCb = t;
return; return;
} }

View File

@ -167,15 +167,6 @@
- Corrected an off-by-one issue where selection previously stopped one row above the clicked item. - Corrected an off-by-one issue where selection previously stopped one row above the clicked item.
- Added visual highlighting for all rows that are selected via checkmarks to clearly indicate active selection. - Added visual highlighting for all rows that are selected via checkmarks to clearly indicate active selection.
---
## v20260101-10-run-checks-shift-multiselect-last-row-checkbox-fix
### Fixed
- Fixed an issue on the Run Checks page where the last row in a shift-selected range was visually highlighted but its checkbox was not checked.
- Ensured checkbox state and row highlight state stay fully in sync for all rows in a shift multi-selection.
- Corrected selection logic so every row within the calculated range is consistently selected and marked.
================================================================================================================================================ ================================================================================================================================================
## v0.1.14 ## v0.1.14