Daltron / NotificationBanner

The easiest way to display highly customizable in app notification banners in iOS
MIT License
4.79k stars 663 forks source link

Custom View Banner cannot be swiped away #232

Closed Captnwalker1 closed 5 years ago

Captnwalker1 commented 5 years ago

Hello, I have a banner made with a customView with multiple views inside of it. It seems touch and swipe would not close the notification, on the root view that I use as the customView init I tried setting isUserInteractionEnabled = true and also false but doesn't seem to make a difference.

Do the gestures not work with customView?

Daltron commented 5 years ago

Hi @Captnwalker1! 😄 It definitely sounds like one of your views inside your custom view is intercepting the touches and gestures. I would go through each view and try to figure out which ones are causing the issues. This doesn't sound like a problem with the library its self so I will go ahead and close the issue.

Captnwalker1 commented 5 years ago

It is an error with the banner's bounds. I put a custom view in which is 130 tall but the banner is stuck at 64 for bounds so the taps are never delivered on the bottom half of the view.

Example project attached. BannerTest.zip

Captnwalker1 commented 5 years ago

I also now see the bannerHeight property, so a suggestion when the banner is created with a custom view to auto populate that from the customView's height