EmptyView
public class EmptyView : UIView
Quick and easy UIView to use when you have no data to show. Also great for displaying errors!
-
Access to
EmptyViewConfig
to set defaults on all instances ofEmptyView
.Declaration
Swift
public static let defaultConfig: EmptyViewConfig
-
Override
defaultConfig
for this once instance.Declaration
Swift
public var config: EmptyViewConfig { get set }
-
Set delegate for
EmptyView
.Declaration
Swift
public weak var delegate: EmptyViewDelegate?
-
Read-only reference to the title
UILabel
.Declaration
Swift
public private(set) var titleLabel: UILabel?
-
Read-only reference to the message
UILabel
Declaration
Swift
public private(set) var messageLabel: UILabel?
-
Read-only reference to the
UIButton
s added toEmptyView
Declaration
Swift
public var buttons: [EmptyViewButtonTag : UIButton] { get }
-
Internal use only.
Declaration
Swift
public let rootView: UIStackView
-
Internal use only.
Declaration
Swift
public let labelsContainer: UIStackView
-
Internal use only.
Declaration
Swift
public let buttonsContainer: UIStackView
-
Read or change the text of
titleLabel
Declaration
Swift
public var title: String? { get set }
-
Read or change the text of
messageLabel
Declaration
Swift
public var message: String? { get set }
-
Add a
UIButton
to theEmptyView
. Note: If there is already aUIView
with givenid
, that view will be removed before the newUIButton
is added.Declaration
Swift
public func addButton(id: EmptyViewButtonTag, message: String)
-
Remove a previously added
UIButton
.Declaration
Swift
public func removeButton(id: EmptyViewButtonTag)
-
Remove all views from
EmptyView
to start over.Declaration
Swift
public func resetViews()
-
Initialize new instance of
EmptyView
.Declaration
Swift
public convenience init()