Фикс активной иконки сайдбара

This commit is contained in:
megavrilinvv
2022-11-24 17:53:06 +03:00
parent eb470cb2a1
commit 2dad7cea0b

View File

@@ -32,7 +32,7 @@ export default {
pageSettings: [
{
id: "calendar",
path: "#/",
path: "#/calendar",
active: true,
icon: "icon-calendar-2",
},
@@ -69,7 +69,7 @@ export default {
mounted() {
let href = window.location.href.slice(22);
this.pageSettings.forEach((el, index) => {
el.path === href
el.path === href.substr(href.lastIndexOf("#"))
? (this.pageSettings[index].active = true)
: (this.pageSettings[index].active = false);
});