https://github.com/gokulnair2001/capo
A custom Framework used to add animations and effect to UIButtons.
https://github.com/gokulnair2001/capo
animation animations capo convenient custom-library flash gradient-background pulse swift5 uibutton uikit xcode
Last synced: 3 months ago
JSON representation
A custom Framework used to add animations and effect to UIButtons.
- Host: GitHub
- URL: https://github.com/gokulnair2001/capo
- Owner: gokulnair2001
- License: mit
- Created: 2020-12-26T08:32:19.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-01-05T09:38:44.000Z (over 4 years ago)
- Last Synced: 2025-11-27T15:31:59.642Z (6 months ago)
- Topics: animation, animations, capo, convenient, custom-library, flash, gradient-background, pulse, swift5, uibutton, uikit, xcode
- Language: Swift
- Homepage: https://capoframe.github.io/Capo/
- Size: 218 KB
- Stars: 11
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Capo
[](https://cocoapods.org/pods/Capo)






[](https://cocoapods.org/pods/Capo)
## About 📒
So Capo is a custom Framework used to apply various animations and effect to a button. Capo reduces your 10-12 lines of code to 1 line making it more convenient to read and execute. Capo comes with various animations like pulse, flash and effects like applying gradient background and etc. So capo doesn't require any additional dependency's ,its a small and optimized library to make your work more convenient, easy, optimised and easy to understand too.
## Idea ❤️
So while coding I found whenever it was about applying animations and effects we were supposed to write same lines of code multiple time, this made my coding frequency slow and even making the code appearance bad. So I thought to make a library which would make my work easy eventually making others work too. This was the idea behind developing Capo.
## Example
To run the example project, clone the repo, and run `pod install` from the Example directory first.
## Requirements
Device running on iOS/iPadOS 12.0+ versions 📱.
## Installation
Capo is available through [CocoaPods](https://cocoapods.org). To install
it, simply add the following line to your Podfile:
```ruby
pod 'Capo'
```
# How To Use 📁 ?
### Apply CornerRadius, BorderWidth and BorderColor
```swift
CapoTuner.tune(button: UIButton ,cornerRadius: CGFloat, borderWidth: CGFloat, borderColor: UIColor )
```
### Apply Gradient Background
```swift
CapoTuner.applyGradient(button:UIButton, color1: UIColor, color2: UIColor, cornerRadius: CGFloat)
```
### Apply Shadow Effect
```swift
CapoTuner.applyShadow(button: UIButton, color: UIColor, width: Double, height: Double, Radius: CGFloat, opacity: Float)
```
### Apply Pulse Animation
```swift
CapoTuner.pulsate(button: UIButton, duration: CFTimeInterval, from: CFTimeInterval, to: CFTimeInterval, autoReverse: Bool = false, repeatCount: Float = 0,velocity: CGFloat, damping: CGFloat)
```
### Apply Flash Aimation
```swift
CapoTuner.flash(button: UIButton, duration: CFTimeInterval, from: CFTimeInterval, to: CFTimeInterval, autoReverse: Bool = false, repeatCount: Float = 0)
```
### Apply PopColor Animation
```swift
CapoTuner.popColors(button: UIButton,fromColor: UIColor, toColor: UIColor, cornerRadius:CGFloat = 0,duration: CFTimeInterval, autoReverse: Bool = false, repeatCount: Float = 0)
```
# Snapshots 🌉
Effect 1 | Effect 2| Effect 3|
--- | --- | ---
|
|
|
Effect 4| Effect 5| Effect 6|
--- | --- | ---
|
|
|
* Sample animations given above are made with arbitrary values, you can change it according to your need 🎛.
* Above given animations are applied on UIButtons!.
## License
Capo is available under the MIT license. See the [LICENSE](https://github.com/gokulnair2001/Capo/blob/master/LICENSE) for more info.
## How to Contribute ✍️
* Install the pod - Steps mentioned above
* If you face issues in any step open a new issue.
* To fix issues: Fork this repository, make your changes and make a Pull Request.
## Note 🔴
* By default the "autoreverse" function for animations are kept false.
## Updates ⚠️
Right now capo comes with limited features, it will be updated with future releases, So stay tuned to know more about Capo.
## Project Admin 👨🏻💻
|
|
| :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
| **[Gokul Nair](https://www.linkedin.com/in/gokul-r-nair/)** |
|
|
# Like the Project ?
If you like using any of my projects or like what I'm doing, please consider backing me with appreciating my work: [Message me](https://www.linkedin.com/in/gokul-r-nair/)🥰
OR
**Drop a star ⭐ if you find this project interesting!**
Made with ❤️ in 🇮🇳 By Gokul Nair