mikaelacaron / Basic-Car-Maintenance

A basic app to track your car's maintenance. Open source for Hacktoberfest 2023. Beginners are welcome!
https://mikaelacaron.github.io/Basic-Car-Maintenance/documentation/basic_car_maintenance/
Apache License 2.0
227 stars 132 forks source link

BUG - Icons preview in ChooseAppIconView not visible #330

Open maartinj opened 3 days ago

maartinj commented 3 days ago

Describe the bug

To Reproduce

Steps to reproduce the behavior:

  1. Run the app
  2. Tap SettingsView
  3. Tap Change App Icon
  4. See icons preview not visible

Expected behavior

Screenshots

Device Info:

mitaligondaliya commented 3 days ago

Could you please assign me?

mitaligondaliya commented 3 days ago

Hello @mikaelacaron I've spent some time investigating the bug, and it seems that displaying AppIcons using UIImage(named: String) is deprecated. We can now fetch app icon images through the CFBundleIcons property list, but this only returns icons at a limited size of 64x64. Another option would be to create a new image set for all the app icons.

Let me know which approach you’d prefer to proceed with.

Here are the reference links where I found the solutions.

https://forums.developer.apple.com/forums/thread/757162

https://stackoverflow.com/questions/77408262/why-cant-swiftuis-image-see-the-appicon-file

mikaelacaron commented 3 days ago

@mitaligondaliya I think returning 64x64 icons is totally fine! Thanks for the links, very helpful!

Check that when they're shown on the view, the images won't scale up with dynamic type, cause then they'd start to get pixelated