summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2020-10-30 21:09:19 +0100
committerGitHub <noreply@github.com>2020-10-30 21:09:19 +0100
commitca86f8d09efccc64dded2d9569395829df06af4e (patch)
tree225c2d2368123ab2d8fab4fe380c847df1959264
parent3415fffbc20c9fcdf18d48f04bb84f0fa6baacdc (diff)
parentb03a508c6c5923e18ade8e8fce256cefbd5ad302 (diff)
Merge pull request #4538 from oldium/fix-titles
luci-base/luci-compat: Replace legend element with h3.
-rw-r--r--modules/luci-base/htdocs/luci-static/resources/form.js4
-rw-r--r--modules/luci-compat/luasrc/view/cbi/nsection.htm4
-rw-r--r--modules/luci-compat/luasrc/view/cbi/nullsection.htm2
-rw-r--r--modules/luci-compat/luasrc/view/cbi/tsection.htm2
-rw-r--r--themes/luci-theme-material/htdocs/luci-static/material/cascade.css3
5 files changed, 8 insertions, 7 deletions
diff --git a/modules/luci-base/htdocs/luci-static/resources/form.js b/modules/luci-base/htdocs/luci-static/resources/form.js
index 568a4abb6..612c8ff94 100644
--- a/modules/luci-base/htdocs/luci-static/resources/form.js
+++ b/modules/luci-base/htdocs/luci-static/resources/form.js
@@ -2219,7 +2219,7 @@ var CBITypedSection = CBIAbstractSection.extend(/** @lends LuCI.form.TypedSectio
});
if (this.title != null && this.title != '')
- sectionEl.appendChild(E('legend', {}, this.title));
+ sectionEl.appendChild(E('h3', {}, this.title));
if (this.description != null && this.description != '')
sectionEl.appendChild(E('div', { 'class': 'cbi-section-descr' }, this.description));
@@ -3138,7 +3138,7 @@ var CBINamedSection = CBIAbstractSection.extend(/** @lends LuCI.form.NamedSectio
});
if (typeof(this.title) === 'string' && this.title !== '')
- sectionEl.appendChild(E('legend', {}, this.title));
+ sectionEl.appendChild(E('h3', {}, this.title));
if (typeof(this.description) === 'string' && this.description !== '')
sectionEl.appendChild(E('div', { 'class': 'cbi-section-descr' }, this.description));
diff --git a/modules/luci-compat/luasrc/view/cbi/nsection.htm b/modules/luci-compat/luasrc/view/cbi/nsection.htm
index faceffeed..511a59b6f 100644
--- a/modules/luci-compat/luasrc/view/cbi/nsection.htm
+++ b/modules/luci-compat/luasrc/view/cbi/nsection.htm
@@ -1,7 +1,7 @@
<% if self:cfgvalue(self.section) then section = self.section %>
<div class="cbi-section">
<% if self.title and #self.title > 0 then -%>
- <legend><%=self.title%></legend>
+ <h3><%=self.title%></h3>
<%- end %>
<% if self.description and #self.description > 0 then -%>
<div class="cbi-section-descr"><%=self.description%></div>
@@ -19,7 +19,7 @@
<% if self.template_addremove then include(self.template_addremove) else -%>
<div class="cbi-section" id="cbi-<%=self.config%>-<%=self.section%>">
<% if self.title and #self.title > 0 then -%>
- <legend><%=self.title%></legend>
+ <h3><%=self.title%></h3>
<%- end %>
<div class="cbi-section-descr"><%=self.description%></div>
<input type="submit" class="btn cbi-button cbi-button-add" name="cbi.cns.<%=self.config%>.<%=self.section%>" value="<%:Add%>" />
diff --git a/modules/luci-compat/luasrc/view/cbi/nullsection.htm b/modules/luci-compat/luasrc/view/cbi/nullsection.htm
index 7230719d1..156f29d18 100644
--- a/modules/luci-compat/luasrc/view/cbi/nullsection.htm
+++ b/modules/luci-compat/luasrc/view/cbi/nullsection.htm
@@ -1,6 +1,6 @@
<div class="cbi-section">
<% if self.title and #self.title > 0 then -%>
- <legend><%=self.title%></legend>
+ <h3><%=self.title%></h3>
<%- end %>
<% if self.description and #self.description > 0 then -%>
<div class="cbi-section-descr"><%=self.description%></div>
diff --git a/modules/luci-compat/luasrc/view/cbi/tsection.htm b/modules/luci-compat/luasrc/view/cbi/tsection.htm
index b7718fa0f..45e51cc69 100644
--- a/modules/luci-compat/luasrc/view/cbi/tsection.htm
+++ b/modules/luci-compat/luasrc/view/cbi/tsection.htm
@@ -1,6 +1,6 @@
<div class="cbi-section" id="cbi-<%=self.config%>-<%=self.sectiontype%>">
<% if self.title and #self.title > 0 then -%>
- <legend><%=self.title%></legend>
+ <h3><%=self.title%></h3>
<%- end %>
<% if self.error_msg and #self.error_msg > 0 then -%>
<div class="cbi-section-error">
diff --git a/themes/luci-theme-material/htdocs/luci-static/material/cascade.css b/themes/luci-theme-material/htdocs/luci-static/material/cascade.css
index f3922c00f..dfa9c5dc0 100644
--- a/themes/luci-theme-material/htdocs/luci-static/material/cascade.css
+++ b/themes/luci-theme-material/htdocs/luci-static/material/cascade.css
@@ -754,7 +754,6 @@ fieldset > fieldset,
border-bottom: thin solid #eee;
}
-.cbi-section > h3:first-child,
.cbi-section > h4:first-child,
.cbi-section > p:first-child,
[data-tab-title] > h3:first-child,
@@ -2547,6 +2546,7 @@ input[name="nslookup"] {
padding: .2rem .5rem;
}
+ .cbi-section > h3:first-child,
.panel-title {
font-size: 1.1rem;
padding-bottom: 1rem;
@@ -2951,6 +2951,7 @@ input[name="nslookup"] {
display: none;
}
+ .cbi-section > h3:first-child,
.panel-title {
font-size: 1.4rem;
padding-bottom: 1rem;