|
@@ -1,3 +1,139 @@
|
|
1
|
+<!-- home -->
|
1
|
2
|
<template>
|
2
|
|
- <div></div>
|
|
3
|
+ <div class="apartment">
|
|
4
|
+ <pure-image :bg-image="require('@/assets/images/apartment/1.jpg')"></pure-image>
|
|
5
|
+ <apartment-navi class="apartment-navi" @goto="handleGoto" />
|
|
6
|
+ <div v-for="(item, index) in list" :key="item.image">
|
|
7
|
+ <modal v-if="visible[index]" class="apartment-modal">
|
|
8
|
+ <pure-image :bg-image="item.image"></pure-image>
|
|
9
|
+ <div class="back-sign" @click="cancelShow(index)">
|
|
10
|
+ <img :src="require('@/assets/images/apartment/backSign.png')" alt />
|
|
11
|
+ </div>
|
|
12
|
+ </modal>
|
|
13
|
+ </div>
|
|
14
|
+ <modal v-if="visible[5]" class="apartment-modal">
|
|
15
|
+ <swiper-image :list="houseList"></swiper-image>
|
|
16
|
+ <div class="back-sign" @click="cancelShow(5)">
|
|
17
|
+ <img :src="require('@/assets/images/apartment/backSign.png')" alt />
|
|
18
|
+ </div>
|
|
19
|
+ </modal>
|
|
20
|
+ </div>
|
3
|
21
|
</template>
|
|
22
|
+
|
|
23
|
+<script>
|
|
24
|
+export default {
|
|
25
|
+ components: {
|
|
26
|
+ PureImage: () => import('./components/PureImage.vue'),
|
|
27
|
+ SwiperImage: () => import('./components/SwiperImage.vue'),
|
|
28
|
+ ApartmentNavi: () => import('./components/ApartmentNavi.vue')
|
|
29
|
+ },
|
|
30
|
+ data() {
|
|
31
|
+ return {
|
|
32
|
+ visible: Array(6).fill(false),
|
|
33
|
+ list: [
|
|
34
|
+ {
|
|
35
|
+ image: require('@/assets/images/apartment/2-2.jpg'),
|
|
36
|
+ color: '#f0f0f0'
|
|
37
|
+ },
|
|
38
|
+ {
|
|
39
|
+ image: require('@/assets/images/apartment/3-1.jpg'),
|
|
40
|
+ color: '#f0f0f0'
|
|
41
|
+ },
|
|
42
|
+ {
|
|
43
|
+ image: require('@/assets/images/apartment/4-1.jpg'),
|
|
44
|
+ color: '#f0f0f0'
|
|
45
|
+ },
|
|
46
|
+ {
|
|
47
|
+ image: require('@/assets/images/apartment/6-1.jpg'),
|
|
48
|
+ color: '#f0f0f0'
|
|
49
|
+ },
|
|
50
|
+ {
|
|
51
|
+ image: require('@/assets/images/apartment/5-1.jpg'),
|
|
52
|
+ color: '#f0f0f0'
|
|
53
|
+ }
|
|
54
|
+ ],
|
|
55
|
+ houseList: [
|
|
56
|
+ {
|
|
57
|
+ image: require('@/assets/images/apartment/7-1.jpg'),
|
|
58
|
+ color: '#f0f0f0'
|
|
59
|
+ },
|
|
60
|
+ {
|
|
61
|
+ image: require('@/assets/images/apartment/7-2.jpg'),
|
|
62
|
+ color: '#f0f0f0'
|
|
63
|
+ },
|
|
64
|
+ {
|
|
65
|
+ image: require('@/assets/images/apartment/7-3.jpg'),
|
|
66
|
+ color: '#f0f0f0'
|
|
67
|
+ },
|
|
68
|
+ {
|
|
69
|
+ image: require('@/assets/images/apartment/7-4.jpg'),
|
|
70
|
+ color: '#f0f0f0'
|
|
71
|
+ },
|
|
72
|
+ {
|
|
73
|
+ image: require('@/assets/images/apartment/7-5.jpg'),
|
|
74
|
+ color: '#f0f0f0'
|
|
75
|
+ },
|
|
76
|
+ {
|
|
77
|
+ image: require('@/assets/images/apartment/7-6.jpg'),
|
|
78
|
+ color: '#f0f0f0'
|
|
79
|
+ },
|
|
80
|
+ {
|
|
81
|
+ image: require('@/assets/images/apartment/7-7.jpg'),
|
|
82
|
+ color: '#f0f0f0'
|
|
83
|
+ },
|
|
84
|
+ {
|
|
85
|
+ image: require('@/assets/images/apartment/7-8.jpg'),
|
|
86
|
+ color: '#f0f0f0'
|
|
87
|
+ }
|
|
88
|
+ ]
|
|
89
|
+ }
|
|
90
|
+ },
|
|
91
|
+
|
|
92
|
+ methods: {
|
|
93
|
+ handleGoto(inx) {
|
|
94
|
+ // inx 是从1开始的
|
|
95
|
+ this.$set(this.visible, inx - 1, true)
|
|
96
|
+ },
|
|
97
|
+ cancelShow(inx) {
|
|
98
|
+ this.$set(this.visible, inx, false)
|
|
99
|
+ }
|
|
100
|
+ }
|
|
101
|
+}
|
|
102
|
+</script>
|
|
103
|
+
|
|
104
|
+<style lang="scss" scoped>
|
|
105
|
+.apartment {
|
|
106
|
+ height: 100%;
|
|
107
|
+ position: relative;
|
|
108
|
+
|
|
109
|
+ .apartment-modal {
|
|
110
|
+ position: absolute;
|
|
111
|
+ width: 100%;
|
|
112
|
+ height: 100%;
|
|
113
|
+ bottom: 0;
|
|
114
|
+ left: 0;
|
|
115
|
+ }
|
|
116
|
+
|
|
117
|
+ .apartment-navi {
|
|
118
|
+ position: absolute;
|
|
119
|
+ width: 100%;
|
|
120
|
+ height: 40%;
|
|
121
|
+ bottom: 0;
|
|
122
|
+ left: 0;
|
|
123
|
+ }
|
|
124
|
+
|
|
125
|
+ .back-sign {
|
|
126
|
+ position: absolute;
|
|
127
|
+ z-index: 500;
|
|
128
|
+ right: 10px;
|
|
129
|
+ bottom: 20px;
|
|
130
|
+ width: 96px;
|
|
131
|
+ height: 78px;
|
|
132
|
+
|
|
133
|
+ img {
|
|
134
|
+ width: 100%;
|
|
135
|
+ height: 100%;
|
|
136
|
+ }
|
|
137
|
+ }
|
|
138
|
+}
|
|
139
|
+</style>
|