about summary refs log tree commit diff
path: root/src/components/NavLink.vue
diff options
context:
space:
mode:
authorPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2019-08-14 15:29:35 +0200
committerPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2019-08-14 15:29:35 +0200
commitc07a0975cac41351dfbc7dce93718f5da28fdab8 (patch)
treeae136be1720c04ad7a8daa35b13637b3e00f0fda /src/components/NavLink.vue
parent5de4fe426fbd8b74d52768ca17b79ca6c1e15f65 (diff)
downloadpuszcza-c07a0975cac41351dfbc7dce93718f5da28fdab8.tar.gz
puszcza-c07a0975cac41351dfbc7dce93718f5da28fdab8.zip
Update NavBar
Diffstat (limited to 'src/components/NavLink.vue')
-rw-r--r--src/components/NavLink.vue17
1 files changed, 4 insertions, 13 deletions
diff --git a/src/components/NavLink.vue b/src/components/NavLink.vue
index 7a9e8f8..8915585 100644
--- a/src/components/NavLink.vue
+++ b/src/components/NavLink.vue
@@ -1,7 +1,7 @@
 <template>
   <li class="navlink">
-    <a v-if="external" :class="linkClass" target="_blank" :href="link">{{ name }}</a>
-    <router-link v-else :class="linkClass" :to="link">{{ name }}</router-link>
+    <a v-if="external" class="link" target="_blank" rel="”noopener”" :href="link">{{ name }}</a>
+    <router-link v-else class="link" :to="link">{{ name }}</router-link>
   </li>
 </template>
 
@@ -10,16 +10,7 @@ export default {
   props: {
     link: String,
     name: String,
-    external: { type: Boolean, default: false },
-    active: { type: Boolean, default: false }
-  },
-  computed: {
-    linkClass() {
-      if (this.active) {
-        return "link active";
-      }
-      return "link";
-    }
+    external: { type: Boolean, default: false }
   }
 };
 </script>
@@ -50,7 +41,7 @@ export default {
   margin: 10px;
 }
 
-.active {
+.router-link-exact-active {
   background-color: #ececec !important;
 }