mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-14 13:26:44 +08:00
他们主页,头像抖动问题处理
This commit is contained in:
@@ -6,13 +6,13 @@
|
||||
<img src="../../../public/images/Avatarwoman.png" alt="">
|
||||
</div> -->
|
||||
<div class="uesr-avaer">
|
||||
<img :src="userInfo.avatar" v-if="userInfo.avatar !== '' ">
|
||||
<div v-else class="uavatar">
|
||||
<router-link :to="'/home/index?id='+userInfo.aid">
|
||||
<div v-if="sex === 1 "><img src="../../../public/images/Avatarman.png" alt=""></div>
|
||||
<div v-else><img src="../../../public/images/Avatarwoman.png" alt=""></div>
|
||||
<router-link :to="'/home/'+userInfo.aid">
|
||||
<img v-if="userInfo.avatar !== '' " :src="userInfo.avatar" >
|
||||
<div v-else class="uavatar">
|
||||
<div v-if="sex === 1 "><img src="../../../public/images/Avatarman.png" style="width: 100%;" alt=""></div>
|
||||
<div v-if="sex === 2 "><img src="../../../public/images/Avatarwoman.png" style="width: 100%" alt=""></div>
|
||||
</div>
|
||||
</router-link>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="user-content">
|
||||
@@ -102,6 +102,7 @@ import {userAvatarText,cutFullName} from "@/utils/tools.js";
|
||||
},
|
||||
mounted() {
|
||||
this.sex = this.userInfo.sex;
|
||||
//console.log(this.sex,'this.sex')
|
||||
// 判断路由是进入的学员默认页面就重置setCurIdentity
|
||||
if(this.$route.path == '/uc/study/task' || this.$route.path == '/study/index'){
|
||||
this.setCurIdentity(1);
|
||||
@@ -218,6 +219,10 @@ import {userAvatarText,cutFullName} from "@/utils/tools.js";
|
||||
width: 120px;
|
||||
height: 120px;
|
||||
margin-right: 20px;
|
||||
.uavatar{
|
||||
width: 120px;
|
||||
height: 120px;
|
||||
}
|
||||
img{
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
@@ -317,7 +322,7 @@ import {userAvatarText,cutFullName} from "@/utils/tools.js";
|
||||
color: #FFFFFF;
|
||||
// border: 1px solid #ffb30f;
|
||||
}
|
||||
.uc-alert{
|
||||
.uc-alert{
|
||||
margin: 10px;
|
||||
text-align: center;
|
||||
padding: 0px 50x;
|
||||
@@ -329,26 +334,6 @@ import {userAvatarText,cutFullName} from "@/utils/tools.js";
|
||||
color: #aa0000;
|
||||
}
|
||||
}
|
||||
.uavatar{
|
||||
border-radius: 50%;
|
||||
// border: 1px solid #73adfe;
|
||||
// color: #73adfe;
|
||||
text-align: center;
|
||||
font-size: 30px;
|
||||
line-height: 100px;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
border-radius: 50%;
|
||||
// background: #d9e9ff;
|
||||
div{
|
||||
border-radius: 50%;
|
||||
img{
|
||||
border-radius: 50%;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media screen and (max-width: 1366px){
|
||||
.uc-header-box {
|
||||
|
||||
Reference in New Issue
Block a user