Consolidate user avatar Vue logic
We construct user avatars and user avatar links in different ways across Vue components. We need to DRY that up. Needed as part of https://gitlab.com/gitlab-org/gitlab-ce/issues/30882
MR: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/10718