Blank
Example
import Blank
var num = 0
let blank: Blank = Blank(type: .fail, image:Blank.image(type: .fail), title: "请求失败", desc: "10014") { tap in
num += 1
print("clicked:\(num)")
self.view.blankConfReset()
}
view.setBlank(blank)
DispatchQueue.main.asyncAfter(deadline: .now() + 2) {
self.view.reloadBlank()
}
DispatchQueue.main.asyncAfter(deadline: .now()+2) {
self.view.updateBlankConf { (conf) in
conf.backgorundColor = .black
conf.titleFont = .boldSystemFont(ofSize: 14);
conf.titleColor = .white
conf.descFont = .boldSystemFont(ofSize: 14);
conf.descColor = .white
conf.verticalOffset = 200
}
}
To run the example project, clone the repo, and run pod install
from the Example directory first.
Requirements
Installation
Blank is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'Blank'
Author
ablett, [email protected]
License
Blank is available under the MIT license. See the LICENSE file for more info.