react-native-reanimated 3.6.2 → 3.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/lib/module/createAnimatedComponent/commonTypes.js.map +1 -1
  2. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Bounce.js +10 -0
  3. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Bounce.js.map +1 -1
  4. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Fade.js +10 -0
  5. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Fade.js.map +1 -1
  6. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Flip.js +12 -0
  7. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Flip.js.map +1 -1
  8. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Lightspeed.js +4 -0
  9. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Lightspeed.js.map +1 -1
  10. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Pinwheel.js +2 -0
  11. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Pinwheel.js.map +1 -1
  12. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Roll.js +4 -0
  13. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Roll.js.map +1 -1
  14. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Rotate.js +8 -0
  15. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Rotate.js.map +1 -1
  16. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Slide.js +8 -0
  17. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Slide.js.map +1 -1
  18. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Stretch.js +4 -0
  19. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Stretch.js.map +1 -1
  20. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Zoom.js +16 -0
  21. package/lib/module/reanimated2/layoutReanimation/defaultAnimations/Zoom.js.map +1 -1
  22. package/lib/module/reanimated2/layoutReanimation/web/animationsManager.js +1 -1
  23. package/lib/module/reanimated2/layoutReanimation/web/animationsManager.js.map +1 -1
  24. package/lib/module/reanimated2/platform-specific/jsVersion.js +1 -1
  25. package/lib/module/reanimated2/platform-specific/jsVersion.js.map +1 -1
  26. package/lib/typescript/createAnimatedComponent/commonTypes.d.ts +6 -3
  27. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Bounce.d.ts +10 -0
  28. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Fade.d.ts +10 -0
  29. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Flip.d.ts +12 -0
  30. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Lightspeed.d.ts +4 -0
  31. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Pinwheel.d.ts +2 -0
  32. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Roll.d.ts +4 -0
  33. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Rotate.d.ts +8 -0
  34. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Slide.d.ts +8 -0
  35. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Stretch.d.ts +4 -0
  36. package/lib/typescript/reanimated2/layoutReanimation/defaultAnimations/Zoom.d.ts +16 -0
  37. package/lib/typescript/reanimated2/platform-specific/jsVersion.d.ts +1 -1
  38. package/package.json +1 -1
  39. package/src/createAnimatedComponent/commonTypes.ts +16 -6
  40. package/src/reanimated2/layoutReanimation/defaultAnimations/Bounce.ts +20 -0
  41. package/src/reanimated2/layoutReanimation/defaultAnimations/Fade.ts +19 -0
  42. package/src/reanimated2/layoutReanimation/defaultAnimations/Flip.ts +24 -0
  43. package/src/reanimated2/layoutReanimation/defaultAnimations/Lightspeed.ts +8 -0
  44. package/src/reanimated2/layoutReanimation/defaultAnimations/Pinwheel.ts +4 -0
  45. package/src/reanimated2/layoutReanimation/defaultAnimations/Roll.ts +8 -0
  46. package/src/reanimated2/layoutReanimation/defaultAnimations/Rotate.ts +16 -0
  47. package/src/reanimated2/layoutReanimation/defaultAnimations/Slide.ts +16 -0
  48. package/src/reanimated2/layoutReanimation/defaultAnimations/Stretch.ts +8 -0
  49. package/src/reanimated2/layoutReanimation/defaultAnimations/Zoom.ts +32 -0
  50. package/src/reanimated2/layoutReanimation/web/animationsManager.ts +10 -2
  51. package/src/reanimated2/platform-specific/jsVersion.ts +1 -1
@@ -19,6 +19,8 @@ export class LightSpeedInRight
19
19
  extends ComplexAnimationBuilder
20
20
  implements IEntryExitAnimationBuilder
