1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
<script>
import PipelineStage from './pipeline_stage.vue';
import LegacyPipelineStage from './legacy_pipeline_stage.vue';
/**
* Renders the pipeline stages portion of the pipeline mini graph.
*/
export default {
components: {
LegacyPipelineStage,
PipelineStage,
},
props: {
stages: {
type: Array,
required: true,
},
updateDropdown: {
type: Boolean,
required: false,
default: false,
},
isGraphql: {
type: Boolean,
required: false,
default: false,
},
isMergeTrain: {
type: Boolean,
required: false,
default: false,
},
pipelineEtag: {
type: String,
required: false,
default: '',
},
},
};
</script>
<template>
<div class="gl-display-inline gl-vertical-align-middle">
<div
v-for="stage in stages"
:key="stage.name"
class="pipeline-mini-graph-stage-container dropdown gl-display-inline-block gl-mr-2 gl-my-2 gl-vertical-align-middle"
>
<pipeline-stage
v-if="isGraphql"
:stage-id="stage.id"
:is-merge-train="isMergeTrain"
:pipeline-etag="pipelineEtag"
@miniGraphStageClick="$emit('miniGraphStageClick')"
/>
<legacy-pipeline-stage
v-else
:stage="stage"
:update-dropdown="updateDropdown"
:is-merge-train="isMergeTrain"
@miniGraphStageClick="$emit('miniGraphStageClick')"
/>
</div>
</div>
</template>
|