react-native 0.74.5 → 0.74.7
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.
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/StyleSheet/StyleSheetTypes.d.ts +17 -15
- package/React/Base/RCTVersion.m +1 -1
- package/React/Views/RCTModalHostView.m +1 -0
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/bridge/DynamicNative.kt +49 -0
- package/ReactAndroid/src/main/java/com/facebook/react/internal/turbomodule/core/TurboModuleInteropUtils.java +2 -5
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.java +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/views/view/ReactViewBackgroundDrawable.java +9 -4
- package/ReactAndroid/src/main/jni/react/jni/JDynamicNative.cpp +46 -0
- package/ReactAndroid/src/main/jni/react/jni/JDynamicNative.h +56 -0
- package/ReactAndroid/src/main/jni/react/jni/OnLoad.cpp +2 -0
- package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
- package/ReactCommon/react/nativemodule/core/platform/android/ReactCommon/JavaTurboModule.cpp +8 -1
- package/ReactCommon/react/nativemodule/samples/platform/android/SampleLegacyModule.java +40 -0
- package/ReactCommon/react/renderer/animations/LayoutAnimationKeyFrameManager.cpp +1 -4
- package/ReactCommon/react/renderer/animations/utils.h +45 -0
- package/package.json +9 -8
- package/sdks/.hermesversion +1 -1
- package/sdks/hermes-engine/utils/build-apple-framework.sh +0 -12
- package/sdks/hermesc/linux64-bin/hermesc +0 -0
- package/sdks/hermesc/osx-bin/hermes +0 -0
- package/sdks/hermesc/osx-bin/hermesc +0 -0
- package/sdks/hermesc/win64-bin/hermesc.exe +0 -0
- package/template/Gemfile +2 -0
- package/template/package.json +5 -5
|
@@ -182,21 +182,23 @@ type MaximumOneOf<T, K extends keyof T = keyof T> = K extends keyof T
|
|
|
182
182
|
|
|
183
183
|
export interface TransformsStyle {
|
|
184
184
|
transform?:
|
|
185
|
-
|
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
185
|
+
| Readonly<
|
|
186
|
+
MaximumOneOf<
|
|
187
|
+
PerspectiveTransform &
|
|
188
|
+
RotateTransform &
|
|
189
|
+
RotateXTransform &
|
|
190
|
+
RotateYTransform &
|
|
191
|
+
RotateZTransform &
|
|
192
|
+
ScaleTransform &
|
|
193
|
+
ScaleXTransform &
|
|
194
|
+
ScaleYTransform &
|
|
195
|
+
TranslateXTransform &
|
|
196
|
+
TranslateYTransform &
|
|
197
|
+
SkewXTransform &
|
|
198
|
+
SkewYTransform &
|
|
199
|
+
MatrixTransform
|
|
200
|
+
>[]
|
|
201
|
+
>
|
|
200
202
|
| string
|
|
201
203
|
| undefined;
|
|
202
204
|
transformOrigin?: Array<string | number> | string | undefined;
|
package/React/Base/RCTVersion.m
CHANGED
|
@@ -119,6 +119,7 @@ RCT_NOT_IMPLEMENTED(-(instancetype)initWithCoder : coder)
|
|
|
119
119
|
if (_isPresented) {
|
|
120
120
|
[_delegate dismissModalHostView:self withViewController:_modalViewController animated:[self hasAnimationType]];
|
|
121
121
|
_isPresented = NO;
|
|
122
|
+
[self setVisible:NO];
|
|
122
123
|
}
|
|
123
124
|
}
|
|
124
125
|
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
package com.facebook.react.bridge
|
|
9
|
+
|
|
10
|
+
import com.facebook.jni.HybridData
|
|
11
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import com.facebook.proguard.annotations.DoNotStripAny
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* An implementation of [Dynamic] that has a C++ implementation.
|
|
16
|
+
*
|
|
17
|
+
* This is used to support Legacy Native Modules that have not been migrated to the new architecture
|
|
18
|
+
* and are using [Dynamic] as a parameter type.
|
|
19
|
+
*/
|
|
20
|
+
@DoNotStripAny
|
|
21
|
+
private class DynamicNative(
|
|
22
|
+
@Suppress("NoHungarianNotation") @field:DoNotStrip private val mHybridData: HybridData?
|
|
23
|
+
) : Dynamic {
|
|
24
|
+
|
|
25
|
+
override fun getType(): ReadableType = getTypeNative()
|
|
26
|
+
|
|
27
|
+
override fun isNull(): Boolean = isNullNative()
|
|
28
|
+
|
|
29
|
+
private external fun getTypeNative(): ReadableType
|
|
30
|
+
|
|
31
|
+
private external fun isNullNative(): Boolean
|
|
32
|
+
|
|
33
|
+
external override fun asBoolean(): Boolean
|
|
34
|
+
|
|
35
|
+
// The native representation is holding the value as Double. We do the Int conversion here.
|
|
36
|
+
override fun asInt(): Int = asDouble().toInt()
|
|
37
|
+
|
|
38
|
+
external override fun asDouble(): Double
|
|
39
|
+
|
|
40
|
+
external override fun asString(): String
|
|
41
|
+
|
|
42
|
+
external override fun asArray(): ReadableArray
|
|
43
|
+
|
|
44
|
+
external override fun asMap(): ReadableMap
|
|
45
|
+
|
|
46
|
+
override fun recycle() {
|
|
47
|
+
// Noop - nothing to recycle since there is no pooling
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -161,14 +161,11 @@ class TurboModuleInteropUtils {
|
|
|
161
161
|
|| paramClass == Callback.class
|
|
162
162
|
|| paramClass == Promise.class
|
|
163
163
|
|| paramClass == ReadableMap.class
|
|
164
|
-
|| paramClass == ReadableArray.class
|
|
164
|
+
|| paramClass == ReadableArray.class
|
|
165
|
+
|| paramClass == Dynamic.class) {
|
|
165
166
|
return convertClassToJniType(paramClass);
|
|
166
167
|
}
|
|
167
168
|
|
|
168
|
-
if (paramClass == Dynamic.class) {
|
|
169
|
-
// TODO(T145105887): Output warnings that TurboModules doesn't yet support Dynamic arguments
|
|
170
|
-
}
|
|
171
|
-
|
|
172
169
|
throw new ParsingException(
|
|
173
170
|
moduleName,
|
|
174
171
|
methodName,
|
package/ReactAndroid/src/main/java/com/facebook/react/views/view/ReactViewBackgroundDrawable.java
CHANGED
|
@@ -579,6 +579,7 @@ public class ReactViewBackgroundDrawable extends Drawable {
|
|
|
579
579
|
}
|
|
580
580
|
|
|
581
581
|
// Clip border ONLY if its color is non transparent
|
|
582
|
+
float pathAdjustment = 0f;
|
|
582
583
|
if (Color.alpha(colorLeft) != 0
|
|
583
584
|
&& Color.alpha(colorTop) != 0
|
|
584
585
|
&& Color.alpha(colorRight) != 0
|
|
@@ -589,6 +590,10 @@ public class ReactViewBackgroundDrawable extends Drawable {
|
|
|
589
590
|
mInnerClipTempRectForBorderRadius.bottom -= borderWidth.bottom;
|
|
590
591
|
mInnerClipTempRectForBorderRadius.left += borderWidth.left;
|
|
591
592
|
mInnerClipTempRectForBorderRadius.right -= borderWidth.right;
|
|
593
|
+
|
|
594
|
+
// only close gap between border and main path if we draw the border, otherwise
|
|
595
|
+
// we wind up pixelating small pixel-radius curves
|
|
596
|
+
pathAdjustment = mGapBetweenPaths;
|
|
592
597
|
}
|
|
593
598
|
|
|
594
599
|
mTempRectForCenterDrawPath.top += borderWidth.top * 0.5f;
|
|
@@ -716,10 +721,10 @@ public class ReactViewBackgroundDrawable extends Drawable {
|
|
|
716
721
|
// (mInnerClipTempRectForBorderRadius), ensuring the border can be
|
|
717
722
|
// drawn on top without the gap.
|
|
718
723
|
mBackgroundColorRenderPath.addRoundRect(
|
|
719
|
-
mInnerClipTempRectForBorderRadius.left -
|
|
720
|
-
mInnerClipTempRectForBorderRadius.top -
|
|
721
|
-
mInnerClipTempRectForBorderRadius.right +
|
|
722
|
-
mInnerClipTempRectForBorderRadius.bottom +
|
|
724
|
+
mInnerClipTempRectForBorderRadius.left - pathAdjustment,
|
|
725
|
+
mInnerClipTempRectForBorderRadius.top - pathAdjustment,
|
|
726
|
+
mInnerClipTempRectForBorderRadius.right + pathAdjustment,
|
|
727
|
+
mInnerClipTempRectForBorderRadius.bottom + pathAdjustment,
|
|
723
728
|
new float[] {
|
|
724
729
|
innerTopLeftRadiusX,
|
|
725
730
|
innerTopLeftRadiusY,
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
#include "JDynamicNative.h"
|
|
9
|
+
#include "ReadableNativeArray.h"
|
|
10
|
+
#include "ReadableNativeMap.h"
|
|
11
|
+
|
|
12
|
+
using namespace facebook::jni;
|
|
13
|
+
|
|
14
|
+
namespace facebook::react {
|
|
15
|
+
|
|
16
|
+
jboolean JDynamicNative::isNullNative() {
|
|
17
|
+
return payload_.isNull();
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
jni::local_ref<ReadableType> JDynamicNative::getTypeNative() {
|
|
21
|
+
return ReadableType::getType(payload_.type());
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
jni::local_ref<jstring> JDynamicNative::asString() {
|
|
25
|
+
return jni::make_jstring(payload_.asString());
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
jboolean JDynamicNative::asBoolean() {
|
|
29
|
+
return payload_.asBool();
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
jdouble JDynamicNative::asDouble() {
|
|
33
|
+
return payload_.asDouble();
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
jni::local_ref<ReadableArray> JDynamicNative::asArray() {
|
|
37
|
+
return jni::adopt_local(reinterpret_cast<ReadableArray::javaobject>(
|
|
38
|
+
ReadableNativeArray::newObjectCxxArgs(payload_).release()));
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
jni::local_ref<ReadableMap> JDynamicNative::asMap() {
|
|
42
|
+
return jni::adopt_local(reinterpret_cast<ReadableMap::javaobject>(
|
|
43
|
+
ReadableNativeMap::createWithContents(std::move(payload_)).release()));
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
} // namespace facebook::react
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include "NativeCommon.h"
|
|
11
|
+
#include "ReadableNativeArray.h"
|
|
12
|
+
#include "ReadableNativeMap.h"
|
|
13
|
+
|
|
14
|
+
#include <fbjni/fbjni.h>
|
|
15
|
+
#include <folly/dynamic.h>
|
|
16
|
+
#include <folly/json.h>
|
|
17
|
+
|
|
18
|
+
namespace facebook::react {
|
|
19
|
+
|
|
20
|
+
struct JDynamic : public jni::JavaClass<JDynamic> {
|
|
21
|
+
constexpr static auto kJavaDescriptor = "Lcom/facebook/react/bridge/Dynamic;";
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
class JDynamicNative : public jni::HybridClass<JDynamicNative, JDynamic> {
|
|
25
|
+
public:
|
|
26
|
+
constexpr static auto kJavaDescriptor =
|
|
27
|
+
"Lcom/facebook/react/bridge/DynamicNative;";
|
|
28
|
+
|
|
29
|
+
JDynamicNative(folly::dynamic payload) : payload_(std::move(payload)) {}
|
|
30
|
+
|
|
31
|
+
static void registerNatives() {
|
|
32
|
+
javaClassStatic()->registerNatives(
|
|
33
|
+
{makeNativeMethod("isNullNative", JDynamicNative::isNullNative),
|
|
34
|
+
makeNativeMethod("getTypeNative", JDynamicNative::getTypeNative),
|
|
35
|
+
makeNativeMethod("asDouble", JDynamicNative::asDouble),
|
|
36
|
+
makeNativeMethod("asBoolean", JDynamicNative::asBoolean),
|
|
37
|
+
makeNativeMethod("asString", JDynamicNative::asString),
|
|
38
|
+
makeNativeMethod("asArray", JDynamicNative::asArray),
|
|
39
|
+
makeNativeMethod("asMap", JDynamicNative::asMap)});
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
private:
|
|
43
|
+
friend HybridBase;
|
|
44
|
+
|
|
45
|
+
jni::local_ref<ReadableType> getTypeNative();
|
|
46
|
+
jni::local_ref<jstring> asString();
|
|
47
|
+
jboolean asBoolean();
|
|
48
|
+
jdouble asDouble();
|
|
49
|
+
jboolean isNullNative();
|
|
50
|
+
jni::local_ref<ReadableArray> asArray();
|
|
51
|
+
jni::local_ref<ReadableMap> asMap();
|
|
52
|
+
|
|
53
|
+
folly::dynamic payload_;
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
} // namespace facebook::react
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
#include "CatalystInstanceImpl.h"
|
|
16
16
|
#include "CxxModuleWrapperBase.h"
|
|
17
17
|
#include "JCallback.h"
|
|
18
|
+
#include "JDynamicNative.h"
|
|
18
19
|
#include "JInspector.h"
|
|
19
20
|
#include "JReactMarker.h"
|
|
20
21
|
#include "JavaScriptExecutorHolder.h"
|
|
@@ -88,6 +89,7 @@ extern "C" JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
|
|
|
88
89
|
NativeMap::registerNatives();
|
|
89
90
|
ReadableNativeMap::registerNatives();
|
|
90
91
|
WritableNativeMap::registerNatives();
|
|
92
|
+
JDynamicNative::registerNatives();
|
|
91
93
|
JReactMarker::registerNatives();
|
|
92
94
|
JInspector::registerNatives();
|
|
93
95
|
});
|
package/ReactCommon/react/nativemodule/core/platform/android/ReactCommon/JavaTurboModule.cpp
CHANGED
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
#include <jsi/JSIDynamic.h>
|
|
20
20
|
#include <react/bridging/Bridging.h>
|
|
21
21
|
#include <react/debug/react_native_assert.h>
|
|
22
|
+
#include <react/jni/JDynamicNative.h>
|
|
22
23
|
#include <react/jni/NativeMap.h>
|
|
23
24
|
#include <react/jni/ReadableNativeMap.h>
|
|
24
25
|
#include <react/jni/WritableNativeMap.h>
|
|
@@ -370,7 +371,9 @@ JNIArgs convertJSIArgsToJNIArgs(
|
|
|
370
371
|
continue;
|
|
371
372
|
}
|
|
372
373
|
|
|
373
|
-
|
|
374
|
+
// Dynamic encapsulates the Null type so we don't want to return null here.
|
|
375
|
+
if ((arg->isNull() && type != "Lcom/facebook/react/bridge/Dynamic;") ||
|
|
376
|
+
arg->isUndefined()) {
|
|
374
377
|
jarg->l = nullptr;
|
|
375
378
|
} else if (type == "Ljava/lang/Double;") {
|
|
376
379
|
if (!arg->isNumber()) {
|
|
@@ -433,6 +436,10 @@ JNIArgs convertJSIArgsToJNIArgs(
|
|
|
433
436
|
auto jParams =
|
|
434
437
|
ReadableNativeMap::createWithContents(std::move(dynamicFromValue));
|
|
435
438
|
jarg->l = makeGlobalIfNecessary(jParams.release());
|
|
439
|
+
} else if (type == "Lcom/facebook/react/bridge/Dynamic;") {
|
|
440
|
+
auto dynamicFromValue = jsi::dynamicFromValue(rt, *arg);
|
|
441
|
+
auto jParams = JDynamicNative::newObjectCxxArgs(dynamicFromValue);
|
|
442
|
+
jarg->l = makeGlobalIfNecessary(jParams.release());
|
|
436
443
|
} else {
|
|
437
444
|
throw JavaTurboModuleInvalidArgumentTypeException(
|
|
438
445
|
type, argIndex, methodName);
|
|
@@ -13,12 +13,14 @@ import android.widget.Toast;
|
|
|
13
13
|
import com.facebook.proguard.annotations.DoNotStrip;
|
|
14
14
|
import com.facebook.react.bridge.Arguments;
|
|
15
15
|
import com.facebook.react.bridge.Callback;
|
|
16
|
+
import com.facebook.react.bridge.Dynamic;
|
|
16
17
|
import com.facebook.react.bridge.Promise;
|
|
17
18
|
import com.facebook.react.bridge.ReactApplicationContext;
|
|
18
19
|
import com.facebook.react.bridge.ReactContextBaseJavaModule;
|
|
19
20
|
import com.facebook.react.bridge.ReactMethod;
|
|
20
21
|
import com.facebook.react.bridge.ReadableArray;
|
|
21
22
|
import com.facebook.react.bridge.ReadableMap;
|
|
23
|
+
import com.facebook.react.bridge.ReadableType;
|
|
22
24
|
import com.facebook.react.bridge.WritableArray;
|
|
23
25
|
import com.facebook.react.bridge.WritableMap;
|
|
24
26
|
import com.facebook.react.bridge.WritableNativeArray;
|
|
@@ -155,6 +157,44 @@ public class SampleLegacyModule extends ReactContextBaseJavaModule {
|
|
|
155
157
|
return map;
|
|
156
158
|
}
|
|
157
159
|
|
|
160
|
+
@SuppressWarnings("unused")
|
|
161
|
+
@ReactMethod(isBlockingSynchronousMethod = true)
|
|
162
|
+
public WritableMap getDynamic(Dynamic dynamic) {
|
|
163
|
+
WritableNativeMap resultMap = new WritableNativeMap();
|
|
164
|
+
ReadableType type = dynamic.getType();
|
|
165
|
+
if (type == ReadableType.Null) {
|
|
166
|
+
log("getDynamic as Null", dynamic, dynamic);
|
|
167
|
+
resultMap.putString("type", "Null");
|
|
168
|
+
resultMap.putNull("value");
|
|
169
|
+
} else if (type == ReadableType.Boolean) {
|
|
170
|
+
boolean result = dynamic.asBoolean();
|
|
171
|
+
log("getDynamic as Boolean", dynamic, result);
|
|
172
|
+
resultMap.putString("type", "Boolean");
|
|
173
|
+
resultMap.putBoolean("value", result);
|
|
174
|
+
} else if (type == ReadableType.Number) {
|
|
175
|
+
int result = dynamic.asInt();
|
|
176
|
+
log("getDynamic as Number", dynamic, result);
|
|
177
|
+
resultMap.putString("type", "Number");
|
|
178
|
+
resultMap.putInt("value", result);
|
|
179
|
+
} else if (type == ReadableType.String) {
|
|
180
|
+
String result = dynamic.asString();
|
|
181
|
+
log("getDynamic as String", dynamic, result);
|
|
182
|
+
resultMap.putString("type", "String");
|
|
183
|
+
resultMap.putString("value", result);
|
|
184
|
+
} else if (type == ReadableType.Array) {
|
|
185
|
+
ReadableArray result = dynamic.asArray();
|
|
186
|
+
log("getDynamic as Array", dynamic, result);
|
|
187
|
+
resultMap.putString("type", "Array");
|
|
188
|
+
resultMap.putArray("value", result);
|
|
189
|
+
} else if (type == ReadableType.Map) {
|
|
190
|
+
ReadableMap result = dynamic.asMap();
|
|
191
|
+
log("getDynamic as Map", dynamic, result);
|
|
192
|
+
resultMap.putString("type", "Map");
|
|
193
|
+
resultMap.putMap("value", result);
|
|
194
|
+
}
|
|
195
|
+
return resultMap;
|
|
196
|
+
}
|
|
197
|
+
|
|
158
198
|
@DoNotStrip
|
|
159
199
|
@SuppressWarnings("unused")
|
|
160
200
|
@ReactMethod(isBlockingSynchronousMethod = true)
|
|
@@ -795,10 +795,7 @@ LayoutAnimationKeyFrameManager::pullTransaction(
|
|
|
795
795
|
finalConflictingMutations.end(),
|
|
796
796
|
&shouldFirstComeBeforeSecondMutation);
|
|
797
797
|
|
|
798
|
-
|
|
799
|
-
immediateMutations.begin(),
|
|
800
|
-
immediateMutations.end(),
|
|
801
|
-
&shouldFirstComeBeforeSecondRemovesOnly);
|
|
798
|
+
handleShouldFirstComeBeforeSecondRemovesOnly(immediateMutations);
|
|
802
799
|
|
|
803
800
|
animation.keyFrames = keyFramesToAnimate;
|
|
804
801
|
inflightAnimations_.push_back(std::move(animation));
|
|
@@ -24,6 +24,40 @@ static inline bool shouldFirstComeBeforeSecondRemovesOnly(
|
|
|
24
24
|
(lhs.index > rhs.index);
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
+
static inline void handleShouldFirstComeBeforeSecondRemovesOnly(
|
|
28
|
+
ShadowViewMutation::List& list) noexcept {
|
|
29
|
+
std::unordered_map<std::string, std::vector<ShadowViewMutation>>
|
|
30
|
+
removeMutationsByTag;
|
|
31
|
+
ShadowViewMutation::List finalList;
|
|
32
|
+
for (auto& mutation : list) {
|
|
33
|
+
if (mutation.type == ShadowViewMutation::Type::Remove) {
|
|
34
|
+
auto key = std::to_string(mutation.parentShadowView.tag);
|
|
35
|
+
removeMutationsByTag[key].push_back(mutation);
|
|
36
|
+
} else {
|
|
37
|
+
finalList.push_back(mutation);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
if (removeMutationsByTag.size() == 0) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
for (auto& mutationsPair : removeMutationsByTag) {
|
|
46
|
+
if (mutationsPair.second.size() > 1) {
|
|
47
|
+
std::stable_sort(
|
|
48
|
+
mutationsPair.second.begin(),
|
|
49
|
+
mutationsPair.second.end(),
|
|
50
|
+
&shouldFirstComeBeforeSecondRemovesOnly);
|
|
51
|
+
}
|
|
52
|
+
finalList.insert(
|
|
53
|
+
finalList.begin(),
|
|
54
|
+
mutationsPair.second.begin(),
|
|
55
|
+
mutationsPair.second.end());
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
list = finalList;
|
|
59
|
+
}
|
|
60
|
+
|
|
27
61
|
static inline bool shouldFirstComeBeforeSecondMutation(
|
|
28
62
|
const ShadowViewMutation& lhs,
|
|
29
63
|
const ShadowViewMutation& rhs) noexcept {
|
|
@@ -55,6 +89,17 @@ static inline bool shouldFirstComeBeforeSecondMutation(
|
|
|
55
89
|
lhs.type == ShadowViewMutation::Type::Insert) {
|
|
56
90
|
return false;
|
|
57
91
|
}
|
|
92
|
+
|
|
93
|
+
// Remove comes before Update
|
|
94
|
+
if (lhs.type == ShadowViewMutation::Type::Remove &&
|
|
95
|
+
rhs.type == ShadowViewMutation::Type::Update) {
|
|
96
|
+
return true;
|
|
97
|
+
}
|
|
98
|
+
if (rhs.type == ShadowViewMutation::Type::Remove &&
|
|
99
|
+
lhs.type == ShadowViewMutation::Type::Update) {
|
|
100
|
+
return false;
|
|
101
|
+
}
|
|
102
|
+
|
|
58
103
|
} else {
|
|
59
104
|
// Make sure that removes on the same level are sorted - highest indices
|
|
60
105
|
// must come first.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.74.
|
|
3
|
+
"version": "0.74.7",
|
|
4
4
|
"description": "A framework for building native apps using React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -110,13 +110,13 @@
|
|
|
110
110
|
"@react-native-community/cli": "13.6.9",
|
|
111
111
|
"@react-native-community/cli-platform-android": "13.6.9",
|
|
112
112
|
"@react-native-community/cli-platform-ios": "13.6.9",
|
|
113
|
-
"@react-native/assets-registry": "0.74.
|
|
114
|
-
"@react-native/codegen": "0.74.
|
|
115
|
-
"@react-native/community-cli-plugin": "0.74.
|
|
116
|
-
"@react-native/gradle-plugin": "0.74.
|
|
117
|
-
"@react-native/js-polyfills": "0.74.
|
|
118
|
-
"@react-native/normalize-colors": "0.74.
|
|
119
|
-
"@react-native/virtualized-lists": "0.74.
|
|
113
|
+
"@react-native/assets-registry": "0.74.89",
|
|
114
|
+
"@react-native/codegen": "0.74.89",
|
|
115
|
+
"@react-native/community-cli-plugin": "0.74.89",
|
|
116
|
+
"@react-native/gradle-plugin": "0.74.89",
|
|
117
|
+
"@react-native/js-polyfills": "0.74.89",
|
|
118
|
+
"@react-native/normalize-colors": "0.74.89",
|
|
119
|
+
"@react-native/virtualized-lists": "0.74.89",
|
|
120
120
|
"abort-controller": "^3.0.0",
|
|
121
121
|
"anser": "^1.4.9",
|
|
122
122
|
"ansi-regex": "^5.0.0",
|
|
@@ -124,6 +124,7 @@
|
|
|
124
124
|
"chalk": "^4.0.0",
|
|
125
125
|
"event-target-shim": "^5.0.1",
|
|
126
126
|
"flow-enums-runtime": "^0.0.6",
|
|
127
|
+
"glob": "^7.1.1",
|
|
127
128
|
"invariant": "^2.2.4",
|
|
128
129
|
"jest-environment-node": "^29.6.3",
|
|
129
130
|
"jsc-android": "^250231.0.0",
|
package/sdks/.hermesversion
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
hermes-2024-
|
|
1
|
+
hermes-2024-09-30-RNv0.74.6-6f503f52cbf98b2b37c4d3900e7f1193d6512548
|
|
@@ -192,19 +192,7 @@ function create_universal_framework {
|
|
|
192
192
|
for i in "${!platforms[@]}"; do
|
|
193
193
|
local platform="${platforms[$i]}"
|
|
194
194
|
local hermes_framework_path="${platform}/hermes.framework"
|
|
195
|
-
local dSYM_path="$hermes_framework_path"
|
|
196
|
-
local dSYM_base_path="$HERMES_PATH/destroot/Library/Frameworks"
|
|
197
|
-
|
|
198
|
-
# If the dSYM rename has failed, the dSYM are generated as 0.dSYM
|
|
199
|
-
# (Apple default name) rather then hermes.framework.dSYM.
|
|
200
|
-
if [[ -e "$dSYM_base_path/${platform}/0.dSYM" ]]; then
|
|
201
|
-
dSYM_path="${platform}/0"
|
|
202
|
-
fi
|
|
203
|
-
|
|
204
195
|
args+="-framework $hermes_framework_path "
|
|
205
|
-
|
|
206
|
-
# Path to dSYM must be absolute
|
|
207
|
-
args+="-debug-symbols $dSYM_base_path/$dSYM_path.dSYM "
|
|
208
196
|
done
|
|
209
197
|
|
|
210
198
|
mkdir -p universal
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/template/Gemfile
CHANGED
package/template/package.json
CHANGED
|
@@ -11,16 +11,16 @@
|
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"react": "18.2.0",
|
|
14
|
-
"react-native": "0.74.
|
|
14
|
+
"react-native": "0.74.7"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"@babel/core": "^7.20.0",
|
|
18
18
|
"@babel/preset-env": "^7.20.0",
|
|
19
19
|
"@babel/runtime": "^7.20.0",
|
|
20
|
-
"@react-native/babel-preset": "0.74.
|
|
21
|
-
"@react-native/eslint-config": "0.74.
|
|
22
|
-
"@react-native/metro-config": "0.74.
|
|
23
|
-
"@react-native/typescript-config": "0.74.
|
|
20
|
+
"@react-native/babel-preset": "0.74.89",
|
|
21
|
+
"@react-native/eslint-config": "0.74.89",
|
|
22
|
+
"@react-native/metro-config": "0.74.89",
|
|
23
|
+
"@react-native/typescript-config": "0.74.89",
|
|
24
24
|
"@types/react": "^18.2.6",
|
|
25
25
|
"@types/react-test-renderer": "^18.0.0",
|
|
26
26
|
"babel-jest": "^29.6.3",
|