mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Make Animated.SpringAnimation JS compatible with Expo SDK 22 (CRNA) native code (#16513)
This commit is contained in:
committed by
Mike Grabowski
parent
ee68b113ff
commit
84241fbcdc
@@ -595,11 +595,14 @@ describe('Native Animated', () => {
|
||||
{
|
||||
type: 'spring',
|
||||
friction: 16,
|
||||
damping: 16,
|
||||
mass: 1,
|
||||
initialVelocity: 0,
|
||||
overshootClamping: false,
|
||||
restDisplacementThreshold: 0.001,
|
||||
restSpeedThreshold: 0.001,
|
||||
tension: 679.08,
|
||||
stiffness: 679.08,
|
||||
toValue: 10,
|
||||
iterations: 1,
|
||||
},
|
||||
@@ -613,11 +616,14 @@ describe('Native Animated', () => {
|
||||
{
|
||||
type: 'spring',
|
||||
friction: 23.05223140901191,
|
||||
damping: 23.05223140901191,
|
||||
mass: 1,
|
||||
initialVelocity: 0,
|
||||
overshootClamping: false,
|
||||
restDisplacementThreshold: 0.001,
|
||||
restSpeedThreshold: 0.001,
|
||||
tension: 299.61882352941177,
|
||||
stiffness: 299.61882352941177,
|
||||
toValue: 10,
|
||||
iterations: 1,
|
||||
},
|
||||
|
||||
@@ -120,6 +120,9 @@ class SpringAnimation extends Animation {
|
||||
restSpeedThreshold: this._restSpeedThreshold,
|
||||
tension: this._tension,
|
||||
friction: this._friction,
|
||||
stiffness: this._tension,
|
||||
damping: this._friction,
|
||||
mass: 1,
|
||||
initialVelocity: withDefault(this._initialVelocity, this._lastVelocity),
|
||||
toValue: this._toValue,
|
||||
iterations: this.__iterations,
|
||||
|
||||
Reference in New Issue
Block a user