summaryrefslogtreecommitdiffhomepage
path: root/applications
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2016-03-03 22:06:39 +0100
committerMatthias Schiffer <mschiffer@universe-factory.net>2016-03-03 22:06:39 +0100
commit4de35274cab2df740941149fe41c3c2bb8c12850 (patch)
treea568b5009d2f5a1abd0e0794c62fb1a6ef802bb4 /applications
parentddc893ccc254e79b0869c709ada07f5ae232a0e3 (diff)
luci-base: view: make checkboxes and radio buttons styleable
Add an empty, normally invisible label after checkboxes and radio buttons with cbi-input-{checkbox,radio} classes to allow CSS styling them as suggested on http://www.paulund.co.uk/style-checkboxes-with-css Signed-off-by: Nils Schneider <nils@nilsschneider.net> Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Diffstat (limited to 'applications')
-rw-r--r--applications/luci-app-ddns/luasrc/view/ddns/detail_lvalue.htm1
-rw-r--r--applications/luci-app-ddns/luasrc/view/ddns/overview_enabled.htm1
2 files changed, 2 insertions, 0 deletions
diff --git a/applications/luci-app-ddns/luasrc/view/ddns/detail_lvalue.htm b/applications/luci-app-ddns/luasrc/view/ddns/detail_lvalue.htm
index 0bcfd44283..b69d780ea9 100644
--- a/applications/luci-app-ddns/luasrc/view/ddns/detail_lvalue.htm
+++ b/applications/luci-app-ddns/luasrc/view/ddns/detail_lvalue.htm
@@ -14,6 +14,7 @@
c = c + 1
%>
<input class="cbi-input-radio" onclick="cbi_d_update(this.id)" onchange="cbi_d_update(this.id)" type="radio"<%= attr("id", cbid..c) .. attr("name", cbid) .. attr("value", key) .. ifattr((self:cfgvalue(section) or self.default) == key, "checked", "checked") %> />
+ <label<%= attr("for", cbid..c) %>></label>
<label<%= attr("for", cbid..c) %>><%=self.vallist[i]%></label>
<% if c == self.size then c = 0 %><% if self.orientation == "horizontal" then %>&#160;<% else %><br /><% end %>
<% end end %>
diff --git a/applications/luci-app-ddns/luasrc/view/ddns/overview_enabled.htm b/applications/luci-app-ddns/luasrc/view/ddns/overview_enabled.htm
index 64b3dae455..2efc125fcc 100644
--- a/applications/luci-app-ddns/luasrc/view/ddns/overview_enabled.htm
+++ b/applications/luci-app-ddns/luasrc/view/ddns/overview_enabled.htm
@@ -10,6 +10,7 @@
attr("id", cbid) .. attr("name", cbid) .. attr("value", self.enabled or 1) ..
ifattr((self:cfgvalue(section) or self.default) == self.enabled, "checked", "checked")
%> />
+<label<%= attr("for", cbid)%>></label>
<%+cbi/valuefooter%>
<!-- ++ END ++ Dynamic DNS ++ overview_enabled.htm ++ -->