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
chenquansheng
2024-09-12 19:30:41 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
9143347dafb9b3e4d4f5eceee8346fe3430d595e
9143347d
1 parent
0577cb04
fix |> 修复点击右上角专题板块下拉按钮,展示全部板块,鸿蒙蒙层没有到底
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
46 additions
and
7 deletions
sight_harmony/commons/wdJsBridge/src/main/ets/bean/Message.ets
sight_harmony/commons/wdWebComponent/src/main/ets/pages/WdWebComponent.ets
sight_harmony/features/wdComponent/src/main/ets/components/SpacialTopicPageComponent.ets
sight_harmony/commons/wdJsBridge/src/main/ets/bean/Message.ets
View file @
9143347
...
...
@@ -40,6 +40,7 @@ interface dataObject {
videoLandscape?: string
imgListData?: string
statusBarMode?: string
color?:string
}
/**
...
...
sight_harmony/commons/wdWebComponent/src/main/ets/pages/WdWebComponent.ets
View file @
9143347
...
...
@@ -16,7 +16,7 @@ export struct WdWebComponent {
webviewControl: BridgeWebViewControl = new BridgeWebViewControl()
onWebPrepared: () => void = () => {
}
receiveH5SendToNativeData: (data
String:string
| undefined) => void = () =>{
receiveH5SendToNativeData: (data
: Message
| undefined) => void = () =>{
}
@Prop isDefaultPage: boolean = false;
...
...
@@ -96,7 +96,7 @@ export struct WdWebComponent {
}
if (data.handlerName === H5CallNativeType.jsCall_receiveH5Data) {
if (data.data?.dataSource === WDH5WebDataSource.WDH5WebDataSourceTopicPageInfo) {
this.receiveH5SendToNativeData(data
.data?.dataJson
)
this.receiveH5SendToNativeData(data)
return
}
}
...
...
@@ -110,6 +110,13 @@ export struct WdWebComponent {
private jsCall_currentPageOperate(data: Message) {
if (data.data?.operateType == WDH5WebPageOperationType.WDH5WebPageOperationTypeSetStatusBar) {
WindowModel.shared.setWindowSystemBarProperties({ statusBarContentColor: data.data?.statusBarMode =='2'?'#ffffff':'#000000'})
return
}
if (data.data?.operateType == WDH5WebPageOperationType.WDH5WebPageOperationTypeBottomBarMaskViewShow ||
data.data?.operateType == WDH5WebPageOperationType.WDH5WebPageOperationTypeBottomBarMaskViewHidden) {
this.receiveH5SendToNativeData(data)
return
}
}
...
...
sight_harmony/features/wdComponent/src/main/ets/components/SpacialTopicPageComponent.ets
View file @
9143347
...
...
@@ -26,6 +26,7 @@ import PageAdModel from '../viewmodel/PageAdvModel';
import { ProcessUtils } from 'wdRouter/Index';
import { GrayManageModel } from '../viewmodel/GrayManageModel';
import router from '@ohos.router';
import { Message,WDH5WebDataSource,WDH5WebPageOperationType } from 'wdJsBridge/src/main/ets/bean/Message';
const TAG: string = 'SpacialTopicPageComponent'
...
...
@@ -58,6 +59,8 @@ export struct SpacialTopicPageComponent {
@State private pageAdvModel: PageAdModel = new PageAdModel();
@State shareInfo: ShareInfoDTO = {} as ShareInfoDTO
@State showBottomView: boolean = false;
@State showBottomMaskView: boolean = false;
@State bgColor: ResourceColor = ''
@State executedStartTime: number = new Date().getTime()
// 国殇灰度管理
...
...
@@ -84,14 +87,17 @@ export struct SpacialTopicPageComponent {
})
}
private receiveH5SendToNativeData(dataString: string | undefined) {
// this.topicDetail = JSON.parse(dataString);
if (dataString == undefined) {
private receiveH5SendToNativeData(data: Message | undefined) {
if (data == undefined) {
return
}
Logger.debug('SpacialTopicPageComponent111', dataString);
this.topicDetail = JSON.parse(dataString);
if (data.data?.dataSource === WDH5WebDataSource.WDH5WebDataSourceTopicPageInfo) {
if (data.data?.dataJson == undefined) {
return
}
this.topicDetail = JSON.parse(data.data?.dataJson);
this.topicInfo = this.topicDetail.topicInfo;
this.pageAdvModel.analysisTopicAdvSource(this.topicDetail)
if (this.topicInfo) {
...
...
@@ -134,6 +140,24 @@ export struct SpacialTopicPageComponent {
}
// this.viewBlogInsightIntentShare();
return
}
if (data.data?.operateType == WDH5WebPageOperationType.WDH5WebPageOperationTypeBottomBarMaskViewShow) {
if (data.data?.color == undefined){
this.bgColor = '#80000000'
}else {
this.bgColor = data.data?.color
}
this.showBottomMaskView = true
return
}
if (data.data?.operateType == WDH5WebPageOperationType.WDH5WebPageOperationTypeBottomBarMaskViewHidden) {
this.showBottomMaskView = false
return
}
}
//意图上报
...
...
@@ -235,6 +259,13 @@ export struct SpacialTopicPageComponent {
interactData: $interactData,
}).visibility(this.showComment ? Visibility.Visible : Visibility.Hidden)
}
if (this.showBottomMaskView){
Column()
.width('100%')
.backgroundColor(this.bgColor)
.height(75)
}
}
}.width(CommonConstants.FULL_WIDTH).height(CommonConstants.FULL_HEIGHT)
}
...
...
Please
register
or
login
to post a comment