Fix animation

This commit is contained in:
Isaac
2025-09-25 13:38:01 +08:00
parent c32d05fdb2
commit 59d351da90
2 changed files with 8 additions and 1 deletions

View File

@@ -104,7 +104,7 @@ public extension CALayer {
return animation
} else if timingFunction == kCAMediaTimingFunctionSpring {
if #available(iOS 26.0, *) {
if #available(iOS 26.0, *), abs(duration - 0.3832) <= 0.0001 {
let animation = make26SpringAnimationImpl(keyPath, duration)
animation.fromValue = from
animation.toValue = to