Jongdari
是一个自定义抽屉效果转场动画框架。
- direction
- animationType
- openDuration
- closeDuration
- distanceMultiplier
- maximumDraggingPercent
- scaleFactor
- maskOpacity
- open(_:animationConfigurationBuilder:)
- registerOpenDrawerGesture(_:maximumDraggingPercent:transitionHandler:)
- pushViewControllerFromDrawer(_:animated:)
- presentFromDrawer(_:animated:closeDrawer:completion:)
let viewController = UIViewController()
self.vm.open(viewController) { (animationConfiguration) in
/// update animation configuration
return animationConfiguration
}
self.vm.registerOpenDrawerGesture(.edge) { (direction) in
switch direction {
case .left:
/// do somethings
case .right:
/// do somethings
}
}
self.vm.presentFromDrawer(viewController, animated: true, closeDrawer: true, completion: nil)
self.vm.pushViewControllerFromDrawer(viewController, animated: true)
- iOS 10.0+
- Swift 5.0+
https://github.com/spirit-jsb/Jongdari.git
spirit-jsb, sibo_jian_29903549@163.com
Jongdari
可在 MIT
许可下使用,更多详情请参阅许可文件。