A simple Ripple animation view in SwiftUI.
solid | outlined |
---|---|
<img style="max-width:100%;" src=https://raw.githubusercontent.com/emmanuelkehinde/RippleView/main/Media/solid.gif?raw=true width=400 align="center" /> |
<img style="max-width:100%;" src=https://raw.githubusercontent.com/emmanuelkehinde/RippleView/main/Media/outlined.gif?raw=true width=400 align="center" /> |
Here is how to integrate the library into your iOS project.
https://github.com/emmanuelkehinde/RippleView.git
Place the RippleView
anywhere you want it to appear in your SwiftUI View.
ZStack {
RippleView()
}
You also have access to some customization options.
@State private var rippleShouldAnimate: Bool = true
ZStack {
RippleView(
style: .solid,
rippleCount: 7,
tintColor: Color.blue,
timeIntervalBetweenRipples: 0.18,
shouldAnimate: $rippleShouldAnimate
)
}
Available parameters include:
solid
or outlined
, defaults to solid
5
black
0.13
true
https://emmanuelkehinde.io/swiftui-building-a-reusable-ripple-animation-view-swift-package/
Enjoy 🚀
link |
Stars: 2 |
Last commit: 2 years ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics