GrowCard.vue
2.53 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<template>
<div class="md:flex justify-between">
<template v-for="(item, index) in growCardList" :key="item.title">
<div
class="growCardItem md:w-1/3 w-full !md:mt-0 !mt-4 bg-white"
:class="index === 0 ? '!md:ml-0' : '!md:ml-4'"
>
<div
class="
growCardItem-top
border border-solid border-t-0 border-r-0 border-l-0 border-b-1
dark:border-#ccc
light:border-#F2F2F5
"
>
<img :src="item.imgUrl" style="width: 5rem; height: 5rem" />
<div class="growCardItem-right">
<div class="flex justify-between ml-3">
<div style="font-size: 1.625rem; color: #333">{{ item.value }}</div>
<img src="../../../../assets/images/tip.png" style="width: 1.4rem; height: 1.4rem" />
</div>
<div class="ml-3">{{ item.title }}</div>
<div class="ml-1.5 mt-3 flex flex-nowrap" style="width: 15rem" v-if="item.offLine">
<div class="count">
<img
src="../../../../assets/images/online.png"
style="width: 0.6rem; height: 0.6rem"
class="mr-1"
/>
在线 {{ item.onLine }}
</div>
<div class="count">
<img
src="../../../../assets/images/offline.png"
style="width: 0.6rem; height: 0.6rem"
class="mr-1"
/>
离线 {{ item.offLine }}
</div>
<div class="count">
<img
src="../../../../assets/images/inactive.png"
style="width: 0.6rem; height: 0.6rem"
class="mr-1"
/>
未激活 {{ item.inactive }}
</div>
</div>
</div>
</div>
<div class="growCardItem-bottom"> 今日新增 {{ item.newDay }}</div>
</div>
</template>
</div>
</template>
<script lang="ts" setup>
import { growCardList } from '../data';
</script>
<style scoped lang="less">
.growCardItem {
height: 11.187rem;
color: #666;
.growCardItem-top {
display: flex;
margin: 1.25rem;
padding-bottom: 0.625rem;
.growCardItem-right {
width: 18.75rem;
.count {
display: flex;
font-size: 0.75rem;
align-items: center;
margin-left: 0.5rem;
}
}
}
.growCardItem-bottom {
margin-left: 1.25rem;
}
}
</style>