Splash screen jump
See original GitHub issueThe splash screens are misaligned and cause jump similar to the react-native-splash-screen.
Tested on Pixel 3 XL emulator and real device 19:8 aspect ratio.
Installed the latest version and followed the instructions on https://www.npmjs.com/package/react-native-bootsplash almost the same
The differences are Styles.xml
<resources>
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<item name="android:textColor">#000000</item>
<item name="android:statusBarColor">@color/statusbar</item>
<item name="android:windowLightStatusBar">true</item>
<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>
</style>
<style name="SplashTheme" parent="Theme.AppCompat.Light.NoActionBar">
<item name="android:background">@drawable/background_splash</item>
<item name="android:statusBarColor">@color/splash</item>
<item name="android:windowLightStatusBar">true</item>
<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>
</style>
</resources>
background_splash
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" android:opacity="opaque">
<item android:drawable="@color/splash" />
<item
android:width="222dp"
android:height="222dp"
android:drawable="@mipmap/icon"
android:gravity="center" />
</layer-list>
Why is this happening?
Issue Analytics
- State:
- Created 4 years ago
- Reactions:4
- Comments:47 (17 by maintainers)
Top Results From Across the Web
Android splash screen jump java - Stack Overflow
I wanted to implement a splash screen but in a correct way - no superficial delay, only showing it while the app is...
Read more >Splash screen jumping up on android #385 - GitHub
On android, there is a small jump up (approx. the height of the status bar, so I suspect it has to do with...
Read more >Implementing the Perfect Splash Screen in Android - Medium
A Splash Screen referred to as a launch screen or startup screen and shows up when your app is loading, and its perfect...
Read more >What is causing unexpected motion of a logo on splash screen?
I noticed that the logo will 'jump' once on the screen. In order to avoid this unexpected 'jump' I changed to this method:...
Read more >Splash Screen shifts up then down on cold start : r/androiddev
So I created a splash screen for my app (according to this link ). Everything works fine until the app cold starts or...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
After using
<item name="android:windowTranslucentStatus">true</item>
status bar was hidden but the problem is react-native-keyboard-aware-scroll-view stopped working on androidi found the problem was using <item name="android:windowTranslucentStatus">true</item> causes this issue so for anyone’s need
i created native module so that after hiding the splash we can set android:windowTranslucentStatus = false
And then after hiding splash
await RNBootSplash.hide({fade: true}); if (Platform.OS === 'android') { NativeModules.StatusBarModule.toggle(false); }
@whimsicaldreamer The issue here is that you set your status bar style directly in code (in your
MainActivity
) but your app does not start with it (it usesRNBootSplashActivity
).So instead of Java code, try to set your styles with a dedicated file (
styles-v28.xml
for Android Pie):Not sure about the android config keys, but you get the idea 🙂