Merge pull request #23 from michael-palmes/iphonexs-max-and-iphonexr-support
Added window dimensions for iPhone XS Max and iPhone XR
This commit is contained in:
commit
5313e5d2c1
|
@ -28,12 +28,17 @@ import { supportsImprovedSpringAnimation } from '../../utils/ReactNativeFeatures
|
|||
|
||||
const emptyFunction = () => {};
|
||||
|
||||
const IPHONE_XS_HEIGHT = 812; // iPhone X and XS
|
||||
const IPHONE_XR_HEIGHT = 896; // iPhone XR and XS Max
|
||||
const { width: WINDOW_WIDTH, height: WINDOW_HEIGHT } = Dimensions.get('window');
|
||||
const IS_IPHONE_X =
|
||||
Platform.OS === 'ios' &&
|
||||
!Platform.isPad &&
|
||||
!Platform.isTVOS &&
|
||||
(WINDOW_HEIGHT === 812 || WINDOW_WIDTH === 812);
|
||||
(WINDOW_HEIGHT === IPHONE_XS_HEIGHT ||
|
||||
WINDOW_WIDTH === IPHONE_XS_HEIGHT ||
|
||||
WINDOW_HEIGHT === IPHONE_XR_HEIGHT ||
|
||||
WINDOW_WIDTH === IPHONE_XR_HEIGHT);
|
||||
|
||||
const EaseInOut = Easing.inOut(Easing.ease);
|
||||
|
||||
|
|
Loading…
Reference in New Issue