luci-app-adblock: align blocklist markup with recent changes
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
8e10118843
commit
994531ea26
1 changed files with 11 additions and 10 deletions
|
@ -33,7 +33,6 @@ end
|
||||||
margin-left:0px;
|
margin-left:0px;
|
||||||
padding-left:2px;
|
padding-left:2px;
|
||||||
line-height:20px;
|
line-height:20px;
|
||||||
height:20px;
|
|
||||||
}
|
}
|
||||||
.table.cbi-section-table .th
|
.table.cbi-section-table .th
|
||||||
{
|
{
|
||||||
|
@ -55,6 +54,11 @@ end
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
<%-
|
||||||
|
local anonclass = (not self.anonymous or self.sectiontitle) and "named" or "anonymous"
|
||||||
|
local titlename = ifattr(not self.anonymous or self.sectiontitle, "data-title", translate("Name"))
|
||||||
|
-%>
|
||||||
|
|
||||||
<fieldset class="cbi-section" id="cbi-<%=self.config%>-<%=self.sectiontype%>">
|
<fieldset class="cbi-section" id="cbi-<%=self.config%>-<%=self.sectiontype%>">
|
||||||
<% if self.title then -%>
|
<% if self.title then -%>
|
||||||
<legend><%=self.title%></legend>
|
<legend><%=self.title%></legend>
|
||||||
|
@ -62,12 +66,7 @@ end
|
||||||
<div class="cbi-section-descr"><%=self.description%></div>
|
<div class="cbi-section-descr"><%=self.description%></div>
|
||||||
<div class="cbi-section-node">
|
<div class="cbi-section-node">
|
||||||
<div class="table cbi-section-table">
|
<div class="table cbi-section-table">
|
||||||
<div class="tr cbi-section-table-titles">
|
<div class="tr cbi-section-table-titles <%=anonclass%>"<%=titlename%>>
|
||||||
<%- if self.sectionhead then -%>
|
|
||||||
<div class="th cbi-section-table-cell"><%=self.sectionhead%></div>
|
|
||||||
<%- else -%>
|
|
||||||
<div class="th"> </div>
|
|
||||||
<%- end -%>
|
|
||||||
<%- for i, k in pairs(self.children) do -%>
|
<%- for i, k in pairs(self.children) do -%>
|
||||||
<div class="th cbi-section-table-cell"<%=width(k)%>>
|
<div class="th cbi-section-table-cell"<%=width(k)%>>
|
||||||
<%-=k.title-%>
|
<%-=k.title-%>
|
||||||
|
@ -76,12 +75,14 @@ end
|
||||||
</div>
|
</div>
|
||||||
<%- local isempty = true
|
<%- local isempty = true
|
||||||
for i, k in ipairs(self:cfgsections()) do
|
for i, k in ipairs(self:cfgsections()) do
|
||||||
section = k
|
local section = k
|
||||||
|
local sectionname = striptags((type(self.sectiontitle) == "function") and self:sectiontitle(section) or k)
|
||||||
|
local sectiontitle = ifattr(sectionname and (not self.anonymous or self.sectiontitle), "data-title", sectionname)
|
||||||
|
|
||||||
isempty = false
|
isempty = false
|
||||||
scope = { valueheader = "cbi/cell_valueheader", valuefooter = "cbi/cell_valuefooter" }
|
scope = { valueheader = "cbi/cell_valueheader", valuefooter = "cbi/cell_valuefooter" }
|
||||||
-%>
|
-%>
|
||||||
<div class="tr cbi-section-table-row" id="cbi-<%=self.config%>-<%=section%>">
|
<div class="tr cbi-section-table-row" id="cbi-<%=self.config%>-<%=section%>"<%=sectiontitle%>>
|
||||||
<div class="th"><%=k%></div>
|
|
||||||
<%-
|
<%-
|
||||||
for k, node in ipairs(self.children) do
|
for k, node in ipairs(self.children) do
|
||||||
node:render(section, scope or {})
|
node:render(section, scope or {})
|
||||||
|
|
Loading…
Reference in a new issue