Skip to content

Commit 72d1ddb

Browse files
author
human
committed
title高度更新和小程序保持一致
1 parent 6b0e80c commit 72d1ddb

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

packages/core/src/platform/env/nav.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export function useInnerHeaderHeight (pageconfig) {
1515

1616
// 固定写死高度
1717
function getTitleHeight () {
18-
return __mpx_mode__ === 'ios' ? 44 : 56
18+
return 44
1919
}
2020

2121
// 计算颜色亮度

packages/webpack-plugin/lib/runtime/components/react/mpx-web-view.tsx

+11-11
Original file line numberDiff line numberDiff line change
@@ -122,17 +122,17 @@ const _WebView = forwardRef<HandlerRef<WebView, WebViewProps>, WebViewProps>((pr
122122

123123
const navigation = useNavigation()
124124

125-
useEffect(() => {
126-
let beforeRemoveSubscription:any
127-
if (__mpx_mode__ !== 'ios') {
128-
beforeRemoveSubscription = navigation?.addListener?.('beforeRemove', beforeRemoveHandle)
129-
}
130-
return () => {
131-
if (isFunction(beforeRemoveSubscription)) {
132-
beforeRemoveSubscription()
133-
}
134-
}
135-
}, [])
125+
// useEffect(() => {
126+
// let beforeRemoveSubscription:any
127+
// if (__mpx_mode__ !== 'ios') {
128+
// beforeRemoveSubscription = navigation?.addListener?.('beforeRemove', beforeRemoveHandle)
129+
// }
130+
// return () => {
131+
// if (isFunction(beforeRemoveSubscription)) {
132+
// beforeRemoveSubscription()
133+
// }
134+
// }
135+
// }, [])
136136

137137
useNodesRef<WebView, WebViewProps>(props, ref, webViewRef, {
138138
style: defaultWebViewStyle

0 commit comments

Comments
 (0)