Don't trigger event for hidden elements

Passes all tests

[ref] #6