📜 ⬆️ ⬇️

App Store style customizable download button

github.com/PavelKatunin/DownloadButton

Recently there was a need to make a download button for video, the download stage itself was very similar to the standard application download button in the Appstore, but only the line showing the already loaded data should have been outside. I thought that such a control could be convenient for displaying a load of different things and that it could be useful somewhere else - and I took it into a separate framework and designed it as cocoapods. Published under Apache 2.0.

It is very welcome to use, edit the code, create an issue on github, offer new features and send a pool of requests.

For the default look, I took a look similar to the one that Apple uses in the Appstore (well, what else?).

Buttons can be customized and brought up, for example, to this state:

Where it made sense, I tried to make editing possible via IB (IB_DESIGNABLE, IBInspectable):

It connects like all the sub-simple, just 2 lines:
pod "DownloadButton" #import <DownloadButton/PKDownloadButton.h> 


There is a Sample project in the repository. Here it is github.com/PavelKatunin/DownloadButton/tree/master/Example
The project is still raw, and it still needs to provide CI and testing.
')
I would be glad if someone will use it in their projects.

In the comments I propose to discuss:
What UI components from Apple applications do you use in your products, but they are not provided in the standard iOS SDK?

Source: https://habr.com/ru/post/259329/


All Articles