diff --git a/app.vue b/app.vue
index 1e01a95184359bed0c1d2252664a59052f0cab05..6a0956c9c20cef07bd8c465aa576a4d0bd55b02d 100644
--- a/app.vue
+++ b/app.vue
@@ -7,7 +7,11 @@
diff --git a/components/i/Sign.vue b/components/i/Sign.vue
index 42e2cef09362273dc9374b6f8b2b2573c4da8d6a..cdeee85e9bd477c075f0d64e0802b74cff277697 100644
--- a/components/i/Sign.vue
+++ b/components/i/Sign.vue
@@ -15,19 +15,10 @@
color="gray"
size="md"
@click="handleGetSignUrl('gitcode')"
- disabled
>
使用 GitCode 登录
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
+
diff --git a/stores/user.js b/stores/user.js
index 70b78b8230851495498661b821f1c751dfae1361..3b6c64a4d007d638c818ad0c28f876bed1cf2b2c 100644
--- a/stores/user.js
+++ b/stores/user.js
@@ -19,5 +19,11 @@ export const useUserStore = defineStore('user', () => {
userInfo.value = null
}
- return { $info, $isSignIn, $signOut }
+ async function $updateUserInfo () {
+ if (!token.value) return
+ const { data } = await useRequest('/v1/user/user_info')
+ userInfo.value = JSON.stringify(data.value.data)
+ }
+
+ return { $info, $isSignIn, $signOut, $updateUserInfo }
})