Baozhangchao hace 3 años
padre
commit
00795a6ef3

+ 1
- 1
src/App.vue Ver fichero

@@ -6,7 +6,7 @@
6 6
 </template>
7 7
 
8 8
 <script>
9
-import Honghe from './components/Honghe.vue'
9
+import Honghe from './pages/Honghe.vue'
10 10
 
11 11
 export default {
12 12
   name: 'App',

BIN
src/assets/saverShaerImg/PressImage.png Ver fichero


BIN
src/assets/saverShaerImg/PressLucky.png Ver fichero


BIN
src/assets/saverShaerImg/back.png Ver fichero


BIN
src/assets/saverShaerImg/haibao.jpg Ver fichero


BIN
src/assets/saverShaerImg/shaerLucky.png Ver fichero


BIN
src/assets/saverShaerImg/shaerLuckyRed.png Ver fichero


+ 0
- 91
src/components/ImageTrans.vue Ver fichero

@@ -1,91 +0,0 @@
1
-<template>
2
-  <div class="card-wrapper">
3
-    <div :class="`card ${classDivAA?'flipped':''}`" @click="transform">
4
-      <div class="back">
5
-        <img src="../assets/popupImg/popuBody.jpg" alt />
6
-      </div>
7
-      <div class="front">
8
-        <img src="../assets/popupImg/backImag.jpg" alt />
9
-      </div>
10
-    </div>
11
-  </div>
12
-</template>
13
-
14
-<script>
15
-export default {
16
-  name: 'ImageTrans',
17
-  props: {
18
-    classDiv: {
19
-      type: Boolean
20
-    }
21
-  },
22
-  data() {
23
-    return {
24
-      classDivAA: false
25
-    }
26
-  },
27
-
28
-  mounted() {
29
-    if (this.classDiv) {
30
-      this.transform()
31
-    }
32
-  },
33
-  methods: {
34
-    transform() {
35
-      // this.classDiv = true
36
-      console.log(
37
-        '🚀 ~ file: ImageTrans.vue ~ line 34 ~ transform ~  this.classDiv',
38
-        // this.classDiv
39
-        setTimeout(() => {
40
-          this.classDivAA = true
41
-        }, 0)
42
-      )
43
-    }
44
-  }
45
-}
46
-</script>
47
-
48
-<style scoped>
49
-.card-wrapper {
50
-  perspective: 600px;
51
-}
52
-
53
-img {
54
-  width: 48vw;
55
-}
56
-.card {
57
-  position: relative;
58
-  width: 320px;
59
-  height: 320px;
60
-  margin: 200px auto;
61
-  color: #fff;
62
-  font-size: 3em;
63
-  text-align: center;
64
-  line-height: 320px;
65
-  box-shadow: 0 20px 20px rgba(50, 50, 50, 0.2);
66
-  transform-style: preserve-3d;
67
-  transition: all 0.8s ease;
68
-}
69
-
70
-.card > div {
71
-  position: absolute;
72
-  top: 0;
73
-  left: 0;
74
-  width: 100%;
75
-  height: 100%;
76
-
77
-  /* 背面不显示 */
78
-  backface-visibility: hidden;
79
-}
80
-
81
-.flipped {
82
-  transform: rotateY(180deg);
83
-}
84
-
85
-.card .front {
86
-}
87
-
88
-.card .back {
89
-  transform: rotateY(180deg);
90
-}
91
-</style>

+ 1
- 4
src/components/Popup.vue Ver fichero

@@ -10,7 +10,6 @@
10 10
             <div class="card-wrapper">
11 11
               <div :class="`dialog-popuImag ${classDivAA?'flipped':''}`">
12 12
                 <!-- <img src="../assets/popupImg/popuBody.jpg" alt /> -->
13
-                <!-- <ImageTrans :classDiv="show" /> -->
14 13
                 <div class="back">
15 14
                   <img style="width: 180px; height:492px" src="../assets/popupImg/popuBody.jpg" alt />
16 15
                 </div>
@@ -54,9 +53,7 @@
54 53
 <script>
55 54
 export default {
56 55
   name: 'Popup',
57
-  components: {
58
-    ImageTrans: () => import('@/components/ImageTrans.vue')
59
-  },
56
+
60 57
   props: {
61 58
     show: {
62 59
       type: Boolean,

+ 0
- 42
src/components/SaveShare.vue Ver fichero

@@ -1,42 +0,0 @@
1
-<template>
2
-  <div>
3
-    <div>
4
-      <div v-if="item==0">
5
-        <h1>未中奖</h1>
6
-      </div>
7
-      <div v-else>
8
-        <h1>中奖页面</h1>
9
-      </div>
10
-    </div>
11
-  </div>
12
-</template>
13
-
14
-<script>
15
-export default {
16
-  name: '',
17
-
18
-  data() {
19
-    return {
20
-      item: null
21
-    }
22
-  },
23
-
24
-  watch: {
25
-    '$route.query.states': {
26
-      handler(val) {
27
-        console.log('🚀 ~ file: SaveShare.vue ~ line 24 ~ val', val)
28
-
29
-        if (val) {
30
-          this.item = val
31
-        } else {
32
-          this.$router.go(-1)
33
-        }
34
-      },
35
-      immediate: true // 页面加载时就启动
36
-    }
37
-  }
38
-}
39
-</script>
40
-
41
-<style>
42
-</style>

src/components/Honghe.vue → src/pages/Honghe.vue Ver fichero


+ 134
- 0
src/pages/SaveShare.vue Ver fichero

@@ -0,0 +1,134 @@
1
+<template>
2
+  <div style="background-color:#c1172d; height:100vh; width:100%;">
3
+    <div
4
+      class="backhome"
5
+      :style="`background:url('${backimg}');background-size: 100% auto;`"
6
+      @click="()=>{}"
7
+    ></div>
8
+
9
+    <div>
10
+      <div v-if="item==0">
11
+        <!-- 领取屏保 -->
12
+        <div class="outer3 flex-col">
13
+          <div class="haibao">
14
+            <img class="haibao" src="../assets/saverShaerImg/haibao.jpg" alt />
15
+          </div>
16
+          <div class="mod2 flex-col">
17
+            <div class="block1 flex-col">
18
+              <div class="section1 flex-col" :style="`background-image: url(${shaerBut});`"></div>
19
+              <span :style="`background-image: url(${pressImage});`" class="info2"></span>
20
+            </div>
21
+          </div>
22
+        </div>
23
+      </div>
24
+      <div v-else>
25
+        <!-- 挂历 -->
26
+        <div class="main5 flex-col" :style="`background-image: url(${shaerButRed});`"></div>
27
+      </div>
28
+    </div>
29
+  </div>
30
+</template>
31
+
32
+<script>
33
+export default {
34
+  name: '',
35
+
36
+  data() {
37
+    return {
38
+      item: null,
39
+      backimg: require('../assets/saverShaerImg/back.png'),
40
+      shaerBut: require('../assets/saverShaerImg/shaerLucky.png'),
41
+      pressImage: require('../assets/saverShaerImg/PressImage.png'),
42
+      shaerButRed: require('../assets/saverShaerImg/shaerLuckyRed.png')
43
+    }
44
+  },
45
+
46
+  watch: {
47
+    '$route.query.states': {
48
+      handler(val) {
49
+        console.log('🚀 ~ file: SaveShare.vue ~ line 24 ~ val', val)
50
+
51
+        if (val) {
52
+          this.item = val
53
+        } else {
54
+          this.$router.go(-1)
55
+        }
56
+      },
57
+      immediate: true // 页面加载时就启动
58
+    }
59
+  }
60
+}
61
+</script>
62
+
63
+<style lang="less" scoper>
64
+.flex-col {
65
+  display: flex;
66
+  flex-direction: column;
67
+}
68
+.backhome {
69
+  width: 75px;
70
+  height: 42px;
71
+  position: fixed;
72
+  left: 1rem;
73
+  top: 1rem;
74
+  z-index: 19;
75
+  background-repeat: no-repeat;
76
+}
77
+.outer3 {
78
+  width: 100vw;
79
+  height: 100vh;
80
+  justify-content: flex-end;
81
+  .haibao {
82
+    width: 100vw;
83
+    position: absolute;
84
+    left: 0;
85
+    top: 0;
86
+  }
87
+  .mod2 {
88
+    z-index: 35;
89
+    height: 210px;
90
+    background-image: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.6));
91
+    width: 100vw;
92
+    justify-content: flex-end;
93
+    padding-bottom: 33px;
94
+    align-items: center;
95
+    .block1 {
96
+      width: 180px;
97
+      height: 113px;
98
+      .section1 {
99
+        height: 48px;
100
+        border-radius: 8px;
101
+        background-size: 100% auto;
102
+        background-color: #fff;
103
+        width: 180px;
104
+        justify-content: center;
105
+        align-items: center;
106
+        border: 0;
107
+      }
108
+      .info2 {
109
+        width: 152px;
110
+        height: 54px;
111
+        display: block;
112
+        color: #fff;
113
+        text-align: center;
114
+        align-self: center;
115
+        margin-top: 12px;
116
+        background-size: 100% auto;
117
+        background-repeat: no-repeat;
118
+      }
119
+    }
120
+  }
121
+}
122
+
123
+.main5 {
124
+  height: 48px;
125
+  border-radius: 8px;
126
+  margin-top: 11px;
127
+  width: 343px;
128
+  background-color: #c1172d;
129
+  border: 0;
130
+  position: fixed;
131
+  z-index: 15;
132
+  bottom: 5vh;
133
+}
134
+</style>

+ 3
- 8
src/router/index.js Ver fichero

@@ -2,8 +2,8 @@
2 2
 
3 3
 import Vue from 'vue'
4 4
 import Router from 'vue-router'
5
-import Honghe from '@/components/Honghe'
6
-import SaveShare from '@/components/SaveShare'
5
+import Honghe from '../pages/Honghe.vue'
6
+import SaveShare from '../pages/SaveShare.vue'
7 7
 // import Login from '@/Login.vue'
8 8
 
9 9
 Vue.use(Router)
@@ -12,12 +12,7 @@ export default new Router({
12 12
 
13 13
 
14 14
   routes: [
15
-    //Loading
16
-    // {
17
-    //   path: '/',
18
-    //   name: 'Login',
19
-    //   component: Login
20
-    // },
15
+
21 16
     //面页
22 17
     {
23 18
       path: '/',