diff options
author | Jo-Philipp Wich <jo@mein.io> | 2018-06-25 08:49:44 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-25 08:49:44 +0200 |
commit | 483c9d35b20b23842b0ab78b09adb59725dfed20 (patch) | |
tree | 38860f5003e60fb78c2791f5b881156b298fc77f /modules/luci-base/luasrc/view/cbi/cell_valueheader.htm | |
parent | a65d55ebcee57d174b557adbbb76df47b3747873 (diff) | |
parent | c7ee1ffcf114e11a81f2fdb707c705b5cb5064e3 (diff) |
Merge pull request #1895 from jow-/master
Responsive OpenWrt theme
Diffstat (limited to 'modules/luci-base/luasrc/view/cbi/cell_valueheader.htm')
-rw-r--r-- | modules/luci-base/luasrc/view/cbi/cell_valueheader.htm | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/modules/luci-base/luasrc/view/cbi/cell_valueheader.htm b/modules/luci-base/luasrc/view/cbi/cell_valueheader.htm index a4b68cda72..dbb0e1120b 100644 --- a/modules/luci-base/luasrc/view/cbi/cell_valueheader.htm +++ b/modules/luci-base/luasrc/view/cbi/cell_valueheader.htm @@ -1,2 +1,10 @@ -<div class="td cbi-value-field<% if self.error and self.error[section] then %> cbi-value-error<% end %>"> +<%- + local title = luci.util.trim(striptags(self.title)) + local ftype = self.template and self.template:gsub("^.+/", "") +-%> +<div class="td cbi-value-field<% if self.error and self.error[section] then %> cbi-value-error<% end %>"<%= + attr("data-name", self.option) .. + ifattr(ftype and #ftype > 0, "data-type", ftype) .. + ifattr(title and #title > 0, "data-title", title) +%>> <div id="cbi-<%=self.config.."-"..section.."-"..self.option%>" data-index="<%=self.index%>" data-depends="<%=pcdata(self:deplist2json(section))%>"> |