Move variant selector object into a jquery plugin