forked from Tokyo-Metro-Gov/covid19
-
Notifications
You must be signed in to change notification settings - Fork 3
/
DevelopmentModeMark.vue
59 lines (55 loc) · 1 KB
/
DevelopmentModeMark.vue
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
<template>
<div v-if="isDevelopmentMode" class="DevelopmentModeMark">
開発中(development mode)
<a
href="https://stopcovid19.city.shizuoka.lg.jp/"
target="_blank"
rel="noopener noreferrer"
>
公開サイトへ
</a>
</div>
</template>
<style lang="scss">
.DevelopmentModeMark {
position: fixed;
bottom: 0;
left: 0;
font-size: 12px;
z-index: 1;
width: 100%;
height: 20px;
text-align: center;
background-color: #ffe200;
color: #4d4d4d;
line-height: 20px;
opacity: 0.9;
// mobile view
@include lessThan($small) {
height: 40px;
a {
display: block;
}
}
}
</style>
<script>
export default {
name: 'DevelopmentModeMark',
props: {
value: {
type: String,
required: false,
default: ''
}
},
computed: {
isDevelopmentMode: () => {
if (process && process.env && process.env.GENERATE_ENV) {
return process.env.GENERATE_ENV === 'development'
}
return false
}
}
}
</script>