Merge branch 'main' of http://192.168.1.42/developOne/harmonyPool
Showing
6 changed files
with
70 additions
and
44 deletions
| @@ -92,6 +92,14 @@ export struct H5NewsWebPageComponent { | @@ -92,6 +92,14 @@ export struct H5NewsWebPageComponent { | ||
| 92 | .backgroundColor(Color.White) | 92 | .backgroundColor(Color.White) |
| 93 | .height(150) | 93 | .height(150) |
| 94 | 94 | ||
| 95 | + //全部评论 | ||
| 96 | + CommentDialogView({ | ||
| 97 | + index: $index, | ||
| 98 | + currentIndex: $currentIndex, | ||
| 99 | + showCommentList: $showCommentList, | ||
| 100 | + publishCommentModel: $publishCommentModel, | ||
| 101 | + interactData: $interactData, | ||
| 102 | + }).visibility(this.showComment ? Visibility.Visible : Visibility.Hidden) | ||
| 95 | } | 103 | } |
| 96 | .margin({top: `${this.topSafeHeight}px`, bottom: `${this.bottomSafeHeight}px`}) | 104 | .margin({top: `${this.topSafeHeight}px`, bottom: `${this.bottomSafeHeight}px`}) |
| 97 | .width(CommonConstants.FULL_WIDTH) | 105 | .width(CommonConstants.FULL_WIDTH) |
| @@ -37,6 +37,7 @@ export struct MorningEveningPaperComponent { | @@ -37,6 +37,7 @@ export struct MorningEveningPaperComponent { | ||
| 37 | @Provide commentList: InteractDataDTO[] = [] | 37 | @Provide commentList: InteractDataDTO[] = [] |
| 38 | @State audioPlayUrl: string = "" | 38 | @State audioPlayUrl: string = "" |
| 39 | @State isNoListContent:boolean = false; | 39 | @State isNoListContent:boolean = false; |
| 40 | + @State isContentFailed:boolean = false; | ||
| 40 | @State executedStartTime:number = new Date().getTime() | 41 | @State executedStartTime:number = new Date().getTime() |
| 41 | // @Consume dailyPaperTopicPageId: number | 42 | // @Consume dailyPaperTopicPageId: number |
| 42 | // @Provide compListItem: CompList = {} as CompList | 43 | // @Provide compListItem: CompList = {} as CompList |
| @@ -177,6 +178,7 @@ export struct MorningEveningPaperComponent { | @@ -177,6 +178,7 @@ export struct MorningEveningPaperComponent { | ||
| 177 | } | 178 | } |
| 178 | this.isNoListContent = this.compListItem && this.compListItem?.operDataList?.length > 0 ?false:true | 179 | this.isNoListContent = this.compListItem && this.compListItem?.operDataList?.length > 0 ?false:true |
| 179 | } catch (exception) { | 180 | } catch (exception) { |
| 181 | + this.isContentFailed = true | ||
| 180 | 182 | ||
| 181 | } | 183 | } |
| 182 | 184 | ||
| @@ -264,56 +266,64 @@ export struct MorningEveningPaperComponent { | @@ -264,56 +266,64 @@ export struct MorningEveningPaperComponent { | ||
| 264 | } | 266 | } |
| 265 | 267 | ||
| 266 | build() { | 268 | build() { |
| 267 | - Stack({ alignContent: Alignment.Top }) { | ||
| 268 | - List() { | ||
| 269 | - if (this.pageInfoBean?.topicInfo?.frontLinkObject) { | ||
| 270 | - | ||
| 271 | - ListItem() { | ||
| 272 | - topicInfoView({ frontLinkObject: this.pageInfoBean?.topicInfo?.frontLinkObject}) | ||
| 273 | - } | 269 | + if (this.isContentFailed){ |
| 270 | + Column(){ | ||
| 271 | + EmptyComponent({emptyType:WDViewDefaultType.WDViewDefaultType_ContentFailed}) | ||
| 272 | + }.backgroundColor(this.mixedBgColor ?? Color.Black) | ||
| 273 | + }else { | ||
| 274 | + Stack({ alignContent: Alignment.Top }) { | ||
| 275 | + List() { | ||
| 276 | + if (this.pageInfoBean?.topicInfo?.frontLinkObject) { | ||
| 274 | 277 | ||
| 275 | - } | 278 | + ListItem() { |
| 279 | + topicInfoView({ frontLinkObject: this.pageInfoBean?.topicInfo?.frontLinkObject}) | ||
| 280 | + } | ||
| 276 | 281 | ||
| 277 | - if (this.audioPlayUrl.length > 0){ | ||
| 278 | - ListItem() { | ||
| 279 | - this.AudioBarView() | ||
| 280 | } | 282 | } |
| 281 | - .margin({ | ||
| 282 | - top: this.isHasTopView ? 10 : 44 + this.topSafeHeight | ||
| 283 | - }) | ||
| 284 | - } | ||
| 285 | 283 | ||
| 286 | - ListItem() { | ||
| 287 | - if(this.isNoListContent){ | ||
| 288 | - EmptyComponent({emptyType:WDViewDefaultType.WDViewDefaultType_NoListContent}) | ||
| 289 | - }else { | ||
| 290 | - SingleColumn999Component({ | ||
| 291 | - compListItem: this.compListItem, | 284 | + if (this.audioPlayUrl.length > 0){ |
| 285 | + ListItem() { | ||
| 286 | + this.AudioBarView() | ||
| 287 | + } | ||
| 288 | + .margin({ | ||
| 289 | + top: this.isHasTopView ? 10 : 44 + this.topSafeHeight | ||
| 292 | }) | 290 | }) |
| 293 | - .margin({ | ||
| 294 | - top: this.isHasTopView || this.audioPlayUrl.length > 0 ? 10 : 44+this.topSafeHeight | 291 | + } |
| 292 | + | ||
| 293 | + ListItem() { | ||
| 294 | + if(this.isNoListContent){ | ||
| 295 | + EmptyComponent({emptyType:WDViewDefaultType.WDViewDefaultType_NoListContent}) | ||
| 296 | + }else { | ||
| 297 | + SingleColumn999Component({ | ||
| 298 | + compListItem: this.compListItem, | ||
| 295 | }) | 299 | }) |
| 300 | + .margin({ | ||
| 301 | + top: this.isHasTopView || this.audioPlayUrl.length > 0 ? 10 : 44+this.topSafeHeight | ||
| 302 | + }) | ||
| 303 | + } | ||
| 296 | } | 304 | } |
| 297 | } | 305 | } |
| 306 | + // .height(`calc(100% - ${this.bottomSafeHeight + this.topSafeHeight + 'vp'})`) | ||
| 307 | + .edgeEffect(EdgeEffect.None) // 必须设置列表为滑动到边缘无效果 | ||
| 308 | + .scrollBar(BarState.Off) | ||
| 309 | + .onWillScroll(scrollOffset =>{ | ||
| 310 | + this.scrollOffset = this.scrollOffset + scrollOffset as number | ||
| 311 | + }) | ||
| 312 | + | ||
| 313 | + this.topPaperTitle() | ||
| 298 | } | 314 | } |
| 299 | - // .height(`calc(100% - ${this.bottomSafeHeight + this.topSafeHeight + 'vp'})`) | ||
| 300 | - .edgeEffect(EdgeEffect.None) // 必须设置列表为滑动到边缘无效果 | ||
| 301 | - .scrollBar(BarState.Off) | ||
| 302 | - .onWillScroll(scrollOffset =>{ | ||
| 303 | - this.scrollOffset = this.scrollOffset + scrollOffset as number | 315 | + .width('100%') |
| 316 | + .height('100%') | ||
| 317 | + .padding({ | ||
| 318 | + top: 0, | ||
| 319 | + // bottom: this.bottomSafeHeight | ||
| 304 | }) | 320 | }) |
| 305 | - | ||
| 306 | - this.topPaperTitle() | 321 | + // .backgroundColor(Color.Black) |
| 322 | + // .backgroundColor(this.pageInfoBean?.backgroundColor ?? Color.Black) | ||
| 323 | + .backgroundColor(this.mixedBgColor ?? Color.Black) | ||
| 307 | } | 324 | } |
| 308 | - .width('100%') | ||
| 309 | - .height('100%') | ||
| 310 | - .padding({ | ||
| 311 | - top: 0, | ||
| 312 | - // bottom: this.bottomSafeHeight | ||
| 313 | - }) | ||
| 314 | - // .backgroundColor(Color.Black) | ||
| 315 | - // .backgroundColor(this.pageInfoBean?.backgroundColor ?? Color.Black) | ||
| 316 | - .backgroundColor(this.mixedBgColor ?? Color.Black) | 325 | + |
| 326 | + | ||
| 317 | } | 327 | } |
| 318 | 328 | ||
| 319 | @Builder | 329 | @Builder |
| @@ -26,7 +26,7 @@ export struct PeopleShipRecommendComponent { | @@ -26,7 +26,7 @@ export struct PeopleShipRecommendComponent { | ||
| 26 | .height('30vp') | 26 | .height('30vp') |
| 27 | .fontColor($r('app.color.color_222222')) | 27 | .fontColor($r('app.color.color_222222')) |
| 28 | .fontWeight(600) | 28 | .fontWeight(600) |
| 29 | - .fontSize($r('app.float.vp_15_7')) | 29 | + .fontSize($r('app.float.vp_18')) |
| 30 | 30 | ||
| 31 | Blank() | 31 | Blank() |
| 32 | Button({ type: ButtonType.Normal, stateEffect: false }) { | 32 | Button({ type: ButtonType.Normal, stateEffect: false }) { |
| @@ -11,8 +11,8 @@ export struct PeopleShipRecommendHeadComponent { | @@ -11,8 +11,8 @@ export struct PeopleShipRecommendHeadComponent { | ||
| 11 | Column(){ | 11 | Column(){ |
| 12 | Stack({ alignContent: Alignment.BottomEnd }) { | 12 | Stack({ alignContent: Alignment.BottomEnd }) { |
| 13 | Image(this.rmhInfo.headPhotoUrl.length > 0 ? this.rmhInfo.headPhotoUrl : $r('app.media.WDAccountOwnerHedaerDefaultIcon')) | 13 | Image(this.rmhInfo.headPhotoUrl.length > 0 ? this.rmhInfo.headPhotoUrl : $r('app.media.WDAccountOwnerHedaerDefaultIcon')) |
| 14 | - .width('40vp') | ||
| 15 | - .height('40vp') | 14 | + .width('44vp') |
| 15 | + .height('44vp') | ||
| 16 | .borderRadius('22vp') | 16 | .borderRadius('22vp') |
| 17 | .objectFit(ImageFit.Cover) | 17 | .objectFit(ImageFit.Cover) |
| 18 | 18 | ||
| @@ -28,7 +28,7 @@ export struct PeopleShipRecommendHeadComponent { | @@ -28,7 +28,7 @@ export struct PeopleShipRecommendHeadComponent { | ||
| 28 | Row() { | 28 | Row() { |
| 29 | Text(this.rmhInfo.userName) | 29 | Text(this.rmhInfo.userName) |
| 30 | .fontColor($r('app.color.color_222222')) | 30 | .fontColor($r('app.color.color_222222')) |
| 31 | - .fontSize($r('app.float.vp_13')) | 31 | + .fontSize($r('app.float.vp_14')) |
| 32 | .fontWeight(600) | 32 | .fontWeight(600) |
| 33 | .maxLines(1) | 33 | .maxLines(1) |
| 34 | .textOverflow({overflow: TextOverflow.Ellipsis}) | 34 | .textOverflow({overflow: TextOverflow.Ellipsis}) |
| @@ -45,7 +45,7 @@ export struct ENewspaperListDialog { | @@ -45,7 +45,7 @@ export struct ENewspaperListDialog { | ||
| 45 | // 手势滑动相关 | 45 | // 手势滑动相关 |
| 46 | private panOption: PanGestureOptions = new PanGestureOptions({ direction: PanDirection.Up | PanDirection.Down }) | 46 | private panOption: PanGestureOptions = new PanGestureOptions({ direction: PanDirection.Up | PanDirection.Down }) |
| 47 | private topFixedHeight = 124 | 47 | private topFixedHeight = 124 |
| 48 | - @State topHeight: number = 124 | 48 | + @State topHeight: number = 204 |
| 49 | private deviceHeight: number = 0 | 49 | private deviceHeight: number = 0 |
| 50 | 50 | ||
| 51 | 51 |
| @@ -24,6 +24,13 @@ export struct MultiPictureListPage { | @@ -24,6 +24,13 @@ export struct MultiPictureListPage { | ||
| 24 | @Provide topSafeHeight: number = AppStorage.get<number>('topSafeHeight') || 0 | 24 | @Provide topSafeHeight: number = AppStorage.get<number>('topSafeHeight') || 0 |
| 25 | // @Provide bgc: Color = Color.White; | 25 | // @Provide bgc: Color = Color.White; |
| 26 | @Provide duration: number = 0 | 26 | @Provide duration: number = 0 |
| 27 | + @State noAnimation: boolean = true | ||
| 28 | + | ||
| 29 | + pageTransition() { | ||
| 30 | + // PageTransitionEnter({ duration: this.noAnimation ? 0 : 300 }) | ||
| 31 | + PageTransitionExit({ duration: !this.noAnimation ? 0 : 300 }) | ||
| 32 | + } | ||
| 33 | + | ||
| 27 | 34 | ||
| 28 | aboutToAppear(): void { | 35 | aboutToAppear(): void { |
| 29 | //获取宽高尺寸 | 36 | //获取宽高尺寸 |
| @@ -65,6 +72,7 @@ export struct MultiPictureListPage { | @@ -65,6 +72,7 @@ export struct MultiPictureListPage { | ||
| 65 | }) | 72 | }) |
| 66 | .onClick(() => { | 73 | .onClick(() => { |
| 67 | this.onBack(); | 74 | this.onBack(); |
| 75 | + this.noAnimation = false | ||
| 68 | router.back(); | 76 | router.back(); |
| 69 | }) | 77 | }) |
| 70 | .id("backImg") | 78 | .id("backImg") |
-
Please register or login to post a comment