Decathlon / vitamin-ios

Decathlon Design System UI components for iOS & iPadOS applications
https://www.decathlon.design
Apache License 2.0
48 stars 14 forks source link

feat: convenience api for flags assets #67

Closed florentlotthepro closed 2 years ago

florentlotthepro commented 2 years ago

Changes description

Add an API to get flags assets from a string.

Context

When we need to use a flag, we have a country code but currently, with the country code, we cannot get the flag.

Checklist

Does this introduce a breaking change?

Other information

How to use:

let frenchFlag: UIImage? = VitaminAssets.flag(countryCode: "fr")?.image
sonarcloud[bot] commented 2 years ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication