Fix weird show/hide behaviour for tags/classes toggle buttons.

References #222