Fixed HTML comment bug

Now ignores hidden elements