Showing
7 changed files
with
65 additions
and
20 deletions
| @@ -108,7 +108,7 @@ export struct ImageAndTextPageComponent { | @@ -108,7 +108,7 @@ export struct ImageAndTextPageComponent { | ||
| 108 | .height(24) | 108 | .height(24) |
| 109 | .margin({ right: 5 }) | 109 | .margin({ right: 5 }) |
| 110 | } | 110 | } |
| 111 | - if (this.interactData?.likeNum != '0') { | 111 | + if (this.interactData?.likeNum) { |
| 112 | Text(`${this.interactData?.likeNum}`) | 112 | Text(`${this.interactData?.likeNum}`) |
| 113 | .fontSize(16) | 113 | .fontSize(16) |
| 114 | .fontColor(this.newsStatusOfUser?.likeStatus === '1' ? '#ED2800' : '#999999') | 114 | .fontColor(this.newsStatusOfUser?.likeStatus === '1' ? '#ED2800' : '#999999') |
| 1 | -import { NetworkUtil, Logger, NetworkType, SPHelper, WindowModel} from 'wdKit'; | 1 | +import { NetworkUtil, Logger, NetworkType, SPHelper, WindowModel, StringUtils} from 'wdKit'; |
| 2 | import { ResponseDTO } from 'wdNetwork'; | 2 | import { ResponseDTO } from 'wdNetwork'; |
| 3 | import { | 3 | import { |
| 4 | ContentDetailDTO, | 4 | ContentDetailDTO, |
| @@ -102,6 +102,7 @@ export struct MultiPictureDetailPageComponent { | @@ -102,6 +102,7 @@ export struct MultiPictureDetailPageComponent { | ||
| 102 | Row({ space: 8 }) { | 102 | Row({ space: 8 }) { |
| 103 | if (this.getImgUrl()){ | 103 | if (this.getImgUrl()){ |
| 104 | Row() { | 104 | Row() { |
| 105 | + Stack() { | ||
| 105 | Image(this.getImgUrl()) | 106 | Image(this.getImgUrl()) |
| 106 | .borderRadius(24) | 107 | .borderRadius(24) |
| 107 | .aspectRatio(1) | 108 | .aspectRatio(1) |
| @@ -110,6 +111,21 @@ export struct MultiPictureDetailPageComponent { | @@ -110,6 +111,21 @@ export struct MultiPictureDetailPageComponent { | ||
| 110 | .height(36) | 111 | .height(36) |
| 111 | .objectFit(ImageFit.Fill) | 112 | .objectFit(ImageFit.Fill) |
| 112 | .interpolation(ImageInterpolation.High) | 113 | .interpolation(ImageInterpolation.High) |
| 114 | + if(!StringUtils.isEmpty(this.contentDetailData.rmhInfo?.authIcon)){ | ||
| 115 | + Stack() { | ||
| 116 | + Image(this.contentDetailData.rmhInfo?.authIcon) | ||
| 117 | + .width($r('app.float.vp_13')) | ||
| 118 | + .height($r('app.float.vp_13')) | ||
| 119 | + .objectFit(ImageFit.Cover) | ||
| 120 | + } | ||
| 121 | + .width(36) | ||
| 122 | + .height(36) | ||
| 123 | + .alignContent(Alignment.BottomEnd) | ||
| 124 | + } | ||
| 125 | + } | ||
| 126 | + .width(36) | ||
| 127 | + .height(36) | ||
| 128 | + .alignContent(Alignment.Center) | ||
| 113 | .onClick(() => { | 129 | .onClick(() => { |
| 114 | if (this.contentDetailData.rmhInfo?.cnMainControl === 1) { | 130 | if (this.contentDetailData.rmhInfo?.cnMainControl === 1) { |
| 115 | // 号主页 | 131 | // 号主页 |
| @@ -380,11 +396,11 @@ export struct MultiPictureDetailPageComponent { | @@ -380,11 +396,11 @@ export struct MultiPictureDetailPageComponent { | ||
| 380 | } | 396 | } |
| 381 | this.netStatus = undefined | 397 | this.netStatus = undefined |
| 382 | this.contentDetailData = resDTO.data?.[0]; | 398 | this.contentDetailData = resDTO.data?.[0]; |
| 383 | - if (this.contentDetailData.rmhPlatform == 1) { | ||
| 384 | - WindowModel.shared.setWindowSystemBarProperties({ | ||
| 385 | - statusBarContentColor: '#ffffff', | ||
| 386 | - }) | ||
| 387 | - } | 399 | + // if (this.contentDetailData.rmhPlatform == 1) { |
| 400 | + // WindowModel.shared.setWindowSystemBarProperties({ | ||
| 401 | + // statusBarContentColor: '#ffffff', | ||
| 402 | + // }) | ||
| 403 | + // } | ||
| 388 | if (this.contentDetailData?.openComment) { | 404 | if (this.contentDetailData?.openComment) { |
| 389 | this.publishCommentModel.targetId = String(this.contentDetailData?.newsId || '') | 405 | this.publishCommentModel.targetId = String(this.contentDetailData?.newsId || '') |
| 390 | this.publishCommentModel.targetRelId = String(this.contentDetailData?.reLInfo?.relId) | 406 | this.publishCommentModel.targetRelId = String(this.contentDetailData?.reLInfo?.relId) |
| @@ -67,14 +67,15 @@ export struct PeopleShipHomePageNavComponent { | @@ -67,14 +67,15 @@ export struct PeopleShipHomePageNavComponent { | ||
| 67 | Row(){ | 67 | Row(){ |
| 68 | Image($r('app.media.people_ship_top_add')) | 68 | Image($r('app.media.people_ship_top_add')) |
| 69 | .objectFit(ImageFit.Auto) | 69 | .objectFit(ImageFit.Auto) |
| 70 | - .width('12vp') | ||
| 71 | - .height('12pv') | 70 | + .width('13vp') |
| 71 | + .height('13pv') | ||
| 72 | .margin({ | 72 | .margin({ |
| 73 | - right: '2vp' | 73 | + right: '3vp' |
| 74 | }) | 74 | }) |
| 75 | Text('关注') | 75 | Text('关注') |
| 76 | .fontSize($r('app.float.vp_12')) | 76 | .fontSize($r('app.float.vp_12')) |
| 77 | .fontColor(Color.White) | 77 | .fontColor(Color.White) |
| 78 | + .height('100%') | ||
| 78 | } | 79 | } |
| 79 | .alignSelf(ItemAlign.Center) | 80 | .alignSelf(ItemAlign.Center) |
| 80 | .justifyContent(FlexAlign.Center) | 81 | .justifyContent(FlexAlign.Center) |
| @@ -42,7 +42,7 @@ export struct SearchHistoryComponent{ | @@ -42,7 +42,7 @@ export struct SearchHistoryComponent{ | ||
| 42 | Row(){ | 42 | Row(){ |
| 43 | Text("搜索历史") | 43 | Text("搜索历史") |
| 44 | .textAlign(TextAlign.Center) | 44 | .textAlign(TextAlign.Center) |
| 45 | - .fontWeight('400lpx') | 45 | + .fontWeight(FontWeight.Regular) |
| 46 | .fontSize('27lpx') | 46 | .fontSize('27lpx') |
| 47 | .lineHeight('38lpx') | 47 | .lineHeight('38lpx') |
| 48 | .fontColor($r('app.color.color_999999')) | 48 | .fontColor($r('app.color.color_999999')) |
| @@ -68,7 +68,7 @@ export struct SearchHistoryComponent{ | @@ -68,7 +68,7 @@ export struct SearchHistoryComponent{ | ||
| 68 | Text(`${item.searchContent}`) | 68 | Text(`${item.searchContent}`) |
| 69 | .fontColor($r('app.color.color_222222')) | 69 | .fontColor($r('app.color.color_222222')) |
| 70 | .fontSize('31lpx') | 70 | .fontSize('31lpx') |
| 71 | - .fontWeight('400lpx') | 71 | + .fontWeight(FontWeight.Regular) |
| 72 | .lineHeight('46lpx') | 72 | .lineHeight('46lpx') |
| 73 | .maxLines(1) | 73 | .maxLines(1) |
| 74 | .constraintSize({maxWidth:index%2 === 0?'270lpx':'230lpx'}) | 74 | .constraintSize({maxWidth:index%2 === 0?'270lpx':'230lpx'}) |
| @@ -68,7 +68,7 @@ export struct SearchHotsComponent{ | @@ -68,7 +68,7 @@ export struct SearchHotsComponent{ | ||
| 68 | .height('31lpx') | 68 | .height('31lpx') |
| 69 | .fontColor($r('app.color.color_666666')) | 69 | .fontColor($r('app.color.color_666666')) |
| 70 | .fontSize('27lpx') | 70 | .fontSize('27lpx') |
| 71 | - .fontWeight('400lpx') | 71 | + .fontWeight(FontWeight.Regular) |
| 72 | .lineHeight('31lpx') | 72 | .lineHeight('31lpx') |
| 73 | .margin({right:'12lpx'}) | 73 | .margin({right:'12lpx'}) |
| 74 | } | 74 | } |
| @@ -77,7 +77,7 @@ export struct SearchHotsComponent{ | @@ -77,7 +77,7 @@ export struct SearchHotsComponent{ | ||
| 77 | .fontColor($r('app.color.color_222222')) | 77 | .fontColor($r('app.color.color_222222')) |
| 78 | .fontSize('31lpx') | 78 | .fontSize('31lpx') |
| 79 | .maxLines(1) | 79 | .maxLines(1) |
| 80 | - .fontWeight('400lpx') | 80 | + .fontWeight(FontWeight.Regular) |
| 81 | .lineHeight('42lpx') | 81 | .lineHeight('42lpx') |
| 82 | }.layoutWeight(1) | 82 | }.layoutWeight(1) |
| 83 | 83 |
| @@ -429,7 +429,7 @@ | @@ -429,7 +429,7 @@ | ||
| 429 | </div> | 429 | </div> |
| 430 | 430 | ||
| 431 | <!-- 分享 --> | 431 | <!-- 分享 --> |
| 432 | - <div class="share" v-if="shareOpen"> | 432 | + <div class="share" v-if="false"> |
| 433 | <div | 433 | <div |
| 434 | v-if="details.shareInfo.sharePosterOpen == 1" | 434 | v-if="details.shareInfo.sharePosterOpen == 1" |
| 435 | class="sharePoster share-wrapper share-box" | 435 | class="sharePoster share-wrapper share-box" |
| @@ -2,7 +2,7 @@ import { Logger } from 'wdKit'; | @@ -2,7 +2,7 @@ import { Logger } from 'wdKit'; | ||
| 2 | import { MultiPictureDetailPageComponent } from 'wdComponent'; | 2 | import { MultiPictureDetailPageComponent } from 'wdComponent'; |
| 3 | import router from '@ohos.router'; | 3 | import router from '@ohos.router'; |
| 4 | import { Params, Action } from 'wdBean'; | 4 | import { Params, Action } from 'wdBean'; |
| 5 | - | 5 | +import { WindowModel } from 'wdKit/Index'; |
| 6 | const TAG = 'MultiPictureDetailPage'; | 6 | const TAG = 'MultiPictureDetailPage'; |
| 7 | 7 | ||
| 8 | /** | 8 | /** |
| @@ -26,6 +26,8 @@ struct MultiPictureDetailPage { | @@ -26,6 +26,8 @@ struct MultiPictureDetailPage { | ||
| 26 | }) | 26 | }) |
| 27 | } | 27 | } |
| 28 | } | 28 | } |
| 29 | + .padding({top:44}) | ||
| 30 | + .backgroundColor(Color.Black) | ||
| 29 | } | 31 | } |
| 30 | 32 | ||
| 31 | pageTransition(){ | 33 | pageTransition(){ |
| @@ -38,6 +40,10 @@ struct MultiPictureDetailPage { | @@ -38,6 +40,10 @@ struct MultiPictureDetailPage { | ||
| 38 | } | 40 | } |
| 39 | 41 | ||
| 40 | aboutToAppear() { | 42 | aboutToAppear() { |
| 43 | + this.openFullScreen() | ||
| 44 | + | ||
| 45 | + Logger.info(TAG, 'aboutToDisappear'); | ||
| 46 | + | ||
| 41 | let par:Action = router.getParams() as Action; | 47 | let par:Action = router.getParams() as Action; |
| 42 | let params = par?.params; | 48 | let params = par?.params; |
| 43 | this.relId = params?.extra?.relId || ''; | 49 | this.relId = params?.extra?.relId || ''; |
| @@ -47,11 +53,33 @@ struct MultiPictureDetailPage { | @@ -47,11 +53,33 @@ struct MultiPictureDetailPage { | ||
| 47 | Logger.info(TAG, 'params', JSON.stringify(params)); | 53 | Logger.info(TAG, 'params', JSON.stringify(params)); |
| 48 | } | 54 | } |
| 49 | 55 | ||
| 50 | - aboutToDisappear() { | ||
| 51 | - Logger.info(TAG, 'aboutToDisappear'); | ||
| 52 | - } | ||
| 53 | - | ||
| 54 | onBackPress() { | 56 | onBackPress() { |
| 55 | Logger.info(TAG, 'onBackPress'); | 57 | Logger.info(TAG, 'onBackPress'); |
| 56 | } | 58 | } |
| 59 | + | ||
| 60 | + /** | ||
| 61 | + * 开启沉浸式 | ||
| 62 | + * TODO:颜色待根据业务接口修改 | ||
| 63 | + */ | ||
| 64 | + openFullScreen() { | ||
| 65 | + WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#ffffff', }) | ||
| 66 | + WindowModel.shared.setWindowLayoutFullScreen(true) | ||
| 67 | + // WindowModel.shared.setWindowSystemBarEnable([]) | ||
| 68 | + } | ||
| 69 | + | ||
| 70 | + aboutToDisappear(): void { | ||
| 71 | + console.log(TAG, 'aboutToDisappear') | ||
| 72 | + this.closeFullScreen() | ||
| 73 | + } | ||
| 74 | + | ||
| 75 | + /** | ||
| 76 | + * 关闭沉浸式 | ||
| 77 | + * TODO:颜色待根据业务接口修改 | ||
| 78 | + */ | ||
| 79 | + closeFullScreen() { | ||
| 80 | + WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#000000', }) | ||
| 81 | + WindowModel.shared.setWindowLayoutFullScreen(false) | ||
| 82 | + // WindowModel.shared.setWindowSystemBarEnable(['status', 'navigation']) | ||
| 83 | + } | ||
| 84 | + | ||
| 57 | } | 85 | } |
-
Please register or login to post a comment