refactor select2 to be able to extend it better