Welcome to mirror list, hosted at ThFree Co, Russian Federation.

environment_external_url.vue « components « environments « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: af537cfb991a5500e0e88079862cdc6ec7b1fc7d (plain)
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
<script>
import { GlTooltipDirective } from '@gitlab/ui';
import Icon from '~/vue_shared/components/icon.vue';
import { s__ } from '~/locale';

/**
 * Renders the external url link in environments table.
 */
export default {
  components: {
    Icon,
  },
  directives: {
    GlTooltip: GlTooltipDirective,
  },
  props: {
    externalUrl: {
      type: String,
      required: true,
    },
  },
  computed: {
    title() {
      return s__('Environments|Open live environment');
    },
  },
};
</script>
<template>
  <a
    v-gl-tooltip
    :title="title"
    :aria-label="title"
    :href="externalUrl"
    class="btn external-url"
    target="_blank"
    rel="noopener noreferrer nofollow"
  >
    <icon name="external-link" />
  </a>
</template>