diff --git a/package.json b/package.json index dd7ed57c8..ec88a94ef 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "calckey", - "version": "12.119.0-calc.9.14", + "version": "12.119.0-calc.9.15", "codename": "aqua", "repository": { "type": "git", diff --git a/packages/client/src/ui/universal.vue b/packages/client/src/ui/universal.vue index d02932673..94d1030e3 100644 --- a/packages/client/src/ui/universal.vue +++ b/packages/client/src/ui/universal.vue @@ -134,20 +134,29 @@ const drawerMenuShowing = ref(false); mainRouter.on('change', () => { drawerMenuShowing.value = false; - const routerState = mainRouter.currentRoute.value.name; - if (routerState === 'index') { +}); + +function updateButtonState(): void { + let routerState = window.location.href; + let secondaryRouterState = mainRouter.currentRoute.value.name; + if (secondaryRouterState != null && secondaryRouterState === 'index') { buttonAnimIndex.value = 0; + return; } - else if (window.location.href.includes('notifications')) { + if (routerState.includes('notifications')) { buttonAnimIndex.value = 1; } - else if (window.location.href.includes('messaging')) { + else if (routerState.includes('messaging')) { buttonAnimIndex.value = 2; } else { - buttonAnimIndex.value = 0; + buttonAnimIndex.value = 3; } -}); +} + +updateButtonState(); + +watch($$(window.location.href), () => (updateButtonState())); document.documentElement.style.overflowY = 'scroll'; @@ -385,6 +394,17 @@ const wallpaper = localStorage.getItem('wallpaper') != null; transition: background 0.1s; } + > .button-wrapper { + > .indicator { + position: absolute; + top: 0; + left: 0; + color: var(--indicator); + font-size: 16px; + animation: blink 1s infinite; + } + } + > .button-wrapper.on { background-color: var(--accentedBg); width: 100%;