21
21
  {
22
+ static presetName = 'LightSpeedInRight';
23
+
22
24
  static createInstance<T extends typeof BaseAnimationBuilder>(
23
25
  this: T
24
26
  ): InstanceType<T> {
@@ -79,6 +81,8 @@ export class LightSpeedInLeft
79
81
  extends ComplexAnimationBuilder
80
82
  implements IEntryExitAnimationBuilder
81
83
  {
84
+ static presetName = 'LightSpeedInLeft';
85
+
82
86
  static createInstance<T extends typeof BaseAnimationBuilder>(
83
87
  this: T
84
88
  ): InstanceType<T> {
@@ -139,6 +143,8 @@ export class LightSpeedOutRight
139
143
  extends ComplexAnimationBuilder
140
144
  implements IEntryExitAnimationBuilder
141
145
  {
146
+ static presetName = 'LightSpeedOutRight';
147
+
142
148
  static createInstance<T extends typeof BaseAnimationBuilder>(
143
149
  this: T
144
150
  ): InstanceType<T> {
@@ -191,6 +197,8 @@ export class LightSpeedOutLeft
191
197
  extends ComplexAnimationBuilder
192
198
  implements IEntryExitAnimationBuilder
193
199
  {
200
+ static presetName = 'LightSpeedOutLeft';
201
+
194
202
  static createInstance<T extends typeof BaseAnimationBuilder>(
195
203
  this: T
196
204
  ): InstanceType<T> {
@@ -17,6 +17,8 @@ export class PinwheelIn
17
17
  extends ComplexAnimationBuilder
18
18
  implements IEntryExitAnimationBuilder
19
19
  {
20
+ static presetName = 'PinwheelIn';
21
+
20
22
  static createInstance<T extends typeof BaseAnimationBuilder>(
21
23
  this: T
22
24
  ): InstanceType<T> {
@@ -73,6 +75,8 @@ export class PinwheelOut
73
75
  extends ComplexAnimationBuilder
74
76
  implements IEntryExitAnimationBuilder
75
77
  {
78
+ static presetName = 'PinwheelOut';
79
+
76
80
  static createInstance<T extends typeof BaseAnimationBuilder>(
77
81
  this: T
78
82
  ): InstanceType<T> {
@@ -18,6 +18,8 @@ export class RollInLeft
18
18
  extends ComplexAnimationBuilder
19
19
  implements IEntryExitAnimationBuilder
20
20
  {
21
+ static presetName = 'RollInLeft';
22
+
21
23
  static createInstance<T extends typeof BaseAnimationBuilder>(
22
24
  this: T
23
25
  ): InstanceType<T> {
@@ -64,6 +66,8 @@ export class RollInRight
64
66
  extends ComplexAnimationBuilder
65
67
  implements IEntryExitAnimationBuilder
66
68
  {
69
+ static presetName = 'RollInRight';
70
+
67
71
  static createInstance<T extends typeof BaseAnimationBuilder>(
68
72
  this: T
69
73
  ): InstanceType<T> {
@@ -107,6 +111,8 @@ export class RollOutLeft
107
111
  extends ComplexAnimationBuilder
108
112
  implements IEntryExitAnimationBuilder
109
113
  {
114
+ static presetName = 'RollOutLeft';
115
+
110
116
  static createInstance<T extends typeof BaseAnimationBuilder>(
111
117
  this: T
112
118
  ): InstanceType<T> {
@@ -155,6 +161,8 @@ export class RollOutRight
155
161
  extends ComplexAnimationBuilder
156
162
  implements IEntryExitAnimationBuilder
157
163
  {
164
+ static presetName = 'RollOutRight';
165
+
158
166
  static createInstance<T extends typeof BaseAnimationBuilder>(
159
167
  this: T
160
168
  ): InstanceType<T> {
@@ -20,6 +20,8 @@ export class RotateInDownLeft
20
20
  extends ComplexAnimationBuilder
21
21
  implements IEntryAnimationBuilder
22
22
  {
23
+ static presetName = 'RotateInDownLeft';
24
+
23
25
  static createInstance<T extends typeof BaseAnimationBuilder>(
24
26
  this: T
25
27
  ): InstanceType<T> {
@@ -70,6 +72,8 @@ export class RotateInDownRight
70
72
  extends ComplexAnimationBuilder
71
73
  implements IEntryAnimationBuilder
72
74
  {
75
+ static presetName = 'RotateInDownRight';
76
+
73
77
  static createInstance<T extends typeof BaseAnimationBuilder>(
74
78
  this: T
75
79
  ): InstanceType<T> {
@@ -120,6 +124,8 @@ export class RotateInUpLeft
120
124
  extends ComplexAnimationBuilder
121
125
  implements IEntryAnimationBuilder
122
126
  {
127
+ static presetName = 'RotateInUpLeft';
128
+
123
129
  static createInstance<T extends typeof BaseAnimationBuilder>(
124
130
  this: T
125
131
  ): InstanceType<T> {
@@ -170,6 +176,8 @@ export class RotateInUpRight
170
176
  extends ComplexAnimationBuilder
171
177
  implements IEntryAnimationBuilder
172
178
  {
179
+ static presetName = 'RotateInUpRight';
180
+
173
181
  static createInstance<T extends typeof BaseAnimationBuilder>(
174
182
  this: T
175
183
  ): InstanceType<T> {
@@ -220,6 +228,8 @@ export class RotateOutDownLeft
220
228
  extends ComplexAnimationBuilder
221
229
  implements IExitAnimationBuilder
222
230
  {
231
+ static presetName = 'RotateOutDownLeft';
232
+
223
233
  static createInstance<T extends typeof BaseAnimationBuilder>(
224
234
  this: T
225
235
  ): InstanceType<T> {
@@ -282,6 +292,8 @@ export class RotateOutDownRight
282
292
  extends ComplexAnimationBuilder
283
293
  implements IExitAnimationBuilder
284
294
  {
295
+ static presetName = 'RotateOutDownRight';
296
+
285
297
  static createInstance<T extends typeof BaseAnimationBuilder>(
286
298
  this: T
287
299
  ): InstanceType<T> {
@@ -344,6 +356,8 @@ export class RotateOutUpLeft
344
356
  extends ComplexAnimationBuilder
345
357
  implements IExitAnimationBuilder
346
358
  {
359
+ static presetName = 'RotateOutUpLeft';
360
+
347
361
  static createInstance<T extends typeof BaseAnimationBuilder>(
348
362
  this: T
349
363
  ): InstanceType<T> {
@@ -406,6 +420,8 @@ export class RotateOutUpRight
406
420
  extends ComplexAnimationBuilder
407
421
  implements IExitAnimationBuilder
408
422
  {
423
+ static presetName = 'RotateOutUpRight';
424
+
409
425
  static createInstance<T extends typeof BaseAnimationBuilder>(
410
426
  this: T
411
427
  ): InstanceType<T> {
@@ -20,6 +20,8 @@ export class SlideInRight
20
20
  extends ComplexAnimationBuilder
21
21
  implements IEntryAnimationBuilder
22
22
  {
23
+ static presetName = 'SlideInRight';
24
+
23
25
  static createInstance<T extends typeof BaseAnimationBuilder>(
24
26
  this: T
25
27
  ): InstanceType<T> {
@@ -63,6 +65,8 @@ export class SlideInLeft
63
65
  extends ComplexAnimationBuilder
64
66
  implements IEntryAnimationBuilder
65
67
  {
68
+ static presetName = 'SlideInLeft';
69
+
66
70
  static createInstance<T extends typeof BaseAnimationBuilder>(
67
71
  this: T
68
72
  ): InstanceType<T> {
@@ -106,6 +110,8 @@ export class SlideOutRight
106
110
  extends ComplexAnimationBuilder
107
111
  implements IExitAnimationBuilder
108
112
  {
113
+ static presetName = 'SlideOutRight';
114
+
109
115
  static createInstance<T extends typeof BaseAnimationBuilder>(
110
116
  this: T
111
117
  ): InstanceType<T> {
@@ -155,6 +161,8 @@ export class SlideOutLeft
155
161
  extends ComplexAnimationBuilder
156
162
  implements IExitAnimationBuilder
157
163
  {
164
+ static presetName = 'SlideOutLeft';
165
+
158
166
  static createInstance<T extends typeof BaseAnimationBuilder>(
159
167
  this: T
160
168
  ): InstanceType<T> {
@@ -204,6 +212,8 @@ export class SlideInUp
204
212
  extends ComplexAnimationBuilder
205
213
  implements IEntryAnimationBuilder
206
214
  {
215
+ static presetName = 'SlideInUp';
216
+
207
217
  static createInstance<T extends typeof BaseAnimationBuilder>(
208
218
  this: T
209
219
  ): InstanceType<T> {
@@ -247,6 +257,8 @@ export class SlideInDown
247
257
  extends ComplexAnimationBuilder
248
258
  implements IEntryAnimationBuilder
249
259
  {
260
+ static presetName = 'SlideInDown';
261
+
250
262
  static createInstance<T extends typeof BaseAnimationBuilder>(
251
263
  this: T
252
264
  ): InstanceType<T> {
@@ -290,6 +302,8 @@ export class SlideOutUp
290
302
  extends ComplexAnimationBuilder
291
303
  implements IExitAnimationBuilder
292
304
  {
305
+ static presetName = 'SlideOutUp';
306
+
293
307
  static createInstance<T extends typeof BaseAnimationBuilder>(
294
308
  this: T
295
309
  ): InstanceType<T> {
@@ -336,6 +350,8 @@ export class SlideOutDown
336
350
  extends ComplexAnimationBuilder
337
351
  implements IExitAnimationBuilder
338
352
  {
353
+ static presetName = 'SlideOutDown';
354
+
339
355
  static createInstance<T extends typeof BaseAnimationBuilder>(
340
356
  this: T
341
357
  ): InstanceType<T> {
@@ -17,6 +17,8 @@ export class StretchInX
17
17
  extends ComplexAnimationBuilder
18
18
  implements IEntryExitAnimationBuilder
19
19
  {
20
+ static presetName = 'StretchInX';
21
+
20
22
  static createInstance<T extends typeof BaseAnimationBuilder>(
21
23
  this: T
22
24
  ): InstanceType<T> {
@@ -57,6 +59,8 @@ export class StretchInY
57
59
  extends ComplexAnimationBuilder
58
60
  implements IEntryExitAnimationBuilder
59
61
  {
62
+ static presetName = 'StretchInY';
63
+
60
64
  static createInstance<T extends typeof BaseAnimationBuilder>(
61
65
  this: T
62
66
  ): InstanceType<T> {
@@ -97,6 +101,8 @@ export class StretchOutX
97
101
  extends ComplexAnimationBuilder
98
102
  implements IEntryExitAnimationBuilder
99
103
  {
104
+ static presetName = 'StretchOutX';
105
+
100
106
  static createInstance<T extends typeof BaseAnimationBuilder>(
101
107
  this: T
102
108
  ): InstanceType<T> {
@@ -137,6 +143,8 @@ export class StretchOutY
137
143
  extends ComplexAnimationBuilder
138
144
  implements IEntryExitAnimationBuilder
139
145
  {
146
+ static presetName = 'StretchOutY';
147
+
140
148
  static createInstance<T extends typeof BaseAnimationBuilder>(
141
149
  this: T
142
150
  ): InstanceType<T> {
@@ -23,6 +23,8 @@ export class ZoomIn
23
23
  extends ComplexAnimationBuilder
24
24
  implements IEntryExitAnimationBuilder
25
25
  {
26
+ static presetName = 'ZoomIn';
27
+
26
28
  static createInstance<T extends typeof BaseAnimationBuilder>(
27
29
  this: T
28
30
  ): InstanceType<T> {
@@ -63,6 +65,8 @@ export class ZoomInRotate
63
65
  extends ComplexAnimationBuilder
64
66
  implements IEntryExitAnimationBuilder
65
67
  {
68
+ static presetName = 'ZoomInRotate';
69
+
66
70
  static createInstance<T extends typeof BaseAnimationBuilder>(
67
71
  this: T
68
72
  ): InstanceType<T> {
@@ -107,6 +111,8 @@ export class ZoomInLeft
107
111
  extends ComplexAnimationBuilder
108
112
  implements IEntryExitAnimationBuilder
109
113
  {
114
+ static presetName = 'ZoomInLeft';
115
+
110
116
  static createInstance<T extends typeof BaseAnimationBuilder>(
111
117
  this: T
112
118
  ): InstanceType<T> {
@@ -150,6 +156,8 @@ export class ZoomInRight
150
156
  extends ComplexAnimationBuilder
151
157
  implements IEntryExitAnimationBuilder
152
158
  {
159
+ static presetName = 'ZoomInRight';
160
+
153
161
  static createInstance<T extends typeof BaseAnimationBuilder>(
154
162
  this: T
155
163
  ): InstanceType<T> {
@@ -193,6 +201,8 @@ export class ZoomInUp
193
201
  extends ComplexAnimationBuilder
194
202
  implements IEntryExitAnimationBuilder
195
203
  {
204
+ static presetName = 'ZoomInUp';
205
+
196
206
  static createInstance<T extends typeof BaseAnimationBuilder>(
197
207
  this: T
198
208
  ): InstanceType<T> {
@@ -236,6 +246,8 @@ export class ZoomInDown
236
246
  extends ComplexAnimationBuilder
237
247
  implements IEntryExitAnimationBuilder
238
248
  {
249
+ static presetName = 'ZoomInDown';
250
+
239
251
  static createInstance<T extends typeof BaseAnimationBuilder>(
240
252
  this: T
241
253
  ): InstanceType<T> {
@@ -279,6 +291,8 @@ export class ZoomInEasyUp
279
291
  extends ComplexAnimationBuilder
280
292
  implements IEntryAnimationBuilder
281
293
  {
294
+ static presetName = 'ZoomInEasyUp';
295
+
282
296
  static createInstance<T extends typeof BaseAnimationBuilder>(
283
297
  this: T
284
298
  ): InstanceType<T> {
@@ -322,6 +336,8 @@ export class ZoomInEasyDown
322
336
  extends ComplexAnimationBuilder
323
337
  implements IEntryAnimationBuilder
324
338
  {
339
+ static presetName = 'ZoomInEasyDown';
340
+
325
341
  static createInstance<T extends typeof BaseAnimationBuilder>(
326
342
  this: T
327
343
  ): InstanceType<T> {
@@ -365,6 +381,8 @@ export class ZoomOut
365
381
  extends ComplexAnimationBuilder
366
382
  implements IEntryExitAnimationBuilder
367
383
  {
384
+ static presetName = 'ZoomOut';
385
+
368
386
  static createInstance<T extends typeof BaseAnimationBuilder>(
369
387
  this: T
370
388
  ): InstanceType<T> {
@@ -405,6 +423,8 @@ export class ZoomOutRotate
405
423
  extends ComplexAnimationBuilder
406
424
  implements IEntryExitAnimationBuilder
407
425
  {
426
+ static presetName = 'ZoomOutRotate';
427
+
408
428
  static createInstance<T extends typeof BaseAnimationBuilder>(
409
429
  this: T
410
430
  ): InstanceType<T> {
@@ -449,6 +469,8 @@ export class ZoomOutLeft
449
469
  extends ComplexAnimationBuilder
450
470
  implements IEntryExitAnimationBuilder
451
471
  {
472
+ static presetName = 'ZoomOutLeft';
473
+
452
474
  static createInstance<T extends typeof BaseAnimationBuilder>(
453
475
  this: T
454
476
  ): InstanceType<T> {
@@ -497,6 +519,8 @@ export class ZoomOutRight
497
519
  extends ComplexAnimationBuilder
498
520
  implements IEntryExitAnimationBuilder
499
521
  {
522
+ static presetName = 'ZoomOutRight';
523
+
500
524
  static createInstance<T extends typeof BaseAnimationBuilder>(
501
525
  this: T
502
526
  ): InstanceType<T> {
@@ -545,6 +569,8 @@ export class ZoomOutUp
545
569
  extends ComplexAnimationBuilder
546
570
  implements IEntryExitAnimationBuilder
547
571
  {
572
+ static presetName = 'ZoomOutUp';
573
+
548
574
  static createInstance<T extends typeof BaseAnimationBuilder>(
549
575
  this: T
550
576
  ): InstanceType<T> {
@@ -593,6 +619,8 @@ export class ZoomOutDown
593
619
  extends ComplexAnimationBuilder
594
620
  implements IEntryExitAnimationBuilder
595
621
  {
622
+ static presetName = 'ZoomOutDown';
623
+
596
624
  static createInstance<T extends typeof BaseAnimationBuilder>(
597
625
  this: T
598
626
  ): InstanceType<T> {
@@ -641,6 +669,8 @@ export class ZoomOutEasyUp
641
669
  extends ComplexAnimationBuilder
642
670
  implements IExitAnimationBuilder
643
671
  {
672
+ static presetName = 'ZoomOutEasyUp';
673
+
644
674
  static createInstance<T extends typeof BaseAnimationBuilder>(
645
675
  this: T
646
676
  ): InstanceType<T> {
@@ -689,6 +719,8 @@ export class ZoomOutEasyDown
689
719
  extends ComplexAnimationBuilder
690
720
  implements IExitAnimationBuilder
691
721
  {
722
+ static presetName = 'ZoomOutEasyDown';
723
+
692
724
  static createInstance<T extends typeof BaseAnimationBuilder>(
693
725
  this: T
694
726
  ): InstanceType<T> {
@@ -2,7 +2,10 @@
2
2
 
3
3
  import type { AnimationConfig, AnimationNames, CustomConfig } from './config';
4
4
  import { Animations } from './config';
5
- import type { AnimatedComponentProps } from '../../../createAnimatedComponent/commonTypes';
5
+ import type {
6
+ AnimatedComponentProps,
7
+ LayoutAnimationStaticContext,
8
+ } from '../../../createAnimatedComponent/commonTypes';
6
9
  import { LayoutAnimationType } from '../animationBuilder/commonTypes';
7
10
  import type { StyleProps } from '../../commonTypes';
8
11
  import { createAnimationWithExistingTransform } from './createAnimation';
@@ -89,9 +92,14 @@ function tryGetAnimationConfigWithTransform<
89
92
  return null;
90
93
  }
91
94
 
95
+ type ConstructorWithStaticContext = LayoutAnimationStaticContext &
96
+ typeof config.constructor;
97
+
92
98
  const isLayoutTransition = animationType === LayoutAnimationType.LAYOUT;
93
99
  const initialAnimationName =
94
- typeof config === 'function' ? config.name : config.constructor.name;
100
+ typeof config === 'function'
101
+ ? config.presetName
102
+ : (config.constructor as ConstructorWithStaticContext).presetName;
95
103
 
96
104
  const shouldFail = checkUndefinedAnimationFail(
97
105
  initialAnimationName,
@@ -4,4 +4,4 @@
4
4
  * with the version used to build the native part of the library in runtime.
5
5
  * Remember to keep this in sync with the version declared in `package.json`
6
6
  */
7
- export const jsVersion = '3.6.2';
7
+ export const jsVersion = '3.6.3';