Add check for visible of elements