Showing
10 changed files
with
29 additions
and
21 deletions
| @@ -34,8 +34,8 @@ | @@ -34,8 +34,8 @@ | ||
| 34 | { | 34 | { |
| 35 | "name": "default", | 35 | "name": "default", |
| 36 | "signingConfig": "default", | 36 | "signingConfig": "default", |
| 37 | - "compileSdkVersion": "4.1.0(11)", | ||
| 38 | - "compatibleSdkVersion": "4.1.0(11)", | 37 | + "compileSdkVersion": "5.0.0(12)", |
| 38 | + "compatibleSdkVersion": "5.0.0(12)", | ||
| 39 | "runtimeOS": "HarmonyOS", | 39 | "runtimeOS": "HarmonyOS", |
| 40 | } | 40 | } |
| 41 | ], | 41 | ], |
| @@ -48,8 +48,8 @@ export struct WdWebLocalComponent { | @@ -48,8 +48,8 @@ export struct WdWebLocalComponent { | ||
| 48 | 48 | ||
| 49 | Row() { | 49 | Row() { |
| 50 | RelativeContainer() { | 50 | RelativeContainer() { |
| 51 | - // Web({ src: this.webResource, controller: this.webviewControl, renderMode: RenderMode.SYNC_RENDER }) | ||
| 52 | - Web({ src: this.webResource, controller: this.webviewControl}) | 51 | + Web({ src: this.webResource, controller: this.webviewControl, renderMode: RenderMode.SYNC_RENDER }) |
| 52 | + // Web({ src: this.webResource, controller: this.webviewControl}) | ||
| 53 | .domStorageAccess(true) | 53 | .domStorageAccess(true) |
| 54 | .databaseAccess(true) | 54 | .databaseAccess(true) |
| 55 | .javaScriptAccess(true) | 55 | .javaScriptAccess(true) |
| @@ -57,9 +57,9 @@ export struct WdWebLocalComponent { | @@ -57,9 +57,9 @@ export struct WdWebLocalComponent { | ||
| 57 | .mixedMode(MixedMode.All) | 57 | .mixedMode(MixedMode.All) |
| 58 | .onlineImageAccess(true) | 58 | .onlineImageAccess(true) |
| 59 | .enableNativeEmbedMode(true) | 59 | .enableNativeEmbedMode(true) |
| 60 | - // .layoutMode(WebLayoutMode.FIT_CONTENT) | ||
| 61 | - // .nestedScroll({ scrollForward: NestedScrollMode.SELF_FIRST, scrollBackward: NestedScrollMode.PARENT_FIRST }) | ||
| 62 | - .height(this.webHeight) | 60 | + .layoutMode(WebLayoutMode.FIT_CONTENT) |
| 61 | + .nestedScroll({ scrollForward: NestedScrollMode.SELF_FIRST, scrollBackward: NestedScrollMode.PARENT_FIRST }) | ||
| 62 | + // .height(this.webHeight) | ||
| 63 | .onPageBegin((event) => { | 63 | .onPageBegin((event) => { |
| 64 | this.onPageBegin(event?.url); | 64 | this.onPageBegin(event?.url); |
| 65 | }) | 65 | }) |
| @@ -172,7 +172,7 @@ export struct SearchResultContentComponent{ | @@ -172,7 +172,7 @@ export struct SearchResultContentComponent{ | ||
| 172 | relId: value.data.relId, | 172 | relId: value.data.relId, |
| 173 | relType: value.data.relType, | 173 | relType: value.data.relType, |
| 174 | newsTitle: value.data.titleLiteral, | 174 | newsTitle: value.data.titleLiteral, |
| 175 | - publishTime: value.data.publishTime, | 175 | + publishTime: StringUtils.isNotEmpty(value.data.firstPublishTime)?value.data.firstPublishTime:value.data.publishTime, |
| 176 | visitorComment: -1, | 176 | visitorComment: -1, |
| 177 | fullColumnImgUrls: photos, | 177 | fullColumnImgUrls: photos, |
| 178 | newsSummary: "", | 178 | newsSummary: "", |
| @@ -43,6 +43,8 @@ const TAG = 'OperRowListView'; | @@ -43,6 +43,8 @@ const TAG = 'OperRowListView'; | ||
| 43 | @Preview | 43 | @Preview |
| 44 | @Component | 44 | @Component |
| 45 | export struct OperRowListView { | 45 | export struct OperRowListView { |
| 46 | + private onBack: () => void = () => { | ||
| 47 | + } | ||
| 46 | @Prop @Watch('onDetailUpdated') contentDetailData: ContentDetailDTO // 稿件详情 | 48 | @Prop @Watch('onDetailUpdated') contentDetailData: ContentDetailDTO // 稿件详情 |
| 47 | @State operationButtonList: string[] = ['comment', 'collect', 'share'] // 组件展示条件 | 49 | @State operationButtonList: string[] = ['comment', 'collect', 'share'] // 组件展示条件 |
| 48 | @ObjectLink publishCommentModel: publishCommentModel | 50 | @ObjectLink publishCommentModel: publishCommentModel |
| @@ -102,6 +104,9 @@ export struct OperRowListView { | @@ -102,6 +104,9 @@ export struct OperRowListView { | ||
| 102 | } | 104 | } |
| 103 | .hoverEffect(HoverEffect.Scale) | 105 | .hoverEffect(HoverEffect.Scale) |
| 104 | .onClick(() => { | 106 | .onClick(() => { |
| 107 | + if (this.onBack) { | ||
| 108 | + this.onBack() | ||
| 109 | + } | ||
| 105 | router.back(); | 110 | router.back(); |
| 106 | }) | 111 | }) |
| 107 | .width(42) | 112 | .width(42) |
| @@ -34,7 +34,7 @@ export struct DetailPlayVLivePage { | @@ -34,7 +34,7 @@ export struct DetailPlayVLivePage { | ||
| 34 | 34 | ||
| 35 | aboutToAppear(): void { | 35 | aboutToAppear(): void { |
| 36 | console.log(TAG, 'aboutToAppear') | 36 | console.log(TAG, 'aboutToAppear') |
| 37 | - // WindowModel.shared.setWindowLayoutFullScreen(true) | 37 | + WindowModel.shared.setWindowLayoutFullScreen(true) |
| 38 | WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#ffffff', }) | 38 | WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#ffffff', }) |
| 39 | 39 | ||
| 40 | //https://pdapis.pdnews.cn/api/rmrb-bff-display-zh/content/zh/c/content/detail?relId=500005302448&relType=1&contentId=20000016340 | 40 | //https://pdapis.pdnews.cn/api/rmrb-bff-display-zh/content/zh/c/content/detail?relId=500005302448&relType=1&contentId=20000016340 |
| @@ -48,7 +48,7 @@ export struct DetailPlayVLivePage { | @@ -48,7 +48,7 @@ export struct DetailPlayVLivePage { | ||
| 48 | } | 48 | } |
| 49 | 49 | ||
| 50 | aboutToDisappear(): void { | 50 | aboutToDisappear(): void { |
| 51 | - // WindowModel.shared.setWindowLayoutFullScreen(false) | 51 | + WindowModel.shared.setWindowLayoutFullScreen(false) |
| 52 | WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#000000', }) | 52 | WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#000000', }) |
| 53 | } | 53 | } |
| 54 | 54 | ||
| @@ -86,7 +86,6 @@ export struct DetailPlayVLivePage { | @@ -86,7 +86,6 @@ export struct DetailPlayVLivePage { | ||
| 86 | .width(40) | 86 | .width(40) |
| 87 | .aspectRatio(1) | 87 | .aspectRatio(1) |
| 88 | .visibility(this.swiperIndex === 0 ? Visibility.Visible : Visibility.Hidden) | 88 | .visibility(this.swiperIndex === 0 ? Visibility.Visible : Visibility.Hidden) |
| 89 | - .animation({ duration: 500 }) | ||
| 90 | .position({ x: '100%', y: '100%' }) | 89 | .position({ x: '100%', y: '100%' }) |
| 91 | .markAnchor({ x: 56, y: 56 }) | 90 | .markAnchor({ x: 56, y: 56 }) |
| 92 | .onClick(() => { | 91 | .onClick(() => { |
| @@ -10,6 +10,7 @@ import { LiveViewModel } from '../../viewModel/LiveViewModel' | @@ -10,6 +10,7 @@ import { LiveViewModel } from '../../viewModel/LiveViewModel' | ||
| 10 | import { ChartItemCompereComponent } from './ChartItemCompereComponent' | 10 | import { ChartItemCompereComponent } from './ChartItemCompereComponent' |
| 11 | import { ChatItemComponent } from './ChartItemComponent' | 11 | import { ChatItemComponent } from './ChartItemComponent' |
| 12 | import { router } from '@kit.ArkUI' | 12 | import { router } from '@kit.ArkUI' |
| 13 | +import { WindowModel } from 'wdKit/Index' | ||
| 13 | 14 | ||
| 14 | const TAG = "PlayerCommentComponent" | 15 | const TAG = "PlayerCommentComponent" |
| 15 | 16 | ||
| @@ -128,6 +129,10 @@ export struct PlayerCommentComponent { | @@ -128,6 +129,10 @@ export struct PlayerCommentComponent { | ||
| 128 | operationButtonList: ['comment', 'collect', 'share', 'like'], | 129 | operationButtonList: ['comment', 'collect', 'share', 'like'], |
| 129 | contentDetailData: this.contentDetailData, | 130 | contentDetailData: this.contentDetailData, |
| 130 | publishCommentModel: this.publishCommentModel, | 131 | publishCommentModel: this.publishCommentModel, |
| 132 | + onBack: () => { | ||
| 133 | + WindowModel.shared.setWindowLayoutFullScreen(false) | ||
| 134 | + WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: '#000000', }) | ||
| 135 | + } | ||
| 131 | }) | 136 | }) |
| 132 | .visibility(this.displayDirection == DisplayDirection.VERTICAL ? Visibility.Visible : Visibility.None) | 137 | .visibility(this.displayDirection == DisplayDirection.VERTICAL ? Visibility.Visible : Visibility.None) |
| 133 | 138 |
| @@ -38,8 +38,7 @@ export struct PlayerComponent { | @@ -38,8 +38,7 @@ export struct PlayerComponent { | ||
| 38 | } | 38 | } |
| 39 | 39 | ||
| 40 | aboutToDisappear(): void { | 40 | aboutToDisappear(): void { |
| 41 | - this.playerController.onCanplay = () => { | ||
| 42 | - } | 41 | + |
| 43 | this.playerController?.pause() | 42 | this.playerController?.pause() |
| 44 | this.playerController?.stop() | 43 | this.playerController?.stop() |
| 45 | this.playerController?.release() | 44 | this.playerController?.release() |
| @@ -29,7 +29,7 @@ export struct VideoChannelDetail { | @@ -29,7 +29,7 @@ export struct VideoChannelDetail { | ||
| 29 | private groupId: string = '' // 楼层id | 29 | private groupId: string = '' // 楼层id |
| 30 | private pageId: string = '' //页面id | 30 | private pageId: string = '' //页面id |
| 31 | private pageNum: number = 1 | 31 | private pageNum: number = 1 |
| 32 | - private pageSize: number = 10 | 32 | + private pageSize: number = 5 |
| 33 | private loadStrategy: string = 'first_load' // 首次加载: first_load, 上推刷新: push_up, 下拉刷新: pull_down | 33 | private loadStrategy: string = 'first_load' // 首次加载: first_load, 上推刷新: push_up, 下拉刷新: pull_down |
| 34 | private refreshTime: number = new Date().getTime() // 第一页刷新时间,用于频道分页排序时过滤,查询时携带【首刷、下拉取当前最新时间;其他的都使用首刷的时间】 | 34 | private refreshTime: number = new Date().getTime() // 第一页刷新时间,用于频道分页排序时过滤,查询时携带【首刷、下拉取当前最新时间;其他的都使用首刷的时间】 |
| 35 | private channelId: string = '' // 频道id | 35 | private channelId: string = '' // 频道id |
| @@ -56,11 +56,11 @@ export struct DetailDialog { | @@ -56,11 +56,11 @@ export struct DetailDialog { | ||
| 56 | .width('100%') | 56 | .width('100%') |
| 57 | .alignItems(HorizontalAlign.Start) | 57 | .alignItems(HorizontalAlign.Start) |
| 58 | // .backgroundColor('#80000000') | 58 | // .backgroundColor('#80000000') |
| 59 | - // .linearGradient({ | ||
| 60 | - // direction: GradientDirection.Top, // 渐变方向 | ||
| 61 | - // repeating: false, // 渐变颜色是否重复 | ||
| 62 | - // colors: [['rgba(0, 0, 0, 0.1)', 0.0], ['rgba(0, 0, 0, 0)', 1.0]] // 数组末尾元素占比小于1时满足重复着色效果 | ||
| 63 | - // }) | 59 | + .linearGradient({ |
| 60 | + direction: GradientDirection.Bottom, // 渐变方向 | ||
| 61 | + colors: [['rgba(0,0,0,0)', 0.1], ['#000000', 0.66], | ||
| 62 | + ['#000000', 1.0]] // 数组末尾元素占比小于1时满足重复着色效果 | ||
| 63 | + }) | ||
| 64 | .padding({ | 64 | .padding({ |
| 65 | top: 20, | 65 | top: 20, |
| 66 | bottom: 30, | 66 | bottom: 30, |
| 1 | { | 1 | { |
| 2 | - "hvigorVersion": "file:../dependencies/hvigor-4.1.2.tgz", | 2 | + "hvigorVersion": "file:../dependencies/hvigor-4.3.0.tgz", |
| 3 | "dependencies": { | 3 | "dependencies": { |
| 4 | - "@ohos/hvigor-ohos-plugin": "file:../dependencies/hvigor-ohos-plugin-4.1.2.tgz", | 4 | + "@ohos/hvigor-ohos-plugin": "file:../dependencies/hvigor-ohos-plugin-4.3.0.tgz", |
| 5 | "rollup": "file:../dependencies/rollup.tgz", | 5 | "rollup": "file:../dependencies/rollup.tgz", |
| 6 | }, | 6 | }, |
| 7 | "execution": { | 7 | "execution": { |
-
Please register or login to post a comment