add select/deselect link container and refactor
refactor select/deselect functionality