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
|
<script>
import { GlIcon, GlLink } from '@gitlab/ui';
export default {
name: 'SidebarDetailRow',
components: {
GlIcon,
GlLink,
},
props: {
title: {
type: String,
required: false,
default: '',
},
value: {
type: String,
required: true,
},
helpUrl: {
type: String,
required: false,
default: '',
},
},
computed: {
hasTitle() {
return this.title.length > 0;
},
hasHelpURL() {
return this.helpUrl.length > 0;
},
},
};
</script>
<template>
<p class="gl-display-flex gl-justify-content-space-between gl-mb-2">
<span v-if="hasTitle"
><b>{{ title }}:</b> {{ value }}</span
>
<gl-link v-if="hasHelpURL" :href="helpUrl" target="_blank">
<gl-icon name="question-o" />
</gl-link>
</p>
</template>
|