安琪酵母(西藏)益生菌信息采集中心智能实验室
longyvfengyun
2023-08-21 66bae94879a1ef44abe28833627564086d74ee13
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
<script setup>
import MapPin from "@/components/MapPin.vue";
 
const props = defineProps({
    info: {
        type: Object,
        default() {
            return {
                num: 99,
                name: "",
                img: {
                    src: "",
                    width: 100,
                    height: 100
                },
                info: {}
            }
        }
    },
    vals: {
        type: Object,
        default() {
            return {
                diff: 0,
                hum: 48.71,
                num: 3,
                tmp: 26.56
            }
        }
    }
});
</script>
 
<template>
    <div class="home-detail">
        <div class="vals-wrapper">
            <div class="vals-name">{{info.name}}</div>
            <div class="vals-item">温度: {{vals.tmp}}℃</div>
            <div class="vals-item">湿度: {{vals.hum}}%RH</div>
            <div class="vals-item">压差: {{vals.diff}}Pa</div>
        </div>
        <div class="home-detail-img">
            <img :src="info.img.src" alt=""/>
        </div>
    </div>
</template>
 
<style lang="less" scoped>
.home-detail {
    position: relative;
    width: 600px;
    text-align: center;
    background-color: #ffffff;
    .vals-wrapper {
        position: absolute;
        top: 8px;
        left: 8px;
        text-align: left;
        padding: 8px;
        background-color: #303133;
        color: #FFFFFF;
        .vals-name {
            text-align: center;
        }
    }
}
.home-detail-img {
    display: inline-block;
    width: 500px;
    img {
        height: auto;
        width: 100%;
    }
}
</style>