GoogleChromeLabs / bubblewrap

Bubblewrap is a Command Line Interface (CLI) that helps developers to create a Project for an Android application that launches an existing Progressive Web App (PWAs) using a Trusted Web Activity.
Apache License 2.0
2.35k stars 161 forks source link

Allow using a different image from `iconUrl` for the Splash Screen #226

Open andreban opened 4 years ago

andreban commented 4 years ago

Bubblewrap uses the icon provided in the Web Manifest to generate both the launcher icons and the splash screen image, in a similar ways that installed PWAs do.

In some cases, developers may want to use an image for the splash screen that is different from the image provided in the Web Manifest and from the launcher icon. See https://github.com/GoogleChromeLabs/bubblewrap/issues/214 for an example.

rajorpratyush commented 4 years ago

Any updates in this one ?

rubensflinco commented 3 years ago

some news, i really need to define a different icon for my splash screen..

oliverpool commented 3 years ago

Even if it is not recommended, you can override the images located at app/src/main/res/drawable-*/splash.png (where * must be replaced by each resolution).

:warning: Warning: Bubblewrap doesn't expect the generated Android project to be updated using external editors. Any files added manually to the Android project will be deleted or overwritten when update is executed. Changes to twa-manifest.json are preserved.

andreban commented 3 years ago

Thanks @oliverpool. Indeed, you can override the images at app/src/main/res/drawable-*/splash.png and everything should work fine as long as bubblewrap update is not invoked, as that will regenerate the project and destroy those images.

alx-glover commented 5 days ago

Bump. Could definitely use this as a supported feature over the src assets workaround. Thanks!