zhenghy

评论与点赞展示

@@ -190,6 +190,7 @@ export struct CommentIconComponent { @@ -190,6 +190,7 @@ export struct CommentIconComponent {
190 .width(this.getMeasureText(this.publishCommentModel.totalCommentNumer) + 190 .width(this.getMeasureText(this.publishCommentModel.totalCommentNumer) +
191 12)// .backgroundColor(Color.Green) 191 12)// .backgroundColor(Color.Green)
192 .id("Text") 192 .id("Text")
  193 + .visibility(this.publishCommentModel.totalCommentNumer ? Visibility.Visible : Visibility.Hidden)
193 // .offset({ 194 // .offset({
194 // x: 3 195 // x: 3
195 // }) 196 // })
@@ -58,7 +58,7 @@ export struct LikeComponent { @@ -58,7 +58,7 @@ export struct LikeComponent {
58 } else if (this.componentType == 5) { 58 } else if (this.componentType == 5) {
59 // 图集点赞,展示标识 59 // 图集点赞,展示标识
60 this.likeCompStyle5() 60 this.likeCompStyle5()
61 - }else { 61 + } else {
62 //1: 底部栏目样式 默认样式 62 //1: 底部栏目样式 默认样式
63 this.likeCompStyle1() 63 this.likeCompStyle1()
64 } 64 }
@@ -188,7 +188,7 @@ export struct LikeComponent { @@ -188,7 +188,7 @@ export struct LikeComponent {
188 .alignItems(VerticalAlign.Center) 188 .alignItems(VerticalAlign.Center)
189 .position({ x: '100%', }) 189 .position({ x: '100%', })
190 .markAnchor({ x: '100%' }) 190 .markAnchor({ x: '100%' })
191 - .backgroundImage(this.likeStatus? $r('app.media.ic_like_back_Select'):$r('app.media.ic_like_back')) 191 + .backgroundImage(this.likeStatus ? $r('app.media.ic_like_back_Select') : $r('app.media.ic_like_back'))
192 .backgroundImageSize(ImageSize.Auto) 192 .backgroundImageSize(ImageSize.Auto)
193 .visibility(this.likeCount > 0 ? Visibility.Visible : Visibility.Hidden) 193 .visibility(this.likeCount > 0 ? Visibility.Visible : Visibility.Hidden)
194 }.width(24).height(24) 194 }.width(24).height(24)
@@ -209,7 +209,7 @@ export struct LikeComponent { @@ -209,7 +209,7 @@ export struct LikeComponent {
209 .width(36) 209 .width(36)
210 .height(36) 210 .height(36)
211 .borderRadius(18) 211 .borderRadius(18)
212 - .backgroundColor(this.pageComponentType === 4 ? '#4D000000' : '#FFF5F5F5') 212 + .backgroundColor((this.pageComponentType === 4 || this.pageComponentType === 2) ? '#4D000000' : '#FFF5F5F5')
213 213
214 214
215 Row() { 215 Row() {