Automatically bind toggleAll action

We are already specifying the element's role ('all') in the HTML. Its behaviour should be predefined; there's no need to also specify in the HTML.

The eventhandler doesn't need to be cleand up on disconnect, because they are removed along with the DOM object.
This commit is contained in:
David Cook
2025-02-20 11:10:30 +11:00
parent c2e54104d0
commit b92c046119
5 changed files with 5 additions and 5 deletions

View File

@@ -17,7 +17,6 @@ describe("CheckedController", () => {
<input
id="selectAllCheckbox"
type="checkbox"
data-action="change->checked#toggleAll"
data-checked-target="all">
<input
id="checkboxA"
@@ -87,7 +86,6 @@ describe("CheckedController", () => {
<input
id="selectAllCheckbox"
type="checkbox"
data-action="change->checked#toggleAll"
data-checked-target="all">
<input
id="checkboxA"