diff options
author | Jo-Philipp Wich <jo@mein.io> | 2018-06-19 17:17:04 +0200 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2018-06-23 18:01:39 +0200 |
commit | bbf096c79eca2e8407d15fe2acfde70c8d08e9c4 (patch) | |
tree | 51adf268e002e8d76e80d78ed4588559d514b490 /modules/luci-mod-admin-full/luasrc/view/admin_uci | |
parent | c4e25bebfc5da6b1d08f9ea6ed9e100ad2cd966d (diff) |
luci-mod-admin-full: cleanup markup
Globally cleanup template markup to support responsive design changes in
OpenWrt theme.
Rework handling of dynamic status tables, consolidate hand-written markup,
fix small render bugs in various places and annotate tables where needed.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'modules/luci-mod-admin-full/luasrc/view/admin_uci')
-rw-r--r-- | modules/luci-mod-admin-full/luasrc/view/admin_uci/changelog.htm | 10 | ||||
-rw-r--r-- | modules/luci-mod-admin-full/luasrc/view/admin_uci/changes.htm | 22 |
2 files changed, 15 insertions, 17 deletions
diff --git a/modules/luci-mod-admin-full/luasrc/view/admin_uci/changelog.htm b/modules/luci-mod-admin-full/luasrc/view/admin_uci/changelog.htm index 4ed4f0a10f..e05ccdece3 100644 --- a/modules/luci-mod-admin-full/luasrc/view/admin_uci/changelog.htm +++ b/modules/luci-mod-admin-full/luasrc/view/admin_uci/changelog.htm @@ -4,7 +4,7 @@ -%> <% export("uci_changelog", function(changes) -%> -<fieldset class="cbi-section"> +<div class="cbi-section"> <strong><%:Legend:%></strong> <div class="uci-change-legend"> <div class="uci-change-legend-label"><ins> </ins> <%:Section added%></div> @@ -32,9 +32,11 @@ ret[#ret+1] = "<br />%s.%s.%s+=<strong>%s</strong>" %{ r, s, o, util.pcdata(v[i]) } end - else + elseif v ~= "" then ret[#ret+1] = "<br />%s.%s.%s=<strong>%s</strong>" %{ r, s, o, util.pcdata(v) } + else + ret[#ret+1] = "<br /><del>%s.%s.<strong>%s</strong></del>" %{ r, s, o } end end end @@ -57,7 +59,7 @@ ret[#ret+1] = "%s.%s.%s+=<strong>%s</strong><br />" %{ r, s, o, util.pcdata(v[i]) } end - + else ret[#ret+1] = "%s.%s.%s=<strong>%s</strong><br />" %{ r, s, o, util.pcdata(v) } @@ -75,5 +77,5 @@ write(table.concat(ret)) %></div> -</fieldset> +</div> <%- end) %> diff --git a/modules/luci-mod-admin-full/luasrc/view/admin_uci/changes.htm b/modules/luci-mod-admin-full/luasrc/view/admin_uci/changes.htm index c69ec1215a..6282244757 100644 --- a/modules/luci-mod-admin-full/luasrc/view/admin_uci/changes.htm +++ b/modules/luci-mod-admin-full/luasrc/view/admin_uci/changes.htm @@ -27,21 +27,17 @@ <div class="cbi-page-actions"> <% if redir_url then %> - <div style="float:left"> - <form class="inline" method="get" action="<%=luci.util.pcdata(redir_url)%>"> - <input class="cbi-button cbi-button-link" style="float:left; margin:0" type="submit" value="<%:Back%>" /> - </form> - </div> + <form method="get" action="<%=luci.util.pcdata(redir_url)%>"> + <input class="cbi-button cbi-button-link" type="submit" value="<%:Back%>" /> + </form> <% end %> - <div style="text-align:right"> - <input class="cbi-button cbi-button-save" type="button" id="apply_button" value="<%:Save & Apply%>" onclick="uci_apply(true); this.blur()" /> - <form class="inline" method="post" action="<%=url("admin/uci/revert")%>"> - <input type="hidden" name="token" value="<%=token%>" /> - <input type="hidden" name="redir" value="<%=pcdata(luci.http.formvalue("redir"))%>" /> - <input class="cbi-button cbi-button-reset" type="submit" value="<%:Revert%>" /> - </form> - </div> + <input class="cbi-button cbi-button-save" type="button" id="apply_button" value="<%:Save & Apply%>" onclick="uci_apply(true); this.blur()" /> + <form method="post" action="<%=url("admin/uci/revert")%>"> + <input type="hidden" name="token" value="<%=token%>" /> + <input type="hidden" name="redir" value="<%=pcdata(luci.http.formvalue("redir"))%>" /> + <input class="cbi-button cbi-button-reset" type="submit" value="<%:Revert%>" /> + </form> </div> <%+footer%> |