maintain the hidden attribute on images