react-native 0.84.0-nightly-20251208-8347cc4b5 → 0.84.0-nightly-20251210-3e9083b42
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/React/Fabric/Mounting/ComponentViews/View/RCTViewComponentView.mm +19 -2
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/perfmonitor/PerfMonitorOverlayManager.kt +5 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsOverrides_RNOSS_Experimental_Android.kt +3 -1
- package/ReactAndroid/src/main/java/com/facebook/react/modules/network/NetworkEventUtil.kt +2 -1
- package/ReactAndroid/src/main/java/com/facebook/react/modules/network/ProgressRequestBody.kt +20 -0
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/runtime/ReactHostInspectorTarget.kt +2 -12
- package/ReactAndroid/src/main/jni/react/runtime/jni/JReactHostInspectorTarget.cpp +2 -40
- package/ReactAndroid/src/main/jni/react/runtime/jni/JReactHostInspectorTarget.h +41 -10
- package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsOverridesOSSExperimental.h +5 -1
- package/ReactCommon/react/renderer/animated/NativeAnimatedNodesManager.cpp +33 -29
- package/index.js +3 -0
- package/index.js.flow +5 -0
- package/package.json +8 -8
- package/src/types/globals.d.ts +30 -1
- package/types_generated/Libraries/Pressability/usePressability.d.ts +27 -0
- package/types_generated/index.d.ts +3 -1
|
@@ -29,7 +29,7 @@ export default class ReactNativeVersion {
|
|
|
29
29
|
static major: number = 0;
|
|
30
30
|
static minor: number = 84;
|
|
31
31
|
static patch: number = 0;
|
|
32
|
-
static prerelease: string | null = 'nightly-
|
|
32
|
+
static prerelease: string | null = 'nightly-20251210-3e9083b42';
|
|
33
33
|
|
|
34
34
|
static getVersionString(): string {
|
|
35
35
|
return `${this.major}.${this.minor}.${this.patch}${this.prerelease != null ? `-${this.prerelease}` : ''}`;
|
package/React/Base/RCTVersion.m
CHANGED
|
@@ -24,7 +24,7 @@ NSDictionary* RCTGetReactNativeVersion(void)
|
|
|
24
24
|
RCTVersionMajor: @(0),
|
|
25
25
|
RCTVersionMinor: @(84),
|
|
26
26
|
RCTVersionPatch: @(0),
|
|
27
|
-
RCTVersionPrerelease: @"nightly-
|
|
27
|
+
RCTVersionPrerelease: @"nightly-20251210-3e9083b42",
|
|
28
28
|
};
|
|
29
29
|
});
|
|
30
30
|
return __rnVersion;
|
|
@@ -1497,8 +1497,15 @@ static NSString *RCTRecursiveAccessibilityLabel(UIView *view)
|
|
|
1497
1497
|
|
|
1498
1498
|
NSMutableArray<UIAccessibilityCustomAction *> *customActions = [NSMutableArray array];
|
|
1499
1499
|
for (const auto &accessibilityAction : accessibilityActions) {
|
|
1500
|
+
NSString *actionName = RCTNSStringFromString(accessibilityAction.name);
|
|
1501
|
+
NSString *actionLabel = actionName;
|
|
1502
|
+
|
|
1503
|
+
if (accessibilityAction.label.has_value()) {
|
|
1504
|
+
actionLabel = RCTNSStringFromString(accessibilityAction.label.value());
|
|
1505
|
+
}
|
|
1506
|
+
|
|
1500
1507
|
[customActions
|
|
1501
|
-
addObject:[[UIAccessibilityCustomAction alloc] initWithName:
|
|
1508
|
+
addObject:[[UIAccessibilityCustomAction alloc] initWithName:actionLabel
|
|
1502
1509
|
target:self
|
|
1503
1510
|
selector:@selector(didActivateAccessibilityCustomAction:)]];
|
|
1504
1511
|
}
|
|
@@ -1553,7 +1560,17 @@ static NSString *RCTRecursiveAccessibilityLabel(UIView *view)
|
|
|
1553
1560
|
- (BOOL)didActivateAccessibilityCustomAction:(UIAccessibilityCustomAction *)action
|
|
1554
1561
|
{
|
|
1555
1562
|
if (_eventEmitter && _props->onAccessibilityAction) {
|
|
1556
|
-
|
|
1563
|
+
// iOS defines the name as the localized label, so iterate through accessibilityActions to find the matching
|
|
1564
|
+
// non-localized action name when passing to JS. This allows for standard action names across platforms.
|
|
1565
|
+
NSString *actionName = action.name;
|
|
1566
|
+
for (const auto &accessibilityAction : _props->accessibilityActions) {
|
|
1567
|
+
if (accessibilityAction.label.has_value() &&
|
|
1568
|
+
[RCTNSStringFromString(accessibilityAction.label.value()) isEqualToString:action.name]) {
|
|
1569
|
+
actionName = RCTNSStringFromString(accessibilityAction.name);
|
|
1570
|
+
break;
|
|
1571
|
+
}
|
|
1572
|
+
}
|
|
1573
|
+
_eventEmitter->onAccessibilityAction(RCTStringFromNSString(actionName));
|
|
1557
1574
|
return YES;
|
|
1558
1575
|
} else {
|
|
1559
1576
|
return NO;
|
|
@@ -83,7 +83,11 @@ internal class PerfMonitorOverlayManager(
|
|
|
83
83
|
UiThreadUtil.runOnUiThread {
|
|
84
84
|
view?.updateRecordingState(state)
|
|
85
85
|
view?.updatePerfIssueCount(perfIssueCount)
|
|
86
|
-
|
|
86
|
+
if (state == TracingState.ENABLED_IN_CDP_MODE) {
|
|
87
|
+
view?.hide()
|
|
88
|
+
} else {
|
|
89
|
+
view?.show()
|
|
90
|
+
}
|
|
87
91
|
}
|
|
88
92
|
}
|
|
89
93
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<8531ce29d0e5362517d35559ebda623b>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -27,5 +27,7 @@ public open class ReactNativeFeatureFlagsOverrides_RNOSS_Experimental_Android :
|
|
|
27
27
|
|
|
28
28
|
override fun enableSwiftUIBasedFilters(): Boolean = true
|
|
29
29
|
|
|
30
|
+
override fun fixTextClippingAndroid15useBoundsForWidth(): Boolean = true
|
|
31
|
+
|
|
30
32
|
override fun preventShadowTreeCommitExhaustion(): Boolean = true
|
|
31
33
|
}
|
|
@@ -35,7 +35,8 @@ internal object NetworkEventUtil {
|
|
|
35
35
|
request.url().toString(),
|
|
36
36
|
request.method(),
|
|
37
37
|
headersMap,
|
|
38
|
-
request.body()?.
|
|
38
|
+
(request.body() as? ProgressRequestBody)?.getBodyPreview()
|
|
39
|
+
?: request.body()?.toString().orEmpty(),
|
|
39
40
|
request.body()?.contentLength() ?: 0,
|
|
40
41
|
)
|
|
41
42
|
InspectorNetworkReporter.reportConnectionTiming(devToolsRequestId, headersMap)
|
package/ReactAndroid/src/main/java/com/facebook/react/modules/network/ProgressRequestBody.kt
CHANGED
|
@@ -23,6 +23,10 @@ internal class ProgressRequestBody(
|
|
|
23
23
|
) : RequestBody() {
|
|
24
24
|
private var contentLength = 0L
|
|
25
25
|
|
|
26
|
+
companion object {
|
|
27
|
+
private const val MAX_BODY_PREVIEW_SIZE = 1024 * 1024 // 1MB
|
|
28
|
+
}
|
|
29
|
+
|
|
26
30
|
override fun contentType(): MediaType? {
|
|
27
31
|
return requestBody.contentType()
|
|
28
32
|
}
|
|
@@ -78,4 +82,20 @@ internal class ProgressRequestBody(
|
|
|
78
82
|
}
|
|
79
83
|
)
|
|
80
84
|
}
|
|
85
|
+
|
|
86
|
+
fun getBodyPreview(): String {
|
|
87
|
+
return try {
|
|
88
|
+
val buffer = okio.Buffer()
|
|
89
|
+
requestBody.writeTo(buffer)
|
|
90
|
+
val size = buffer.size()
|
|
91
|
+
if (size <= MAX_BODY_PREVIEW_SIZE) {
|
|
92
|
+
buffer.readUtf8()
|
|
93
|
+
} else {
|
|
94
|
+
buffer.readUtf8(MAX_BODY_PREVIEW_SIZE.toLong()) +
|
|
95
|
+
"\n... [truncated, showing $MAX_BODY_PREVIEW_SIZE of $size bytes]"
|
|
96
|
+
}
|
|
97
|
+
} catch (e: Exception) {
|
|
98
|
+
""
|
|
99
|
+
}
|
|
100
|
+
}
|
|
81
101
|
}
|
|
@@ -53,29 +53,19 @@ internal class ReactHostInspectorTarget(reactHostImpl: ReactHostImpl) :
|
|
|
53
53
|
|
|
54
54
|
override fun addPerfMonitorListener(listener: PerfMonitorUpdateListener) {
|
|
55
55
|
perfMonitorListeners.add(listener)
|
|
56
|
+
registerTracingStateListener { state, _ -> listener.onRecordingStateChanged(state) }
|
|
56
57
|
}
|
|
57
58
|
|
|
58
59
|
override fun pauseAndAnalyzeBackgroundTrace(): Boolean {
|
|
59
|
-
|
|
60
|
-
perfMonitorListeners.forEach { listener ->
|
|
61
|
-
listener.onRecordingStateChanged(TracingState.DISABLED)
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
return emitted
|
|
60
|
+
return stopAndMaybeEmitBackgroundTrace()
|
|
65
61
|
}
|
|
66
62
|
|
|
67
63
|
override fun resumeBackgroundTrace() {
|
|
68
64
|
startBackgroundTrace()
|
|
69
|
-
perfMonitorListeners.forEach { listener ->
|
|
70
|
-
listener.onRecordingStateChanged(TracingState.ENABLED_IN_BACKGROUND_MODE)
|
|
71
|
-
}
|
|
72
65
|
}
|
|
73
66
|
|
|
74
67
|
override fun stopBackgroundTrace() {
|
|
75
68
|
stopAndDiscardBackgroundTrace()
|
|
76
|
-
perfMonitorListeners.forEach { listener ->
|
|
77
|
-
listener.onRecordingStateChanged(TracingState.DISABLED)
|
|
78
|
-
}
|
|
79
69
|
}
|
|
80
70
|
|
|
81
71
|
fun handleNativePerfIssueAdded(
|
|
@@ -17,35 +17,6 @@ using namespace facebook::react::jsinspector_modern;
|
|
|
17
17
|
|
|
18
18
|
namespace facebook::react {
|
|
19
19
|
|
|
20
|
-
namespace {
|
|
21
|
-
jni::local_ref<JTracingState::javaobject> convertCPPTracingStateToJava(
|
|
22
|
-
TracingState tracingState) {
|
|
23
|
-
auto tracingStateClass = jni::findClassLocal(
|
|
24
|
-
"com/facebook/react/devsupport/inspector/TracingState");
|
|
25
|
-
auto valueOfMethod =
|
|
26
|
-
tracingStateClass->getStaticMethod<JTracingState(jstring)>("valueOf");
|
|
27
|
-
|
|
28
|
-
switch (tracingState) {
|
|
29
|
-
case TracingState::Disabled:
|
|
30
|
-
return valueOfMethod(
|
|
31
|
-
tracingStateClass, jni::make_jstring("DISABLED").get());
|
|
32
|
-
|
|
33
|
-
case TracingState::EnabledInBackgroundMode:
|
|
34
|
-
return valueOfMethod(
|
|
35
|
-
tracingStateClass,
|
|
36
|
-
jni::make_jstring("ENABLED_IN_BACKGROUND_MODE").get());
|
|
37
|
-
|
|
38
|
-
case TracingState::EnabledInCDPMode:
|
|
39
|
-
return valueOfMethod(
|
|
40
|
-
tracingStateClass, jni::make_jstring("ENABLED_IN_CDP_MODE").get());
|
|
41
|
-
|
|
42
|
-
default:
|
|
43
|
-
jni::throwNewJavaException(
|
|
44
|
-
"java/lang/IllegalStateException", "Unexpected new TracingState.");
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
} // namespace
|
|
48
|
-
|
|
49
20
|
JReactHostInspectorTarget::JReactHostInspectorTarget(
|
|
50
21
|
alias_ref<JReactHostInspectorTarget::javaobject> jobj,
|
|
51
22
|
alias_ref<JReactHostImpl> reactHostImpl,
|
|
@@ -266,17 +237,8 @@ JReactHostInspectorTarget::getTracingState() {
|
|
|
266
237
|
jlong JReactHostInspectorTarget::registerTracingStateListener(
|
|
267
238
|
jni::alias_ref<JTracingStateListener::javaobject> listener) {
|
|
268
239
|
auto cppListener = [globalRef = make_global(listener)](
|
|
269
|
-
TracingState
|
|
270
|
-
|
|
271
|
-
globalRef->getClass()
|
|
272
|
-
->getMethod<void(
|
|
273
|
-
jni::local_ref<JTracingState::javaobject>, jboolean)>(
|
|
274
|
-
"onStateChanged");
|
|
275
|
-
|
|
276
|
-
method(
|
|
277
|
-
globalRef,
|
|
278
|
-
convertCPPTracingStateToJava(state),
|
|
279
|
-
static_cast<jboolean>(screenshotsEnabled));
|
|
240
|
+
TracingState tracingState, bool screenshotsEnabled) {
|
|
241
|
+
globalRef->onStateChanged(tracingState, screenshotsEnabled);
|
|
280
242
|
};
|
|
281
243
|
|
|
282
244
|
return static_cast<jlong>(
|
|
@@ -20,16 +20,53 @@
|
|
|
20
20
|
|
|
21
21
|
namespace facebook::react {
|
|
22
22
|
|
|
23
|
-
struct JTaskInterface : public jni::JavaClass<JTaskInterface> {
|
|
24
|
-
static constexpr auto kJavaDescriptor = "Lcom/facebook/react/interfaces/TaskInterface;";
|
|
25
|
-
};
|
|
26
|
-
|
|
27
23
|
struct JTracingState : public jni::JavaClass<JTracingState> {
|
|
28
24
|
static constexpr auto kJavaDescriptor = "Lcom/facebook/react/devsupport/inspector/TracingState;";
|
|
29
25
|
};
|
|
30
26
|
|
|
27
|
+
namespace {
|
|
28
|
+
|
|
29
|
+
enum class TracingState {
|
|
30
|
+
Disabled,
|
|
31
|
+
EnabledInBackgroundMode,
|
|
32
|
+
EnabledInCDPMode,
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
jni::local_ref<JTracingState::javaobject> convertCPPTracingStateToJava(TracingState tracingState)
|
|
36
|
+
{
|
|
37
|
+
auto tracingStateClass = jni::findClassLocal("com/facebook/react/devsupport/inspector/TracingState");
|
|
38
|
+
auto valueOfMethod = tracingStateClass->getStaticMethod<JTracingState(jstring)>("valueOf");
|
|
39
|
+
|
|
40
|
+
switch (tracingState) {
|
|
41
|
+
case TracingState::Disabled:
|
|
42
|
+
return valueOfMethod(tracingStateClass, jni::make_jstring("DISABLED").get());
|
|
43
|
+
|
|
44
|
+
case TracingState::EnabledInBackgroundMode:
|
|
45
|
+
return valueOfMethod(tracingStateClass, jni::make_jstring("ENABLED_IN_BACKGROUND_MODE").get());
|
|
46
|
+
|
|
47
|
+
case TracingState::EnabledInCDPMode:
|
|
48
|
+
return valueOfMethod(tracingStateClass, jni::make_jstring("ENABLED_IN_CDP_MODE").get());
|
|
49
|
+
|
|
50
|
+
default:
|
|
51
|
+
jni::throwNewJavaException("java/lang/IllegalStateException", "Unexpected new TracingState.");
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
} // namespace
|
|
56
|
+
|
|
57
|
+
struct JTaskInterface : public jni::JavaClass<JTaskInterface> {
|
|
58
|
+
static constexpr auto kJavaDescriptor = "Lcom/facebook/react/interfaces/TaskInterface;";
|
|
59
|
+
};
|
|
60
|
+
|
|
31
61
|
struct JTracingStateListener : public jni::JavaClass<JTracingStateListener> {
|
|
32
62
|
static constexpr auto kJavaDescriptor = "Lcom/facebook/react/devsupport/inspector/TracingStateListener;";
|
|
63
|
+
|
|
64
|
+
void onStateChanged(TracingState tracingState, bool screenshotsEnabled) const
|
|
65
|
+
{
|
|
66
|
+
static auto method =
|
|
67
|
+
javaClassStatic()->getMethod<void(jni::local_ref<JTracingState::javaobject>, jboolean)>("onStateChanged");
|
|
68
|
+
return method(self(), convertCPPTracingStateToJava(tracingState), static_cast<jboolean>(screenshotsEnabled));
|
|
69
|
+
}
|
|
33
70
|
};
|
|
34
71
|
|
|
35
72
|
struct JFrameTimingSequence : public jni::JavaClass<JFrameTimingSequence> {
|
|
@@ -112,12 +149,6 @@ struct JReactHostImpl : public jni::JavaClass<JReactHostImpl> {
|
|
|
112
149
|
}
|
|
113
150
|
};
|
|
114
151
|
|
|
115
|
-
enum class TracingState {
|
|
116
|
-
Disabled,
|
|
117
|
-
EnabledInBackgroundMode,
|
|
118
|
-
EnabledInCDPMode,
|
|
119
|
-
};
|
|
120
|
-
|
|
121
152
|
/**
|
|
122
153
|
* A callback that will be invoked when tracing state has changed.
|
|
123
154
|
*/
|
|
@@ -22,7 +22,7 @@ constexpr struct {
|
|
|
22
22
|
int32_t Major = 0;
|
|
23
23
|
int32_t Minor = 84;
|
|
24
24
|
int32_t Patch = 0;
|
|
25
|
-
std::string_view Prerelease = "nightly-
|
|
25
|
+
std::string_view Prerelease = "nightly-20251210-3e9083b42";
|
|
26
26
|
} ReactNativeVersion;
|
|
27
27
|
|
|
28
28
|
} // namespace facebook::react
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<6a047fa1d33ea17ebd7ba8d0680ee1cc>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -35,6 +35,10 @@ class ReactNativeFeatureFlagsOverridesOSSExperimental : public ReactNativeFeatur
|
|
|
35
35
|
return true;
|
|
36
36
|
}
|
|
37
37
|
|
|
38
|
+
bool fixTextClippingAndroid15useBoundsForWidth() override {
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
|
|
38
42
|
bool preventShadowTreeCommitExhaustion() override {
|
|
39
43
|
return true;
|
|
40
44
|
}
|
|
@@ -653,20 +653,22 @@ void NativeAnimatedNodesManager::updateNodes(
|
|
|
653
653
|
// in Animated, value nodes like RGBA are parents and Color node is child
|
|
654
654
|
// (the opposite of tree structure)
|
|
655
655
|
for (const auto childTag : nextNode.node->getChildren()) {
|
|
656
|
-
auto child = getAnimatedNode<AnimatedNode>(childTag)
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
656
|
+
if (auto child = getAnimatedNode<AnimatedNode>(childTag)) {
|
|
657
|
+
child->activeIncomingNodes++;
|
|
658
|
+
if (child->bfsColor != animatedGraphBFSColor_) {
|
|
659
|
+
child->bfsColor = animatedGraphBFSColor_;
|
|
660
660
|
#ifdef REACT_NATIVE_DEBUG
|
|
661
|
-
|
|
661
|
+
activeNodesCount++;
|
|
662
662
|
#endif
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
663
|
+
const auto connectedToFinishedAnimation =
|
|
664
|
+
is_node_connected_to_finished_animation(
|
|
665
|
+
child, childTag, nextNode.connectedToFinishedAnimation);
|
|
666
|
+
nodesQueue.emplace_back(
|
|
667
|
+
NodesQueueItem{
|
|
668
|
+
.node = child,
|
|
669
|
+
.connectedToFinishedAnimation =
|
|
670
|
+
connectedToFinishedAnimation});
|
|
671
|
+
}
|
|
670
672
|
}
|
|
671
673
|
}
|
|
672
674
|
}
|
|
@@ -721,27 +723,29 @@ void NativeAnimatedNodesManager::updateNodes(
|
|
|
721
723
|
}
|
|
722
724
|
|
|
723
725
|
for (auto childTag : nextNode.node->getChildren()) {
|
|
724
|
-
auto child = getAnimatedNode<AnimatedNode>(childTag)
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
726
|
+
if (auto child = getAnimatedNode<AnimatedNode>(childTag)) {
|
|
727
|
+
child->activeIncomingNodes--;
|
|
728
|
+
if (child->activeIncomingNodes == 0 &&
|
|
729
|
+
child->bfsColor != animatedGraphBFSColor_) {
|
|
730
|
+
child->bfsColor = animatedGraphBFSColor_;
|
|
729
731
|
#ifdef REACT_NATIVE_DEBUG
|
|
730
|
-
|
|
732
|
+
updatedNodesCount++;
|
|
731
733
|
#endif
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
734
|
+
const auto connectedToFinishedAnimation =
|
|
735
|
+
is_node_connected_to_finished_animation(
|
|
736
|
+
child, childTag, nextNode.connectedToFinishedAnimation);
|
|
737
|
+
nodesQueue.emplace_back(
|
|
738
|
+
NodesQueueItem{
|
|
739
|
+
.node = child,
|
|
740
|
+
.connectedToFinishedAnimation =
|
|
741
|
+
connectedToFinishedAnimation});
|
|
742
|
+
}
|
|
740
743
|
#ifdef REACT_NATIVE_DEBUG
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
+
else if (child->bfsColor == animatedGraphBFSColor_) {
|
|
745
|
+
cyclesDetected++;
|
|
746
|
+
}
|
|
744
747
|
#endif
|
|
748
|
+
}
|
|
745
749
|
}
|
|
746
750
|
}
|
|
747
751
|
|
package/index.js
CHANGED
|
@@ -341,6 +341,9 @@ module.exports = {
|
|
|
341
341
|
get useColorScheme() {
|
|
342
342
|
return require('./Libraries/Utilities/useColorScheme').default;
|
|
343
343
|
},
|
|
344
|
+
get usePressability() {
|
|
345
|
+
return require('./Libraries/Pressability/usePressability').default;
|
|
346
|
+
},
|
|
344
347
|
get useWindowDimensions() {
|
|
345
348
|
return require('./Libraries/Utilities/useWindowDimensions').default;
|
|
346
349
|
},
|
package/index.js.flow
CHANGED
|
@@ -408,6 +408,11 @@ export * as TurboModuleRegistry from './Libraries/TurboModule/TurboModuleRegistr
|
|
|
408
408
|
export {default as UIManager} from './Libraries/ReactNative/UIManager';
|
|
409
409
|
export {unstable_batchedUpdates} from './Libraries/ReactNative/RendererProxy';
|
|
410
410
|
export {default as useAnimatedValue} from './Libraries/Animated/useAnimatedValue';
|
|
411
|
+
export type {
|
|
412
|
+
PressabilityConfig,
|
|
413
|
+
EventHandlers as PressabilityEventHandlers,
|
|
414
|
+
} from './Libraries/Pressability/Pressability';
|
|
415
|
+
export {default as usePressability} from './Libraries/Pressability/usePressability';
|
|
411
416
|
export {default as useColorScheme} from './Libraries/Utilities/useColorScheme';
|
|
412
417
|
export {default as useWindowDimensions} from './Libraries/Utilities/useWindowDimensions';
|
|
413
418
|
export {default as UTFSequence} from './Libraries/UTFSequence';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.84.0-nightly-
|
|
3
|
+
"version": "0.84.0-nightly-20251210-3e9083b42",
|
|
4
4
|
"description": "A framework for building native apps using React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -160,13 +160,13 @@
|
|
|
160
160
|
},
|
|
161
161
|
"dependencies": {
|
|
162
162
|
"@jest/create-cache-key-function": "^29.7.0",
|
|
163
|
-
"@react-native/assets-registry": "0.84.0-nightly-
|
|
164
|
-
"@react-native/codegen": "0.84.0-nightly-
|
|
165
|
-
"@react-native/community-cli-plugin": "0.84.0-nightly-
|
|
166
|
-
"@react-native/gradle-plugin": "0.84.0-nightly-
|
|
167
|
-
"@react-native/js-polyfills": "0.84.0-nightly-
|
|
168
|
-
"@react-native/normalize-colors": "0.84.0-nightly-
|
|
169
|
-
"@react-native/virtualized-lists": "0.84.0-nightly-
|
|
163
|
+
"@react-native/assets-registry": "0.84.0-nightly-20251210-3e9083b42",
|
|
164
|
+
"@react-native/codegen": "0.84.0-nightly-20251210-3e9083b42",
|
|
165
|
+
"@react-native/community-cli-plugin": "0.84.0-nightly-20251210-3e9083b42",
|
|
166
|
+
"@react-native/gradle-plugin": "0.84.0-nightly-20251210-3e9083b42",
|
|
167
|
+
"@react-native/js-polyfills": "0.84.0-nightly-20251210-3e9083b42",
|
|
168
|
+
"@react-native/normalize-colors": "0.84.0-nightly-20251210-3e9083b42",
|
|
169
|
+
"@react-native/virtualized-lists": "0.84.0-nightly-20251210-3e9083b42",
|
|
170
170
|
"abort-controller": "^3.0.0",
|
|
171
171
|
"anser": "^1.4.9",
|
|
172
172
|
"ansi-regex": "^5.0.0",
|
package/src/types/globals.d.ts
CHANGED
|
@@ -461,8 +461,18 @@ declare global {
|
|
|
461
461
|
| 'text';
|
|
462
462
|
|
|
463
463
|
interface URL {
|
|
464
|
-
|
|
464
|
+
readonly hash: string;
|
|
465
|
+
readonly host: string;
|
|
466
|
+
readonly hostname: string;
|
|
467
|
+
readonly href: string;
|
|
468
|
+
readonly origin: string;
|
|
469
|
+
readonly password: string;
|
|
470
|
+
readonly pathname: string;
|
|
471
|
+
readonly port: string;
|
|
472
|
+
readonly protocol: string;
|
|
473
|
+
search: string;
|
|
465
474
|
readonly searchParams: URLSearchParams;
|
|
475
|
+
readonly username: string;
|
|
466
476
|
|
|
467
477
|
toJSON(): string;
|
|
468
478
|
toString(): string;
|
|
@@ -479,8 +489,27 @@ declare global {
|
|
|
479
489
|
* Based on definitions of lib.dom and lib.dom.iterable
|
|
480
490
|
*/
|
|
481
491
|
interface URLSearchParams {
|
|
492
|
+
/**
|
|
493
|
+
* Returns the number of search parameter entries.
|
|
494
|
+
*/
|
|
495
|
+
readonly size: number;
|
|
496
|
+
|
|
482
497
|
append(key: string, value: string): void;
|
|
498
|
+
delete(name: string): void;
|
|
499
|
+
get(name: string): string | null;
|
|
500
|
+
getAll(name: string): string[];
|
|
501
|
+
has(name: string): boolean;
|
|
502
|
+
set(name: string, value: string): void;
|
|
503
|
+
sort(): void;
|
|
483
504
|
toString(): string;
|
|
505
|
+
forEach(
|
|
506
|
+
callbackfn: (value: string, key: string, parent: URLSearchParams) => void,
|
|
507
|
+
thisArg?: any,
|
|
508
|
+
): void;
|
|
509
|
+
|
|
510
|
+
keys(): IterableIterator<string>;
|
|
511
|
+
values(): IterableIterator<string>;
|
|
512
|
+
entries(): IterableIterator<[string, string]>;
|
|
484
513
|
|
|
485
514
|
[Symbol.iterator](): IterableIterator<[string, string]>;
|
|
486
515
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
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
|
+
* @generated SignedSource<<679a6d7be762fc192387af04838933c3>>
|
|
8
|
+
*
|
|
9
|
+
* This file was translated from Flow by scripts/js-api/build-types/index.js.
|
|
10
|
+
* Original file: packages/react-native/Libraries/Pressability/usePressability.js
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
import { type EventHandlers, type PressabilityConfig } from "./Pressability";
|
|
14
|
+
/**
|
|
15
|
+
* Creates a persistent instance of `Pressability` that automatically configures
|
|
16
|
+
* itself and resets. Accepts null `config` to support lazy initialization. Once
|
|
17
|
+
* initialized, will not un-initialize until the component has been unmounted.
|
|
18
|
+
*
|
|
19
|
+
* In order to use `usePressability`, do the following:
|
|
20
|
+
*
|
|
21
|
+
* const config = useMemo(...);
|
|
22
|
+
* const eventHandlers = usePressability(config);
|
|
23
|
+
* const pressableView = <View {...eventHandlers} />;
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
declare function usePressability(config: null | undefined | PressabilityConfig): null | EventHandlers;
|
|
27
|
+
export default usePressability;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<de754bf2c017a2c8acd393684d6146fc>>
|
|
8
8
|
*
|
|
9
9
|
* This file was translated from Flow by scripts/js-api/build-types/index.js.
|
|
10
10
|
* Original file: packages/react-native/index.js.flow
|
|
@@ -147,6 +147,8 @@ export * as TurboModuleRegistry from "./Libraries/TurboModule/TurboModuleRegistr
|
|
|
147
147
|
export { default as UIManager } from "./Libraries/ReactNative/UIManager";
|
|
148
148
|
export { unstable_batchedUpdates } from "./Libraries/ReactNative/RendererProxy";
|
|
149
149
|
export { default as useAnimatedValue } from "./Libraries/Animated/useAnimatedValue";
|
|
150
|
+
export type { PressabilityConfig, EventHandlers as PressabilityEventHandlers } from "./Libraries/Pressability/Pressability";
|
|
151
|
+
export { default as usePressability } from "./Libraries/Pressability/usePressability";
|
|
150
152
|
export { default as useColorScheme } from "./Libraries/Utilities/useColorScheme";
|
|
151
153
|
export { default as useWindowDimensions } from "./Libraries/Utilities/useWindowDimensions";
|
|
152
154
|
export { default as UTFSequence } from "./Libraries/UTFSequence";
|