Tim_Walker 1 éve
szülő
commit
08b075796d
2 módosított fájl, 0 hozzáadás és 70 törlés
  1. 0 64
      src/components/tab/index.vue
  2. 0 6
      src/pages/user/coupon/index.vue

+ 0 - 64
src/components/tab/index.vue

@@ -1,64 +0,0 @@
-<template>
-  <view>
-    <view class="tabs">
-      <view class="tab" :class="{ active: currentIndex === index }" v-for="(item, index) in navList" :key="index"
-        @tap="onClickNav(index)">
-        <view class="name-item">{{ item.name }}</view>
-      </view>
-    </view>
-    <slot :name="navList[currentIndex].name"></slot>
-  </view>
-</template>
-
-<script>
-export default {
-  props: {
-    navList: {
-      type: Array,
-      default() {
-        return [];
-      },
-    },
-  },
-  data() {
-    return {
-      currentIndex: 0,
-    };
-  },
-  methods: {
-    onClickNav(index) {
-      this.currentIndex = index;
-    },
-  },
-};
-</script>
-
-<style scoped lang="scss">
-.tabs {
-  display: flex;
-  justify-content: space-around;
-  font-size: 28rpx;
-  color: #ffffff;
-  background-color: #347caf;
-
-  .name-item {
-    padding: 20rpx 0;
-    color: #ffffff;
-  }
-}
-
-.active {
-  font-weight: bold;
-  position: relative;
-
-  .name-item::after {
-    content: '';
-    height: 2px;
-    width: 100%;
-    background-color: #ffffff;
-    position: absolute;
-    bottom: 0;
-    left: 0;
-  }
-}
-</style>

+ 0 - 6
src/pages/user/coupon/index.vue

@@ -1,7 +1,5 @@
 <template>
   <view class="container">
-    <tab :navList="list" />
-
     <!-- 优惠券的可用和失效 -->
     <view class="use">
       <u-tabs
@@ -50,11 +48,7 @@
 </template>
 
 <script>
-import tab from '@/components/tab';
 export default {
-  components: {
-    tab,
-  },
   data() {
     return {
       list: [