Based on what I can tell after-request is not triggered because the response causes a full page
reload and the persisted input values were due to browser autofill, not htmx state.
+3
-2
Diff
round #1
+2
-2
appview/pages/templates/repo/settings/fragments/addLabelDefModal.html
+2
-2
appview/pages/templates/repo/settings/fragments/addLabelDefModal.html
···
28
28
29
29
{{ define "basicLabelDef" }}
30
30
<form
31
+
autocomplete="off"
31
32
hx-put="/{{ $.RepoInfo.FullName }}/settings/label"
32
33
hx-indicator="#spinner"
33
34
hx-swap="none"
34
-
hx-on::after-request="if(event.detail.successful) this.reset()"
35
35
class="flex flex-col space-y-4">
36
36
37
37
<p class="text-gray-500 dark:text-gray-400">These labels can have a name and a color.</p>
···
49
49
50
50
{{ define "kvLabelDef" }}
51
51
<form
52
+
autocomplete="off"
52
53
hx-put="/{{ $.RepoInfo.FullName }}/settings/label"
53
54
hx-indicator="#spinner"
54
55
hx-swap="none"
55
-
hx-on::after-request="if(event.detail.successful) this.reset()"
56
56
class="flex flex-col space-y-4">
57
57
58
58
<p class="text-gray-500 dark:text-gray-400">
History
2 rounds
1 comment
tobinio.dev
submitted
#1
1 commit
expand
collapse
appview/pages: reset label & secret form correctly
`after-request` is not triggered because the response causes a full page
reload.
Persisted input values were due to browser autofill, not htmx state.
Signed-off-by: tobinio <Tobias.frischmann1@gmail.com>
expand 1 comment
pull request successfully merged
tobinio.dev
submitted
#0
1 commit
expand
collapse
appview/pages: reset label & secret form correctly
`after-request` is not triggered because the response causes a full page
reload.
Persisted input values were due to browser autofill, not htmx state.
thanks!