blob: 51704e06b06d3838e5940db091997488de602c3b (
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
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
|
<template>
<div class="home" ref="appRef">
<div class="show">
<div class="top">
<div class="top-left">
<TargetView class="top-left-target"/>
<ImageView class="top-left-iamge"/>
</div>
<SourceView class="top-right"/>
</div>
<NodeView class="bottom"/>
</div>
</div>
</template>
<script>
import TargetView from './module/target.vue'
import ImageView from './module/image.vue'
import SourceView from './module/source.vue'
import NodeView from './module/node.vue'
export default {
name: 'home',
components: { TargetView, ImageView, SourceView, NodeView }
}
</script>
<style lang="less" scoped>
.home {
width: 100%;
height: 100%;
position: relative; /* 确保相对定位生效 */
}
.show {
height: 95%;
width: 95%;
position: absolute; /* 绝对定位 */
top: 50%; /* 向下偏移50% */
left: 50%; /* 向右偏移50% */
transform: translate(-50%, -50%); /* 回移50% */
display: flex;
flex-direction: column;
justify-content: space-between;
}
.top {
height: 49%;
display: flex;
flex-direction: row;
justify-content: space-between;
.top-left {
width: 49.5%;
display: flex;
flex-direction: column;
justify-content: space-between;
.top-left-target {
height: 48%;
background-image:url('../../img/background/homeTargetBg.svg');
background-repeat: no-repeat;
background-size: cover;
}
.top-left-iamge {
height: 48%;
background-image:url('../../img/background/homeTargetBg.svg');
background-repeat: no-repeat;
background-size: cover;
}
}
.top-right {
width: 49.5%;
background-image:url('../../img/background/homeSourceBg.svg');
background-repeat: no-repeat;
background-size: cover;
}
}
.bottom {
height: 49%;
background-image:url('../../img/background/homeNodeBg.svg');
background-repeat: no-repeat;
background-size: cover;
}
</style>
|