preserve shown/hidden state for class attributes