Fix android bottom

This commit is contained in:
Marc Rousavy 2021-02-19 21:14:42 +01:00
parent f1a2db1141
commit 27f5ad016b
3 changed files with 15 additions and 2 deletions

View File

@ -3,6 +3,6 @@
<item name="android:windowBackground">#000000</item>
<item name="android:textColor">#000000</item>
<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowTranslucentNavigation">true</item>
<item name="android:windowTranslucentNavigation">false</item>
</style>
</resources>

View File

@ -25,6 +25,15 @@ Navigation.setDefaultOptions({
visible: true,
style: 'dark'
},
animations: {
setRoot: {
alpha: {
duration: 500,
from: 0,
to: 1,
}
},
}
});
Navigation.registerComponent('Splash', () => gestureHandlerRootHOC(Splash), () => Splash);

View File

@ -3,11 +3,15 @@ import StaticSafeAreaInsets from "react-native-static-safe-area-insets";
export const CONTENT_SPACING = 15;
const SAFE_BOTTOM = Platform.select({
ios: StaticSafeAreaInsets.safeAreaInsetsBottom
}) ?? 0
export const SAFE_AREA_PADDING = {
paddingLeft: StaticSafeAreaInsets.safeAreaInsetsLeft + CONTENT_SPACING,
paddingTop: StaticSafeAreaInsets.safeAreaInsetsTop + CONTENT_SPACING,
paddingRight: StaticSafeAreaInsets.safeAreaInsetsRight + CONTENT_SPACING,
paddingBottom: StaticSafeAreaInsets.safeAreaInsetsBottom + CONTENT_SPACING
paddingBottom: SAFE_BOTTOM + CONTENT_SPACING
}
// whether to use takeSnapshot() instead of takePhoto() on Android