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 Dark and Tinted icons are not placed in the correct directory #596

Open
vlazdra opened this issue Oct 8, 2024 · 3 comments · May be fixed by #597
Open

iOS Dark and Tinted icons are not placed in the correct directory #596

vlazdra opened this issue Oct 8, 2024 · 3 comments · May be fixed by #597
Labels

Comments

@vlazdra
Copy link

vlazdra commented Oct 8, 2024

ℹ️ Info

0.14.1

💬 Description

When running the command it creates an additional folder for the Dark and for the Tinted icons which is not how it's supposed to be. The Dark and Tinted icons should be placed in the already existing or the main AppIcon catalog (taking into account the flavor part if present)

📜 Pubspec.yaml

flutter_launcher_icons:
  android: true
  ios: true
  image_path_android: 'app_icons/android-development.png'
  image_path_ios: 'app_icons/ios-development.png'
  image_path_ios_dark_transparent: 'app_icons/logo-development.png'
  image_path_ios_tinted_grayscale: 'app_icons/logo-development.png'
  desaturate_tinted_to_grayscale_ios: true
  remove_alpha_ios: true
  adaptive_icon_background: '#ffffff'
  adaptive_icon_foreground: 'app_icons/logo-development.png'
  adaptive_icon_foreground_inset: 0
  adaptive_icon_monochrome: 'app_icons/logo-development.png'
  web:
    generate: false
  windows:
    generate: false
  macos:
    generate: false
@vlazdra vlazdra added the bug label Oct 8, 2024
@vlazdra vlazdra linked a pull request Oct 8, 2024 that will close this issue
@MarkOSullivan94
Copy link
Collaborator

MarkOSullivan94 commented Oct 9, 2024

The Dark and Tinted icons should be placed in the already existing or the main AppIcon catalog (taking into account the flavor part if present)

@vlazdra can you please provide me with a link to the documentation which states this?

I tested the v0.14.1 dark icon and tinted icon implementation tonight with no issues thankfully

@vlazdra
Copy link
Author

vlazdra commented Oct 9, 2024

@vlazdra, could you please provide a link to the documentation that outlines this?

@MarkOSullivan94 I haven't had a chance to review the documentation thoroughly, but when I open the Xcode preview of the icon catalog, I notice that for the icon you've set up, there are additional versions on the right side. Assuming the UI in Xcode serves as the guide, I believe that if I'm creating different versions of the same icon, they should be placed within the same catalog that already contains all existing icon sizes and dimensions, including the newly added dark and tinted icons. Since these are variations of the same launcher icon, they should reside in the same launcher icon catalog.

Currently, my launcher icon is named AppIcon, and I have three different sets based on the flavor:

  • AppIcon-development.appiconset
  • AppIcon-staging.appiconset
  • AppIcon-production.appiconset

However, the current version of the library is creating an additional appiconset for the dark and tinted versions for each flavor, which seems unnecessary. Additionally, the Contents.json file references the correct icons but points to the wrong directory, causing the icons not to display properly in Xcode when using flavors.

When I run the command to generate all the flavors in my project, it unnecessarily creates additional catalogs that aren't properly linked with the main icon set. Here's a screenshot illustrating this issue:
Issue Screenshot

On the other hand, with the changes I've introduced in this PR, the Dark and Tinted icons are generated inside my main app icon set folder, ensuring they are properly linked and displayed in Xcode:
Fixed Screenshot

Note: The Contents.json file is generated accordingly, so I haven't modified that file.

@MarkOSullivan94
Copy link
Collaborator

@KevinHaendel I know you worked on this feature, what's your thoughts?

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

Successfully merging a pull request may close this issue.

2 participants