Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS Launch Backgrounds not working in certain content_modes #726

Open
Taormina opened this issue Sep 1, 2024 · 0 comments
Open

iOS Launch Backgrounds not working in certain content_modes #726

Taormina opened this issue Sep 1, 2024 · 0 comments

Comments

@Taormina
Copy link

Taormina commented Sep 1, 2024

Attention: If you open a bug report without sufficient details, it will be closed. Is your question
related to Android 12? Please check the notes on Android 12 first (https://pub.dev/packages/flutter_native_splash#android-12-support).

Describe the bug

On iOS, the scaleToFill option is not working as expected. I was able to manually get it to work, but I wanted to report my findings to further improve the library.

Configuration

flutter_native_splash:
  background_image: assets/images/town.png
  ios_content_mode: scaleAspectFill

Device (please complete the following information):

  • Device: iPhone 15 Pro, iPhone 15 Pro Max (Simulator)
  • OS: 17.6.1, OS 17.5
  • XCode: 15.4

To Reproduce

  1. Run the library to produce ios_content_mode: center results.
  2. Observe that everything is fine.
  3. Rerun the library with ios_content_mode: scaleAspectFill.
  4. Observe a black splash screen. This is even visible in XCode's LaunchScreen storyboard.

Screenshots
If applicable, add screenshots to help explain your problem. If in doubt, attach a screenshot.
Excepted Result:
Screenshot 2024-09-01 at 2 27 01 PM

Actual Result:
Screenshot 2024-09-01 at 2 28 30 PM

Additional context
The left is the code I manually changed to get it to work. I think that the view, image AND background is being given scaleToFill, but I think only the LaunchBackground needs to be given the contentMode and we want to leave the overall view and foreground image alone for now.
Screenshot 2024-09-01 at 2 28 45 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant