diff --git a/NKModalPresenter/NKModalController.swift b/NKModalPresenter/NKModalController.swift index 3609c26..d2cfc1e 100644 --- a/NKModalPresenter/NKModalController.swift +++ b/NKModalPresenter/NKModalController.swift @@ -426,6 +426,11 @@ public class NKModalController: NKModalContainerViewController { } } + public func updatePosition(_ position: NKModalPresentPosition, duration: TimeInterval? = nil, completion: (() -> Void)? = nil) { + targetPosition = position + updateLayout(duration: duration, completion: completion) + } + public func updateLayout(duration: TimeInterval? = nil, completion: (() -> Void)? = nil) { contentSize = getContentSize() layoutView(duration: duration, completion: completion)