AYPullSheetViewController 1.0.0

AYPullSheetViewController 1.0.0

Anton Yereshchenko 维护。



  • Anton Yereshchenko

AYPullSheetViewController

CI Status Version License Platform

关于

AYPullSheetViewController - 是拉动视图控制器。您可以使用它来显示任何附加信息或向用户提供操作列表以供选择。

安装

AYPullSheetViewController 可通过 CocoaPods 获取。要安装它,只需将以下行添加到您的 Podfile 中

inhibit_all_warnings!

target 'YOUR_TARGET_NAME' do
  use_frameworks!
	pod 'AYPullSheetViewController'
end

使用方法

// 'clickHandler' - closure of 'AYActionViewClickHandler' type.

let pullSheet = AYPullSheetViewController.create(
  initialAppearancePercent: 32,
  finalAppearancePercent: 92,
  horizontalSpacing: 16,
  animationType: .scaled)
  
pullSheet.containerView?.pullView?.topCornerRadius = 16
pullSheet.containerView?.pullView?.arrow?.strokeColor = .action

pullSheet.addRow(actionView: AYPullItemActionView.make(with: "Home", image: nil, clickHandler: clickHandler))
pullSheet.addRow(actionView: AYPullItemActionView.make(with: "About", image: nil, clickHandler: clickHandler))
pullSheet.addRow(actionView: AYPullItemActionView.make(with: "Settings", image: nil, clickHandler: clickHandler))

present(pullSheet, animated: true, completion: nil)

演示

作者

Anton Yereshchenko

许可证

AYPullSheetViewController 在 MIT 许可证下可用。有关更多信息,请参阅 LICENSE 文件。

在项目中使用

图标

Icons8 - https://icons8.com