exyte / fan-menu

Menu with a circular layout based on Macaw
MIT License
728 stars 58 forks source link

add method so we can change the image of FanMenuButton #57

Closed amirtutunchi closed 1 year ago

amirtutunchi commented 3 years ago

Hi first of all thanks for this wonderful component, it would be very nice if we could have better access to the image view of FanMenuButton. for example we could change the image or set the font for the title label. I think that way you can not use struct for FanMenuButton

shipinev commented 3 years ago

Hey @amirtutunchi. Glad that you like FanMenu, and thanks for your feedback. I will discuss these API changes with our team. Thanks!

f3dm76 commented 1 year ago

Hey @amirtutunchi, sorry for super late response. You can already set the image of the button like this:

FanMenuButton(
                id: button.0,
                image: UIImage(named: "image_name"), 
                color: Color(val: button.1)
            )

I added font and font weight in version 0.7.6, please give it a go, have a nice day P.S. you might want to check out this library in SwiftUI, which does the same https://github.com/exyte/FloatingButton