xugenyuan

ref |> 修复子评论 查看更多和收起交互UI

Signed-off-by: xugenyuan <xugenyuan@wondertek.com.cn>
@@ -422,30 +422,32 @@ struct footerExpandedView { @@ -422,30 +422,32 @@ struct footerExpandedView {
422 build() { 422 build() {
423 Row() { 423 Row() {
424 if (this.item.expanded) { 424 if (this.item.expanded) {
425 - if (this.item.childsHasMore) { 425 + Row() {
  426 + Text().backgroundColor($r('app.color.color_EDEDED')).width(24).height(1)
  427 + if (this.item.childsHasMore) {
  428 + Row() {
  429 + Text('查看更多回复').fontColor($r('app.color.color_222222')).fontSize(14)
  430 + Image($r('app.media.comment_unfold')).width(12).height(12)
  431 + }.margin({ left: 6 })
  432 + .onClick(() => {
  433 + if (this.item.isLoading) {
  434 + return
  435 + }
  436 + this.item.isLoading = true
  437 + fetchChildContentCommentList(this.contentId, this.contentType, this.item)
  438 + })
  439 + }
426 Row() { 440 Row() {
427 - Text().backgroundColor($r('app.color.color_EDEDED')).width(24).height(1)  
428 - Text('查看更多回复').fontColor($r('app.color.color_222222')).fontSize(14).margin({ left: 6 })  
429 - Image($r('app.media.comment_unfold')).width(12).height(12)  
430 - }.margin({ left: 53 }) 441 + Text('收起').fontColor($r('app.color.color_222222')).fontSize(14)
  442 + Image($r('app.media.comment_pickUp')).width(12).height(12)
  443 + }.margin({ left: 6 })
431 .onClick(() => { 444 .onClick(() => {
432 - if (this.item.isLoading) {  
433 - return  
434 - }  
435 - this.item.isLoading = true  
436 - fetchChildContentCommentList(this.contentId, this.contentType, this.item) 445 + this.item.pageNum = 1
  446 + this.item.expanded = false
  447 + this.item.childComments = []
  448 + this.item.childCommentsLazyDataSource.clear()
437 }) 449 })
438 - }  
439 - Row() {  
440 - Text('收起').fontColor($r('app.color.color_222222')).fontSize(14)  
441 - Image($r('app.media.comment_pickUp')).width(12).height(12)  
442 - }.margin({ left: this.item.childsHasMore ? 32 : 213 })  
443 - .onClick(() => {  
444 - this.item.pageNum = 1  
445 - this.item.expanded = false  
446 - this.item.childComments = []  
447 - this.item.childCommentsLazyDataSource.clear()  
448 - }) 450 + }.margin({ left: 53 })
449 } else { 451 } else {
450 Row() { 452 Row() {
451 Text().backgroundColor($r('app.color.color_EDEDED')).width(24).height(1) 453 Text().backgroundColor($r('app.color.color_EDEDED')).width(24).height(1)
@@ -12,7 +12,7 @@ export default struct NoMoreLayout { @@ -12,7 +12,7 @@ export default struct NoMoreLayout {
12 Text($r('app.string.footer_text')) 12 Text($r('app.string.footer_text'))
13 .fontSize(RefreshConstants.NoMoreLayoutConstant_TITLE_FONT) 13 .fontSize(RefreshConstants.NoMoreLayoutConstant_TITLE_FONT)
14 .textAlign(TextAlign.Center) 14 .textAlign(TextAlign.Center)
15 - .fontColor('#CCCCCC') 15 + .fontColor('#999999')
16 .margin({bottom:40}) 16 .margin({bottom:40})
17 } 17 }
18 .width(RefreshConstants.FULL_WIDTH) 18 .width(RefreshConstants.FULL_WIDTH)