<template>
  <view class="index-box">
    <index-nav @setTabNum="setTabNum"></index-nav>
    <view class="list-box">
      <view class="box-one" v-if="tabNum===0">
        <slide-item></slide-item>
      </view>
      <view class="box-two" v-else-if="tabNum===1">
        <attachment-list></attachment-list>
      </view>
      <view class="box-three" v-else>
        <attachment-list></attachment-list>
      </view>
    </view>
  </view>
</template>

<script>
import IndexNav from "@/pages/index/model/index-nav";
import AttachmentList from "@/pages/index/model/attachment-list";
import SlideItem from "@/pages/index/model/slide-item";
export default {
  components: {SlideItem, AttachmentList, IndexNav},
  data() {
    return {
      tabNum:0
    }
  },

  methods: {
    setTabNum(tabNum){
      this.tabNum=tabNum
    }
  }
}
</script>

<style scoped lang="scss">
.index-box{
  overflow: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: none;
  height: 100vh ;
  width: 100vw;
  .box-one{

  }

}

</style>
