Skip to content

Create beautiful, scalable icons with SwiftUI.

License

Notifications You must be signed in to change notification settings

danielsaidi/BadgeIcon

Repository files navigation

Project Icon

Version Swift 6.1 Swift UI Documentation MIT License

BadgeIcon

BadgeIcon is a SwiftUI library that lets you create beautiful, scalable icons, using SF Symbols or custom assets:

Demo gif

BadgeIcon comes with 118 predefined icons, and lets you create custom icons with rich customization options.

Installation

BadgeIcon can be installed with the Swift Package Manager:

https://github.com/danielsaidi/BadgeIcon.git

Getting started

BadgeIcon has 118 predefined icons, like .alert, .bug, and .heart, which will scale to fill the available space:

struct ContentView: View {

    var body: some View {
        BadgeIcon.calendar
        BadgeIcon.heart.frame(width: 150)
    }
}

You can also create your own badge icons, with a rich set of icon and badge style options:

extension BadgeIcon {

    public static let prominentError = Self(
        icon: MyCustomErrorIcon(),
        style: .init(
            badgeColor: .red
        )
    )
}

You can use both Image values or custom views as the icon that is shown inside the badge.

Documentation

The online documentation has more information, articles, code examples, etc.

Demo Application

The Demo folder has a demo app that lets you explore the library and try changing the app icon.

Support My Work

You can become a sponsor to help me dedicate more time on my various open-source tools. Every contribution, no matter the size, makes a real difference in keeping these tools free and actively developed.

Contact

Feel free to reach out if you have questions or want to contribute in any way:

License

BadgeIcon is available under the MIT license. See the LICENSE file for more info.

About

Create beautiful, scalable icons with SwiftUI.

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Contributors 2

  •  
  •