diff options
author | Filipa Lacerda <filipa@gitlab.com> | 2017-09-26 10:47:19 +0000 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-09-26 10:47:19 +0000 |
commit | b524b9ebc7089f6f00c8874466c2023a47dd07e5 (patch) | |
tree | 49c0cfc6b54ede4ae0299a4445c0252e49209ece /app/assets/javascripts/cycle_analytics/components/stage_code_component.vue | |
parent | ba4f7413023c68958853cd1968730aad39534e51 (diff) | |
download | gitlab-ce-b524b9ebc7089f6f00c8874466c2023a47dd07e5.tar.gz |
Moves cycle analytics components into vue files
Diffstat (limited to 'app/assets/javascripts/cycle_analytics/components/stage_code_component.vue')
-rw-r--r-- | app/assets/javascripts/cycle_analytics/components/stage_code_component.vue | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/app/assets/javascripts/cycle_analytics/components/stage_code_component.vue b/app/assets/javascripts/cycle_analytics/components/stage_code_component.vue new file mode 100644 index 00000000000..e4d62b649e5 --- /dev/null +++ b/app/assets/javascripts/cycle_analytics/components/stage_code_component.vue @@ -0,0 +1,47 @@ +<script> + import userAvatarImage from '../../vue_shared/components/user_avatar/user_avatar_image.vue'; + + export default { + props: { + items: Array, + stage: Object, + }, + components: { + userAvatarImage, + }, + }; +</script> +<template> + <div> + <div class="events-description"> + {{ stage.description }} + <limit-warning :count="items.length" /> + </div> + <ul class="stage-event-list"> + <li v-for="mergeRequest in items" class="stage-event-item"> + <div class="item-details"> + <!-- FIXME: Pass an alt attribute here for accessibility --> + <user-avatar-image :img-src="mergeRequest.author.avatarUrl"/> + <h5 class="item-title merge-merquest-title"> + <a :href="mergeRequest.url"> + {{ mergeRequest.title }} + </a> + </h5> + <a :href="mergeRequest.url" class="issue-link">!{{ mergeRequest.iid }}</a> + · + <span> + {{ s__('OpenedNDaysAgo|Opened') }} + <a :href="mergeRequest.url" class="issue-date">{{ mergeRequest.createdAt }}</a> + </span> + <span> + {{ s__('ByAuthor|by') }} + <a :href="mergeRequest.author.webUrl" class="issue-author-link">{{ mergeRequest.author.name }}</a> + </span> + </div> + <div class="item-time"> + <total-time :time="mergeRequest.totalTime"></total-time> + </div> + </li> + </ul> + </div> +</template> |