<template>
  <div class="header">
    <div class="tabs-nav-warp">
      <div class="tabs-nav" scroll-x="true">
        <div class="ul">
          <div class="li" :class="{'on':activeTab===0}" @click="tabChange(0)">首页</div>
          <div class="li" :class="{'on':activeTab===index+1}" v-for="(item,index) in classifyData" :key="index">
            {{item.categoryName}}
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import {commonMixin} from '../mixin'
export default {
  mixins: [commonMixin],
  data () {
    return {
      activeTab: 0
    }
  },
  computed: {

  },
}
</script>

<style lang="scss" scoped>
  
  .tabs-nav-warp{
    margin-top: 20px;
    padding:0 30px;
    overflow: hidden;
    .tabs-nav{
      .ul{
        display: flex;
        .li{
          flex: 1 0 auto;
          margin-left: 36px;
          font-size: 30px;
          color: #999999;
          position: relative;
          padding-bottom: 18px;
          &:first-child{
            margin-left: 0;
          }
          &.on{
            &:after{
              content: '';
              width: 100%;
              height: 4px;
              background: #C5AA7B;
              position: absolute;
              left: 0;
              bottom: 0;
            }
            font-weight:bold;
          }
        }
      }
    }
  }
</style>
