Swiftpack.co - DeluxeAlonso/DLProgressHUD as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by DeluxeAlonso.
DeluxeAlonso/DLProgressHUD 1.0.0
Lightweight Progress HUD implementation for iOS.
⭐️ 4
🕓 51 weeks ago
.package(url: "https://github.com/DeluxeAlonso/DLProgressHUD.git", from: "1.0.0")


CI Status Version License Platform

Lightweight Progress HUD implementation for iOS.


Loading Loading with text Text only Image Image with text
<img style="max-width:100%;" src="Scsrc="https://raw.github.com/DeluxeAlonso/DLProgressHUD/main/hots/TextOnly.png" width=200 height=100>

Example project

To run the example project, clone the repo, and run pod install from the Example directory beforehand.


DLProgressHUD requires iOS 13.0 and Swift 5.0 or above. For iOS 12 support you can use 0.1.12 pod version.


DLProgressHUD is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'DLProgressHUD'


There are five modes that can be used to show the progress HUD: loading, loadingWithText, textOnly, image and imageWithText.

You just need to call the show method and pass the HUD mode as a parameter:


Available HUD modes

Mode Description
loading HUD with an activity indicator only
loadingWithText(_ text: String) HUD with an activity indicator and a text label below it
textOnly(_ text: String) HUD with a text label only
image(_ image: UIImage) HUD with an image view only
imageWithText(image: UIImage, text: String) HUD with an image view and a text label below it

Appearance and presentation configuration

There are two ways to configure the appearance and presentation of DLProgressHUD:

  1. You can do it globally using the DefaultHudConfiguration class before instantiation.
DLProgressHUD.defaultConfiguration.backgroundInteractionEnabled = true
  1. You can create your own configuration instance that conforms to HudConfigurationProtocol protocol and pass it on DLProgressHUD's methods.
struct HudCustomConfiguration: HudConfigurationProtocol {
    var hudContentPreferredHeight: CGFloat = 64
    var hudContentPreferredWidth: CGFloat = 180
    var textFont: UIFont = .systemFont(ofSize: 18.0)
let configuration = HudCustomConfiguration()
DLProgressHUD.show(.textOnly("Loading..."), configuration: configuration)


DeluxeAlonso, [email protected]


DLProgressHUD is available under the MIT license. See the LICENSE file for more info.


Stars: 4
Last commit: 51 weeks ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

Update deployment target to iOS 13
51 weeks ago

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics