import { Dimensions , ScaledSize , Platform , StatusBar } from "react-native" ; const iPhoneX_HEIGHT = 812 ; const iPhoneXr_HEIGHT = 896 ; const iPhoneXs_HEIGHT = 896 ; const iPhoneXsMax_HEIGHT = 896 ; const iPhoneSE_HEIGHT = 568 ; const iPhone11_HEIGHT = 896 ; const iPhone11Pro_HEIGHT = 812 ; const iPhone11ProMax_HEIGHT = 896 ; const iPhone12_HEIGHT = 844 ; const iPhone12Pro_HEIGHT = 844 ; const iPhone12ProMax_HEIGHT = 926 ; const iPhone12Mini_HEIGHT = 812 ; /**
 * This and hasNotch functions are the same,
 * just want to make two functions with different names
 * hasNotch is more accurate name
 */ const isIPhoneNotchFamily = ( ) => { return detection ( ) ; } ; const isIPhoneXFamily = ( ) => { return detection ( ) ; } ; const hasNotch = ( ) => { return detection ( ) ; } ; const isIPhoneSE = ( dim ) => dim . height === iPhoneSE_HEIGHT ; const isIPhoneX = ( dim ) => dim . height === iPhoneX_HEIGHT ; const isIPhoneXr = ( dim ) => dim . height === iPhoneXr_HEIGHT ; const isIPhoneXs = ( dim ) => dim . height === iPhoneXs_HEIGHT ; const isIPhoneXsMax = ( dim ) => dim . height === iPhoneXsMax_HEIGHT ; const isIPhone11 = ( dim ) => dim . height === iPhone11_HEIGHT ; const isIPhone11Pro = ( dim ) => dim . height === iPhone11Pro_HEIGHT ; const isIPhone11ProMax = ( dim ) => dim . height === iPhone11ProMax_HEIGHT ; const isIPhone12 = ( dim ) => dim . height === iPhone12_HEIGHT ; const isIPhone12Pro = ( dim ) => dim . height === iPhone12Pro_HEIGHT ; const isIPhone12ProMax = ( dim ) => dim . height === iPhone12ProMax_HEIGHT ; const isIPhone12Mini = ( dim ) => dim . height === iPhone12Mini_HEIGHT ; const detection = ( ) => { const dim = Dimensions . get ( "window" ) ; return ( Platform . OS === "ios" && ! Platform . isPad && ! Platform . isTVOS && ( isIPhoneX ( dim ) || isIPhoneXr ( dim ) || isIPhoneXs ( dim ) || isIPhoneXsMax ( dim ) || isIPhone11 ( dim ) || isIPhone11Pro ( dim ) || isIPhone11ProMax ( dim ) || isIPhone12 ( dim ) || isIPhone12Pro ( dim ) || isIPhone12ProMax ( dim ) ) ) ; } ; const getStatusBarHeight = ( ) => { return Platform . select ( { ios : hasNotch ( ) ? 44 : 30 , android : StatusBar . currentHeight , } ) ; } ; export { getStatusBarHeight , hasNotch , isIPhoneNotchFamily , isIPhoneXFamily , isIPhoneSE , isIPhoneX , isIPhoneXr , isIPhoneXs , isIPhoneXsMax , isIPhone11 , isIPhone11Pro , isIPhone11ProMax , isIPhone12 , isIPhone12Pro , isIPhone12ProMax , isIPhone12Mini , } ;