Fix language dropdown
This commit is contained in:
parent
dfc20e90df
commit
71029c7955
|
@ -62,14 +62,8 @@
|
||||||
this.showMenu = !this.showMenu;
|
this.showMenu = !this.showMenu;
|
||||||
},
|
},
|
||||||
|
|
||||||
buildLanguageRoute(locale: string | number) {
|
buildLanguageRoute (locale: string | number) {
|
||||||
const paths = this.$route.fullPath.split('/')
|
return '/' + locale
|
||||||
|
|
||||||
if (paths.length > 0 && Object.prototype.hasOwnProperty.call(this.availableLanguages, paths[0])) {
|
|
||||||
return '/' + locale + '/' + paths.slice(1).join('/')
|
|
||||||
}
|
|
||||||
|
|
||||||
return '/' + locale + this.$route.fullPath
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@ -85,6 +79,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu {
|
.menu {
|
||||||
|
z-index: 10;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
background-clip: padding-box;
|
background-clip: padding-box;
|
||||||
border: 1px solid rgba(0,0,0,.15);
|
border: 1px solid rgba(0,0,0,.15);
|
||||||
|
|
Loading…
Reference in New Issue