diff --git a/components.d.ts b/components.d.ts index e0b6694e9..0e4819a0e 100644 --- a/components.d.ts +++ b/components.d.ts @@ -16,6 +16,9 @@ declare module 'vue' { IconCustomAvatar: typeof import('~icons/custom/avatar')['default'] IconCustomLogo: typeof import('~icons/custom/logo')['default'] IconCustomLogoFill: typeof import('~icons/custom/logo-fill')['default'] + IconCustomNoPermission: typeof import('~icons/custom/no-permission')['default'] + IconCustomNotFound: typeof import('~icons/custom/not-found')['default'] + IconCustomServiceError: typeof import('~icons/custom/service-error')['default'] IconGridiconsFullscreen: typeof import('~icons/gridicons/fullscreen')['default'] IconGridiconsFullscreenExit: typeof import('~icons/gridicons/fullscreen-exit')['default'] IconIcOutlineCheck: typeof import('~icons/ic/outline-check')['default'] diff --git a/src/router/guard/dynamic.ts b/src/router/guard/dynamic.ts index 5ac73c6c2..eb8a69acd 100644 --- a/src/router/guard/dynamic.ts +++ b/src/router/guard/dynamic.ts @@ -35,11 +35,12 @@ export async function createDynamicRouteGuard( next({ path: to.fullPath, replace: true, query: to.query }); return false; } - // 动态路由已经加载,仍然未找到,重定向到not-found - if (to.name === routeName('not-found-page')) { - next({ name: routeName('not-found'), replace: true }); - return false; - } + } + + // 动态路由已经加载,仍然未找到,重定向到not-found + if (to.name === routeName('not-found-page')) { + next({ name: routeName('not-found'), replace: true }); + return false; } return true; diff --git a/src/store/subscribe/theme.ts b/src/store/subscribe/theme.ts index 88ac78b1c..23fb7e591 100644 --- a/src/store/subscribe/theme.ts +++ b/src/store/subscribe/theme.ts @@ -28,6 +28,9 @@ export default function subscribeThemeStore() { } else { removeDarkClass(); } + }, + { + immediate: true, } );