From d7d15f6c5c1b79df43b4be2d5fd13e277b66a065 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Mon, 23 Jul 2018 14:30:03 +0200 Subject: [PATCH] luci-base: rework reveal/hide CBI password template button Also add a hidden type password field to prevent browser autocompleters from entering the login passwords into fields liek the wireless WPA key field. Signed-off-by: Jo-Philipp Wich (cherry picked from commit b6dd0ecd6cc7eb1f4c758a0815f725ff0be4f157) --- modules/luci-base/luasrc/view/cbi/value.htm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/modules/luci-base/luasrc/view/cbi/value.htm b/modules/luci-base/luasrc/view/cbi/value.htm index c8c905eb11..942ab72e77 100644 --- a/modules/luci-base/luasrc/view/cbi/value.htm +++ b/modules/luci-base/luasrc/view/cbi/value.htm @@ -1,10 +1,16 @@ <%+cbi/valueheader%> + <%- if self.password then -%> + /> + <%- end -%> 0, "data-choices", { self.keylist, self.vallist }) %> /> - <% if self.password then %><% end %> + <%- if self.password then -%> +
∗
+ <% end %> <%+cbi/valuefooter%> -- 2.30.2