Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
zhangwenqiang
2024-08-05 16:14:21 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
0e60bcca88394a7c6c8a7ba9e4e898f7f59f439c
0e60bcca
1 parent
fdc4e053
fix:[17891]点赞样式设置-祈福或默哀,详情页点赞后,数字不应为红色
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletions
sight_harmony/features/wdComponent/src/main/ets/components/ImageAndTextPageComponent.ets
sight_harmony/features/wdComponent/src/main/ets/components/ImageAndTextPageComponent.ets
View file @
0e60bcc
...
...
@@ -117,7 +117,8 @@ export struct ImageAndTextPageComponent {
if (this.likeNum > 0) {
Text(NumberFormatterUtils.formatNumberWithWan(this.likeNum))
.fontSize(16)
.fontColor(this.newsStatusOfUser?.likeStatus == '1' ? '#ED2800' : '#999999')
//.fontColor(this.newsStatusOfUser?.likeStatus == '1' ? '#ED2800' : '#999999')
.fontColor((this.likeNumTextColor()))
.fontFamily('PingFang SC-Regular')
.fontWeight(400)
.margin({ left: 5 })
...
...
@@ -267,6 +268,14 @@ export struct ImageAndTextPageComponent {
.backgroundColor(Color.White)
}
private likeNumTextColor() {
if(this.newsStatusOfUser?.likeStatus == '1'){
//已点赞状态 祈福和默哀为黑色 其余为红色
return (this.contentDetailData?.likesStyle == 2 || this.contentDetailData?.likesStyle == 3) ? '#222222' : '#ED2800'
}
return '#999999'
}
private async getDetail() {
this.isNetConnected = NetworkUtil.isNetConnected()
if (!this.isNetConnected) {
...
...
Please
register
or
login
to post a comment