Orbiting Icons
Concentric orbits of app icons or avatars circling a center logo at different speeds and directions, always upright. Tap the center to send a shock-wave pulse that kicks and spins the orbits.
- animation
- icon
- motion
snippet.swift206 lines
5 files • Scroll to see all →
/// One orbit: a radius, a speed and the items riding on it.public struct OrbitingIconsRing<Item: Identifiable> { public var radius: CGFloat /// Seconds per full revolution. public var period: Double public var clockwise: Bool /// Rotation offset of the first item. public var phase: Angle public var items: [Item] public init(radius: CGFloat, period: Double = 20, clockwise: Bool = true, phase: Angle = .zero, items: [Item]) { self.radius = radius self.period = period self.clockwise = clockwise self.phase = phase self.items = items }}Viewing: OrbitRingModel.swift•1 of 5