mirror of
https://github.com/wled/WLED.git
synced 2025-07-21 17:56:33 +00:00
Fix search function behavior when filter is active
This commit is contained in:
parent
155c12f657
commit
698f5f951e
@ -2722,10 +2722,13 @@ function search(f,l=null)
|
||||
if (!l) return;
|
||||
|
||||
// clear filter if searching in fxlist
|
||||
if (l === 'fxlist' && f === document.activeElement) {
|
||||
if (l === 'fxlist' && f.value !== '') {
|
||||
gId("filters").querySelectorAll("input[type=checkbox]").forEach((e)=>{e.checked=false;});
|
||||
}
|
||||
|
||||
// do not search if filter is active
|
||||
if (gId("filters").querySelectorAll("input[type=checkbox]:checked").length) return;
|
||||
|
||||
var el = gId(l).querySelectorAll('.lstI');
|
||||
// filter list items but leave (Default & Solid) always visible
|
||||
for (i = (l==='pcont'?0:1); i < el.length; i++) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user