From b05b6c20c08478a570952d821d5d38cb4d05cd75 Mon Sep 17 00:00:00 2001 From: Kevin G Christiano Date: Tue, 26 May 2020 09:38:08 -0400 Subject: [PATCH] looking bette --- MVMCoreUI/Atomic/Atoms/Views/LoadingSpinner.swift | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/MVMCoreUI/Atomic/Atoms/Views/LoadingSpinner.swift b/MVMCoreUI/Atomic/Atoms/Views/LoadingSpinner.swift index 4a82793b..675e40d0 100644 --- a/MVMCoreUI/Atomic/Atoms/Views/LoadingSpinner.swift +++ b/MVMCoreUI/Atomic/Atoms/Views/LoadingSpinner.swift @@ -77,7 +77,7 @@ open class LoadingSpinner: View { Pose(delay: 0.7, start: 0.500, length: 0.5), Pose(delay: 0.6, start: 1.000, length: 0.3), Pose(delay: 0.5, start: 1.500, length: 0.2), - Pose(delay: 0.4, start: 1.875, length: 0.2), + Pose(delay: 0.5, start: 1.875, length: 0.2), Pose(delay: 0.3, start: 2.250, length: 0.3), Pose(delay: 0.2, start: 2.600, length: 0.5), Pose(delay: 0.2, start: 3.000, length: 0.7) @@ -93,7 +93,7 @@ open class LoadingSpinner: View { var strokeEnds = [CGFloat]() let poses = Self.poses - let totalSeconds = poses.reduce(0) { $0 + $1.delay } + var totalSeconds: CFTimeInterval = poses.reduce(0) { $0 + $1.delay } for pose in poses { time += pose.delay @@ -103,6 +103,8 @@ open class LoadingSpinner: View { strokeEnds.append(pose.length) } + totalSeconds += 0.3 + animateKeyPath(keyPath: "strokeEnd", duration: totalSeconds, times: times, values: strokeEnds) animateKeyPath(keyPath: "transform.rotation", duration: totalSeconds, times: times, values: rotations) }