diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-11-18 18:06:53 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-11-18 18:06:53 +0000 |
commit | 143f196f8b3c40ceb7e9335a8dcc712b079519b9 (patch) | |
tree | 909df13e1f99b456287934741ba466b506e01129 /app/assets/javascripts/repository/components/last_commit.vue | |
parent | 575ccb036ea14c6a899482a83bd985ffbc992077 (diff) | |
download | gitlab-ce-143f196f8b3c40ceb7e9335a8dcc712b079519b9.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/repository/components/last_commit.vue')
-rw-r--r-- | app/assets/javascripts/repository/components/last_commit.vue | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/app/assets/javascripts/repository/components/last_commit.vue b/app/assets/javascripts/repository/components/last_commit.vue index 26c1f5813f5..70678b0db37 100644 --- a/app/assets/javascripts/repository/components/last_commit.vue +++ b/app/assets/javascripts/repository/components/last_commit.vue @@ -1,5 +1,6 @@ <script> import { GlTooltipDirective, GlLink, GlButton, GlLoadingIcon } from '@gitlab/ui'; +import defaultAvatarUrl from 'images/no_avatar.png'; import { sprintf, s__ } from '~/locale'; import Icon from '../../vue_shared/components/icon.vue'; import UserAvatarLink from '../../vue_shared/components/user_avatar/user_avatar_link.vue'; @@ -83,6 +84,7 @@ export default { this.showDescription = !this.showDescription; }, }, + defaultAvatarUrl, }; </script> @@ -97,6 +99,9 @@ export default { :img-size="40" class="avatar-cell" /> + <span v-else class="avatar-cell user-avatar-link"> + <img :src="$options.defaultAvatarUrl" width="40" height="40" class="avatar s40" /> + </span> <div class="commit-detail flex-list"> <div class="commit-content qa-commit-content"> <gl-link :href="commit.webUrl" class="commit-row-message item-title"> @@ -119,6 +124,9 @@ export default { > {{ commit.author.name }} </gl-link> + <template v-else> + {{ commit.authorName }} + </template> {{ s__('LastCommit|authored') }} <timeago-tooltip :time="commit.authoredDate" tooltip-placement="bottom" /> </div> @@ -132,9 +140,8 @@ export default { </div> <div class="commit-actions flex-row"> <div v-if="commit.signatureHtml" v-html="commit.signatureHtml"></div> - <div class="ci-status-link"> + <div v-if="commit.pipeline" class="ci-status-link"> <gl-link - v-if="commit.pipeline" v-gl-tooltip.left :href="commit.pipeline.detailedStatus.detailsPath" :title="statusTitle" |