adds classnames to objects