luci-base: do not trigger form action when revealing password
Ref: https://github.com/openwrt/luci/issues/2327 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
6a0c1d1ab6
commit
241b90c7f6
1 changed files with 1 additions and 1 deletions
|
@ -21,6 +21,6 @@
|
|||
ifattr(#self.keylist > 0, "data-choices", { self.keylist, self.vallist })
|
||||
%> />
|
||||
<%- if self.password then -%>
|
||||
<button class="cbi-button cbi-button-neutral" title="<%:Reveal/hide password%>" aria-label="<%:Reveal/hide password%>" onclick="var e = this.previousElementSibling; e.type = (e.type === 'password') ? 'text' : 'password'">∗</button>
|
||||
<button class="cbi-button cbi-button-neutral" title="<%:Reveal/hide password%>" aria-label="<%:Reveal/hide password%>" onclick="var e = this.previousElementSibling; e.type = (e.type === 'password') ? 'text' : 'password'; event.preventDefault()">∗</button>
|
||||
<% end %>
|
||||
<%+cbi/valuefooter%>
|
||||
|
|
Loading…
Reference in a new issue