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
张善主
2024-05-27 17:09:18 +0800
Browse Files
Options
Browse Files
Download
Plain Diff
Commit
6252ef15c971ef79941ff71dfc4fc868b2cd57b1
6252ef15
2 parents
ff485108
fa6f8c76
Merge remote-tracking branch 'origin/main'
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
17 deletions
sight_harmony/features/wdComponent/src/main/ets/components/cardview/MoreComponent.ets
sight_harmony/features/wdComponent/src/main/ets/components/comment/view/QualityCommentsComponent.ets
sight_harmony/features/wdDetailPlayShortVideo/src/main/ets/view/PlayerRightView.ets
sight_harmony/features/wdComponent/src/main/ets/components/cardview/MoreComponent.ets
View file @
6252ef1
/**
* More_Comp
*/
import { ContentDTO , contentListParams, FullColumnImgUrlDTO,
import { ContentDTO , contentListParams, FullColumnImgUrlDTO,
CompDTO
} from 'wdBean/Index';
import MinePageDatasModel from '../../model/MinePageDatasModel';
import SearcherAboutDataModel from '../../model/SearcherAboutDataModel';
import { SearchDescription } from '../../viewmodel/SearchResultContentItem';
import { CardParser } from '../CardParser'
const TAG: string = 'More_Comp';
...
...
@@ -13,26 +14,54 @@ const TAG: string = 'More_Comp';
@Component
export struct MoreComponent {
@State contentDTO: ContentDTO = new ContentDTO();
@State showDetail: boolean = false;
aboutToAppear(): void {
this.dealSearchSameList()
}
build() {
Row() {
Text('点击展开更多相似')
.fontSize(16)
Text(`(${this.contentDTO.sameContentListSize})`)
.fontSize(16)
Image($r('app.media.comment_unfold'))
.width(16)
.height(16)
if (this.showDetail) {
ForEach(this.contentDTO.sameContentList, (item: ContentDTO, index: number) => {
CardParser({compDTO:new CompDTO, contentDTO: item })
})
} else {
Column() {
Divider()
.width('100%')
.height(10)
.color($r('app.color.color_F5F5F5'))
.strokeWidth('1lpx')
Row() {
Text('点击展开更多相似')
.fontSize(16)
Text(`(${this.contentDTO.sameContentListSize})`)
.fontSize(16)
Image($r('app.media.comment_unfold'))
.width(16)
.height(16)
}
.justifyContent(FlexAlign.Center)
.width('100%')
.height(48)
.backgroundColor(0xffffff)
.onClick(() => {
this.showDetail = true;
})
Divider()
.width('100%')
.height(10)
.color($r('app.color.color_F5F5F5'))
.strokeWidth('1lpx')
}
}
.justifyContent(FlexAlign.Center)
.width('100%')
.height(48)
.backgroundColor(0xffffff)
}
dealSearchSameList() {
...
...
@@ -88,6 +117,8 @@ export struct MoreComponent {
console.log("ycg","123")
}
})
console.log("MoreComponent", JSON.stringify(this.contentDTO.sameContentList))
}).catch((err: Error) => {
console.log(TAG, JSON.stringify(err))
})
...
...
sight_harmony/features/wdComponent/src/main/ets/components/comment/view/QualityCommentsComponent.ets
View file @
6252ef1
...
...
@@ -176,6 +176,7 @@ export struct QualityCommentsComponent {
.fontWeight(400)
.fontColor($r('app.color.color_222222'))
.lineHeight('42lpx')
.visibility(this.tileOpacity < 0.8 ? 1 : 0)
}
.height(44)
.width('100%')
...
...
sight_harmony/features/wdDetailPlayShortVideo/src/main/ets/view/PlayerRightView.ets
View file @
6252ef1
...
...
@@ -37,10 +37,14 @@ export struct PlayerRightView {
@Consume showCommentList: boolean
@Consume displayDirection: DisplayDirection
@Consume publishCommentModel: publishCommentModel
@State likesStyle: number = this.contentDetailData.likesStyle // 赞样式 1红心(点赞) 2大拇指(祈福) 3蜡烛(默哀) 4置空
@State likesStyle: number | string = 1 // 赞样式 1红心(点赞) 2大拇指(祈福) 3蜡烛(默哀) 4置空
@State openLikes: boolean = false // 是否可以点赞 1:可以 0:不可以
aboutToAppear() {
// 内容用 点赞样式 1红心(点赞) 2大拇指(祈福) 3蜡烛(默哀) 4置空
this.likesStyle = this.contentDetailData.likesStyle
this.openLikes = this.contentDetailData.openLikes == 1 ? true : false
// console.log(TAG, 'this.likesStyle', this.likesStyle)
// console.log(TAG, 'this.openLikes', this.openLikes)
}
/**
...
...
@@ -299,7 +303,7 @@ export struct PlayerRightView {
.margin({ top: 2 })
}
.margin({ bottom: 20 })
.visibility(this.likesStyle
!== 4 ? Visibility.Visible : Visibility.Non
e)
.visibility(this.likesStyle
== 4 || this.likesStyle == 'empty' || !this.openLikes ? Visibility.None : Visibility.Visibl
e)
.onClick(() => {
// TODO:点赞动画
this.toggleLikeStatus()
...
...
Please
register
or
login
to post a comment