shaogen1995 1 rok temu
rodzic
commit
0a32695811
3 zmienionych plików z 18 dodań i 39 usunięć
  1. 5 0
      src/views/HomeView.vue
  2. 6 20
      src/views/MoreContent.vue
  3. 7 19
      src/views/PoemList.vue

+ 5 - 0
src/views/HomeView.vue

@@ -138,6 +138,11 @@ const backFu = () => {
     @touchstart="handletouchstart($event)"
     @touchend="touchEnd($event)"
   >
+    <!-- 预加载字体 -->
+    <div style="opacity: 0;pointer-events: none; font-family: KingHwa_OldSong">
+      123
+    </div>
+
     <!-- 了解更多视频 -->
     <Transition name="fade-in">
       <video

+ 6 - 20
src/views/MoreContent.vue

@@ -1,5 +1,10 @@
 <template>
-  <div class="ZMoveBox">
+  <div
+    v-touch:swipe.left="() => onSwipeChange(1)"
+    v-touch:swipe.right="() => onSwipeChange(-1)"
+    :swipe-options="{ direction: 'horizontal' }"
+    class="ZMoveBox"
+  >
     <div
       class="ZMbox"
       :style="`width: ${pageWidth * pageNum}px; left:-${indexAc * pageWidth}px`"
@@ -95,15 +100,6 @@
         >
       </div>
     </div>
-
-    <!-- 左右滑动盒子 -->
-    <div
-      v-touch:swipe.left="() => onSwipeChange(1)"
-      v-touch:swipe.right="() => onSwipeChange(-1)"
-      class="ROWmove"
-      :swipe-options="{ direction: 'horizontal' }"
-    />
-
     <!-- 指示器 -->
     <ProgressBar
       class="pagination"
@@ -721,15 +717,5 @@ const playVideoFu = (val, flag) => {
   .operation-tipHide {
     opacity: 0;
   }
-
-  // 左右滑动盒子
-  .ROWmove {
-    position: absolute;
-    z-index: 19;
-    width: 100%;
-    height: 100%;
-    top: 0;
-    left: 0;
-  }
 }
 </style>

+ 7 - 19
src/views/PoemList.vue

@@ -1,5 +1,10 @@
 <template>
-  <div class="poem-list-page">
+  <div
+    v-touch:swipe.left="() => onSwipeChange(1)"
+    v-touch:swipe.right="() => onSwipeChange(-1)"
+    class="poem-list-page"
+    :swipe-options="{ direction: 'horizontal' }"
+  >
     <div
       class="RWbox"
       :style="`width: ${domWidth}px; left:-${
@@ -79,14 +84,6 @@
       />
     </div>
 
-    <!-- 左右滑动外层盒子 -->
-    <div
-      v-touch:swipe.left="() => onSwipeChange(1)"
-      v-touch:swipe.right="() => onSwipeChange(-1)"
-      :swipe-options="{ direction: 'horizontal' }"
-      class="SWmove"
-    />
-
     <!-- 选择 时代 -->
     <div
       :class="`RWsBtn ${ageFlga ? 'RWsBtnHide' : ''}`"
@@ -313,15 +310,6 @@ const isMoveFu = (index, num) => {
   height: 100%;
   background-color: #f3f4ef;
 
-  // 滑动模块
-  .SWmove {
-    position: absolute;
-    top: 0;
-    left: 0;
-    width: 100%;
-    height: 100%;
-    z-index: 21;
-  }
   .RWsBtn {
     position: absolute;
     z-index: 22;
@@ -714,7 +702,7 @@ const isMoveFu = (index, num) => {
     }
   }
 
-  .operation-tipHide{
+  .operation-tipHide {
     opacity: 0;
   }
   // 返场视频