fix(tables): checked parts can now be sorted. Fixes #137

This commit is contained in:
2026-02-06 13:21:51 +01:00
parent c8e9ce3fb4
commit 8234a79cc0
+8
View File
@@ -176,6 +176,14 @@ class BrickChanger {
// Not going through dataset to avoid converting
this.html_parent.setAttribute(this.parent_dataset, value);
}
// Update the data-sort attribute on the parent TD for sortable tables
if (this.html_type == "checkbox") {
const parentTd = this.html_element.closest('td');
if (parentTd && parentTd.hasAttribute('data-sort')) {
parentTd.setAttribute('data-sort', Number(this.html_element.checked));
}
}
} catch (error) {
console.log(error.message);