projects
/
oweals
/
luci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
dede2a9
)
luci-base: form.js: toggle inactive CSS class on unsatisfied field cells
author
Jo-Philipp Wich
<jo@mein.io>
Tue, 28 Apr 2020 07:51:54 +0000
(09:51 +0200)
committer
Jo-Philipp Wich
<jo@mein.io>
Thu, 7 May 2020 17:40:49 +0000
(19:40 +0200)
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit
428e3bd6dc0afcc1ff1c2a62506d66bebc59976f
)
modules/luci-base/htdocs/luci-static/resources/form.js
patch
|
blob
|
history
diff --git
a/modules/luci-base/htdocs/luci-static/resources/form.js
b/modules/luci-base/htdocs/luci-static/resources/form.js
index 0e48041cb7fcb330593d8dca9e1c5470aebfaa31..2cd06d1901bb86054cedca3518e26f8f30a4fe0e 100644
(file)
--- a/
modules/luci-base/htdocs/luci-static/resources/form.js
+++ b/
modules/luci-base/htdocs/luci-static/resources/form.js
@@
-1754,6
+1754,10
@@
var CBIAbstractValue = CBIAbstractElement.extend(/** @lends LuCI.form.AbstractVa
if (field && field.classList.contains('hidden') == active) {
field.classList[active ? 'remove' : 'add']('hidden');
+
+ if (dom.matches(field.parentNode, '.td.cbi-value-field'))
+ field.parentNode.classList[active ? 'remove' : 'add']('inactive');
+
return true;
}