princeLee 4 лет назад
Родитель
Сommit
3321e0d3b7
1 измененных файлов с 4 добавлено и 1 удалено
  1. 4 1
      src/components/newLayout/Head.vue

+ 4 - 1
src/components/newLayout/Head.vue

@@ -3,7 +3,7 @@
     <div class="head-logo">
       <svg-icon icon-class="zhihui-logo" @click="topHome()" />
     </div>
-    <div v-for="item in headList" :key="item.path" class="nav-tag" @click="changeNavTag(item)">
+    <div v-for="item in headList" :key="item.path" class="nav-tag" :class="{'active-nav-tag':activeNavTag === item.name}" @click="changeNavTag(item)">
       <div v-if="item.icon" class="icon">
         <div v-show="notice && item.name.search(/个人工作台/)>=0" class="if-notice" />
         <svg-icon :icon-class="item.icon" />
@@ -171,6 +171,9 @@ export default {
     transform: translateY(-50%);
   }
 }
+.active-nav-tag {
+  background-color: #1E89F7;
+}
 .nav-tag-type {
   margin-top: auto;
   color: #ffffff;