MMLoadingButton 1.0.4

MMLoadingButton 1.0.4

测试已测试
Lang语言 SwiftSwift
许可证 MIT
发布最后发布2016年10月
SPM支持 SPM

MM 维护。



  • Millman

MMLoadingButton

示例

要运行示例项目,请克隆仓库,并首先从 Example 目录中运行 pod install

要求

描述:这是一个自定义按钮,带有加载进度动画以及成功和错误状态。

    1.Scuess can set Transition
    2.Error can set reminder message
    3.Error message will autoLayout when show

1. 错误、成功、过渡的演示

LoadingButton

2. 设置

LoadingButton

3. 设置(错误颜色、顶部边距、字体)

LoadingButton

2. 带钩子动画的成功

loadingButton.stopLoading(true, completed: {
    print("Scuess Completed")
})

LoadingButton

3. 带叉号动画的错误

loadingButton.stopLoading(false, completed: {
    print("Error Completed")
})

LoadingButton

4. 带叉号、消息和动画的错误

loadingButton.stopWithError("Error !!", hideInternal: 2, completed: {
    print ("Fail Message Completed")
})

LoadingButton

5. 使用函数添加过渡

    loadingBtn.addScuessPresentVC(vc)

LoadingButton

如果您以默认过渡方式呈现 presentingViewController,则可以使用以下方式添加自定义过渡:

    loadingBtn.addScuessWithDismissVC()

LoadingButton

6. 当显示错误消息时自动推送底部视图

LoadingButton

安装

MMLoadingButton 通过 CocoaPods 提供。要安装它,只需将以下行添加到您的 Podfile 中

Swift3
pod "MMLoadingButton"
Swift 2.3
pod ‘MMCardView’,:git => 'https://github.com/MillmanY/MMLoadingButton', :branch => ‘Swift2

作者

Millman, [email protected]

许可证

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