react-native-reanimated 2.6.0 → 2.9.0

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 (164) hide show
  1. package/Common/cpp/SharedItems/ShareableValue.cpp +2 -2
  2. package/Common/cpp/Tools/RuntimeDecorator.cpp +17 -25
  3. package/android/.gradle/7.2/dependencies-accessors/dependencies-accessors.lock +0 -0
  4. package/android/.gradle/7.2/executionHistory/executionHistory.bin +0 -0
  5. package/android/.gradle/7.2/executionHistory/executionHistory.lock +0 -0
  6. package/android/.gradle/7.2/fileHashes/fileHashes.bin +0 -0
  7. package/android/.gradle/7.2/fileHashes/fileHashes.lock +0 -0
  8. package/android/.gradle/7.2/fileHashes/resourceHashesCache.bin +0 -0
  9. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  10. package/android/.gradle/buildOutputCleanup/cache.properties +1 -1
  11. package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  12. package/android/.gradle/checksums/checksums.lock +0 -0
  13. package/android/.gradle/checksums/md5-checksums.bin +0 -0
  14. package/android/.gradle/checksums/sha1-checksums.bin +0 -0
  15. package/android/CMakeLists.txt +19 -8
  16. package/android/build.gradle +22 -8
  17. package/android/react-native-reanimated-65-hermes.aar +0 -0
  18. package/android/react-native-reanimated-65-jsc.aar +0 -0
  19. package/android/react-native-reanimated-66-hermes.aar +0 -0
  20. package/android/react-native-reanimated-66-jsc.aar +0 -0
  21. package/android/react-native-reanimated-67-hermes.aar +0 -0
  22. package/android/react-native-reanimated-67-jsc.aar +0 -0
  23. package/android/react-native-reanimated-68-hermes.aar +0 -0
  24. package/android/react-native-reanimated-68-jsc.aar +0 -0
  25. package/android/react-native-reanimated-69-hermes.aar +0 -0
  26. package/android/react-native-reanimated-69-jsc.aar +0 -0
  27. package/android/rnVersionPatch/69/.gitkeep +0 -0
  28. package/android/src/main/cpp/NativeProxy.cpp +35 -14
  29. package/android/src/main/cpp/headers/NativeProxy.h +2 -0
  30. package/android/src/main/java/com/swmansion/reanimated/NativeProxy.java +11 -8
  31. package/android/src/main/java/com/swmansion/reanimated/layoutReanimation/AnimationsManager.java +13 -6
  32. package/android/src/main/java/com/swmansion/reanimated/sensor/ReanimatedSensorListener.java +24 -1
  33. package/android/src/main/java/com/swmansion/reanimated/sensor/ReanimatedSensorType.java +7 -5
  34. package/ios/LayoutReanimation/REAAnimationsManager.h +1 -1
  35. package/ios/LayoutReanimation/REAAnimationsManager.m +2 -2
  36. package/ios/LayoutReanimation/REASnapshot.m +1 -1
  37. package/ios/LayoutReanimation/REAUIManager.h +1 -1
  38. package/ios/LayoutReanimation/REAUIManager.mm +4 -5
  39. package/ios/Nodes/REAAlwaysNode.h +1 -1
  40. package/ios/Nodes/REAAlwaysNode.m +5 -5
  41. package/ios/Nodes/REABezierNode.h +1 -1
  42. package/ios/Nodes/REABezierNode.m +4 -5
  43. package/ios/Nodes/REABlockNode.h +1 -1
  44. package/ios/Nodes/REABlockNode.m +2 -2
  45. package/ios/Nodes/REACallFuncNode.h +1 -1
  46. package/ios/Nodes/REACallFuncNode.m +5 -5
  47. package/ios/Nodes/REAClockNodes.h +1 -1
  48. package/ios/Nodes/REAClockNodes.m +4 -4
  49. package/ios/Nodes/REAConcatNode.h +1 -1
  50. package/ios/Nodes/REAConcatNode.m +3 -3
  51. package/ios/Nodes/REACondNode.h +1 -1
  52. package/ios/Nodes/REACondNode.m +3 -3
  53. package/ios/Nodes/READebugNode.h +1 -1
  54. package/ios/Nodes/READebugNode.m +3 -3
  55. package/ios/Nodes/REAEventNode.h +1 -2
  56. package/ios/Nodes/REAEventNode.m +3 -3
  57. package/ios/Nodes/REAFunctionNode.h +1 -1
  58. package/ios/Nodes/REAFunctionNode.m +3 -3
  59. package/ios/Nodes/REAJSCallNode.h +1 -1
  60. package/ios/Nodes/REAJSCallNode.m +3 -3
  61. package/ios/Nodes/REANode.m +2 -2
  62. package/ios/Nodes/REAOperatorNode.h +1 -1
  63. package/ios/Nodes/REAOperatorNode.m +2 -3
  64. package/ios/Nodes/REAParamNode.h +1 -1
  65. package/ios/Nodes/REAParamNode.m +4 -4
  66. package/ios/Nodes/REAPropsNode.h +1 -1
  67. package/ios/Nodes/REAPropsNode.m +4 -6
  68. package/ios/Nodes/REASetNode.h +1 -1
  69. package/ios/Nodes/REASetNode.m +4 -4
  70. package/ios/Nodes/REAStyleNode.h +1 -1
  71. package/ios/Nodes/REAStyleNode.m +2 -3
  72. package/ios/Nodes/REATransformNode.h +1 -1
  73. package/ios/Nodes/REATransformNode.m +2 -2
  74. package/ios/Nodes/REAValueNode.h +1 -3
  75. package/ios/Nodes/REAValueNode.m +1 -1
  76. package/ios/REAEventDispatcher.m +1 -1
  77. package/ios/REAModule.h +1 -1
  78. package/ios/REAModule.m +4 -5
  79. package/ios/REANodesManager.h +1 -2
  80. package/ios/REANodesManager.m +21 -23
  81. package/ios/Transitioning/RCTConvert+REATransition.h +1 -2
  82. package/ios/Transitioning/RCTConvert+REATransition.m +1 -1
  83. package/ios/Transitioning/REAAllTransitions.h +1 -1
  84. package/ios/Transitioning/REAAllTransitions.m +2 -3
  85. package/ios/Transitioning/REATransition.h +2 -3
  86. package/ios/Transitioning/REATransition.m +3 -4
  87. package/ios/Transitioning/REATransitionAnimation.m +1 -2
  88. package/ios/Transitioning/REATransitionManager.m +2 -4
  89. package/ios/Transitioning/REATransitionValues.m +2 -3
  90. package/ios/native/NativeMethods.h +1 -3
  91. package/ios/native/NativeMethods.mm +1 -1
  92. package/ios/native/NativeProxy.h +2 -2
  93. package/ios/native/NativeProxy.mm +20 -17
  94. package/ios/native/REAIOSErrorHandler.h +2 -4
  95. package/ios/native/REAIOSErrorHandler.mm +1 -1
  96. package/ios/native/REAIOSLogger.h +1 -3
  97. package/ios/native/REAIOSLogger.mm +1 -1
  98. package/ios/native/REAIOSScheduler.h +1 -3
  99. package/ios/native/REAIOSScheduler.mm +2 -2
  100. package/ios/native/REAInitializer.h +0 -7
  101. package/ios/native/REAInitializer.mm +13 -3
  102. package/ios/native/UIResponder+Reanimated.mm +3 -3
  103. package/ios/sensor/ReanimatedSensor.h +1 -1
  104. package/ios/sensor/ReanimatedSensor.m +3 -3
  105. package/ios/sensor/ReanimatedSensorContainer.h +1 -1
  106. package/ios/sensor/ReanimatedSensorContainer.m +2 -2
  107. package/lib/Animated.js +8 -30
  108. package/lib/ConfigHelper.js +0 -1
  109. package/lib/index.js +5 -30
  110. package/lib/reanimated2/Easing.js +9 -3
  111. package/lib/reanimated2/NativeReanimated/NativeReanimated.js +1 -1
  112. package/lib/reanimated2/animation/sequence.js +0 -3
  113. package/lib/reanimated2/component/FlatList.js +3 -3
  114. package/lib/reanimated2/component/Image.js +4 -0
  115. package/lib/reanimated2/component/ScrollView.js +4 -0
  116. package/lib/reanimated2/component/Text.js +4 -0
  117. package/lib/reanimated2/component/View.js +4 -0
  118. package/lib/reanimated2/core.js +0 -41
  119. package/lib/reanimated2/globals.d.ts +1 -2
  120. package/lib/reanimated2/hook/utils.js +0 -5
  121. package/lib/reanimated2/js-reanimated/global.js +25 -0
  122. package/lib/reanimated2/js-reanimated/index.js +0 -24
  123. package/lib/reanimated2/mock.js +6 -0
  124. package/lib/types/lib/Animated.d.ts +8 -0
  125. package/lib/types/lib/index.d.ts +4 -0
  126. package/lib/types/lib/reanimated2/commonTypes.d.ts +0 -1
  127. package/lib/types/lib/reanimated2/component/Image.d.ts +3 -0
  128. package/lib/types/lib/reanimated2/component/ScrollView.d.ts +3 -0
  129. package/lib/types/lib/reanimated2/component/Text.d.ts +3 -0
  130. package/lib/types/lib/reanimated2/component/View.d.ts +3 -0
  131. package/lib/types/lib/reanimated2/hook/useAnimatedSensor.d.ts +1 -3
  132. package/lib/types/lib/reanimated2/js-reanimated/global.d.ts +1 -0
  133. package/lib/types/lib/reanimated2/mock.d.ts +6 -0
  134. package/package.json +18 -14
  135. package/plugin.js +36 -33
  136. package/react-native-reanimated.d.ts +16 -7
  137. package/src/Animated.ts +13 -0
  138. package/src/ConfigHelper.ts +0 -1
  139. package/src/index.ts +7 -0
  140. package/src/reanimated2/Easing.ts +9 -3
  141. package/src/reanimated2/NativeReanimated/NativeReanimated.ts +1 -1
  142. package/src/reanimated2/animation/sequence.ts +0 -5
  143. package/src/reanimated2/commonTypes.ts +0 -1
  144. package/src/reanimated2/component/FlatList.tsx +3 -6
  145. package/src/reanimated2/component/Image.ts +6 -0
  146. package/src/reanimated2/component/ScrollView.ts +6 -0
  147. package/src/reanimated2/component/Text.ts +6 -0
  148. package/src/reanimated2/component/View.ts +6 -0
  149. package/src/reanimated2/core.ts +0 -52
  150. package/src/reanimated2/globals.d.ts +1 -2
  151. package/src/reanimated2/hook/useAnimatedSensor.ts +1 -3
  152. package/src/reanimated2/hook/utils.ts +0 -6
  153. package/src/reanimated2/js-reanimated/global.ts +33 -0
  154. package/src/reanimated2/js-reanimated/index.ts +0 -31
  155. package/src/reanimated2/mock.ts +6 -0
  156. package/android/react-native-reanimated-64-hermes.aar +0 -0
  157. package/android/react-native-reanimated-64-jsc.aar +0 -0
  158. package/lib/reanimated2/component/WrappedComponents.js +0 -9
  159. package/lib/reanimated2/component/index.js +0 -4
  160. package/lib/types/lib/reanimated2/component/WrappedComponents.d.ts +0 -8
  161. package/lib/types/lib/reanimated2/component/index.d.ts +0 -9
  162. package/src/Animated.js +0 -31
  163. package/src/reanimated2/component/WrappedComponents.ts +0 -11
  164. package/src/reanimated2/component/index.ts +0 -9
