Browse Source

头部导航栏修改

yangc 8 years ago
parent
commit
3f9e02033f
1 changed files with 7 additions and 6 deletions
  1. 7 6
      components/default/Header.vue

+ 7 - 6
components/default/Header.vue

@@ -33,11 +33,7 @@
                 </li>
               </ul>
             </div>
-            <nuxt-link class="item" :to="'/'">商城首页</nuxt-link>
-            <!--<nuxt-link class="item" to="/user">买家中心</nuxt-link>
-            <nuxt-link class="item" to="/vendor">卖家中心</nuxt-link>-->
-            <!--<a class="item" :href="url + '/user'">买家中心</a>
-            <a class="item" :href="url + '/vendor'">卖家中心</a>-->
+            <nuxt-link class="item" :to="'/'" v-show="showHome">商城首页</nuxt-link>
             <a class="item" href="/user#/index">买家中心</a>
             <a class="item" @click="toVendor">卖家中心</a>
           </template>
@@ -47,7 +43,6 @@
             <nuxt-link class="item" :to="'/'">商城首页</nuxt-link>
           </template>
           <nuxt-link class="item" to="/help/home">帮助中心</nuxt-link>
-          <!--<a class="item" href="/help#/home">帮助中心</a>-->
         </div>
       </div>
     </nav>
@@ -75,6 +70,9 @@
       },
       url () {
         return this.$store.state.option.url
+      },
+      showHome () {
+        return this.$route.path && this.$route.path !== '/' && this.$route.path !== ''
       }
     },
     methods: {
@@ -167,6 +165,9 @@
   .header .navbar .navbar-container .navbar-right .dropdown .dropdown-menu .menu-item{
     height: 30px;
   }
+  .header .navbar .navbar-container .navbar-right >a:hover {
+    font-weight: bold;
+  }
   .dropdown-menu>li>a{
     padding: 0;
     line-height: 30px;