wangliang_wd

feat:优化我的头像

... ... @@ -26,6 +26,7 @@ export default struct MinePageUserSimpleInfoUI {
}else{
this.headPhotoUrl = ""
this.levelHead = ""
this.userType = "1"
}
}
... ... @@ -33,12 +34,20 @@ export default struct MinePageUserSimpleInfoUI {
Row(){
//头像
Stack(){
if (this.headPhotoUrl.length > 0){
Image(this.headPhotoUrl)
.alt(this.userType === '1'?$r('app.media.default_head'):$r('app.media.AccountOwner_DefaultIcon'))
.alt(this.userType === "1"?$r('app.media.default_head'):$r('app.media.AccountOwner_DefaultIcon'))
.width(`${this.calcHeight(100)}lpx`)
.height(`${this.calcHeight(100)}lpx`)
.objectFit(ImageFit.Cover)
.borderRadius(50)
}else {
Image(this.userType === "1"?$r('app.media.default_head'):$r('app.media.AccountOwner_DefaultIcon'))
.width(`${this.calcHeight(100)}lpx`)
.height(`${this.calcHeight(100)}lpx`)
.objectFit(ImageFit.Cover)
.borderRadius(50)
}
if(StringUtils.isNotEmpty(this.levelHead)){
Image(this.levelHead)
... ...