Using devtools protocol the el.style check misses and it ends up thinking it's a single element. This means it marks the same first match hidden multiple times.
By using querySelectorAll first we will be able to capture all valid selection if we have matches. If only one is selected we can still iterate over it that one time.
If we come back into this we wont try to execute again if we have seen the selector.
Using devtools protocol the
el.style
check misses and it ends up thinking it's a single element. This means it marks the same first match hidden multiple times.By using querySelectorAll first we will be able to capture all valid selection if we have matches. If only one is selected we can still iterate over it that one time.
If we come back into this we wont try to execute again if we have seen the selector.