Jetpack splash screen Icon is not getting displayed when dark mode ON
Asked Answered
L

1

8

I have created a launch screen using Jetpack splash screen API everything is working fine except the windowSplashScreenAnimatedIcon is not getting displayed when the dark mode is turned on.

Even though I'm using the material day light theme, forcefully opted light as default theme (AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_NO))

I 'm aware of the considerations for the app icon detailed on the google developer portal,

<style name="Theme.App.Starting" parent="Theme.SplashScreen">
    <item name="windowSplashScreenBackground">@color/white</item>
    <item name="windowSplashScreenAnimatedIcon">@drawable/splash_content</item>
    <item name="windowSplashScreenAnimationDuration">500</item>
    <item name="postSplashScreenTheme">@style/Theme.Main</item>
</style>

Any help will be really appreciated.

Thank you

Lakendra answered 18/11, 2021 at 7:3 Comment(4)
@Praveen yes, I have already tried the same but no luckLakendra
@Mable John I have the same problem, do you find the solution?Crispin
@Crispin No, still looking for a way to fix the problemLakendra
@MableJohn I think it is splash lib bug, it is still in alpha. Please write here if you find any solution.Crispin
A
0

My icon was all black circle in dark mode but normal png in light mode. My solution was I updated my Splash API from androidx.core:core-splashscreen:1.0.0-beta01 to implementation 'androidx.core:core-splashscreen:1.1.0-alpha02.

Albanese answered 7/11, 2023 at 9:43 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.