react-native 0.79.4 → 0.79.6
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/React/Base/RCTVersion.m +1 -1
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/ReactInstanceManager.java +2 -2
- package/ReactAndroid/src/main/java/com/facebook/react/modules/statusbar/StatusBarModule.kt +3 -16
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.java +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/uimanager/DisplayMetricsHolder.kt +13 -0
- package/ReactAndroid/src/main/java/com/facebook/react/uimanager/NativeViewHierarchyManager.java +0 -3
- package/ReactAndroid/src/main/java/com/facebook/react/views/modal/ReactModalHostView.kt +26 -0
- package/ReactCommon/React-FabricComponents.podspec +5 -1
- package/ReactCommon/cxxreact/ReactNativeVersion.h +2 -2
- package/ReactCommon/react/nativemodule/core/platform/android/ReactCommon/JavaTurboModule.cpp +12 -8
- package/ReactCommon/react/renderer/components/modal/CMakeLists.txt +4 -1
- package/ReactCommon/react/renderer/components/modal/ModalHostViewComponentDescriptor.h +3 -2
- package/ReactCommon/react/renderer/components/modal/ModalHostViewState.h +4 -12
- package/ReactCommon/react/renderer/components/modal/ModalHostViewUtils.h +2 -2
- package/ReactCommon/react/renderer/components/modal/ModalHostViewUtils.mm +1 -1
- package/ReactCommon/react/renderer/components/modal/platform/android/JReactModalHostView.h +38 -0
- package/ReactCommon/react/renderer/components/modal/platform/android/ModalHostViewUtils.cpp +18 -0
- package/ReactCommon/react/renderer/components/modal/platform/cxx/ModalHostViewUtils.cpp +17 -0
- package/index.js.flow +115 -0
- package/package.json +9 -9
- package/sdks/hermes-engine/hermes-utils.rb +4 -1
- 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/sdks/hermesc/win64-bin/msvcp140.dll +0 -0
- package/sdks/hermesc/win64-bin/vcruntime140.dll +0 -0
- package/sdks/hermesc/win64-bin/vcruntime140_1.dll +0 -0
package/React/Base/RCTVersion.m
CHANGED
|
@@ -1399,14 +1399,14 @@ public class ReactInstanceManager {
|
|
|
1399
1399
|
new RuntimeException(
|
|
1400
1400
|
"detachRootViewFromInstance called with ReactRootView with invalid id"));
|
|
1401
1401
|
}
|
|
1402
|
-
|
|
1403
|
-
clearReactRoot(reactRoot);
|
|
1404
1402
|
} else {
|
|
1405
1403
|
reactContext
|
|
1406
1404
|
.getCatalystInstance()
|
|
1407
1405
|
.getJSModule(AppRegistry.class)
|
|
1408
1406
|
.unmountApplicationComponentAtRootTag(reactRoot.getRootViewTag());
|
|
1409
1407
|
}
|
|
1408
|
+
|
|
1409
|
+
clearReactRoot(reactRoot);
|
|
1410
1410
|
}
|
|
1411
1411
|
|
|
1412
1412
|
@ThreadConfined(UI)
|
|
@@ -13,8 +13,6 @@ import android.os.Build
|
|
|
13
13
|
import android.view.View
|
|
14
14
|
import android.view.WindowInsetsController
|
|
15
15
|
import android.view.WindowManager
|
|
16
|
-
import androidx.core.view.ViewCompat
|
|
17
|
-
import androidx.core.view.WindowInsetsCompat
|
|
18
16
|
import com.facebook.common.logging.FLog
|
|
19
17
|
import com.facebook.fbreact.specs.NativeStatusBarManagerAndroidSpec
|
|
20
18
|
import com.facebook.react.bridge.GuardedRunnable
|
|
@@ -23,6 +21,7 @@ import com.facebook.react.bridge.ReactApplicationContext
|
|
|
23
21
|
import com.facebook.react.bridge.UiThreadUtil
|
|
24
22
|
import com.facebook.react.common.ReactConstants
|
|
25
23
|
import com.facebook.react.module.annotations.ReactModule
|
|
24
|
+
import com.facebook.react.uimanager.DisplayMetricsHolder.getStatusBarHeightPx
|
|
26
25
|
import com.facebook.react.uimanager.PixelUtil
|
|
27
26
|
import com.facebook.react.views.view.setStatusBarTranslucency
|
|
28
27
|
import com.facebook.react.views.view.setStatusBarVisibility
|
|
@@ -34,29 +33,17 @@ public class StatusBarModule(reactContext: ReactApplicationContext?) :
|
|
|
34
33
|
|
|
35
34
|
@Suppress("DEPRECATION")
|
|
36
35
|
override fun getTypedExportedConstants(): Map<String, Any> {
|
|
36
|
+
val currentActivity = reactApplicationContext.currentActivity
|
|
37
37
|
val statusBarColor =
|
|
38
38
|
currentActivity?.window?.statusBarColor?.let { color ->
|
|
39
39
|
String.format("#%06X", 0xFFFFFF and color)
|
|
40
40
|
} ?: "black"
|
|
41
41
|
return mapOf(
|
|
42
|
-
HEIGHT_KEY to PixelUtil.toDIPFromPixel(getStatusBarHeightPx()),
|
|
42
|
+
HEIGHT_KEY to PixelUtil.toDIPFromPixel(getStatusBarHeightPx(currentActivity).toFloat()),
|
|
43
43
|
DEFAULT_BACKGROUND_COLOR_KEY to statusBarColor,
|
|
44
44
|
)
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
@Suppress("DEPRECATION")
|
|
48
|
-
private fun getStatusBarHeightPx(): Float {
|
|
49
|
-
val windowInsets =
|
|
50
|
-
currentActivity?.window?.decorView?.let(ViewCompat::getRootWindowInsets) ?: return 0f
|
|
51
|
-
return windowInsets
|
|
52
|
-
.getInsets(
|
|
53
|
-
WindowInsetsCompat.Type.statusBars() or
|
|
54
|
-
WindowInsetsCompat.Type.navigationBars() or
|
|
55
|
-
WindowInsetsCompat.Type.displayCutout())
|
|
56
|
-
.top
|
|
57
|
-
.toFloat()
|
|
58
|
-
}
|
|
59
|
-
|
|
60
47
|
@Suppress("DEPRECATION")
|
|
61
48
|
override fun setColor(colorDouble: Double, animated: Boolean) {
|
|
62
49
|
val color = colorDouble.toInt()
|
|
@@ -7,9 +7,12 @@
|
|
|
7
7
|
|
|
8
8
|
package com.facebook.react.uimanager
|
|
9
9
|
|
|
10
|
+
import android.app.Activity
|
|
10
11
|
import android.content.Context
|
|
11
12
|
import android.util.DisplayMetrics
|
|
12
13
|
import android.view.WindowManager
|
|
14
|
+
import androidx.core.view.ViewCompat
|
|
15
|
+
import androidx.core.view.WindowInsetsCompat
|
|
13
16
|
import com.facebook.react.bridge.WritableMap
|
|
14
17
|
import com.facebook.react.bridge.WritableNativeMap
|
|
15
18
|
|
|
@@ -99,4 +102,14 @@ public object DisplayMetricsHolder {
|
|
|
99
102
|
putDouble("fontScale", fontScale)
|
|
100
103
|
putDouble("densityDpi", displayMetrics.densityDpi.toDouble())
|
|
101
104
|
}
|
|
105
|
+
|
|
106
|
+
internal fun getStatusBarHeightPx(activity: Activity?): Int {
|
|
107
|
+
val windowInsets = activity?.window?.decorView?.let(ViewCompat::getRootWindowInsets) ?: return 0
|
|
108
|
+
return windowInsets
|
|
109
|
+
.getInsets(
|
|
110
|
+
WindowInsetsCompat.Type.statusBars() or
|
|
111
|
+
WindowInsetsCompat.Type.navigationBars() or
|
|
112
|
+
WindowInsetsCompat.Type.displayCutout())
|
|
113
|
+
.top
|
|
114
|
+
}
|
|
102
115
|
}
|
|
@@ -39,6 +39,8 @@ import com.facebook.react.bridge.WritableNativeMap
|
|
|
39
39
|
import com.facebook.react.common.ReactConstants
|
|
40
40
|
import com.facebook.react.common.annotations.VisibleForTesting
|
|
41
41
|
import com.facebook.react.config.ReactFeatureFlags
|
|
42
|
+
import com.facebook.react.uimanager.DisplayMetricsHolder
|
|
43
|
+
import com.facebook.react.uimanager.DisplayMetricsHolder.getStatusBarHeightPx
|
|
42
44
|
import com.facebook.react.uimanager.JSPointerDispatcher
|
|
43
45
|
import com.facebook.react.uimanager.JSTouchDispatcher
|
|
44
46
|
import com.facebook.react.uimanager.PixelUtil.pxToDp
|
|
@@ -52,6 +54,7 @@ import com.facebook.react.views.view.ReactViewGroup
|
|
|
52
54
|
import com.facebook.react.views.view.setStatusBarTranslucency
|
|
53
55
|
import com.facebook.react.views.view.setSystemBarsTranslucency
|
|
54
56
|
import java.util.Objects
|
|
57
|
+
import com.facebook.yoga.annotations.DoNotStrip
|
|
55
58
|
|
|
56
59
|
/**
|
|
57
60
|
* ReactModalHostView is a view that sits in the view hierarchy representing a Modal view.
|
|
@@ -66,6 +69,7 @@ import java.util.Objects
|
|
|
66
69
|
* addition and removal of views to the DialogRootViewGroup.
|
|
67
70
|
*/
|
|
68
71
|
@SuppressLint("ViewConstructor")
|
|
72
|
+
@DoNotStrip
|
|
69
73
|
public class ReactModalHostView(context: ThemedReactContext) :
|
|
70
74
|
ViewGroup(context), LifecycleEventListener {
|
|
71
75
|
|
|
@@ -121,6 +125,7 @@ public class ReactModalHostView(context: ThemedReactContext) :
|
|
|
121
125
|
private var createNewDialog = false
|
|
122
126
|
|
|
123
127
|
init {
|
|
128
|
+
initStatusBarHeight(context)
|
|
124
129
|
dialogRootViewGroup = DialogRootViewGroup(context)
|
|
125
130
|
}
|
|
126
131
|
|
|
@@ -448,6 +453,26 @@ public class ReactModalHostView(context: ThemedReactContext) :
|
|
|
448
453
|
|
|
449
454
|
private companion object {
|
|
450
455
|
private const val TAG = "ReactModalHost"
|
|
456
|
+
|
|
457
|
+
// We store the status bar height to be able to properly position
|
|
458
|
+
// the modal on the first render.
|
|
459
|
+
private var statusBarHeight = 0
|
|
460
|
+
|
|
461
|
+
private fun initStatusBarHeight(reactContext: ReactContext) {
|
|
462
|
+
statusBarHeight = getStatusBarHeightPx(reactContext.currentActivity)
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
@JvmStatic
|
|
466
|
+
@DoNotStrip
|
|
467
|
+
private fun getScreenDisplayMetricsWithoutInsets(): Long {
|
|
468
|
+
val displayMetrics = DisplayMetricsHolder.getScreenDisplayMetrics()
|
|
469
|
+
return encodeFloatsToLong(
|
|
470
|
+
displayMetrics.widthPixels.toFloat().pxToDp(),
|
|
471
|
+
(displayMetrics.heightPixels - statusBarHeight).toFloat().pxToDp())
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
private fun encodeFloatsToLong(width: Float, height: Float): Long =
|
|
475
|
+
(width.toRawBits().toLong()) shl 32 or (height.toRawBits().toLong())
|
|
451
476
|
}
|
|
452
477
|
|
|
453
478
|
/**
|
|
@@ -463,6 +488,7 @@ public class ReactModalHostView(context: ThemedReactContext) :
|
|
|
463
488
|
*/
|
|
464
489
|
public class DialogRootViewGroup internal constructor(context: Context) :
|
|
465
490
|
ReactViewGroup(context), RootView {
|
|
491
|
+
|
|
466
492
|
internal var stateWrapper: StateWrapper? = null
|
|
467
493
|
internal var eventDispatcher: EventDispatcher? = null
|
|
468
494
|
|
|
@@ -109,7 +109,11 @@ Pod::Spec.new do |s|
|
|
|
109
109
|
sss.dependency folly_dep_name, folly_version
|
|
110
110
|
sss.compiler_flags = folly_compiler_flags
|
|
111
111
|
sss.source_files = "react/renderer/components/modal/**/*.{m,mm,cpp,h}"
|
|
112
|
-
sss.exclude_files =
|
|
112
|
+
sss.exclude_files = [
|
|
113
|
+
"react/renderer/components/modal/tests",
|
|
114
|
+
"react/renderer/components/modal/platform/android/**/*.{cpp,h}",
|
|
115
|
+
"react/renderer/components/modal/platform/cxx/**/*.{cpp,h}"
|
|
116
|
+
]
|
|
113
117
|
sss.header_dir = "react/renderer/components/modal"
|
|
114
118
|
end
|
|
115
119
|
|
|
@@ -14,14 +14,14 @@
|
|
|
14
14
|
|
|
15
15
|
#define REACT_NATIVE_VERSION_MAJOR 0
|
|
16
16
|
#define REACT_NATIVE_VERSION_MINOR 79
|
|
17
|
-
#define REACT_NATIVE_VERSION_PATCH
|
|
17
|
+
#define REACT_NATIVE_VERSION_PATCH 6
|
|
18
18
|
|
|
19
19
|
namespace facebook::react {
|
|
20
20
|
|
|
21
21
|
constexpr struct {
|
|
22
22
|
int32_t Major = 0;
|
|
23
23
|
int32_t Minor = 79;
|
|
24
|
-
int32_t Patch =
|
|
24
|
+
int32_t Patch = 6;
|
|
25
25
|
std::string_view Prerelease = "";
|
|
26
26
|
} ReactNativeVersion;
|
|
27
27
|
|
package/ReactCommon/react/nativemodule/core/platform/android/ReactCommon/JavaTurboModule.cpp
CHANGED
|
@@ -989,15 +989,19 @@ void JavaTurboModule::setEventEmitterCallback(
|
|
|
989
989
|
*eventEmitterMap_[eventName].get());
|
|
990
990
|
};
|
|
991
991
|
|
|
992
|
-
|
|
993
|
-
arg.l = JCxxCallbackImpl::newObjectCxxArgs([eventEmitterLookup = std::move(
|
|
994
|
-
eventEmitterLookup)](
|
|
992
|
+
auto callback = JCxxCallbackImpl::newObjectCxxArgs([eventEmitterLookup = std::move(eventEmitterLookup)](
|
|
995
993
|
folly::dynamic args) {
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
994
|
+
auto eventName = args.at(0).asString();
|
|
995
|
+
auto eventArgs = args.size() > 1 ? args.at(1) : nullptr;
|
|
996
|
+
eventEmitterLookup(eventName).emit(std::move(eventArgs));
|
|
997
|
+
});
|
|
998
|
+
|
|
999
|
+
jvalue args[1];
|
|
1000
|
+
args[0].l = callback.release();
|
|
1001
|
+
// CallVoidMethod is replaced with CallVoidMethodA as it's unsafe on 32bit and
|
|
1002
|
+
// causes crashes https://github.com/facebook/react-native/issues/51628
|
|
1003
|
+
env->CallVoidMethodA(instance_.get(), cachedMethodId, args);
|
|
1004
|
+
FACEBOOK_JNI_THROW_PENDING_EXCEPTION();
|
|
1001
1005
|
}
|
|
1002
1006
|
|
|
1003
1007
|
} // namespace facebook::react
|
|
@@ -14,7 +14,10 @@ add_compile_options(
|
|
|
14
14
|
-Wpedantic
|
|
15
15
|
-DLOG_TAG=\"Fabric\")
|
|
16
16
|
|
|
17
|
-
file(GLOB rrc_modal_SRC CONFIGURE_DEPENDS
|
|
17
|
+
file(GLOB rrc_modal_SRC CONFIGURE_DEPENDS
|
|
18
|
+
*.cpp
|
|
19
|
+
platform/android/*.cpp)
|
|
20
|
+
|
|
18
21
|
add_library(rrc_modal STATIC ${rrc_modal_SRC})
|
|
19
22
|
|
|
20
23
|
target_include_directories(rrc_modal PUBLIC ${REACT_COMMON_DIR})
|
|
@@ -30,8 +30,9 @@ class ModalHostViewComponentDescriptor final
|
|
|
30
30
|
*shadowNode.getState())
|
|
31
31
|
.getData();
|
|
32
32
|
|
|
33
|
-
layoutableShadowNode.setSize(
|
|
34
|
-
|
|
33
|
+
layoutableShadowNode.setSize(Size{
|
|
34
|
+
.width = stateData.screenSize.width,
|
|
35
|
+
.height = stateData.screenSize.height});
|
|
35
36
|
layoutableShadowNode.setPositionType(YGPositionTypeAbsolute);
|
|
36
37
|
|
|
37
38
|
ConcreteComponentDescriptor::adopt(shadowNode);
|
|
@@ -9,15 +9,12 @@
|
|
|
9
9
|
|
|
10
10
|
#include <react/renderer/core/graphicsConversions.h>
|
|
11
11
|
#include <react/renderer/graphics/Float.h>
|
|
12
|
+
#include "ModalHostViewUtils.h"
|
|
12
13
|
|
|
13
14
|
#ifdef ANDROID
|
|
14
15
|
#include <folly/dynamic.h>
|
|
15
16
|
#endif
|
|
16
17
|
|
|
17
|
-
#if defined(__APPLE__) && TARGET_OS_IOS
|
|
18
|
-
#include "ModalHostViewUtils.h"
|
|
19
|
-
#endif
|
|
20
|
-
|
|
21
18
|
namespace facebook::react {
|
|
22
19
|
|
|
23
20
|
/*
|
|
@@ -27,12 +24,7 @@ class ModalHostViewState final {
|
|
|
27
24
|
public:
|
|
28
25
|
using Shared = std::shared_ptr<const ModalHostViewState>;
|
|
29
26
|
|
|
30
|
-
|
|
31
|
-
ModalHostViewState() : screenSize(RCTModalHostViewScreenSize()) {
|
|
32
|
-
#else
|
|
33
|
-
ModalHostViewState(){
|
|
34
|
-
#endif
|
|
35
|
-
};
|
|
27
|
+
ModalHostViewState() : screenSize(ModalHostViewScreenSize()) {}
|
|
36
28
|
ModalHostViewState(Size screenSize_) : screenSize(screenSize_){};
|
|
37
29
|
|
|
38
30
|
#ifdef ANDROID
|
|
@@ -40,8 +32,8 @@ class ModalHostViewState final {
|
|
|
40
32
|
const ModalHostViewState& previousState,
|
|
41
33
|
folly::dynamic data)
|
|
42
34
|
: screenSize(Size{
|
|
43
|
-
(Float)data["screenWidth"].getDouble(),
|
|
44
|
-
(Float)data["screenHeight"].getDouble()}){};
|
|
35
|
+
.width = (Float)data["screenWidth"].getDouble(),
|
|
36
|
+
.height = (Float)data["screenHeight"].getDouble()}){};
|
|
45
37
|
#endif
|
|
46
38
|
|
|
47
39
|
const Size screenSize{};
|
|
@@ -7,10 +7,10 @@
|
|
|
7
7
|
|
|
8
8
|
#pragma once
|
|
9
9
|
|
|
10
|
-
#include <react/renderer/
|
|
10
|
+
#include <react/renderer/graphics/Size.h>
|
|
11
11
|
|
|
12
12
|
namespace facebook::react {
|
|
13
13
|
|
|
14
|
-
Size
|
|
14
|
+
Size ModalHostViewScreenSize(void);
|
|
15
15
|
|
|
16
16
|
} // namespace facebook::react
|
|
@@ -0,0 +1,38 @@
|
|
|
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 <fbjni/fbjni.h>
|
|
11
|
+
#include <react/renderer/graphics/Size.h>
|
|
12
|
+
|
|
13
|
+
namespace facebook::react {
|
|
14
|
+
|
|
15
|
+
class JReactModalHostView
|
|
16
|
+
: public facebook::jni::JavaClass<JReactModalHostView> {
|
|
17
|
+
public:
|
|
18
|
+
static auto constexpr kJavaDescriptor =
|
|
19
|
+
"Lcom/facebook/react/views/modal/ReactModalHostView;";
|
|
20
|
+
|
|
21
|
+
static Size getDisplayMetrics() {
|
|
22
|
+
static auto method =
|
|
23
|
+
JReactModalHostView::javaClassStatic()->getStaticMethod<jlong()>(
|
|
24
|
+
"getScreenDisplayMetricsWithoutInsets");
|
|
25
|
+
auto result = method(javaClassStatic());
|
|
26
|
+
|
|
27
|
+
// Inspired from yogaMeassureToSize from conversions.h
|
|
28
|
+
int32_t wBits = 0xFFFFFFFF & (result >> 32);
|
|
29
|
+
int32_t hBits = 0xFFFFFFFF & result;
|
|
30
|
+
|
|
31
|
+
auto* measuredWidth = reinterpret_cast<float*>(&wBits);
|
|
32
|
+
auto* measuredHeight = reinterpret_cast<float*>(&hBits);
|
|
33
|
+
|
|
34
|
+
return Size{.width = *measuredWidth, .height = *measuredHeight};
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
} // namespace facebook::react
|
|
@@ -0,0 +1,18 @@
|
|
|
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 <react/renderer/components/modal/ModalHostViewUtils.h>
|
|
9
|
+
#include <react/renderer/graphics/Size.h>
|
|
10
|
+
#include "JReactModalHostView.h"
|
|
11
|
+
|
|
12
|
+
namespace facebook::react {
|
|
13
|
+
|
|
14
|
+
Size ModalHostViewScreenSize() {
|
|
15
|
+
return JReactModalHostView::getDisplayMetrics();
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
} // namespace facebook::react
|
|
@@ -0,0 +1,17 @@
|
|
|
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 <react/renderer/components/modal/ModalHostViewUtils.h>
|
|
9
|
+
#include <react/renderer/graphics/Size.h>
|
|
10
|
+
|
|
11
|
+
namespace facebook::react {
|
|
12
|
+
|
|
13
|
+
Size ModalHostViewScreenSize() {
|
|
14
|
+
return Size{0, 0};
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
} // namespace facebook::react
|
package/index.js.flow
ADDED
|
@@ -0,0 +1,115 @@
|
|
|
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
|
+
* @format
|
|
8
|
+
* @flow strict-local
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
// ----------------------------------------------------------------------------
|
|
12
|
+
// Types entry point for react-native.
|
|
13
|
+
//
|
|
14
|
+
// IMPORTANT: Keep this file in sync with index.js. Test your changes whenever
|
|
15
|
+
// updating React Native's public API.
|
|
16
|
+
// ----------------------------------------------------------------------------
|
|
17
|
+
|
|
18
|
+
// TODO(T215317597): Reconsider the pre-existing grouping of these APIs
|
|
19
|
+
|
|
20
|
+
export type {HostInstance} from './src/private/types/HostInstance';
|
|
21
|
+
export type {HostComponent} from './src/private/types/HostComponent';
|
|
22
|
+
export {default as registerCallableModule} from './Libraries/Core/registerCallableModule';
|
|
23
|
+
|
|
24
|
+
/// <reference path="src/types/globals.d.ts" />
|
|
25
|
+
|
|
26
|
+
// #region Components
|
|
27
|
+
|
|
28
|
+
export {default as AccessibilityInfo} from './Libraries/Components/AccessibilityInfo/AccessibilityInfo';
|
|
29
|
+
export {default as ActivityIndicator} from './Libraries/Components/ActivityIndicator/ActivityIndicator';
|
|
30
|
+
export {default as Button} from './Libraries/Components/Button';
|
|
31
|
+
export {default as DrawerLayoutAndroid} from './Libraries/Components/DrawerAndroid/DrawerLayoutAndroid';
|
|
32
|
+
export {default as experimental_LayoutConformance} from './Libraries/Components/LayoutConformance/LayoutConformance';
|
|
33
|
+
export {default as FlatList} from './Libraries/Lists/FlatList';
|
|
34
|
+
export {default as Image} from './Libraries/Image/Image';
|
|
35
|
+
export {default as ImageBackground} from './Libraries/Image/ImageBackground';
|
|
36
|
+
export {default as InputAccessoryView} from './Libraries/Components/TextInput/InputAccessoryView';
|
|
37
|
+
export {default as KeyboardAvoidingView} from './Libraries/Components/Keyboard/KeyboardAvoidingView';
|
|
38
|
+
export {default as Modal} from './Libraries/Modal/Modal';
|
|
39
|
+
export {default as Pressable} from './Libraries/Components/Pressable/Pressable';
|
|
40
|
+
export {default as ProgressBarAndroid} from './Libraries/Components/ProgressBarAndroid/ProgressBarAndroid';
|
|
41
|
+
export {default as RefreshControl} from './Libraries/Components/RefreshControl/RefreshControl';
|
|
42
|
+
export {default as SafeAreaView} from './Libraries/Components/SafeAreaView/SafeAreaView';
|
|
43
|
+
export {default as ScrollView} from './Libraries/Components/ScrollView/ScrollView';
|
|
44
|
+
export {default as SectionList} from './Libraries/Lists/SectionList';
|
|
45
|
+
export {default as StatusBar} from './Libraries/Components/StatusBar/StatusBar';
|
|
46
|
+
export {default as Switch} from './Libraries/Components/Switch/Switch';
|
|
47
|
+
export {default as Text} from './Libraries/Text/Text';
|
|
48
|
+
export {default as TextInput} from './Libraries/Components/TextInput/TextInput';
|
|
49
|
+
export {default as Touchable} from './Libraries/Components/Touchable/Touchable';
|
|
50
|
+
export {default as TouchableHighlight} from './Libraries/Components/Touchable/TouchableHighlight';
|
|
51
|
+
export {default as TouchableNativeFeedback} from './Libraries/Components/Touchable/TouchableNativeFeedback';
|
|
52
|
+
export {default as TouchableOpacity} from './Libraries/Components/Touchable/TouchableOpacity';
|
|
53
|
+
export {default as TouchableWithoutFeedback} from './Libraries/Components/Touchable/TouchableWithoutFeedback';
|
|
54
|
+
export {default as View} from './Libraries/Components/View/View';
|
|
55
|
+
export {default as VirtualizedList} from './Libraries/Lists/VirtualizedList';
|
|
56
|
+
export {default as VirtualizedSectionList} from './Libraries/Lists/VirtualizedSectionList';
|
|
57
|
+
|
|
58
|
+
// #endregion
|
|
59
|
+
// #region APIs
|
|
60
|
+
|
|
61
|
+
export {default as ActionSheetIOS} from './Libraries/ActionSheetIOS/ActionSheetIOS';
|
|
62
|
+
export {default as Alert} from './Libraries/Alert/Alert';
|
|
63
|
+
export {default as Animated} from './Libraries/Animated/Animated';
|
|
64
|
+
export * as Appearance from './Libraries/Utilities/Appearance';
|
|
65
|
+
export {default as AppRegistry} from './Libraries/ReactNative/AppRegistry';
|
|
66
|
+
export {default as AppState} from './Libraries/AppState/AppState';
|
|
67
|
+
export {default as BackHandler} from './Libraries/Utilities/BackHandler';
|
|
68
|
+
export {default as Clipboard} from './Libraries/Components/Clipboard/Clipboard';
|
|
69
|
+
export {default as DeviceInfo} from './Libraries/Utilities/DeviceInfo';
|
|
70
|
+
export {default as DevMenu} from './src/private/devmenu/DevMenu';
|
|
71
|
+
export {default as DevSettings} from './Libraries/Utilities/DevSettings';
|
|
72
|
+
export {default as Dimensions} from './Libraries/Utilities/Dimensions';
|
|
73
|
+
export {default as Easing} from './Libraries/Animated/Easing';
|
|
74
|
+
export {findNodeHandle} from './Libraries/ReactNative/RendererProxy';
|
|
75
|
+
export {default as I18nManager} from './Libraries/ReactNative/I18nManager';
|
|
76
|
+
export {default as InteractionManager} from './Libraries/Interaction/InteractionManager';
|
|
77
|
+
export {default as Keyboard} from './Libraries/Components/Keyboard/Keyboard';
|
|
78
|
+
export {default as LayoutAnimation} from './Libraries/LayoutAnimation/LayoutAnimation';
|
|
79
|
+
export {default as Linking} from './Libraries/Linking/Linking';
|
|
80
|
+
export {default as LogBox} from './Libraries/LogBox/LogBox';
|
|
81
|
+
export {default as NativeDialogManagerAndroid} from './Libraries/NativeModules/specs/NativeDialogManagerAndroid';
|
|
82
|
+
export {default as NativeEventEmitter} from './Libraries/EventEmitter/NativeEventEmitter';
|
|
83
|
+
export {default as Networking} from './Libraries/Network/RCTNetworking';
|
|
84
|
+
export {default as PanResponder} from './Libraries/Interaction/PanResponder';
|
|
85
|
+
export {default as PermissionsAndroid} from './Libraries/PermissionsAndroid/PermissionsAndroid';
|
|
86
|
+
export {default as PixelRatio} from './Libraries/Utilities/PixelRatio';
|
|
87
|
+
export {default as PushNotificationIOS} from './Libraries/PushNotificationIOS/PushNotificationIOS';
|
|
88
|
+
export {default as Settings} from './Libraries/Settings/Settings';
|
|
89
|
+
export {default as Share} from './Libraries/Share/Share';
|
|
90
|
+
export {default as StyleSheet} from './Libraries/StyleSheet/StyleSheet';
|
|
91
|
+
export * as Systrace from './Libraries/Performance/Systrace';
|
|
92
|
+
export {default as ToastAndroid} from './Libraries/Components/ToastAndroid/ToastAndroid';
|
|
93
|
+
export * as TurboModuleRegistry from './Libraries/TurboModule/TurboModuleRegistry';
|
|
94
|
+
export {default as UIManager} from './Libraries/ReactNative/UIManager';
|
|
95
|
+
export {unstable_batchedUpdates} from './Libraries/ReactNative/RendererProxy';
|
|
96
|
+
export {default as useAnimatedValue} from './Libraries/Animated/useAnimatedValue';
|
|
97
|
+
export {default as useColorScheme} from './Libraries/Utilities/useColorScheme';
|
|
98
|
+
export {default as useWindowDimensions} from './Libraries/Utilities/useWindowDimensions';
|
|
99
|
+
export {default as UTFSequence} from './Libraries/UTFSequence';
|
|
100
|
+
export {default as Vibration} from './Libraries/Vibration/Vibration';
|
|
101
|
+
|
|
102
|
+
// #endregion
|
|
103
|
+
// #region Plugins
|
|
104
|
+
|
|
105
|
+
export {default as DeviceEventEmitter} from './Libraries/EventEmitter/RCTDeviceEventEmitter';
|
|
106
|
+
export {DynamicColorIOS} from './Libraries/StyleSheet/PlatformColorValueTypesIOS';
|
|
107
|
+
export {default as NativeAppEventEmitter} from './Libraries/EventEmitter/RCTNativeAppEventEmitter';
|
|
108
|
+
export {default as NativeModules} from './Libraries/BatchedBridge/NativeModules';
|
|
109
|
+
export {default as Platform} from './Libraries/Utilities/Platform';
|
|
110
|
+
export {PlatformColor} from './Libraries/StyleSheet/PlatformColorValueTypes';
|
|
111
|
+
export {default as processColor} from './Libraries/StyleSheet/processColor';
|
|
112
|
+
export {default as requireNativeComponent} from './Libraries/ReactNative/requireNativeComponent';
|
|
113
|
+
export {RootTagContext} from './Libraries/ReactNative/RootTag';
|
|
114
|
+
|
|
115
|
+
// #endregion
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.79.
|
|
3
|
+
"version": "0.79.6",
|
|
4
4
|
"description": "A framework for building native apps using React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"gradle.properties",
|
|
40
40
|
"gradle/libs.versions.toml",
|
|
41
41
|
"index.js",
|
|
42
|
-
"index.flow
|
|
42
|
+
"index.js.flow",
|
|
43
43
|
"interface.js",
|
|
44
44
|
"jest-preset.js",
|
|
45
45
|
"jest",
|
|
@@ -109,13 +109,13 @@
|
|
|
109
109
|
},
|
|
110
110
|
"dependencies": {
|
|
111
111
|
"@jest/create-cache-key-function": "^29.7.0",
|
|
112
|
-
"@react-native/assets-registry": "0.79.
|
|
113
|
-
"@react-native/codegen": "0.79.
|
|
114
|
-
"@react-native/community-cli-plugin": "0.79.
|
|
115
|
-
"@react-native/gradle-plugin": "0.79.
|
|
116
|
-
"@react-native/js-polyfills": "0.79.
|
|
117
|
-
"@react-native/normalize-colors": "0.79.
|
|
118
|
-
"@react-native/virtualized-lists": "0.79.
|
|
112
|
+
"@react-native/assets-registry": "0.79.6",
|
|
113
|
+
"@react-native/codegen": "0.79.6",
|
|
114
|
+
"@react-native/community-cli-plugin": "0.79.6",
|
|
115
|
+
"@react-native/gradle-plugin": "0.79.6",
|
|
116
|
+
"@react-native/js-polyfills": "0.79.6",
|
|
117
|
+
"@react-native/normalize-colors": "0.79.6",
|
|
118
|
+
"@react-native/virtualized-lists": "0.79.6",
|
|
119
119
|
"abort-controller": "^3.0.0",
|
|
120
120
|
"anser": "^1.4.9",
|
|
121
121
|
"ansi-regex": "^5.0.0",
|
|
@@ -204,7 +204,10 @@ def hermestag_file(react_native_path)
|
|
|
204
204
|
end
|
|
205
205
|
|
|
206
206
|
def release_tarball_url(version, build_type)
|
|
207
|
-
maven_repo_url =
|
|
207
|
+
maven_repo_url =
|
|
208
|
+
ENV['ENTERPRISE_REPOSITORY'] != nil && ENV['ENTERPRISE_REPOSITORY'] != "" ?
|
|
209
|
+
ENV['ENTERPRISE_REPOSITORY'] :
|
|
210
|
+
"https://repo1.maven.org/maven2"
|
|
208
211
|
namespace = "com/facebook/react"
|
|
209
212
|
# Sample url from Maven:
|
|
210
213
|
# https://repo1.maven.org/maven2/com/facebook/react/react-native-artifacts/0.71.0/react-native-artifacts-0.71.0-hermes-ios-debug.tar.gz
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|