Implement selection

'selected' class added to component that happens to be selected at the
moment.