authentication component
This commit is contained in:
33
components/_ShareComponent/ViewWrapper.tsx
Normal file
33
components/_ShareComponent/ViewWrapper.tsx
Normal file
@@ -0,0 +1,33 @@
|
||||
import { globalStyles } from "@/constants/global-styles";
|
||||
import { ImageBackground, ScrollView, View } from "react-native";
|
||||
import { SafeAreaView } from "react-native-safe-area-context";
|
||||
|
||||
interface ViewWrapperProps {
|
||||
children: React.ReactNode;
|
||||
}
|
||||
|
||||
const ViewWrapper = ({ children }: ViewWrapperProps) => {
|
||||
const assetBackground = require("../../assets/images/main-background.png");
|
||||
|
||||
return (
|
||||
<SafeAreaView
|
||||
edges={[]}
|
||||
style={{
|
||||
flex: 1,
|
||||
// paddingTop: StatusBar.currentHeight,
|
||||
}}
|
||||
>
|
||||
<ScrollView contentContainerStyle={{ flexGrow: 1 }}>
|
||||
<ImageBackground
|
||||
source={assetBackground}
|
||||
resizeMode="cover"
|
||||
style={globalStyles.imageBackground}
|
||||
>
|
||||
<View style={globalStyles.container}>{children}</View>
|
||||
</ImageBackground>
|
||||
</ScrollView>
|
||||
</SafeAreaView>
|
||||
);
|
||||
};
|
||||
|
||||
export default ViewWrapper;
|
||||
Reference in New Issue
Block a user