All Projects → zevwings → ZVProgressHUD

zevwings / ZVProgressHUD

Licence: MIT License
ZVProgressHUD is a pure-swift and wieldy HUD.

Programming Languages

swift
15916 projects
ruby
36898 projects - #4 most used programming language
objective c
16641 projects - #2 most used programming language

Projects that are alternatives of or similar to ZVProgressHUD

Ftindicator
A light wight UI package contains local notification, progress HUD, toast, with blur effect, elegant API and themes support.
Stars: ✭ 292 (+873.33%)
Mutual labels:  notifications, progress, hud
Lcprogresshud
一个超简单的活动指示器。适配横屏。
Stars: ✭ 100 (+233.33%)
Mutual labels:  progress, hud
Progresshud
ProgressHUD is a lightweight and easy-to-use HUD for iOS.
Stars: ✭ 2,045 (+6716.67%)
Mutual labels:  hud, progresshud
Svprogresshud
A clean and lightweight progress HUD for your iOS and tvOS app.
Stars: ✭ 12,339 (+41030%)
Mutual labels:  progress, hud
Apesuperhud
A simple way to display a HUD with a message or progress information in your application.
Stars: ✭ 156 (+420%)
Mutual labels:  progress, hud
react-native-modal-loader
Customizable animated modal progress hud for react apps.
Stars: ✭ 36 (+20%)
Mutual labels:  progress, hud
fluffychat
+++++Moved to GitLab+++++
Stars: ✭ 47 (+56.67%)
Mutual labels:  notifications
progress
Class to show progress during script run
Stars: ✭ 64 (+113.33%)
Mutual labels:  progress
Graphical notifications Zabbix
No description or website provided.
Stars: ✭ 77 (+156.67%)
Mutual labels:  notifications
corpwechatbot
企业微信的python封装接口,简易上手,开箱即用,一行代码实现消息推送。A more convenient python wrapper interface of corpwechat(wework, wecom) official API, use only one line of code to send your messages to your corpwechat(wework, wecom) .
Stars: ✭ 119 (+296.67%)
Mutual labels:  notifications
OneSignal-WordPress-Plugin
OneSignal is a free push notification service for web and mobile apps. This plugin makes it easy to integrate your website with OneSignal Push Notifications. https://onesignal.com
Stars: ✭ 71 (+136.67%)
Mutual labels:  notifications
DottedProgressBar
Simple and powerful animated progress bar with dots
Stars: ✭ 40 (+33.33%)
Mutual labels:  progress
content-reminder
⏰ A GitHub Action that reminds you to share your own content
Stars: ✭ 28 (-6.67%)
Mutual labels:  notifications
spontit-api-python-wrapper
Send functional, flexible push notifications to iOS, Android, and desktop devices (without your own app or website).
Stars: ✭ 35 (+16.67%)
Mutual labels:  notifications
abstract notifier
ActionMailer-like interface for any type of notifications
Stars: ✭ 105 (+250%)
Mutual labels:  notifications
wearable
Android Wear/ Wear OS Examples
Stars: ✭ 67 (+123.33%)
Mutual labels:  notifications
react-awesome-notifications
A beautiful fully customizable React + Redux notification system built with styled-components
Stars: ✭ 29 (-3.33%)
Mutual labels:  notifications
homely
🏠 - A bunch of mosquittos. IoT wiring and notification framework, with an unix style.
Stars: ✭ 15 (-50%)
Mutual labels:  notifications
php-onesignal-sdk
PHP SDK for OneSignal RESTful API
Stars: ✭ 19 (-36.67%)
Mutual labels:  notifications
SimpleCloudNotifier
SimpleCloudNotifier is a app to display messages that you can send to your phone with a simple POST requests.
Stars: ✭ 15 (-50%)
Mutual labels:  notifications

ZVProgressHUD

Carthage compatible CocoaPods Compatible Platform

ZVProgressHUD is a pure-swift and wieldy HUD.

中文文档

Requirements

  • iOS 8.0+
  • Swift 5.0

Appetize

You can run this demo at Appetize

Installation

Cocoapod

