relatedcode / ProgressHUD

ProgressHUD is a lightweight and easy-to-use HUD for iOS. Over 5000+ animations. ‼️

Home Page:https://relatedcode.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

completion handler on hide

gurgeous opened this issue · comments

Great work, thanks for making it available! This thing is sweet.

One minor feature request. It would be nice to get a callback after the if hide timer, since I typically have to take some action on my end. For example, I want to show "Success!" for 1.5 seconds and then dismiss my modal vc. The builtin hiding delay is thoughtful but I can't take advantage of it without a completion handler.

Typical flow:

  1. show hud for at least one second even if network request is quite fast
  2. show "Success!" for 1.5 seconds to give user a chance to read
  3. hide hud & dismiss view controller