Description
ConcrentricProgressRingView is a circular progress bar written in Swift that takes inspiration from watchOS's activity ring charts. With an easy-to-use API, you can fully customize the number of rings, color, width, margin, and radius. You can also animate progress updates with a simple method.
ConcentricProgressRingView alternatives and similar libraries
Based on the "Animation" category.
Alternatively, view ConcentricProgressRingView alternatives based on common mentions on social networks and blogs.
-
Pop
An extensible iOS and OS X animation library, useful for physics-based interactions. -
Spring
A library to simplify iOS animations in Swift. -
Shimmer
An easy way to add a simple, shimmering effect to any view in an iOS app. -
IBAnimatable
Design and prototype customized UI, interaction, navigation, transition and animation for App Store ready Apps in Interface Builder with IBAnimatable. -
Keyframes
A library for converting Adobe AE shape based animations to a data format and play it back on Android and iOS devices. -
Advance
Physics-based animations for iOS, tvOS, and macOS. -
JHChainableAnimations
Easy to read and write chainable animations in Objective-C and Swift -
Stellar
A fantastic Physical animation library for swift -
EasyAnimation
A Swift library to take the power of UIView.animateWithDuration(_:, animations:...) to a whole new level - layers, springs, chain-able animations and mixing view and layer animations together! -
Chat App
Real time chat app written in Swift 5 using Firebase -
RZTransitions
A library of custom iOS View Controller Animations and Interactions. -
DKChainableAnimationKit
⭐ Chainable animations in Swift -
PulsingHalo
iOS Component for creating a pulsing animation. -
CKWaveCollectionViewTransition
Cool wave like transition between two or more UICollectionView -
SAConfettiView
Confetti! Who doesn't like confetti? -
Interpolate
Swift interpolation for gesture-driven animations -
LSAnimator
⛓ Easy to Read and Write Multi-chain Animations Lib in Objective-C and Swift. -
Popsicle
Delightful, extensible Swift value interpolation framework -
ActivityIndicatorView
A number of preset loading indicators created with SwiftUI -
AnimationEngine
Easily build advanced custom animations on iOS. -
Awesome-iOS-Animation
Curated list of iOS Animation libraries -
DCAnimationKit
A collection of animations for iOS. Simple, just add water animations. -
ZoomTransitioning
ZoomTransitioning provides a custom transition with image zooming animation and swiping the screen edge. -
Twinkle
:sparkles: Twinkle interface elements in Swift -
JDAnimationKit
Animate easy and with less code with Swift -
FlightAnimator
Advanced Natural Motion Animations, Simple Blocks Based Syntax -
UIView-Shake
UIView category that adds shake animation -
AHKBendableView
UIView subclass that bends its edges when its position changes. -
AHDownloadButton
Customizable download button with progress and transition animations. It is based on Apple's App Store download button. -
Animo
Bring life to CALayers with SpriteKit-like animation builders -
WXWaveView
Add smooth water waves to your views. -
MotionMachine
A powerful, elegant, and modular animation library for Swift. -
RippleEffectView
RippleEffectView - A Neat Rippling View Effect -
SamuraiTransition
SamuraiTransition is an open source Swift based library providing a collection of ViewController transitions featuring a number of neat “cutting” animations. -
JRMFloatingAnimation
An Objective-C animation library used to create floating image views. -
CCMRadarView
CCMRadarView uses the IBDesignable tools to make an easy customizable radar view with animation -
Pop By Example
Facebook's Pop Framework, By Examples -
Walker
Each step you take reveals a new horizon. You have taken the first step today. -
SYBlinkAnimationKit
A blink effect animation framework for iOS, written in Swift. -
ADPuzzleAnimation
Inspired by Fabric - Answers animation. Allows to "build" given view with pieces. Allows to "destroy" given view into pieces -
Wave
:ocean: Declarative chainable animations in Swift -
Stagehand
Modern, type-safe API for building animations on iOS -
SMSwipeableTabView
Swipeable Views with Tabs (Like Android SwipeView With Tabs Layout)
Appwrite - The open-source backend cloud platform
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of ConcentricProgressRingView or a related project?
README
[](meta/repo-banner.png) [](meta/repo-banner-bottom.png)
Fully customizable, circular progress bar written in Swift.
Example
To run the example project, clone the repo, and run pod install
from the Example directory first. You can also view the example app at Appetize.io.
Usage
At the top of your file, make sure to import "ConcentricProgressRingView"
import ConcentricProgressRingView
Then, instantiate ConcentricProgressRingView in your view controller:
func viewDidLoad() {
super.viewDidLoad()
let fgColor1 = UIColor.yellow
let bgColor1 = UIColor.darkGray
let fgColor2 = UIColor.green
let bgColor2 = UIColor.darkGray
let rings = [
ProgressRing(color: fgColor1, backgroundColor: bgColor1, width: 18),
ProgressRing(color: fgColor2, backgroundColor: bgColor2, width: 18),
]
let margin: CGFloat = 2
let radius: CGFloat = 80
let progressRingView = ConcentricProgressRingView(center: view.center, radius: radius, margin: margin, rings: rings)
view.addSubview(progressRingView)
}
[](example1.png)
You can customize the width, margin, and radius, along with the number of rings. Here's another example with 6 progress rings, with a smaller bar width, larger margin between rings, and a larger radius:
let rings = [
ProgressRing(color: fgColor1, backgroundColor: bgColor1, width: 10),
ProgressRing(color: fgColor2, backgroundColor: bgColor2, width: 10),
ProgressRing(color: fgColor1, backgroundColor: bgColor1, width: 10),
ProgressRing(color: fgColor2, backgroundColor: bgColor2, width: 10),
ProgressRing(color: fgColor1, backgroundColor: bgColor1, width: 10),
ProgressRing(color: fgColor2, backgroundColor: bgColor2, width: 10),
]
let margin: CGFloat = 10
let radius: CGFloat = 120
let progressRingView = ConcentricProgressRingView(center: view.center, radius: radius, margin: margin, rings: rings)
Repeating widths can get a bit tedious, so you can omit them---but you'll still need to provide default values to the initializer. If you don't, the compiler will warn you that there's a problem. The initializer can throw if you provide invalid parameters, so you'll need to handle that.
let rings = [
ProgressRing(color: fgColor1, backgroundColor: bgColor1),
ProgressRing(color: fgColor2, backgroundColor: bgColor2),
ProgressRing(color: fgColor1, backgroundColor: bgColor1),
ProgressRing(color: fgColor2, backgroundColor: bgColor2),
ProgressRing(color: fgColor1, backgroundColor: bgColor1),
ProgressRing(color: fgColor2, backgroundColor: bgColor2),
]
let margin: CGFloat = 10
let radius: CGFloat = 120
let width: CGFloat = 8
let progressRingView = try? ConcentricProgressRingView(center: view.center, radius: radius, margin: margin, rings: rings, defaultColor: nil, defaultWidth: width)
Rings can have varying widths, colors, and background colors.
let rings = [
ProgressRing(color: UIColor(.RGB(160, 255, 0)), backgroundColor: UIColor(.RGB(44, 66, 4)), width: 40),
ProgressRing(color: UIColor(.RGB(255, 211, 0)), backgroundColor: UIColor(.RGB(85, 78, 0)), width: 20),
ProgressRing(color: UIColor(.RGB(255, 28, 93))),
]
let progressRingView = try! ConcentricProgressRingView(center: view.center, radius: radius, margin: margin, rings: rings, defaultWidth: 30)
Updating Progress
To animate a progress update, use setProgress
.
ring.arcs[1].setProgress(0.5, duration: 2)
You can also use subscripts to access the individual arcs.
ring[1].setProgress(0.5, duration: 2)
If you just want to change the progress, just set the progress on the ring, and it'll change immediately.
ring[1].progress = 0.5
If you'd like to update multiple rings simulataneously, you can iterate over ConcentricProgressRingView
since it conforms to SequenceType
.
for ring in progressRingView {
ring.progress = 0.5
}
Requirements
Installation
ConcentricProgressRingView is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "ConcentricProgressRingView"
TODO
- [x] Swift 3
- [ ] Documentation
- [x] Tests
Author
Dan Loewenherz, [email protected]
License
ConcentricProgressRingView is available under the Apache 2.0 license. See the [LICENSE](LICENSE) file for more info.
<!-- Images -->
<!-- Links -->
*Note that all licence references and agreements mentioned in the ConcentricProgressRingView README section above
are relevant to that project's source code only.