feat: 头像显示

This commit is contained in:
2026-06-04 14:16:19 +08:00
parent 8ab14e88f1
commit aa672194ea
4 changed files with 32 additions and 12 deletions

View File

@@ -51,7 +51,9 @@
<div class="info">
<img src="@/assets/images/profile-content-bg.jpg" alt="" />
<div class="content">
<div class="profile"></div>
<div class="profile">
<img class="profile-avatar" :src="userInfoStore.state.userInfo.avatarUrl" alt="" />
</div>
<div class="name">
{{ $t('MainHeader.HiName', { name: userInfo.username }) }}
</div>
@@ -286,7 +288,12 @@
width: 5rem;
height: 5rem;
border-radius: 50%;
background: #cfcfcf;
.profile-avatar{
width: 100%;
height: 100%;
border-radius: 50%;
object-fit: cover;
}
}
> .name {
font-size: 1.4rem;

View File

@@ -119,10 +119,6 @@
loadUserProfile
} = useSettingsForm({ t, locale })
// watch(locale, () => {
// loadUserProfile()
// })
onMounted(() => {
loadUserProfile()
})