luci-base: form.js: toggle inactive CSS class on unsatisfied field cells
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
daa318c1b2
commit
428e3bd6dc
1 changed files with 4 additions and 0 deletions
|
@ -1777,6 +1777,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;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue