Closed Kohdepitcher closed 5 years ago
Solved the issue by modifying the following line in the LarkPresentationController
override var frameOfPresentedViewInContainerView: CGRect { guard let containerView = containerView else { return .zero } return CGRect(x: 0, y: containerView.bounds.height - self.height, width: containerView.bounds.width, height: containerView.bounds.height) }
to this
override var frameOfPresentedViewInContainerView: CGRect { guard let containerView = containerView else { return .zero } return CGRect(x: 0, y: containerView.bounds.height - self.height, width: containerView.bounds.width, height: self.height) }
This will make the presented controller using the lark transition to be the same height as the default height or custom height.
Thanks for your research. If you want, you can create Pull Request for Source folder. Or I can do it.
@Kohdepitcher thanks for pull request. I am publish new version 1.0.9
, please, update.
Hi, been trying to use this library to present one of my own custom VCs but I can't work out why the height of the presented view controller using lark doesn't have the same height as the custom height provided to the transition delegate. For example, ive told the delegate to be half the screen size which works for the transition but the view controller that is presented is still the same height as the screen height. This means that any views pinned to the bottom of the safe area for example are missing when using Lark.
in this screen shot, you can see that the pink button is cut off even though it is constrained to be centre vertical and centre horizontal.![IMG_1852](https://user-images.githubusercontent.com/15321325/58148078-a49ee880-7ca0-11e9-84c5-a03d78d01a49.png)
Is there anyway to force the presented view controller's frame to match the frame of the lark transition? I've tried messing with the code in the library and can't seem to get it to work. I've noticed that frameOfPresentedViewInContainerView method never gets called in the presentation controller.
override var frameOfPresentedViewInContainerView: CGRect { guard let containerView = containerView else { return .zero } print("frameOfPresentedViewInContainerView") return CGRect(x: 0, y: containerView.bounds.height - self.height, width: containerView.bounds.width, height: self.height) }