import React from 'react';
import {
Platform,
StyleSheet,
View,
NativeModules,
SafeAreaView,
} from 'react-native';
import { Dimensions } from 'react-native'
import Theme from '../components/theme.style.js';
const { StatusBarManager } = NativeModules;
const statusBarHeight = StatusBarManager.HEIGHT;
const OS = Platform.OS;
const CustomSafeArea = ({customStatusBar, hideTopBar, children}) => {
if(customStatusBar && OS === "ios") {
return (
{children}
)
}
return (
<>
{ OS === "ios" && }
{children}
>
)
};
const styles = StyleSheet.create({
customSafeArea: (hideTopBar) => {
return {
flex: 1,
backgroundColor: !hideTopBar ? Theme.colors.primary : Theme.colors.white,
}
},
statusBarHeight: {
height: statusBarHeight,
backgroundColor: Theme.colors.primary,
width: '100%'
}
});
export default CustomSafeArea;