Generate classnames based on a selector