web/elements: unselect top checkbox in table when not all elements are selected
Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
parent
db0af3763b
commit
7b01a208a2
|
@ -447,6 +447,8 @@ export abstract class Table<T> extends AKElement {
|
||||||
name="select-all"
|
name="select-all"
|
||||||
type="checkbox"
|
type="checkbox"
|
||||||
aria-label=${t`Select all rows`}
|
aria-label=${t`Select all rows`}
|
||||||
|
.checked=${this.selectedElements.length ===
|
||||||
|
this.data?.results.length}
|
||||||
@input=${(ev: InputEvent) => {
|
@input=${(ev: InputEvent) => {
|
||||||
if ((ev.target as HTMLInputElement).checked) {
|
if ((ev.target as HTMLInputElement).checked) {
|
||||||
this.selectedElements =
|
this.selectedElements =
|
||||||
|
|
Reference in New Issue