aboutsummaryrefslogtreecommitdiff
path: root/cmd/monfront/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/monfront/main.go')
-rw-r--r--cmd/monfront/main.go16
1 files changed, 10 insertions, 6 deletions
diff --git a/cmd/monfront/main.go b/cmd/monfront/main.go
index 3f71727..048a09c 100644
--- a/cmd/monfront/main.go
+++ b/cmd/monfront/main.go
@@ -685,13 +685,17 @@ var (
input.focus();
}
- els = document.querySelectorAll('thead > tr');
- for (i = 0; i < els.length; i++) {
- els[i].addEventListener('click', {handleEvent: row_head_click_event});
+ for (selector of ['thead > tr', 'thead input']) {
+ els = document.querySelectorAll(selector);
+ for (i = 0; i < els.length; i++) {
+ els[i].addEventListener('click', {handleEvent: row_head_click_event});
+ }
}
- els = document.querySelectorAll('tbody > tr');
- for (i = 0; i < els.length; i++) {
- els[i].addEventListener('click', {handleEvent: row_click_event});
+ for (selector of ['tbody > tr', 'tbody input']) {
+ els = document.querySelectorAll(selector);
+ for (i = 0; i < els.length; i++) {
+ els[i].addEventListener('click', {handleEvent: row_click_event});
+ }
}</script></body></html>`,
"checklist": `{{ template "header" . }}
<form method="post" action="/action">