react-native 0.83.0-nightly-20250923-2065c3180 → 0.83.0-nightly-20250924-53f89bacd
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/Components/TextInput/TextInput.js +6 -0
- package/Libraries/Components/View/ViewNativeComponent.js +2 -2
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/React/Base/RCTVersion.m +1 -1
- package/React/CoreModules/RCTAppearance.h +1 -1
- package/React/CoreModules/RCTDevLoadingView.mm +3 -10
- package/React/Views/RCTBorderDrawing.h +1 -1
- package/ReactAndroid/api/ReactAndroid.api +2 -1
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/DefaultDevLoadingViewImplementation.kt +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerBase.kt +7 -14
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/perfmonitor/PerfMonitorDevHelper.kt +4 -0
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/perfmonitor/PerfMonitorOverlayManager.kt +20 -31
- package/ReactAndroid/src/main/java/com/facebook/react/devsupport/perfmonitor/PerfMonitorOverlayView.kt +3 -3
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/views/scroll/ReactHorizontalScrollView.java +26 -1
- package/ReactAndroid/src/main/jni/react/jni/JReactMarker.h +6 -8
- package/ReactCommon/cxxreact/JSExecutor.h +1 -1
- package/ReactCommon/cxxreact/JSIndexedRAMBundle.h +4 -4
- package/ReactCommon/cxxreact/ReactMarker.h +6 -8
- package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
- package/ReactCommon/jsiexecutor/jsireact/JSIExecutor.h +1 -1
- package/package.json +8 -8
- 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/src/private/webapis/dom/nodes/ReactNativeElement.js +12 -2
- package/types_generated/Libraries/Components/View/ViewNativeComponent.d.ts +3 -3
|
@@ -449,6 +449,12 @@ function InternalTextInput(props: TextInputProps): React.Node {
|
|
|
449
449
|
before we can get to the long term breaking change.
|
|
450
450
|
*/
|
|
451
451
|
if (instance != null) {
|
|
452
|
+
// Register the input immediately when the ref is set so that focus()
|
|
453
|
+
// can be called from ref callbacks
|
|
454
|
+
// Double registering during useLayoutEffect is fine, because the underlying
|
|
455
|
+
// state is a Set.
|
|
456
|
+
TextInputState.registerInput(instance);
|
|
457
|
+
|
|
452
458
|
// $FlowFixMe[prop-missing] - See the explanation above.
|
|
453
459
|
// $FlowFixMe[unsafe-object-assign]
|
|
454
460
|
Object.assign(instance, {
|
|
@@ -21,8 +21,8 @@ const ViewNativeComponent: HostComponent<Props> =
|
|
|
21
21
|
}));
|
|
22
22
|
|
|
23
23
|
interface NativeCommands {
|
|
24
|
-
+focus: () => void;
|
|
25
|
-
+blur: () => void;
|
|
24
|
+
+focus: (viewRef: HostInstance) => void;
|
|
25
|
+
+blur: (viewRef: HostInstance) => void;
|
|
26
26
|
+hotspotUpdate: (viewRef: HostInstance, x: number, y: number) => void;
|
|
27
27
|
+setPressed: (viewRef: HostInstance, pressed: boolean) => void;
|
|
28
28
|
}
|
|
@@ -29,7 +29,7 @@ export default class ReactNativeVersion {
|
|
|
29
29
|
static major: number = 0;
|
|
30
30
|
static minor: number = 83;
|
|
31
31
|
static patch: number = 0;
|
|
32
|
-
static prerelease: string | null = 'nightly-
|
|
32
|
+
static prerelease: string | null = 'nightly-20250924-53f89bacd';
|
|
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: @(83),
|
|
26
26
|
RCTVersionPatch: @(0),
|
|
27
|
-
RCTVersionPrerelease: @"nightly-
|
|
27
|
+
RCTVersionPrerelease: @"nightly-20250924-53f89bacd",
|
|
28
28
|
};
|
|
29
29
|
});
|
|
30
30
|
return __rnVersion;
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
#import <React/RCTEventEmitter.h>
|
|
13
13
|
|
|
14
14
|
RCT_EXTERN void RCTEnableAppearancePreference(BOOL enabled);
|
|
15
|
-
RCT_EXTERN void RCTOverrideAppearancePreference(NSString *
|
|
15
|
+
RCT_EXTERN void RCTOverrideAppearancePreference(NSString *);
|
|
16
16
|
RCT_EXTERN void RCTUseKeyWindowForSystemStyle(BOOL useMainScreen);
|
|
17
17
|
RCT_EXTERN NSString *RCTCurrentOverrideAppearancePreference(void);
|
|
18
18
|
RCT_EXTERN NSString *RCTColorSchemePreference(UITraitCollection *traitCollection);
|
|
@@ -85,14 +85,6 @@ RCT_EXPORT_MODULE()
|
|
|
85
85
|
dispatch_time(DISPATCH_TIME_NOW, 0.2 * NSEC_PER_SEC), dispatch_get_main_queue(), self->_initialMessageBlock);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
- (void)hideBannerAfter:(CGFloat)delay
|
|
89
|
-
{
|
|
90
|
-
// Cancel previous hide call after the delay.
|
|
91
|
-
[NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(hide) object:nil];
|
|
92
|
-
// Set new hide call after a delay.
|
|
93
|
-
[self performSelector:@selector(hide) withObject:nil afterDelay:delay];
|
|
94
|
-
}
|
|
95
|
-
|
|
96
88
|
- (void)showMessage:(NSString *)message color:(UIColor *)color backgroundColor:(UIColor *)backgroundColor
|
|
97
89
|
{
|
|
98
90
|
if (!RCTDevLoadingViewGetEnabled() || _hiding) {
|
|
@@ -128,6 +120,9 @@ RCT_EXPORT_MODULE()
|
|
|
128
120
|
self->_container = [[UIView alloc] init];
|
|
129
121
|
self->_container.backgroundColor = backgroundColor;
|
|
130
122
|
self->_container.translatesAutoresizingMaskIntoConstraints = NO;
|
|
123
|
+
UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(hide)];
|
|
124
|
+
[self->_container addGestureRecognizer:tapGesture];
|
|
125
|
+
self->_container.userInteractionEnabled = YES;
|
|
131
126
|
|
|
132
127
|
self->_label = [[UILabel alloc] init];
|
|
133
128
|
self->_label.translatesAutoresizingMaskIntoConstraints = NO;
|
|
@@ -158,8 +153,6 @@ RCT_EXPORT_MODULE()
|
|
|
158
153
|
[self->_label.centerXAnchor constraintEqualToAnchor:self->_container.centerXAnchor],
|
|
159
154
|
[self->_label.bottomAnchor constraintEqualToAnchor:self->_container.bottomAnchor constant:-5],
|
|
160
155
|
]];
|
|
161
|
-
|
|
162
|
-
[self hideBannerAfter:15.0];
|
|
163
156
|
});
|
|
164
157
|
}
|
|
165
158
|
|
|
@@ -61,7 +61,7 @@ RCT_EXTERN CGPathRef RCTPathCreateWithRoundedRect(
|
|
|
61
61
|
CGRect bounds,
|
|
62
62
|
RCTCornerInsets cornerInsets,
|
|
63
63
|
const CGAffineTransform *transform,
|
|
64
|
-
|
|
64
|
+
BOOL inverted);
|
|
65
65
|
|
|
66
66
|
/**
|
|
67
67
|
* Draw a CSS-compliant border as an image. You can determine if it's scalable
|
|
@@ -5566,7 +5566,7 @@ public final class com/facebook/react/views/scroll/ReactHorizontalScrollContaine
|
|
|
5566
5566
|
public final class com/facebook/react/views/scroll/ReactHorizontalScrollContainerViewManager$Companion {
|
|
5567
5567
|
}
|
|
5568
5568
|
|
|
5569
|
-
public class com/facebook/react/views/scroll/ReactHorizontalScrollView : android/widget/HorizontalScrollView, android/view/View$OnLayoutChangeListener, android/view/ViewGroup$OnHierarchyChangeListener, com/facebook/react/uimanager/ReactClippingViewGroup, com/facebook/react/uimanager/ReactOverflowViewWithInset, com/facebook/react/views/scroll/ReactAccessibleScrollView, com/facebook/react/views/scroll/ReactScrollViewHelper$HasFlingAnimator, com/facebook/react/views/scroll/ReactScrollViewHelper$HasScrollEventThrottle, com/facebook/react/views/scroll/ReactScrollViewHelper$HasScrollState, com/facebook/react/views/scroll/ReactScrollViewHelper$HasSmoothScroll, com/facebook/react/views/scroll/ReactScrollViewHelper$HasStateWrapper {
|
|
5569
|
+
public class com/facebook/react/views/scroll/ReactHorizontalScrollView : android/widget/HorizontalScrollView, android/view/View$OnLayoutChangeListener, android/view/ViewGroup$OnHierarchyChangeListener, com/facebook/react/uimanager/ReactClippingViewGroup, com/facebook/react/uimanager/ReactOverflowViewWithInset, com/facebook/react/views/scroll/ReactAccessibleScrollView, com/facebook/react/views/scroll/ReactScrollViewHelper$HasFlingAnimator, com/facebook/react/views/scroll/ReactScrollViewHelper$HasScrollEventThrottle, com/facebook/react/views/scroll/ReactScrollViewHelper$HasScrollState, com/facebook/react/views/scroll/ReactScrollViewHelper$HasSmoothScroll, com/facebook/react/views/scroll/ReactScrollViewHelper$HasStateWrapper, com/facebook/react/views/scroll/VirtualViewContainer {
|
|
5570
5570
|
public fun <init> (Landroid/content/Context;)V
|
|
5571
5571
|
public fun <init> (Landroid/content/Context;Lcom/facebook/react/views/scroll/FpsListener;)V
|
|
5572
5572
|
public fun abortAnimation ()V
|
|
@@ -5596,6 +5596,7 @@ public class com/facebook/react/views/scroll/ReactHorizontalScrollView : android
|
|
|
5596
5596
|
public fun getScrollEnabled ()Z
|
|
5597
5597
|
public fun getScrollEventThrottle ()I
|
|
5598
5598
|
public fun getStateWrapper ()Lcom/facebook/react/uimanager/StateWrapper;
|
|
5599
|
+
public fun getVirtualViewContainerState ()Lcom/facebook/react/views/scroll/VirtualViewContainerState;
|
|
5599
5600
|
protected fun handleInterceptedTouchEvent (Landroid/view/MotionEvent;)V
|
|
5600
5601
|
public fun isPartiallyScrolledInView (Landroid/view/View;)Z
|
|
5601
5602
|
protected fun onAttachedToWindow ()V
|
|
@@ -94,13 +94,13 @@ public class DefaultDevLoadingViewImplementation(
|
|
|
94
94
|
if (backgroundColor != null) {
|
|
95
95
|
view.setBackgroundColor(backgroundColor.toInt())
|
|
96
96
|
}
|
|
97
|
+
view.setOnClickListener { hideInternal() }
|
|
97
98
|
val popup =
|
|
98
99
|
PopupWindow(
|
|
99
100
|
view,
|
|
100
101
|
ViewGroup.LayoutParams.MATCH_PARENT,
|
|
101
102
|
ViewGroup.LayoutParams.WRAP_CONTENT,
|
|
102
103
|
)
|
|
103
|
-
popup.isTouchable = false
|
|
104
104
|
popup.showAtLocation(currentActivity.window.decorView, Gravity.NO_GRAVITY, 0, topOffset)
|
|
105
105
|
devLoadingView = view
|
|
106
106
|
devLoadingPopup = popup
|
|
@@ -78,7 +78,6 @@ import java.io.File
|
|
|
78
78
|
import java.net.MalformedURLException
|
|
79
79
|
import java.net.URL
|
|
80
80
|
import java.util.Locale
|
|
81
|
-
import javax.inject.Provider
|
|
82
81
|
|
|
83
82
|
public abstract class DevSupportManagerBase(
|
|
84
83
|
protected val applicationContext: Context,
|
|
@@ -185,6 +184,7 @@ public abstract class DevSupportManagerBase(
|
|
|
185
184
|
}
|
|
186
185
|
|
|
187
186
|
private var perfMonitorOverlayManager: PerfMonitorOverlayManager? = null
|
|
187
|
+
private var perfMonitorInitialized = false
|
|
188
188
|
private var tracingStateProvider: TracingStateProvider? = null
|
|
189
189
|
|
|
190
190
|
init {
|
|
@@ -222,13 +222,6 @@ public abstract class DevSupportManagerBase(
|
|
|
222
222
|
perfMonitorOverlayManager =
|
|
223
223
|
PerfMonitorOverlayManager(
|
|
224
224
|
reactInstanceDevHelper,
|
|
225
|
-
Provider {
|
|
226
|
-
val context = reactInstanceDevHelper.currentActivity
|
|
227
|
-
if (context == null || context.isFinishing) {
|
|
228
|
-
return@Provider null
|
|
229
|
-
}
|
|
230
|
-
context
|
|
231
|
-
},
|
|
232
225
|
{ openDebugger(DebuggerFrontendPanelName.PERFORMANCE.toString()) },
|
|
233
226
|
)
|
|
234
227
|
}
|
|
@@ -552,14 +545,16 @@ public abstract class DevSupportManagerBase(
|
|
|
552
545
|
}
|
|
553
546
|
|
|
554
547
|
override fun onNewReactContextCreated(reactContext: ReactContext) {
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
if (reactInstanceDevHelper is PerfMonitorDevHelper) {
|
|
548
|
+
if (!perfMonitorInitialized && reactInstanceDevHelper is PerfMonitorDevHelper) {
|
|
558
549
|
perfMonitorOverlayManager?.let { manager ->
|
|
559
550
|
reactInstanceDevHelper.inspectorTarget?.addPerfMonitorListener(manager)
|
|
560
551
|
}
|
|
561
552
|
perfMonitorOverlayManager?.enable()
|
|
553
|
+
perfMonitorOverlayManager?.startBackgroundTrace()
|
|
554
|
+
perfMonitorInitialized = true
|
|
562
555
|
}
|
|
556
|
+
|
|
557
|
+
resetCurrentContext(reactContext)
|
|
563
558
|
}
|
|
564
559
|
|
|
565
560
|
override fun onReactInstanceDestroyed(reactContext: ReactContext) {
|
|
@@ -877,8 +872,6 @@ public abstract class DevSupportManagerBase(
|
|
|
877
872
|
devLoadingViewManager?.showMessage("Reloading...")
|
|
878
873
|
}
|
|
879
874
|
|
|
880
|
-
perfMonitorOverlayManager?.reset()
|
|
881
|
-
|
|
882
875
|
devServerHelper.openPackagerConnection(
|
|
883
876
|
javaClass.simpleName,
|
|
884
877
|
object : PackagerCommandListener {
|
|
@@ -928,7 +921,7 @@ public abstract class DevSupportManagerBase(
|
|
|
928
921
|
hideRedboxDialog()
|
|
929
922
|
hideDevOptionsDialog()
|
|
930
923
|
devLoadingViewManager?.hide()
|
|
931
|
-
perfMonitorOverlayManager?.
|
|
924
|
+
perfMonitorOverlayManager?.disable()
|
|
932
925
|
|
|
933
926
|
devServerHelper.closePackagerConnection()
|
|
934
927
|
}
|
package/ReactAndroid/src/main/java/com/facebook/react/devsupport/perfmonitor/PerfMonitorDevHelper.kt
CHANGED
|
@@ -7,11 +7,15 @@
|
|
|
7
7
|
|
|
8
8
|
package com.facebook.react.devsupport.perfmonitor
|
|
9
9
|
|
|
10
|
+
import android.app.Activity
|
|
11
|
+
|
|
10
12
|
/**
|
|
11
13
|
* Interface implemented by [com.facebook.react.runtime.ReactHostImplDevHelper] exposing additional
|
|
12
14
|
* hooks used to implement the V2 Perf Monitor overlay (experimental).
|
|
13
15
|
*/
|
|
14
16
|
internal interface PerfMonitorDevHelper {
|
|
17
|
+
public val currentActivity: Activity?
|
|
18
|
+
|
|
15
19
|
/**
|
|
16
20
|
* The inspector target object. Matches the lifetime of the ReactHost. May be null if modern JS
|
|
17
21
|
* debugging is disabled.
|
|
@@ -7,44 +7,26 @@
|
|
|
7
7
|
|
|
8
8
|
package com.facebook.react.devsupport.perfmonitor
|
|
9
9
|
|
|
10
|
-
import android.content.Context
|
|
11
10
|
import com.facebook.react.bridge.UiThreadUtil
|
|
12
11
|
import com.facebook.react.devsupport.interfaces.TracingState
|
|
13
|
-
import javax.inject.Provider
|
|
14
12
|
|
|
15
13
|
internal class PerfMonitorOverlayManager(
|
|
16
14
|
private val devHelper: PerfMonitorDevHelper,
|
|
17
|
-
private val contextProvider: Provider<Context?>,
|
|
18
15
|
private val onRequestOpenDevTools: () -> Unit,
|
|
19
16
|
) : PerfMonitorUpdateListener {
|
|
20
17
|
private var enabled: Boolean = false
|
|
21
|
-
private var initialized: Boolean = false
|
|
22
18
|
private var view: PerfMonitorOverlayView? = null
|
|
23
19
|
private var tracingState: TracingState = TracingState.ENABLEDINCDPMODE
|
|
24
20
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
}
|
|
29
|
-
|
|
21
|
+
/** Enable the Perf Monitor overlay. */
|
|
22
|
+
fun enable() {
|
|
23
|
+
enabled = true
|
|
30
24
|
UiThreadUtil.runOnUiThread {
|
|
31
|
-
val context =
|
|
25
|
+
val context = devHelper.currentActivity ?: return@runOnUiThread
|
|
32
26
|
view = PerfMonitorOverlayView(context, ::handleRecordingButtonPress)
|
|
33
|
-
|
|
34
|
-
// Start background tracing
|
|
35
|
-
devHelper.inspectorTarget?.resumeBackgroundTrace()
|
|
36
|
-
|
|
37
|
-
view?.show()
|
|
38
|
-
initialized = true
|
|
39
27
|
}
|
|
40
28
|
}
|
|
41
29
|
|
|
42
|
-
/** Enable the Perf Monitor overlay. Will be shown when updates are received. */
|
|
43
|
-
fun enable() {
|
|
44
|
-
enabled = true
|
|
45
|
-
init()
|
|
46
|
-
}
|
|
47
|
-
|
|
48
30
|
/** Disable the Perf Monitor overlay. Will remain hidden when updates are received. */
|
|
49
31
|
fun disable() {
|
|
50
32
|
UiThreadUtil.runOnUiThread { view?.hide() }
|
|
@@ -52,24 +34,31 @@ internal class PerfMonitorOverlayManager(
|
|
|
52
34
|
enabled = false
|
|
53
35
|
}
|
|
54
36
|
|
|
55
|
-
/**
|
|
56
|
-
fun
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
37
|
+
/** Start background trace recording. */
|
|
38
|
+
fun startBackgroundTrace() {
|
|
39
|
+
if (!enabled) {
|
|
40
|
+
return
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
devHelper.inspectorTarget?.let { target ->
|
|
44
|
+
target.resumeBackgroundTrace()
|
|
45
|
+
onRecordingStateChanged(target.getTracingState())
|
|
46
|
+
}
|
|
61
47
|
}
|
|
62
48
|
|
|
63
49
|
override fun onRecordingStateChanged(state: TracingState) {
|
|
64
50
|
tracingState = state
|
|
65
|
-
|
|
51
|
+
UiThreadUtil.runOnUiThread {
|
|
52
|
+
view?.updateRecordingState(state)
|
|
53
|
+
view?.show()
|
|
54
|
+
}
|
|
66
55
|
}
|
|
67
56
|
|
|
68
57
|
private fun handleRecordingButtonPress() {
|
|
69
58
|
when (tracingState) {
|
|
70
59
|
TracingState.ENABLEDINBACKGROUNDMODE -> {
|
|
71
|
-
devHelper.inspectorTarget?.let {
|
|
72
|
-
if (!
|
|
60
|
+
devHelper.inspectorTarget?.let { target ->
|
|
61
|
+
if (!target.pauseAndAnalyzeBackgroundTrace()) {
|
|
73
62
|
onRequestOpenDevTools()
|
|
74
63
|
}
|
|
75
64
|
}
|
|
@@ -55,11 +55,11 @@ internal class PerfMonitorOverlayView(
|
|
|
55
55
|
|
|
56
56
|
if (state == TracingState.ENABLEDINBACKGROUNDMODE) {
|
|
57
57
|
(statusIndicator.background as GradientDrawable).setColor(Color.RED)
|
|
58
|
-
statusLabel.text = "
|
|
58
|
+
statusLabel.text = "Profiling Active"
|
|
59
59
|
tooltipLabel.text = "Press ☰ to open"
|
|
60
60
|
} else {
|
|
61
61
|
(statusIndicator.background as GradientDrawable).setColor(Color.GRAY)
|
|
62
|
-
statusLabel.text = "
|
|
62
|
+
statusLabel.text = "Profiling Stopped"
|
|
63
63
|
tooltipLabel.text = "Press ☰ to restart"
|
|
64
64
|
}
|
|
65
65
|
dialog.show()
|
|
@@ -164,7 +164,7 @@ internal class PerfMonitorOverlayView(
|
|
|
164
164
|
shape = GradientDrawable.RECTANGLE
|
|
165
165
|
setColor(Color.BLACK)
|
|
166
166
|
cornerRadius = dpToPx(14.5f)
|
|
167
|
-
alpha = (0.
|
|
167
|
+
alpha = (0.4 * 255).toInt()
|
|
168
168
|
setStroke(dpToPx(1f).toInt(), COLOR_OVERLAY_BORDER)
|
|
169
169
|
}
|
|
170
170
|
showDividers = LinearLayout.SHOW_DIVIDER_MIDDLE
|
package/ReactAndroid/src/main/java/com/facebook/react/views/scroll/ReactHorizontalScrollView.java
CHANGED
|
@@ -79,7 +79,8 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
79
79
|
HasStateWrapper,
|
|
80
80
|
HasFlingAnimator,
|
|
81
81
|
HasScrollEventThrottle,
|
|
82
|
-
HasSmoothScroll
|
|
82
|
+
HasSmoothScroll,
|
|
83
|
+
VirtualViewContainer {
|
|
83
84
|
|
|
84
85
|
private static boolean DEBUG_MODE = false && ReactBuildConfig.DEBUG;
|
|
85
86
|
private static String TAG = ReactHorizontalScrollView.class.getSimpleName();
|
|
@@ -100,6 +101,7 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
100
101
|
private final ValueAnimator DEFAULT_FLING_ANIMATOR = ObjectAnimator.ofInt(this, "scrollX", 0, 0);
|
|
101
102
|
|
|
102
103
|
private Rect mOverflowInset = new Rect();
|
|
104
|
+
private @Nullable VirtualViewContainerState mVirtualViewContainerState;
|
|
103
105
|
private boolean mActivelyScrolling;
|
|
104
106
|
private @Nullable Rect mClippingRect;
|
|
105
107
|
private Overflow mOverflow = Overflow.SCROLL;
|
|
@@ -156,6 +158,7 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
156
158
|
*/
|
|
157
159
|
private void initView() {
|
|
158
160
|
mOverflowInset = new Rect();
|
|
161
|
+
mVirtualViewContainerState = null;
|
|
159
162
|
mActivelyScrolling = false;
|
|
160
163
|
mClippingRect = null;
|
|
161
164
|
// The default value for `overflow` is set to `Visible` in the Yoga style props.
|
|
@@ -209,6 +212,15 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
209
212
|
|
|
210
213
|
private void updateView() {}
|
|
211
214
|
|
|
215
|
+
@Override
|
|
216
|
+
public VirtualViewContainerState getVirtualViewContainerState() {
|
|
217
|
+
if (mVirtualViewContainerState == null) {
|
|
218
|
+
mVirtualViewContainerState = new VirtualViewContainerState(this);
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
return mVirtualViewContainerState;
|
|
222
|
+
}
|
|
223
|
+
|
|
212
224
|
@Override
|
|
213
225
|
public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
|
|
214
226
|
super.onInitializeAccessibilityNodeInfo(info);
|
|
@@ -512,6 +524,9 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
512
524
|
}
|
|
513
525
|
|
|
514
526
|
ReactScrollViewHelper.emitLayoutEvent(this);
|
|
527
|
+
if (mVirtualViewContainerState != null) {
|
|
528
|
+
mVirtualViewContainerState.updateState();
|
|
529
|
+
}
|
|
515
530
|
}
|
|
516
531
|
|
|
517
532
|
/**
|
|
@@ -605,7 +620,11 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
605
620
|
this,
|
|
606
621
|
mOnScrollDispatchHelper.getXFlingVelocity(),
|
|
607
622
|
mOnScrollDispatchHelper.getYFlingVelocity());
|
|
623
|
+
if (mVirtualViewContainerState != null) {
|
|
624
|
+
mVirtualViewContainerState.updateState();
|
|
625
|
+
}
|
|
608
626
|
}
|
|
627
|
+
|
|
609
628
|
} finally {
|
|
610
629
|
Systrace.endSection(Systrace.TRACE_TAG_REACT);
|
|
611
630
|
}
|
|
@@ -856,6 +875,9 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
856
875
|
if (mRemoveClippedSubviews) {
|
|
857
876
|
updateClippingRect();
|
|
858
877
|
}
|
|
878
|
+
if (mVirtualViewContainerState != null) {
|
|
879
|
+
mVirtualViewContainerState.updateState();
|
|
880
|
+
}
|
|
859
881
|
}
|
|
860
882
|
|
|
861
883
|
@Override
|
|
@@ -875,6 +897,9 @@ public class ReactHorizontalScrollView extends HorizontalScrollView
|
|
|
875
897
|
if (mMaintainVisibleContentPositionHelper != null) {
|
|
876
898
|
mMaintainVisibleContentPositionHelper.stop();
|
|
877
899
|
}
|
|
900
|
+
if (mVirtualViewContainerState != null) {
|
|
901
|
+
mVirtualViewContainerState.cleanup();
|
|
902
|
+
}
|
|
878
903
|
}
|
|
879
904
|
|
|
880
905
|
@Override
|
|
@@ -24,20 +24,18 @@ class JReactMarker : public facebook::jni::JavaClass<JReactMarker> {
|
|
|
24
24
|
private:
|
|
25
25
|
static void logMarker(const std::string& marker);
|
|
26
26
|
static void logMarker(const std::string& marker, const std::string& tag);
|
|
27
|
-
static void
|
|
28
|
-
|
|
29
|
-
const std::string& tag,
|
|
30
|
-
const int instanceKey);
|
|
27
|
+
static void
|
|
28
|
+
logMarker(const std::string& marker, const std::string& tag, int instanceKey);
|
|
31
29
|
static void logPerfMarker(
|
|
32
|
-
|
|
30
|
+
ReactMarker::ReactMarkerId markerId,
|
|
33
31
|
const char* tag);
|
|
34
32
|
static void logPerfMarkerBridgeless(
|
|
35
|
-
|
|
33
|
+
ReactMarker::ReactMarkerId markerId,
|
|
36
34
|
const char* tag);
|
|
37
35
|
static void logPerfMarkerWithInstanceKey(
|
|
38
|
-
|
|
36
|
+
ReactMarker::ReactMarkerId markerId,
|
|
39
37
|
const char* tag,
|
|
40
|
-
|
|
38
|
+
int instanceKey);
|
|
41
39
|
static void nativeLogMarker(
|
|
42
40
|
jni::alias_ref<jclass> /* unused */,
|
|
43
41
|
const std::string& markerNameStr,
|
|
@@ -61,12 +61,12 @@ class RN_EXPORT [[deprecated(
|
|
|
61
61
|
};
|
|
62
62
|
|
|
63
63
|
void init();
|
|
64
|
-
std::string getModuleCode(
|
|
65
|
-
void readBundle(char* buffer,
|
|
64
|
+
std::string getModuleCode(uint32_t id) const;
|
|
65
|
+
void readBundle(char* buffer, std::streamsize bytes) const;
|
|
66
66
|
void readBundle(
|
|
67
67
|
char* buffer,
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
std::streamsize bytes,
|
|
69
|
+
std::istream::pos_type position) const;
|
|
70
70
|
|
|
71
71
|
mutable std::unique_ptr<std::istream> m_bundle;
|
|
72
72
|
ModuleTable m_table;
|
|
@@ -57,13 +57,13 @@ extern RN_EXPORT std::shared_mutex logTaggedMarkerImplMutex;
|
|
|
57
57
|
extern RN_EXPORT LogTaggedMarker logTaggedMarkerImpl;
|
|
58
58
|
extern RN_EXPORT LogTaggedMarker logTaggedMarkerBridgelessImpl;
|
|
59
59
|
|
|
60
|
-
extern RN_EXPORT void logMarker(
|
|
60
|
+
extern RN_EXPORT void logMarker(ReactMarkerId markerId); // Bridge only
|
|
61
61
|
extern RN_EXPORT void logTaggedMarker(
|
|
62
|
-
|
|
62
|
+
ReactMarkerId markerId,
|
|
63
63
|
const char* tag); // Bridge only
|
|
64
|
-
extern RN_EXPORT void logMarkerBridgeless(
|
|
64
|
+
extern RN_EXPORT void logMarkerBridgeless(ReactMarkerId markerId);
|
|
65
65
|
extern RN_EXPORT void logTaggedMarkerBridgeless(
|
|
66
|
-
|
|
66
|
+
ReactMarkerId markerId,
|
|
67
67
|
const char* tag);
|
|
68
68
|
|
|
69
69
|
struct ReactMarkerEvent {
|
|
@@ -76,7 +76,7 @@ class RN_EXPORT StartupLogger {
|
|
|
76
76
|
public:
|
|
77
77
|
static StartupLogger& getInstance();
|
|
78
78
|
|
|
79
|
-
void logStartupEvent(
|
|
79
|
+
void logStartupEvent(ReactMarkerId markerId, double markerTime);
|
|
80
80
|
void reset();
|
|
81
81
|
double getAppStartupStartTime();
|
|
82
82
|
double getInitReactRuntimeStartTime();
|
|
@@ -101,8 +101,6 @@ class RN_EXPORT StartupLogger {
|
|
|
101
101
|
// When the marker got logged from the platform, it will notify here. This is
|
|
102
102
|
// used to collect react markers that are logged in the platform instead of in
|
|
103
103
|
// C++.
|
|
104
|
-
extern RN_EXPORT void logMarkerDone(
|
|
105
|
-
const ReactMarkerId markerId,
|
|
106
|
-
double markerTime);
|
|
104
|
+
extern RN_EXPORT void logMarkerDone(ReactMarkerId markerId, double markerTime);
|
|
107
105
|
|
|
108
106
|
} // namespace facebook::react::ReactMarker
|
|
@@ -22,7 +22,7 @@ constexpr struct {
|
|
|
22
22
|
int32_t Major = 0;
|
|
23
23
|
int32_t Minor = 83;
|
|
24
24
|
int32_t Patch = 0;
|
|
25
|
-
std::string_view Prerelease = "nightly-
|
|
25
|
+
std::string_view Prerelease = "nightly-20250924-53f89bacd";
|
|
26
26
|
} ReactNativeVersion;
|
|
27
27
|
|
|
28
28
|
} // namespace facebook::react
|
|
@@ -91,7 +91,7 @@ class [[deprecated(
|
|
|
91
91
|
const std::string& moduleId,
|
|
92
92
|
const std::string& methodId,
|
|
93
93
|
const folly::dynamic& arguments) override;
|
|
94
|
-
void invokeCallback(
|
|
94
|
+
void invokeCallback(double callbackId, const folly::dynamic& arguments)
|
|
95
95
|
override;
|
|
96
96
|
void setGlobalVariable(
|
|
97
97
|
std::string propName,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.83.0-nightly-
|
|
3
|
+
"version": "0.83.0-nightly-20250924-53f89bacd",
|
|
4
4
|
"description": "A framework for building native apps using React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -159,13 +159,13 @@
|
|
|
159
159
|
},
|
|
160
160
|
"dependencies": {
|
|
161
161
|
"@jest/create-cache-key-function": "^29.7.0",
|
|
162
|
-
"@react-native/assets-registry": "0.83.0-nightly-
|
|
163
|
-
"@react-native/codegen": "0.83.0-nightly-
|
|
164
|
-
"@react-native/community-cli-plugin": "0.83.0-nightly-
|
|
165
|
-
"@react-native/gradle-plugin": "0.83.0-nightly-
|
|
166
|
-
"@react-native/js-polyfills": "0.83.0-nightly-
|
|
167
|
-
"@react-native/normalize-colors": "0.83.0-nightly-
|
|
168
|
-
"@react-native/virtualized-lists": "0.83.0-nightly-
|
|
162
|
+
"@react-native/assets-registry": "0.83.0-nightly-20250924-53f89bacd",
|
|
163
|
+
"@react-native/codegen": "0.83.0-nightly-20250924-53f89bacd",
|
|
164
|
+
"@react-native/community-cli-plugin": "0.83.0-nightly-20250924-53f89bacd",
|
|
165
|
+
"@react-native/gradle-plugin": "0.83.0-nightly-20250924-53f89bacd",
|
|
166
|
+
"@react-native/js-polyfills": "0.83.0-nightly-20250924-53f89bacd",
|
|
167
|
+
"@react-native/normalize-colors": "0.83.0-nightly-20250924-53f89bacd",
|
|
168
|
+
"@react-native/virtualized-lists": "0.83.0-nightly-20250924-53f89bacd",
|
|
169
169
|
"abort-controller": "^3.0.0",
|
|
170
170
|
"anser": "^1.4.9",
|
|
171
171
|
"ansi-regex": "^5.0.0",
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -25,8 +25,10 @@ import type {InstanceHandle} from './internals/NodeInternals';
|
|
|
25
25
|
import type ReactNativeDocument from './ReactNativeDocument';
|
|
26
26
|
|
|
27
27
|
import TextInputState from '../../../../../Libraries/Components/TextInput/TextInputState';
|
|
28
|
+
import {Commands as ViewCommands} from '../../../../../Libraries/Components/View/ViewNativeComponent';
|
|
28
29
|
import {create as createAttributePayload} from '../../../../../Libraries/ReactNative/ReactFabricPublicInstance/ReactNativeAttributePayload';
|
|
29
30
|
import warnForStyleProps from '../../../../../Libraries/ReactNative/ReactFabricPublicInstance/warnForStyleProps';
|
|
31
|
+
import * as ReactNativeFeatureFlags from '../../../featureflags/ReactNativeFeatureFlags';
|
|
30
32
|
import {
|
|
31
33
|
getNativeElementReference,
|
|
32
34
|
getPublicInstanceFromInstanceHandle,
|
|
@@ -140,11 +142,19 @@ class ReactNativeElement extends ReadOnlyElement implements NativeMethods {
|
|
|
140
142
|
*/
|
|
141
143
|
|
|
142
144
|
blur(): void {
|
|
143
|
-
TextInputState.
|
|
145
|
+
if (TextInputState.isTextInput(this)) {
|
|
146
|
+
TextInputState.blurTextInput(this);
|
|
147
|
+
} else if (ReactNativeFeatureFlags.enableImperativeFocus()) {
|
|
148
|
+
ViewCommands.blur(this);
|
|
149
|
+
}
|
|
144
150
|
}
|
|
145
151
|
|
|
146
152
|
focus() {
|
|
147
|
-
TextInputState.
|
|
153
|
+
if (TextInputState.isTextInput(this)) {
|
|
154
|
+
TextInputState.focusTextInput(this);
|
|
155
|
+
} else if (ReactNativeFeatureFlags.enableImperativeFocus()) {
|
|
156
|
+
ViewCommands.focus(this);
|
|
157
|
+
}
|
|
148
158
|
}
|
|
149
159
|
|
|
150
160
|
measure(callback: MeasureOnSuccessCallback) {
|
|
@@ -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<<0e0b8133451b0955959343701829daf2>>
|
|
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/Libraries/Components/View/ViewNativeComponent.js
|
|
@@ -15,8 +15,8 @@ import type { HostInstance } from "../../../src/private/types/HostInstance";
|
|
|
15
15
|
import { type ViewProps as Props } from "./ViewPropTypes";
|
|
16
16
|
declare const ViewNativeComponent: HostComponent<Props>;
|
|
17
17
|
interface NativeCommands {
|
|
18
|
-
readonly focus: () => void;
|
|
19
|
-
readonly blur: () => void;
|
|
18
|
+
readonly focus: (viewRef: HostInstance) => void;
|
|
19
|
+
readonly blur: (viewRef: HostInstance) => void;
|
|
20
20
|
readonly hotspotUpdate: (viewRef: HostInstance, x: number, y: number) => void;
|
|
21
21
|
readonly setPressed: (viewRef: HostInstance, pressed: boolean) => void;
|
|
22
22
|
}
|