gianpispi / Bauletto

Display iOS 13 style banner with ease.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ideas for improving

wiencheck opened this issue · comments

• Customizable duration fo the animation, 1 second feels unnecessary long for the slide animation
• Banner grows if image is big, I think the height of the banner should be locked to certain value so it looks more concise
• If text is too long, the banner just expands horizontally, sometimes even outside screen's bounds. Using something like MarqueeLabel or at least multi-line label would be great.
• The forceShowNext() method does not seem to work, it makes the current banner disappear and doesn't show the next one. For now I had to use a workaround shown below:

            Bauletto.hide()
            Bauletto.shared.removeBannersInQueue()
            DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
                Bauletto.show(withSettings: settings)
            }

• Adding tap gesture so touching the banner would perform some action
• Swiping the banner out of the screen, that's the thing I don't like about stock banners, they lack any interactivity
• There should be a way to figure out publicly if a banner is currently visible
• If nil is passed as icon, the image of heart appears, I think it should be empty in this case. For now I'm passing UIImage() instead of nil

I think this library is great and I love how it looks, but it could use some improvements. If I ever find some time I'm gonna try to submit a PR with some of those changes 😃

Hi Adam,
Thanks for your feedback, it really means a lot to me.

Those are really great ideas, which I would like to implement. Right now I don't have much time, but I will try to carve out some for these improvements! PRs are always accepted 😉

Thanks again!

I needed something like this in my app quickly and decided to create my own library for this purpose. Your project inspired me so the similar name is no coincidence 😛

https://github.com/wiencheck/Bauly