mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-02-27 09:17:21 +08:00
* MaskedViewIOS use broke react-native-web support, this fixes it. * Fallback more gracefully. * Actually return the value ...
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
import {
|
||||
BackAndroid as DeprecatedBackAndroid,
|
||||
BackHandler as ModernBackHandler,
|
||||
MaskedViewIOS,
|
||||
} from 'react-native';
|
||||
|
||||
const BackHandler = ModernBackHandler || DeprecatedBackAndroid;
|
||||
|
||||
export { BackHandler };
|
||||
export { BackHandler, MaskedViewIOS };
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
import { BackHandler } from 'react-native';
|
||||
import React from 'react';
|
||||
import { BackHandler, View } from 'react-native';
|
||||
|
||||
export { BackHandler };
|
||||
const MaskedViewIOS = () => <View>{this.props.children}</View>;
|
||||
|
||||
export { BackHandler, MaskedViewIOS };
|
||||
|
||||
@@ -6,10 +6,10 @@ import {
|
||||
Image,
|
||||
Platform,
|
||||
StyleSheet,
|
||||
MaskedViewIOS,
|
||||
View,
|
||||
ViewPropTypes,
|
||||
} from 'react-native';
|
||||
import { MaskedViewIOS } from '../../PlatformHelpers';
|
||||
import SafeAreaView from 'react-native-safe-area-view';
|
||||
|
||||
import HeaderTitle from './HeaderTitle';
|
||||
@@ -379,7 +379,7 @@ class Header extends React.PureComponent {
|
||||
if (
|
||||
options.headerLeft ||
|
||||
options.headerBackImage ||
|
||||
Platform.OS === 'android' ||
|
||||
Platform.OS !== 'ios' ||
|
||||
transitionPreset !== 'uikit'
|
||||
) {
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user