diff --git a/index.html b/index.html
index c884133..9e5009a 100644
--- a/index.html
+++ b/index.html
@@ -5,7 +5,7 @@
-
Metavatar-慧影
+ Metavatar
diff --git a/src/router/index.ts b/src/router/index.ts
index 3601e29..386d28f 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -1,4 +1,4 @@
-import { createRouter, createWebHashHistory, RouteRecordRaw } from "vue-router";
+import { createRouter, createWebHashHistory, RouteRecordRaw, useRoute } from "vue-router";
import { getCurrentInstance } from "vue";
export const Layout = () => import("@/layout/index.vue");
@@ -219,7 +219,9 @@ const router = createRouter({
// 2023-5-23 添加平滑滚动 YWQ
scrollBehavior: () => ({ behavior: "smooth", left: 0, top: 0 }),
});
-
+router.beforeEach((to, from) => {
+ document.title = 'Metavatar-' + (to.query.p || from.query.p || localStorage.getItem("title") || '')
+})
/**
* 重置路由
*/
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index eaa0d2a..2553ee3 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -19,7 +19,7 @@
>
{{
- $t("login.title") + " " + $t("login.login")
+ title + " " + $t("login.login")
}}