CocoaPods is a dependency manager for Swift and Objective-C Cocoa projects.

You can install Cocoapod with the following command

$ sudo gem install cocoapods

To integrate ZVProgressHUD into your project using CocoaPods, specify it into your Podfile

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'

target 'TargetName' do
    use_frameworks!
    pod 'ZVProgressHUD', '~> 2.0.0'
end

Then,install your dependencies with CocoaPods.

$ pod install

Carthage

Carthage is intended to be the simplest way to add frameworks to your application.

You can install Carthage with Homebrew using following command:

$ brew update
$ brew install carthage

To integrate ZVProgressHUD into your project using Carthage, specify it into your Cartfile

github "zevwings/ZVProgressHUD" ~> 0.0.1

Then,build the framework with Carthage using carthage update and drag ZVProgressHUD.framework into your project.

Note:

The framework is under the Carthage/Build, and you should drag it into Target -> Genral -> Embedded Binaries

Usage

You can use import ProgressHUD when you needed to use ZVProgressHUD.

Showing a HUD

When you start a task, You can using following code:

// class method
ProgressHUD.shared.show()
// or you can use instance method 
let hud = ProgressHUD()
hud.show()

you can custom animation type, use following code:

/// the animation type, default is flat
public enum AnimationType {
	case flat		
	case native	
}

/// this code will modify global animation type.
ProgressHUD.shared.animationType = .flat

when you want modify the superview of ZVProgressHUD, use the following code:

// the HUD will show delay 0.0
ZVProgressHUD.show(with: "Loading", in: superview, delay: 0.0)

Dismiss a HUD

you can use a simple code to close HUD.

// class method
ProgressHUD.shared.dismiss()
// or you can use instance method 
hud.dismiss()

Showing a confirm

when you want show a comfirm infomation, use the following code:

ProgressHUD.shared.showError(with: "error")
ProgressHUD.shared.showSuccess(with: "success")
ProgressHUD.shared.showWarning(with: "warning")

Showing a custom image

you also can show a custom image, use the following code:

let image = UIImage(named: "smile")
ProgressHUD.shared.showImage(image!)
// or
ProgressHUD.shared.showImage(image!, title: "smile everyday!")

Showing a custom animation

you can use the following code to custom a animation indicator.

var images = [UIImage]()
for index in 1 ... 3 {
    let image = UIImage(named: "loading_0\(index)")
    images.append(image!)
}

ProgressHUD.shared.showAnimation(images)

Showing a progress

ProgressHUD.shared.showProgress(0.0, title: "Progress")

Custom logo

// set logoSize of HUD, CGSize(30, 30)
class var logoSize: CGSize 
// set logo image of HUD, default is nil
class var logo: UIImage 

Custom properties

// set displayStyle type of HUD, default is dark.
class var displayStyle: DisplayStyle 

// set mask type of HUD
class var maskType: MaskType 

// the cornerRadius of basic view   
class var cornerRadius: CGFloat 

// the offset of basic view
class var offset: UIOffset 

// the font of title label
class var font: UIFont 

// you can change the line width of indicator when animation type is `flat`
class var strokeWith: CGFloat 

// the size of indicator
class var indicatorSize: CGSize 

// the animation type, default is `flat`
class var animationType: IndicatorView.AnimationType 

Custom Insets of content

class var contentInsets: UIEdgeInsets 

class var titleEdgeInsets: UIEdgeInsets 

class var indicatorEdgeInsets: UIEdgeInsets 

Notifications

you can add an observer to do something from hud's notifications.

extension NSNotification.Name {
	
	 // this hud did disappear
    public static let ProgressHUDReceivedTouchUpInsideEvent: Notification.Name

	 // this hud will appear
    public static let ProgressHUDWillAppear: Notification.Name

	 // this hud did appear
    public static let ProgressHUDDidAppear: Notification.Name

	 // this hud will disappear
    public static let ProgressHUDWillDisappear: Notification.Name

	 // this hud did disappear
    public static let ProgressHUDDidDisappear: Notification.Name
}

License

ZVProgressHUD distributed under the terms and conditions of the MIT License

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].