@@ -1,6 +1,6 @@
1
- #import "REAConcatNode.h"
2
- #import "REANodesManager.h"
3
- #import "REAValueNode.h"
1
+ #import <RNReanimated/REAConcatNode.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAValueNode.h>
4
4
 
5
5
  @implementation REAConcatNode {
6
6
  NSArray<NSNumber *> *_input;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REACondNode : REANode
4
4
 
@@ -1,8 +1,8 @@
1
- #import "REACondNode.h"
1
+ #import <RNReanimated/REACondNode.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAUtils.h>
2
4
  #import <React/RCTConvert.h>
3
5
  #import <React/RCTLog.h>
4
- #import "REANodesManager.h"
5
- #import "REAUtils.h"
6
6
 
7
7
  @implementation REACondNode {
8
8
  NSNumber *_condNodeID;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface READebugNode : REANode
4
4
 
@@ -1,8 +1,8 @@
1
- #import "READebugNode.h"
1
+ #import <RNReanimated/READebugNode.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAUtils.h>
2
4
  #import <React/RCTConvert.h>
3
5
  #import <React/RCTLog.h>
4
- #import "REANodesManager.h"
5
- #import "REAUtils.h"
6
6
 
7
7
  @implementation READebugNode {
8
8
  NSNumber *_valueNodeID;
@@ -1,5 +1,4 @@
1
- #import "REANode.h"
2
-
1
+ #import <RNReanimated/REANode.h>
3
2
  #import <React/RCTEventDispatcher.h>
4
3
 
5
4
  @interface REAEventNode : REANode
@@ -1,6 +1,6 @@
1
- #import "REAEventNode.h"
2
- #import "REANodesManager.h"
3
- #import "REAValueNode.h"
1
+ #import <RNReanimated/REAEventNode.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAValueNode.h>
4
4
 
5
5
  @implementation REAEventNode {
6
6
  NSArray *_argMapping;
@@ -1,5 +1,5 @@
1
1
 
2
- #import "REANode.h"
2
+ #import <RNReanimated/REANode.h>
3
3
 
4
4
  @interface REAFunctionNode : REANode
5
5
 
@@ -1,7 +1,7 @@
1
1
 
2
- #import "REAFunctionNode.h"
3
- #import "REANodesManager.h"
4
- #import "REAParamNode.h"
2
+ #import <RNReanimated/REAFunctionNode.h>
3
+ #import <RNReanimated/REANodesManager.h>
4
+ #import <RNReanimated/REAParamNode.h>
5
5
 
6
6
  @implementation REAFunctionNode {
7
7
  NSNumber *_nodeToBeEvaluated;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REAJSCallNode : REANode
4
4
 
@@ -1,6 +1,6 @@
1
- #import "REAJSCallNode.h"
2
- #import "REAModule.h"
3
- #import "REANodesManager.h"
1
+ #import <RNReanimated/REAJSCallNode.h>
2
+ #import <RNReanimated/REAModule.h>
3
+ #import <RNReanimated/REANodesManager.h>
4
4
 
5
5
  @implementation REAJSCallNode {
6
6
  NSArray<NSNumber *> *_input;
@@ -1,5 +1,5 @@
1
- #import "REANode.h"
2
- #import "REANodesManager.h"
1
+ #import <RNReanimated/REANode.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
3
 
4
4
  #import <React/RCTDefines.h>
5
5
 
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REAOperatorNode : REANode
4
4
 
@@ -1,8 +1,7 @@
1
+ #import <RNReanimated/REANodesManager.h>
2
+ #import <RNReanimated/REAOperatorNode.h>
1
3
  #include <tgmath.h>
2
4
 
3
- #import "REANodesManager.h"
4
- #import "REAOperatorNode.h"
5
-
6
5
  typedef id (^REAOperatorBlock)(NSArray<REANode *> *inputNodes);
7
6
 
8
7
  #define REA_REDUCE(OP) \
@@ -1,4 +1,4 @@
1
- #import "REAValueNode.h"
1
+ #import <RNReanimated/REAValueNode.h>
2
2
 
3
3
  @interface REAParamNode : REAValueNode
4
4
 
@@ -1,7 +1,7 @@
1
- #import "REAParamNode.h"
2
- #import "REAClockNodes.h"
3
- #import "REANodesManager.h"
4
- #import "REAValueNode.h"
1
+ #import <RNReanimated/REAClockNodes.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAParamNode.h>
4
+ #import <RNReanimated/REAValueNode.h>
5
5
 
6
6
  @implementation REAParamNode {
7
7
  NSMutableArray<REANodeID> *_argstack;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REAPropsNode : REANode <REAFinalNode>
4
4
 
@@ -1,9 +1,7 @@
1
- #import "REAPropsNode.h"
2
-
3
- #import "REAModule.h"
4
- #import "REANodesManager.h"
5
- #import "REAStyleNode.h"
6
-
1
+ #import <RNReanimated/REAModule.h>
2
+ #import <RNReanimated/REANodesManager.h>
3
+ #import <RNReanimated/REAPropsNode.h>
4
+ #import <RNReanimated/REAStyleNode.h>
7
5
  #import <React/RCTComponentData.h>
8
6
  #import <React/RCTLog.h>
9
7
  #import <React/RCTUIManager.h>
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REASetNode : REANode
4
4
 
@@ -1,9 +1,9 @@
1
- #import "REASetNode.h"
1
+ #import <RNReanimated/REANodesManager.h>
2
+ #import <RNReanimated/REASetNode.h>
3
+ #import <RNReanimated/REAUtils.h>
4
+ #import <RNReanimated/REAValueNode.h>
2
5
  #import <React/RCTConvert.h>
3
6
  #import <React/RCTLog.h>
4
- #import "REANodesManager.h"
5
- #import "REAUtils.h"
6
- #import "REAValueNode.h"
7
7
 
8
8
  @implementation REASetNode {
9
9
  NSNumber *_whatNodeID;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REAStyleNode : REANode
4
4
 
@@ -1,6 +1,5 @@
1
- #import "REAStyleNode.h"
2
-
3
- #import "REANodesManager.h"
1
+ #import <RNReanimated/REANodesManager.h>
2
+ #import <RNReanimated/REAStyleNode.h>
4
3
 
5
4
  @implementation REAStyleNode {
6
5
  NSMutableDictionary<NSString *, REANodeID> *_styleConfig;
@@ -1,4 +1,4 @@
1
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
2
2
 
3
3
  @interface REATransformNode : REANode
4
4
 
@@ -1,6 +1,6 @@
1
- #import "REATransformNode.h"
1
+ #import <RNReanimated/REANodesManager.h>
2
+ #import <RNReanimated/REATransformNode.h>
2
3
  #import <React/RCTConvert.h>
3
- #import "REANodesManager.h"
4
4
 
5
5
  @implementation REATransformNode {
6
6
  NSArray<id> *_transformConfigs;
@@ -1,6 +1,4 @@
1
- #import <UIKit/UIKit.h>
2
-
3
- #import "REANode.h"
1
+ #import <RNReanimated/REANode.h>
4
2
 
5
3
  @class REAValueNode;
6
4
 
@@ -1,4 +1,4 @@
1
- #import "REAValueNode.h"
1
+ #import <RNReanimated/REAValueNode.h>
2
2
 
3
3
  @implementation REAValueNode {
4
4
  NSNumber *_value;
@@ -1,4 +1,4 @@
1
- #import "REAEventDispatcher.h"
1
+ #import <RNReanimated/REAEventDispatcher.h>
2
2
  #import <RNReanimated/REAModule.h>
3
3
  #import <React/RCTBridge+Private.h>
4
4
  #import <React/RCTDefines.h>
package/ios/REAModule.h CHANGED
@@ -5,7 +5,7 @@
5
5
  #import <React/RCTUIManagerObserverCoordinator.h>
6
6
  #import <React/RCTUIManagerUtils.h>
7
7
 
8
- #import "REAValueNode.h"
8
+ #import <RNReanimated/REAValueNode.h>
9
9
 
10
10
  @interface REAModule : RCTEventEmitter <RCTBridgeModule, RCTEventDispatcherObserver, RCTUIManagerObserver>
11
11
 
package/ios/REAModule.m CHANGED
@@ -1,8 +1,7 @@
1
- #import "REAModule.h"
2
-
3
- #import "REANodesManager.h"
4
- #import "Transitioning/REATransitionManager.h"
5
- #import "native/NativeProxy.h"
1
+ #import <RNReanimated/NativeProxy.h>
2
+ #import <RNReanimated/REAModule.h>
3
+ #import <RNReanimated/REANodesManager.h>
4
+ #import <RNReanimated/REATransitionManager.h>
6
5
 
7
6
  typedef void (^AnimatedOperation)(REANodesManager *nodesManager);
8
7
 
@@ -1,8 +1,7 @@
1
1
  #import <Foundation/Foundation.h>
2
-
2
+ #import <RNReanimated/REANode.h>
3
3
  #import <React/RCTBridgeModule.h>
4
4
  #import <React/RCTUIManager.h>
5
- #import "REANode.h"
6
5
 
7
6
  @class REAModule;
8
7
 
@@ -1,29 +1,27 @@
1
- #import "REANodesManager.h"
2
-
1
+ #import <RNReanimated/REAAlwaysNode.h>
2
+ #import <RNReanimated/REABezierNode.h>
3
+ #import <RNReanimated/REABlockNode.h>
4
+ #import <RNReanimated/REACallFuncNode.h>
5
+ #import <RNReanimated/REAClockNodes.h>
6
+ #import <RNReanimated/REAConcatNode.h>
7
+ #import <RNReanimated/REACondNode.h>
8
+ #import <RNReanimated/READebugNode.h>
9
+ #import <RNReanimated/REAEventNode.h>
10
+ #import <RNReanimated/REAFunctionNode.h>
11
+ #import <RNReanimated/REAJSCallNode.h>
12
+ #import <RNReanimated/REAModule.h>
13
+ #import <RNReanimated/REANode.h>
14
+ #import <RNReanimated/REANodesManager.h>
15
+ #import <RNReanimated/REAOperatorNode.h>
16
+ #import <RNReanimated/REAParamNode.h>
17
+ #import <RNReanimated/REAPropsNode.h>
18
+ #import <RNReanimated/REASetNode.h>
19
+ #import <RNReanimated/REAStyleNode.h>
20
+ #import <RNReanimated/REATransformNode.h>
21
+ #import <RNReanimated/REAValueNode.h>
3
22
  #import <React/RCTConvert.h>
4
-
5
23
  #import <React/RCTShadowView.h>
6
24
  #import <stdatomic.h>
7
- #import "Nodes/REAAlwaysNode.h"
8
- #import "Nodes/REABezierNode.h"
9
- #import "Nodes/REABlockNode.h"
10
- #import "Nodes/REACallFuncNode.h"
11
- #import "Nodes/REAClockNodes.h"
12
- #import "Nodes/REAConcatNode.h"
13
- #import "Nodes/REACondNode.h"
14
- #import "Nodes/READebugNode.h"
15
- #import "Nodes/REAEventNode.h"
16
- #import "Nodes/REAFunctionNode.h"
17
- #import "Nodes/REAJSCallNode.h"
18
- #import "Nodes/REANode.h"
19
- #import "Nodes/REAOperatorNode.h"
20
- #import "Nodes/REAParamNode.h"
21
- #import "Nodes/REAPropsNode.h"
22
- #import "Nodes/REASetNode.h"
23
- #import "Nodes/REAStyleNode.h"
24
- #import "Nodes/REATransformNode.h"
25
- #import "Nodes/REAValueNode.h"
26
- #import "REAModule.h"
27
25
 
28
26
  // Interface below has been added in order to use private methods of RCTUIManager,
29
27
  // RCTUIManager#UpdateView is a React Method which is exported to JS but in
@@ -1,7 +1,6 @@
1
+ #import <RNReanimated/REATransition.h>
1
2
  #import <React/RCTConvert.h>
2
3
 
3
- #import "REATransition.h"
4
-
5
4
  @interface RCTConvert (REATransition)
6
5
 
7
6
  + (REATransitionType)REATransitionType:(id)json;
@@ -1,4 +1,4 @@
1
- #import "RCTConvert+REATransition.h"
1
+ #import <RNReanimated/RCTConvert+REATransition.h>
2
2
 
3
3
  @implementation RCTConvert (REATransition)
4
4
 
@@ -1,4 +1,4 @@
1
- #import "REATransition.h"
1
+ #import <RNReanimated/REATransition.h>
2
2
 
3
3
  @interface REATransitionGroup : REATransition
4
4
  @property (nonatomic) BOOL sequence;
@@ -1,8 +1,7 @@
1
+ #import <RNReanimated/RCTConvert+REATransition.h>
2
+ #import <RNReanimated/REAAllTransitions.h>
1
3
  #import <React/RCTViewManager.h>
2
4
 
3
- #import "RCTConvert+REATransition.h"
4
- #import "REAAllTransitions.h"
5
-
6
5
  @interface REASnapshotRemover : NSObject <CAAnimationDelegate>
7
6
  @end
8
7
 
@@ -1,10 +1,9 @@
1
1
  #import <QuartzCore/QuartzCore.h>
2
+ #import <RNReanimated/REATransitionAnimation.h>
3
+ #import <RNReanimated/REATransitionValues.h>
2
4
  #import <React/RCTView.h>
3
5
  #import <UIKit/UIKit.h>
4
6
 
5
- #import "REATransitionAnimation.h"
6
- #import "REATransitionValues.h"
7
-
8
7
  // TODO: fix below implementation
9
8
  #define IS_LAYOUT_ONLY(view) ([view isKindOfClass:[RCTView class]] && view.backgroundColor == nil)
10
9
 
@@ -1,12 +1,11 @@
1
1
  #import <QuartzCore/QuartzCore.h>
2
+ #import <RNReanimated/RCTConvert+REATransition.h>
3
+ #import <RNReanimated/REATransition.h>
4
+ #import <RNReanimated/REATransitionValues.h>
2
5
  #import <React/RCTConvert.h>
3
6
  #import <React/RCTViewManager.h>
4
7
  #import <UIKit/UIKit.h>
5
8
 
6
- #import "RCTConvert+REATransition.h"
7
- #import "REATransition.h"
8
- #import "REATransitionValues.h"
9
-
10
9
  #define DEFAULT_PROPAGATION_SPEED 3
11
10
 
12
11
  @interface REATransitionGroup : REATransition
@@ -1,7 +1,6 @@
1
+ #import <RNReanimated/REATransitionAnimation.h>
1
2
  #import <UIKit/UIKit.h>
2
3
 
3
- #import "REATransitionAnimation.h"
4
-
5
4
  #define DEFAULT_DURATION 0.25
6
5
 
7
6
  #if TARGET_IPHONE_SIMULATOR
@@ -1,10 +1,8 @@
1
- #import "REATransitionManager.h"
2
-
1
+ #import <RNReanimated/REATransition.h>
2
+ #import <RNReanimated/REATransitionManager.h>
3
3
  #import <React/RCTUIManager.h>
4
4
  #import <React/RCTUIManagerObserverCoordinator.h>
5
5
 
6
- #import "REATransition.h"
7
-
8
6
  @interface REATransitionManager () <RCTUIManagerObserver>
9
7
  @end
10
8
 
@@ -1,9 +1,8 @@
1
+ #import <RNReanimated/REATransition.h>
2
+ #import <RNReanimated/REATransitionValues.h>
1
3
  #import <React/RCTView.h>
2
4
  #import <React/RCTViewManager.h>
3
5
 
4
- #import "REATransition.h"
5
- #import "REATransitionValues.h"
6
-
7
6
  @implementation REATransitionValues
8
7
 
9
8
  - (instancetype)initWithView:(UIView *)view forRoot:(UIView *)root
@@ -1,11 +1,9 @@
1
1
  #import <Foundation/Foundation.h>
2
- #import <RNGestureHandlerStateManager.h>
2
+ #import <RNReanimated/RNGestureHandlerStateManager.h>
3
3
  #import <React/RCTUIManager.h>
4
4
  #include <string>
5
- #import <string>
6
5
  #include <utility>
7
6
  #include <vector>
8
- #import <vector>
9
7
 
10
8
  namespace reanimated {
11
9
 
@@ -1,4 +1,4 @@
1
- #import "NativeMethods.h"
1
+ #import <RNReanimated/NativeMethods.h>
2
2
  #import <React/RCTEventDispatcher.h>
3
3
  #import <React/RCTScrollView.h>
4
4
 
@@ -1,7 +1,7 @@
1
- #import <React/RCTEventDispatcher.h>
2
-
3
1
  #if __cplusplus
2
+
4
3
  #import <RNReanimated/NativeReanimatedModule.h>
4
+ #import <React/RCTEventDispatcher.h>
5
5
  #include <memory>
6
6
 
7
7
  namespace reanimated {
@@ -1,22 +1,21 @@
1
- #if TARGET_IPHONE_SIMULATOR
2
- #import <dlfcn.h>
3
- #endif
4
-
1
+ #import <RNReanimated/LayoutAnimationsProxy.h>
2
+ #import <RNReanimated/NativeMethods.h>
3
+ #import <RNReanimated/NativeProxy.h>
4
+ #import <RNReanimated/REAAnimationsManager.h>
5
+ #import <RNReanimated/REAIOSErrorHandler.h>
6
+ #import <RNReanimated/REAIOSScheduler.h>
7
+ #import <RNReanimated/REAModule.h>
8
+ #import <RNReanimated/REANodesManager.h>
9
+ #import <RNReanimated/REAUIManager.h>
10
+ #import <RNReanimated/RNGestureHandlerStateManager.h>
11
+ #import <RNReanimated/ReanimatedSensorContainer.h>
5
12
  #import <React/RCTFollyConvert.h>
6
13
  #import <React/RCTUIManager.h>
7
14
  #import <folly/json.h>
8
15
 
9
- #import <RNGestureHandlerStateManager.h>
10
- #import "LayoutAnimationsProxy.h"
11
- #import "NativeMethods.h"
12
- #import "NativeProxy.h"
13
- #import "REAAnimationsManager.h"
14
- #import "REAIOSErrorHandler.h"
15
- #import "REAIOSScheduler.h"
16
- #import "REAModule.h"
17
- #import "REANodesManager.h"
18
- #import "REAUIManager.h"
19
- #import "ReanimatedSensorContainer.h"
16
+ #if TARGET_IPHONE_SIMULATOR
17
+ #import <dlfcn.h>
18
+ #endif
20
19
 
21
20
  #if __has_include(<reacthermes/HermesExecutorFactory.h>)
22
21
  #import <reacthermes/HermesExecutorFactory.h>
@@ -163,8 +162,12 @@ std::shared_ptr<NativeReanimatedModule> createReanimatedModule(
163
162
  scrollTo(viewTag, uiManager, x, y, animated);
164
163
  };
165
164
 
166
- id<RNGestureHandlerStateManager> gestureHandlerStateManager = [bridge moduleForName:@"RNGestureHandlerModule"];
167
- auto setGestureStateFunction = [gestureHandlerStateManager](int handlerTag, int newState) {
165
+ id<RNGestureHandlerStateManager> gestureHandlerStateManager = nil;
166
+ auto setGestureStateFunction = [gestureHandlerStateManager, bridge](int handlerTag, int newState) mutable {
167
+ if (gestureHandlerStateManager == nil) {
168
+ gestureHandlerStateManager = [bridge moduleForName:@"RNGestureHandlerModule"];
169
+ }
170
+
168
171
  setGestureState(gestureHandlerStateManager, handlerTag, newState);
169
172
  };
170
173
 
@@ -1,9 +1,7 @@
1
- #pragma once
2
-
1
+ #import <RNReanimated/ErrorHandler.h>
2
+ #import <RNReanimated/Scheduler.h>
3
3
  #include <memory>
4
4
  #include <string>
5
- #include "ErrorHandler.h"
6
- #include "Scheduler.h"
7
5
 
8
6
  namespace reanimated {
9
7
 
@@ -1,5 +1,5 @@
1
- #include "REAIOSErrorHandler.h"
2
1
  #import <Foundation/Foundation.h>
2
+ #import <RNReanimated/REAIOSErrorHandler.h>
3
3
  #import <React/RCTLog.h>
4
4
 
5
5
  namespace reanimated {
@@ -1,7 +1,5 @@
1
- #pragma once
2
-
1
+ #import <RNReanimated/ReanimatedHiddenHeaders.h>
3
2
  #include <stdio.h>
4
- #include "ReanimatedHiddenHeaders.h"
5
3
 
6
4
  namespace reanimated {
7
5
 
@@ -1,5 +1,5 @@
1
- #include "REAIOSLogger.h"
2
1
  #import <Foundation/Foundation.h>
2
+ #import <RNReanimated/REAIOSLogger.h>
3
3
 
4
4
  namespace reanimated {
5
5
 
@@ -1,10 +1,8 @@
1
- #pragma once
2
-
1
+ #import <RNReanimated/Scheduler.h>
3
2
  #import <React/RCTUIManager.h>
4
3
  #import <ReactCommon/CallInvoker.h>
5
4
  #include <stdio.h>
6
5
  #include <memory>
7
- #include "Scheduler.h"
8
6
 
9
7
  namespace reanimated {
10
8
 
@@ -1,5 +1,5 @@
1
- #include "REAIOSScheduler.h"
2
- #include "RuntimeManager.h"
1
+ #import <RNReanimated/REAIOSScheduler.h>
2
+ #import <RNReanimated/RuntimeManager.h>
3
3
 
4
4
  namespace reanimated {
5
5
 
@@ -1,10 +1,3 @@
1
- //
2
- // REAInitializer.h
3
- // RNReanimated
4
- //
5
- // Created by Szymon Kapala on 27/07/2021.
6
- //
7
-
8
1
  #import <Foundation/Foundation.h>
9
2
  #import <RNReanimated/NativeProxy.h>
10
3
  #import <RNReanimated/REAEventDispatcher.h>
@@ -1,5 +1,5 @@
1
- #import "REAInitializer.h"
2
- #import "REAUIManager.h"
1
+ #import <RNReanimated/REAInitializer.h>
2
+ #import <RNReanimated/REAUIManager.h>
3
3
 
4
4
  @interface RCTEventDispatcher (Reanimated)
5
5
 
@@ -45,10 +45,20 @@ JSIExecutor::RuntimeInstaller REAJSIExecutorRuntimeInstaller(
45
45
  auto callInvoker = std::make_shared<react::BridgeJSCallInvoker>(bridge.reactInstance);
46
46
  auto reanimatedModule = reanimated::createReanimatedModule(bridge, callInvoker);
47
47
  #endif
48
+ auto workletRuntimeValue = runtime
49
+ .global()
50
+ .getProperty(runtime, "ArrayBuffer")
51
+ .asObject(runtime)
52
+ .asFunction(runtime)
53
+ .callAsConstructor(runtime, {static_cast<double>(sizeof(void*))});
54
+ uintptr_t* workletRuntimeData = reinterpret_cast<uintptr_t*>(
55
+ workletRuntimeValue.getObject(runtime).getArrayBuffer(runtime).data(runtime));
56
+ workletRuntimeData[0] = reinterpret_cast<uintptr_t>(reanimatedModule->runtime.get());
57
+
48
58
  runtime.global().setProperty(
49
59
  runtime,
50
60
  "_WORKLET_RUNTIME",
51
- static_cast<double>(reinterpret_cast<std::uintptr_t>(reanimatedModule->runtime.get())));
61
+ workletRuntimeValue);
52
62
 
53
63
  runtime.global().setProperty(
54
64
  runtime,