SebastianBoldt / Jelly

🌊 - Jelly is a library for animated, non-interactive & interactive viewcontroller transitions and presentations with the focus on a simple and yet flexible API.
http://www.sebastianboldt.com/
MIT License
2.45k stars 123 forks source link

Adjust height automatically with in-call status bar #39

Closed vdeep closed 6 years ago

vdeep commented 7 years ago

Is there any way we can automatically adjust the height/top of the presented view controller when in-call status bar is displayed/hidden? You can check the screenshots for reference.

jelly-in-call-status-bar-issue

Here I've set the size of the presented view controller to be offset 20 from all sides from main screen bounds. I'm using JellySlideInPresentation with following settings:

let presentation = JellySlideInPresentation(
            dismissCurve: .easeInEaseOut,
            presentationCurve: .easeInEaseOut,
            cornerRadius: 4,
            backgroundStyle: .dimmed(alpha: 0.8),
            jellyness: .jelly,
            duration: .normal,
            directionShow: .bottom,
            directionDismiss: .bottom,
            widthForViewController: .custom(value: targetSize.width),
            heightForViewController: .custom(value: targetSize.height),
            horizontalAlignment: .center,
            verticalAlignment: .center,
            marginGuards: .zero,
            corners: .allCorners)

Please let me know if this is achievable.

SebastianBoldt commented 7 years ago

It is currently not possible to achieve this using Jelly. But I think it could be possible to integrate this functionality into Jellys Presentation Controller Logic. I will try to put this into the next release if its possible. I'll keep you up to date.

UPDATE: According to the Apple Docs this should be possible. I'll give it a try if I find some time.

bildschirmfoto 2017-03-28 um 11 58 44

SebastianBoldt commented 6 years ago

Can be accomplished by using the new LIVE UPDATE Feature in Jelly 2.0.0.