Implement Partial Hydration for Activity (#32863)

Stacked on #32862 and #32842.

This means that Activity boundaries now act as boundaries which can have
their effects mounted independently. Just like Suspense boundaries, we
hydrate the outer content first and then start hydrating the content in
an Offscreen lane. Flowing props or interacting with the content
increases the priority just like Suspense boundaries.

This skips emitting even the comments for `<Activity mode="hidden">` so
we don't hydrate those. Instead those are deferred to a later client
render.

The implementation are just forked copies of the SuspenseComponent
branches and then carefully going through each line and tweaking it.

The main interesting bit is that, unlike Suspense, Activity boundaries
don't have fallbacks so all those branches where you might commit a
suspended tree disappears. Instead, if something suspends while
hydration, we can just leave the dehydrated content in place. However,
if something does suspend during client rendering then it should bubble
up to the parent. Therefore, we have to be careful to only
pushSuspenseHandler when hydrating. That's really the main difference.

This just uses the existing basic Activity tests but I've started work
on port all of the applicable Suspense tests in SelectiveHydration-test
and PartialHydration-test to Activity versions.

DiffTrain build for [3ef31d196a](https://github.com/facebook/react/commit/3ef31d196a83e45d4c70b300a265a9c657c386b4)
This commit is contained in:
sebmarkbage
2025-04-22 18:07:47 -07:00
parent 1ed5cd364a
commit 520902d9c2
23 changed files with 7961 additions and 4781 deletions
+1 -1
View File
@@ -1 +1 @@
19.2.0-native-fb-17f88c80-20250422
19.2.0-native-fb-3ef31d19-20250422
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<0b6590522eb4cf48244a47f0ae7bfc8f>>
* @generated SignedSource<<d4a49cc2733833ed94561a8032a6faad>>
*/
"use strict";
@@ -404,5 +404,5 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
})();
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<2fafd8b44adafd221fec21bb898ac76c>>
* @generated SignedSource<<d2bab8536f4680d22758a6c9e6bf0ef5>>
*/
"use strict";
@@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<2fafd8b44adafd221fec21bb898ac76c>>
* @generated SignedSource<<d2bab8536f4680d22758a6c9e6bf0ef5>>
*/
"use strict";
@@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -7,13 +7,13 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<c262b49ca303d859bd3e412983cc967b>>
* @generated SignedSource<<adf9f9293cfb107d0c8978df972ca943>>
*/
"use strict";
__DEV__ &&
(function () {
function JSCompiler_object_inline_createNodeMock_1139() {
function JSCompiler_object_inline_createNodeMock_1148() {
return null;
}
function findHook(fiber, id) {
@@ -715,6 +715,50 @@ __DEV__ &&
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function lanesToEventPriority(lanes) {
lanes &= -lanes;
return 0 !== DiscreteEventPriority && DiscreteEventPriority < lanes
@@ -4008,6 +4052,11 @@ __DEV__ &&
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current, fiber);
push(suspenseHandlerStackCursor, fiber, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current, fiber),
@@ -6169,6 +6218,7 @@ __DEV__ &&
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -6545,6 +6595,42 @@ __DEV__ &&
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
var hiddenProp = nextProps.hidden;
void 0 !== hiddenProp &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === hiddenProp
? "hidden"
: !1 === hiddenProp
? "hidden={false}"
: "hidden={...}",
hiddenProp ? 'mode="hidden"' : 'mode="visible"'
);
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(
workInProgress,
workInProgress.pendingProps
);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -7032,10 +7118,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7052,10 +7138,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7090,22 +7176,22 @@ __DEV__ &&
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -7123,31 +7209,32 @@ __DEV__ &&
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if (
(pushPrimaryTreeSuspenseHandler(workInProgress),
isSuspenseInstanceFallback())
)
(showFallback = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = showFallback.digest),
(nextPrimaryChildren = showFallback.message),
(nextProps = showFallback.stack),
(showFallback = showFallback.componentStack),
(nextPrimaryChildren = nextPrimaryChildren
? Error(nextPrimaryChildren)
(nextPrimaryChildren = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = nextPrimaryChildren.digest),
(showFallback = nextPrimaryChildren.message),
(nextProps = nextPrimaryChildren.stack),
(nextPrimaryChildren = nextPrimaryChildren.componentStack),
(showFallback = showFallback
? Error(showFallback)
: Error(
"The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering."
)),
(nextPrimaryChildren.stack = nextProps || ""),
(nextPrimaryChildren.digest = JSCompiler_temp),
(JSCompiler_temp = void 0 === showFallback ? null : showFallback),
(showFallback.stack = nextProps || ""),
(showFallback.digest = JSCompiler_temp),
(JSCompiler_temp =
void 0 === nextPrimaryChildren ? null : nextPrimaryChildren),
(nextProps = {
value: nextPrimaryChildren,
value: showFallback,
source: null,
stack: JSCompiler_temp
}),
"string" === typeof JSCompiler_temp &&
CapturedStacks.set(nextPrimaryChildren, nextProps),
CapturedStacks.set(showFallback, nextProps),
null === hydrationErrors
? (hydrationErrors = [nextProps])
: hydrationErrors.push(nextProps),
@@ -7168,58 +7255,20 @@ __DEV__ &&
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(
JSCompiler_temp,
renderLanes
)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
isSuspenseInstancePending() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -7240,12 +7289,12 @@ __DEV__ &&
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -7258,27 +7307,27 @@ __DEV__ &&
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -7289,12 +7338,12 @@ __DEV__ &&
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7698,6 +7747,14 @@ __DEV__ &&
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -7907,10 +7964,10 @@ __DEV__ &&
current.$$typeof === REACT_LAZY_TYPE &&
(workInProgress =
" Did you wrap a component in React.lazy() more than once?");
current = getComponentNameFromType(current) || current;
renderLanes = getComponentNameFromType(current) || current;
throw Error(
"Element type is invalid. Received a promise that resolves to: " +
current +
renderLanes +
". Lazy element type must resolve to a class or function." +
workInProgress
);
@@ -8183,40 +8240,83 @@ __DEV__ &&
renderLanes
);
case 31:
return (
(renderLanes = workInProgress.pendingProps),
(returnFiber = renderLanes.hidden),
void 0 !== returnFiber &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === returnFiber
? "hidden"
: !1 === returnFiber
? "hidden={false}"
: "hidden={...}",
returnFiber ? 'mode="hidden"' : 'mode="visible"'
),
(returnFiber = workInProgress.mode),
(renderLanes = {
mode: renderLanes.mode,
children: renderLanes.children
}),
null === current
? ((current = mountWorkInProgressOffscreenFiber(
prevSibling = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, prevSibling);
else if (
((returnFiber = current.memoizedState), null !== returnFiber)
)
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
returnFiber
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
prevSibling = workInProgressRoot;
if (
null !== prevSibling &&
((nextProps = getBumpedLaneForHydration(
prevSibling,
renderLanes
)),
0 !== nextProps && nextProps !== returnFiber.retryLane)
)
throw (
((returnFiber.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(prevSibling, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
} else
(workInProgress = mountActivityChildren(
workInProgress,
prevSibling
)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current))
: ((current = createWorkInProgress(current.child, renderLanes)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current)),
workInProgress
);
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: prevSibling.mode,
children: prevSibling.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -8504,7 +8604,48 @@ __DEV__ &&
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(renderLanes = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== renderLanes &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -=
current.treeBaseDuration));
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -8512,7 +8653,8 @@ __DEV__ &&
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
child = newProps;
if (null !== child && null !== child.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -8523,11 +8665,11 @@ __DEV__ &&
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(child = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== child &&
((child = workInProgress.child),
null !== child &&
(workInProgress.treeBaseDuration -= child.treeBaseDuration));
@@ -8779,6 +8921,22 @@ __DEV__ &&
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress),
null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -8844,6 +9002,10 @@ __DEV__ &&
case 4:
popHostContainer(interruptedWork);
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -9608,6 +9770,9 @@ __DEV__ &&
}
} else recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -9841,6 +10006,7 @@ __DEV__ &&
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -10047,6 +10213,15 @@ __DEV__ &&
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -10355,6 +10530,13 @@ __DEV__ &&
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -10517,6 +10699,14 @@ __DEV__ &&
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -12445,6 +12635,7 @@ __DEV__ &&
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -15439,10 +15630,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
internals.overrideHookState = overrideHookState;
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -15464,7 +15655,7 @@ __DEV__ &&
exports._Scheduler = Scheduler;
exports.act = act;
exports.create = function (element, options) {
var createNodeMock = JSCompiler_object_inline_createNodeMock_1139,
var createNodeMock = JSCompiler_object_inline_createNodeMock_1148,
isConcurrent = !1,
isStrictMode = !1;
"object" === typeof options &&
@@ -15587,5 +15778,5 @@ __DEV__ &&
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
})();
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<18a669f5e961eede4c0dce450c0bdd8c>>
* @generated SignedSource<<a7c8bb91b1a1b6a7b50a4d0da92f0e5f>>
*/
"use strict";
@@ -547,6 +547,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function lanesToEventPriority(lanes) {
lanes &= -lanes;
return 2 < lanes
@@ -2631,6 +2675,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -4267,6 +4316,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -4617,6 +4667,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -4986,10 +5058,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5006,10 +5077,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5038,22 +5108,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -5071,7 +5141,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -5095,58 +5165,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -5167,12 +5196,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -5180,27 +5209,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -5211,12 +5240,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5492,10 +5521,18 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
workInProgress.memoizedProps.value
);
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
var state = workInProgress.memoizedState;
if (null !== state) {
if (null !== state.dehydrated)
var state$73 = workInProgress.memoizedState;
if (null !== state$73) {
if (null !== state$73.dehydrated)
return (
pushPrimaryTreeSuspenseHandler(workInProgress),
(workInProgress.flags |= 128),
@@ -5515,17 +5552,17 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
break;
case 19:
var didSuspendBefore = 0 !== (current.flags & 128);
state = 0 !== (renderLanes & workInProgress.childLanes);
state ||
state$73 = 0 !== (renderLanes & workInProgress.childLanes);
state$73 ||
(propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
),
(state = 0 !== (renderLanes & workInProgress.childLanes)));
(state$73 = 0 !== (renderLanes & workInProgress.childLanes)));
if (didSuspendBefore) {
if (state)
if (state$73)
return updateSuspenseListComponent(
current,
workInProgress,
@@ -5539,7 +5576,7 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
(didSuspendBefore.tail = null),
(didSuspendBefore.lastEffect = null));
push(suspenseStackCursor, suspenseStackCursor.current);
if (state) break;
if (state$73) break;
else return null;
case 22:
return (
@@ -5862,29 +5899,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -5973,14 +6056,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$89 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$89 = lastTailNode),
for (var lastTailNode$90 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$90 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$89
null === lastTailNode$90
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$89.sibling = null);
: (lastTailNode$90.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -5990,19 +6073,19 @@ function bubbleProperties(completedWork) {
newChildLanes = 0,
subtreeFlags = 0;
if (didBailout)
for (var child$90 = completedWork.child; null !== child$90; )
(newChildLanes |= child$90.lanes | child$90.childLanes),
(subtreeFlags |= child$90.subtreeFlags & 65011712),
(subtreeFlags |= child$90.flags & 65011712),
(child$90.return = completedWork),
(child$90 = child$90.sibling);
for (var child$91 = completedWork.child; null !== child$91; )
(newChildLanes |= child$91.lanes | child$91.childLanes),
(subtreeFlags |= child$91.subtreeFlags & 65011712),
(subtreeFlags |= child$91.flags & 65011712),
(child$91.return = completedWork),
(child$91 = child$91.sibling);
else
for (child$90 = completedWork.child; null !== child$90; )
(newChildLanes |= child$90.lanes | child$90.childLanes),
(subtreeFlags |= child$90.subtreeFlags),
(subtreeFlags |= child$90.flags),
(child$90.return = completedWork),
(child$90 = child$90.sibling);
for (child$91 = completedWork.child; null !== child$91; )
(newChildLanes |= child$91.lanes | child$91.childLanes),
(subtreeFlags |= child$91.subtreeFlags),
(subtreeFlags |= child$91.flags),
(child$91.return = completedWork),
(child$91 = child$91.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -6120,7 +6203,41 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -6167,11 +6284,11 @@ function completeWork(current, workInProgress, renderLanes) {
null !== newProps.alternate.memoizedState &&
null !== newProps.alternate.memoizedState.cachePool &&
(index = newProps.alternate.memoizedState.cachePool.pool);
var cache$95 = null;
var cache$98 = null;
null !== newProps.memoizedState &&
null !== newProps.memoizedState.cachePool &&
(cache$95 = newProps.memoizedState.cachePool.pool);
cache$95 !== index && (newProps.flags |= 2048);
(cache$98 = newProps.memoizedState.cachePool.pool);
cache$98 !== index && (newProps.flags |= 2048);
}
renderLanes !== current &&
renderLanes &&
@@ -6196,8 +6313,8 @@ function completeWork(current, workInProgress, renderLanes) {
index = workInProgress.memoizedState;
if (null === index) return bubbleProperties(workInProgress), null;
newProps = 0 !== (workInProgress.flags & 128);
cache$95 = index.rendering;
if (null === cache$95)
cache$98 = index.rendering;
if (null === cache$98)
if (newProps) cutOffTailIfNeeded(index, !1);
else {
if (
@@ -6205,11 +6322,11 @@ function completeWork(current, workInProgress, renderLanes) {
(null !== current && 0 !== (current.flags & 128))
)
for (current = workInProgress.child; null !== current; ) {
cache$95 = findFirstSuspended(current);
if (null !== cache$95) {
cache$98 = findFirstSuspended(current);
if (null !== cache$98) {
workInProgress.flags |= 128;
cutOffTailIfNeeded(index, !1);
current = cache$95.updateQueue;
current = cache$98.updateQueue;
workInProgress.updateQueue = current;
scheduleRetryEffect(workInProgress, current);
workInProgress.subtreeFlags = 0;
@@ -6234,7 +6351,7 @@ function completeWork(current, workInProgress, renderLanes) {
}
else {
if (!newProps)
if (((current = findFirstSuspended(cache$95)), null !== current)) {
if (((current = findFirstSuspended(cache$98)), null !== current)) {
if (
((workInProgress.flags |= 128),
(newProps = !0),
@@ -6244,7 +6361,7 @@ function completeWork(current, workInProgress, renderLanes) {
cutOffTailIfNeeded(index, !0),
null === index.tail &&
"hidden" === index.tailMode &&
!cache$95.alternate)
!cache$98.alternate)
)
return bubbleProperties(workInProgress), null;
} else
@@ -6256,13 +6373,13 @@ function completeWork(current, workInProgress, renderLanes) {
cutOffTailIfNeeded(index, !1),
(workInProgress.lanes = 4194304));
index.isBackwards
? ((cache$95.sibling = workInProgress.child),
(workInProgress.child = cache$95))
? ((cache$98.sibling = workInProgress.child),
(workInProgress.child = cache$98))
: ((current = index.last),
null !== current
? (current.sibling = cache$95)
: (workInProgress.child = cache$95),
(index.last = cache$95));
? (current.sibling = cache$98)
: (workInProgress.child = cache$98),
(index.last = cache$98));
}
if (null !== index.tail)
return (
@@ -6357,6 +6474,18 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128), workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -6417,6 +6546,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -6446,9 +6579,9 @@ function commitHookEffectListMount(flags, finishedWork) {
do {
if ((updateQueue.tag & flags) === flags) {
lastEffect = void 0;
var create$111 = updateQueue.create,
var create$115 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$111();
lastEffect = create$115();
inst.destroy = lastEffect;
}
updateQueue = updateQueue.next;
@@ -6564,8 +6697,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
else if ("function" === typeof ref)
try {
ref(null);
} catch (error$113) {
captureCommitPhaseError(current, nearestMountedAncestor, error$113);
} catch (error$117) {
captureCommitPhaseError(current, nearestMountedAncestor, error$117);
}
else ref.current = null;
}
@@ -6725,11 +6858,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$112) {
} catch (error$116) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$112
error$116
);
}
}
@@ -6768,6 +6901,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
case 12:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -6968,6 +7104,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -7122,6 +7259,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -7279,12 +7425,12 @@ function commitReconciliationEffects(finishedWork) {
break;
case 3:
case 4:
var parent$114 = hostParentFiber.stateNode.containerInfo,
before$115 = getHostSibling(finishedWork);
var parent$118 = hostParentFiber.stateNode.containerInfo,
before$119 = getHostSibling(finishedWork);
insertOrAppendPlacementNodeIntoContainer(
finishedWork,
before$115,
parent$114
before$119,
parent$118
);
break;
default:
@@ -7421,6 +7567,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -7561,6 +7714,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -8445,8 +8606,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
exitStatus = workInProgressRootExitStatus;
break;
} catch (thrownValue$129) {
handleThrow(root, thrownValue$129);
} catch (thrownValue$134) {
handleThrow(root, thrownValue$134);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -8561,8 +8722,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$131) {
handleThrow(root, thrownValue$131);
} catch (thrownValue$136) {
handleThrow(root, thrownValue$136);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -9071,6 +9232,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -9721,24 +9883,24 @@ function wrapFiber(fiber) {
fiberToWrapper.set(fiber, wrapper));
return wrapper;
}
var internals$jscomp$inline_1422 = {
var internals$jscomp$inline_1439 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1423 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1440 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1423.isDisabled &&
hook$jscomp$inline_1423.supportsFiber
!hook$jscomp$inline_1440.isDisabled &&
hook$jscomp$inline_1440.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1423.inject(
internals$jscomp$inline_1422
(rendererID = hook$jscomp$inline_1440.inject(
internals$jscomp$inline_1439
)),
(injectedHook = hook$jscomp$inline_1423);
(injectedHook = hook$jscomp$inline_1440);
} catch (err) {}
}
exports._Scheduler = Scheduler;
@@ -9862,4 +10024,4 @@ exports.unstable_batchedUpdates = function (fn, a) {
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<8b8618533c9d803de0ea5139ba1e5479>>
* @generated SignedSource<<95833321888af4636e84de6c88293cb7>>
*/
"use strict";
@@ -595,6 +595,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function lanesToEventPriority(lanes) {
lanes &= -lanes;
return 2 < lanes
@@ -2747,6 +2791,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -4391,6 +4440,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -4743,6 +4793,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -5123,10 +5195,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5143,10 +5214,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5175,22 +5245,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -5208,7 +5278,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -5232,58 +5302,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -5304,12 +5333,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -5322,27 +5351,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -5353,12 +5382,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -5648,6 +5677,14 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -6025,29 +6062,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -6136,14 +6219,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$90 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$90 = lastTailNode),
for (var lastTailNode$91 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$91 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$90
null === lastTailNode$91
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$90.sibling = null);
: (lastTailNode$91.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -6155,53 +6238,53 @@ function bubbleProperties(completedWork) {
if (didBailout)
if (0 !== (completedWork.mode & 2)) {
for (
var treeBaseDuration$92 = completedWork.selfBaseDuration,
child$93 = completedWork.child;
null !== child$93;
var treeBaseDuration$93 = completedWork.selfBaseDuration,
child$94 = completedWork.child;
null !== child$94;
)
(newChildLanes |= child$93.lanes | child$93.childLanes),
(subtreeFlags |= child$93.subtreeFlags & 65011712),
(subtreeFlags |= child$93.flags & 65011712),
(treeBaseDuration$92 += child$93.treeBaseDuration),
(child$93 = child$93.sibling);
completedWork.treeBaseDuration = treeBaseDuration$92;
(newChildLanes |= child$94.lanes | child$94.childLanes),
(subtreeFlags |= child$94.subtreeFlags & 65011712),
(subtreeFlags |= child$94.flags & 65011712),
(treeBaseDuration$93 += child$94.treeBaseDuration),
(child$94 = child$94.sibling);
completedWork.treeBaseDuration = treeBaseDuration$93;
} else
for (
treeBaseDuration$92 = completedWork.child;
null !== treeBaseDuration$92;
treeBaseDuration$93 = completedWork.child;
null !== treeBaseDuration$93;
)
(newChildLanes |=
treeBaseDuration$92.lanes | treeBaseDuration$92.childLanes),
(subtreeFlags |= treeBaseDuration$92.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$92.flags & 65011712),
(treeBaseDuration$92.return = completedWork),
(treeBaseDuration$92 = treeBaseDuration$92.sibling);
treeBaseDuration$93.lanes | treeBaseDuration$93.childLanes),
(subtreeFlags |= treeBaseDuration$93.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$93.flags & 65011712),
(treeBaseDuration$93.return = completedWork),
(treeBaseDuration$93 = treeBaseDuration$93.sibling);
else if (0 !== (completedWork.mode & 2)) {
treeBaseDuration$92 = completedWork.actualDuration;
child$93 = completedWork.selfBaseDuration;
treeBaseDuration$93 = completedWork.actualDuration;
child$94 = completedWork.selfBaseDuration;
for (var child = completedWork.child; null !== child; )
(newChildLanes |= child.lanes | child.childLanes),
(subtreeFlags |= child.subtreeFlags),
(subtreeFlags |= child.flags),
(treeBaseDuration$92 += child.actualDuration),
(child$93 += child.treeBaseDuration),
(treeBaseDuration$93 += child.actualDuration),
(child$94 += child.treeBaseDuration),
(child = child.sibling);
completedWork.actualDuration = treeBaseDuration$92;
completedWork.treeBaseDuration = child$93;
completedWork.actualDuration = treeBaseDuration$93;
completedWork.treeBaseDuration = child$94;
} else
for (
treeBaseDuration$92 = completedWork.child;
null !== treeBaseDuration$92;
treeBaseDuration$93 = completedWork.child;
null !== treeBaseDuration$93;
)
(newChildLanes |=
treeBaseDuration$92.lanes | treeBaseDuration$92.childLanes),
(subtreeFlags |= treeBaseDuration$92.subtreeFlags),
(subtreeFlags |= treeBaseDuration$92.flags),
(treeBaseDuration$92.return = completedWork),
(treeBaseDuration$92 = treeBaseDuration$92.sibling);
treeBaseDuration$93.lanes | treeBaseDuration$93.childLanes),
(subtreeFlags |= treeBaseDuration$93.subtreeFlags),
(subtreeFlags |= treeBaseDuration$93.flags),
(treeBaseDuration$93.return = completedWork),
(treeBaseDuration$93 = treeBaseDuration$93.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -6319,7 +6402,46 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(renderLanes = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== renderLanes &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -= current.treeBaseDuration));
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -6327,7 +6449,8 @@ function completeWork(current, workInProgress, renderLanes) {
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
index = newProps;
if (null !== index && null !== index.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -6337,11 +6460,11 @@ function completeWork(current, workInProgress, renderLanes) {
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(index = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== index &&
((index = workInProgress.child),
null !== index &&
(workInProgress.treeBaseDuration -= index.treeBaseDuration));
@@ -6376,11 +6499,11 @@ function completeWork(current, workInProgress, renderLanes) {
null !== newProps.alternate.memoizedState &&
null !== newProps.alternate.memoizedState.cachePool &&
(index = newProps.alternate.memoizedState.cachePool.pool);
var cache$101 = null;
var cache$106 = null;
null !== newProps.memoizedState &&
null !== newProps.memoizedState.cachePool &&
(cache$101 = newProps.memoizedState.cachePool.pool);
cache$101 !== index && (newProps.flags |= 2048);
(cache$106 = newProps.memoizedState.cachePool.pool);
cache$106 !== index && (newProps.flags |= 2048);
}
renderLanes !== current &&
renderLanes &&
@@ -6410,8 +6533,8 @@ function completeWork(current, workInProgress, renderLanes) {
index = workInProgress.memoizedState;
if (null === index) return bubbleProperties(workInProgress), null;
newProps = 0 !== (workInProgress.flags & 128);
cache$101 = index.rendering;
if (null === cache$101)
cache$106 = index.rendering;
if (null === cache$106)
if (newProps) cutOffTailIfNeeded(index, !1);
else {
if (
@@ -6419,11 +6542,11 @@ function completeWork(current, workInProgress, renderLanes) {
(null !== current && 0 !== (current.flags & 128))
)
for (current = workInProgress.child; null !== current; ) {
cache$101 = findFirstSuspended(current);
if (null !== cache$101) {
cache$106 = findFirstSuspended(current);
if (null !== cache$106) {
workInProgress.flags |= 128;
cutOffTailIfNeeded(index, !1);
current = cache$101.updateQueue;
current = cache$106.updateQueue;
workInProgress.updateQueue = current;
scheduleRetryEffect(workInProgress, current);
workInProgress.subtreeFlags = 0;
@@ -6448,7 +6571,7 @@ function completeWork(current, workInProgress, renderLanes) {
}
else {
if (!newProps)
if (((current = findFirstSuspended(cache$101)), null !== current)) {
if (((current = findFirstSuspended(cache$106)), null !== current)) {
if (
((workInProgress.flags |= 128),
(newProps = !0),
@@ -6458,7 +6581,7 @@ function completeWork(current, workInProgress, renderLanes) {
cutOffTailIfNeeded(index, !0),
null === index.tail &&
"hidden" === index.tailMode &&
!cache$101.alternate)
!cache$106.alternate)
)
return bubbleProperties(workInProgress), null;
} else
@@ -6470,13 +6593,13 @@ function completeWork(current, workInProgress, renderLanes) {
cutOffTailIfNeeded(index, !1),
(workInProgress.lanes = 4194304));
index.isBackwards
? ((cache$101.sibling = workInProgress.child),
(workInProgress.child = cache$101))
? ((cache$106.sibling = workInProgress.child),
(workInProgress.child = cache$106))
: ((current = index.last),
null !== current
? (current.sibling = cache$101)
: (workInProgress.child = cache$101),
(index.last = cache$101));
? (current.sibling = cache$106)
: (workInProgress.child = cache$106),
(index.last = cache$106));
}
if (null !== index.tail)
return (
@@ -6574,6 +6697,21 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -6640,6 +6778,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -6712,9 +6854,9 @@ function commitHookEffectListMount(flags, finishedWork) {
finishedWork
);
lastEffect = void 0;
var create$117 = updateQueue.create,
var create$123 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$117();
lastEffect = create$123();
inst.destroy = lastEffect;
0 !== (flags & 8)
? null !== injectedProfilingHooks &&
@@ -6854,8 +6996,8 @@ function safelyCallComponentWillUnmount(
} else
try {
instance.componentWillUnmount();
} catch (error$121) {
captureCommitPhaseError(current, nearestMountedAncestor, error$121);
} catch (error$127) {
captureCommitPhaseError(current, nearestMountedAncestor, error$127);
}
}
function safelyAttachRef(current, nearestMountedAncestor) {
@@ -6917,8 +7059,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
recordEffectDuration(current);
}
else ref(null);
} catch (error$122) {
captureCommitPhaseError(current, nearestMountedAncestor, error$122);
} catch (error$128) {
captureCommitPhaseError(current, nearestMountedAncestor, error$128);
}
else ref.current = null;
}
@@ -7101,11 +7243,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
} else
try {
finishedRoot.componentDidMount();
} catch (error$118) {
} catch (error$124) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$118
error$124
);
}
else {
@@ -7122,11 +7264,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$119) {
} catch (error$125) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$119
error$125
);
}
recordEffectDuration();
@@ -7137,11 +7279,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$120) {
} catch (error$126) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$120
error$126
);
}
}
@@ -7190,6 +7332,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
))
: recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -7393,6 +7538,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -7555,6 +7701,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -7714,12 +7869,12 @@ function commitReconciliationEffects(finishedWork) {
break;
case 3:
case 4:
var parent$123 = hostParentFiber.stateNode.containerInfo,
before$124 = getHostSibling(finishedWork);
var parent$129 = hostParentFiber.stateNode.containerInfo,
before$130 = getHostSibling(finishedWork);
insertOrAppendPlacementNodeIntoContainer(
finishedWork,
before$124,
parent$123
before$130,
parent$129
);
break;
default:
@@ -7875,6 +8030,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -8026,6 +8188,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -8960,8 +9130,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
exitStatus = workInProgressRootExitStatus;
break;
} catch (thrownValue$142) {
handleThrow(root, thrownValue$142);
} catch (thrownValue$149) {
handleThrow(root, thrownValue$149);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -9078,8 +9248,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$144) {
handleThrow(root, thrownValue$144);
} catch (thrownValue$151) {
handleThrow(root, thrownValue$151);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -9662,6 +9832,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -10329,17 +10500,17 @@ function wrapFiber(fiber) {
fiberToWrapper.set(fiber, wrapper));
return wrapper;
}
var internals$jscomp$inline_1229 = {
var internals$jscomp$inline_1247 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422",
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422",
getLaneLabelMap: function () {
for (
var map = new Map(), lane = 1, index$148 = 0;
31 > index$148;
index$148++
var map = new Map(), lane = 1, index$155 = 0;
31 > index$155;
index$155++
) {
var label = getLabelForLane(lane);
map.set(lane, label);
@@ -10352,16 +10523,16 @@ var internals$jscomp$inline_1229 = {
}
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1482 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1505 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1482.isDisabled &&
hook$jscomp$inline_1482.supportsFiber
!hook$jscomp$inline_1505.isDisabled &&
hook$jscomp$inline_1505.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1482.inject(
internals$jscomp$inline_1229
(rendererID = hook$jscomp$inline_1505.inject(
internals$jscomp$inline_1247
)),
(injectedHook = hook$jscomp$inline_1482);
(injectedHook = hook$jscomp$inline_1505);
} catch (err) {}
}
exports._Scheduler = Scheduler;
@@ -10485,4 +10656,4 @@ exports.unstable_batchedUpdates = function (fn, a) {
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<94dcbb359a45c5c73c7e3be45faa50ef>>
* @generated SignedSource<<6f4909cfbb5b2f0a7671d23954235942>>
*/
"use strict";
@@ -1412,7 +1412,7 @@ __DEV__ &&
exports.useTransition = function () {
return resolveDispatcher().useTransition();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<bbe3a5a50049874caa1e102cce5bdfaf>>
* @generated SignedSource<<9544a908fcba7316c3c3e12020e06f64>>
*/
"use strict";
@@ -587,4 +587,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<ef4fa51e658ff943a5bf6e3a6a5e2df1>>
* @generated SignedSource<<0dccd0c23701e93e1314106030bab224>>
*/
"use strict";
@@ -591,7 +591,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.2.0-native-fb-17f88c80-20250422";
exports.version = "19.2.0-native-fb-3ef31d19-20250422";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -1 +1 @@
17f88c80ed20b4e5f21255d9e1268542a2fbc1bd
3ef31d196a83e45d4c70b300a265a9c657c386b4
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<bb4541cf4a4c035629b9c69793203130>>
* @generated SignedSource<<5754cca2d1255ac615656e4737b87dea>>
*/
"use strict";
@@ -1881,6 +1881,50 @@ __DEV__ &&
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function addFiberToLanesMap(root, fiber, lanes) {
if (isDevToolsPresent)
for (root = root.pendingUpdatersLaneMap; 0 < lanes; ) {
@@ -4903,6 +4947,11 @@ __DEV__ &&
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current, fiber);
push(suspenseHandlerStackCursor, fiber, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current, fiber),
@@ -7017,6 +7066,7 @@ __DEV__ &&
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -7393,6 +7443,42 @@ __DEV__ &&
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
var hiddenProp = nextProps.hidden;
void 0 !== hiddenProp &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === hiddenProp
? "hidden"
: !1 === hiddenProp
? "hidden={false}"
: "hidden={...}",
hiddenProp ? 'mode="hidden"' : 'mode="visible"'
);
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(
workInProgress,
workInProgress.pendingProps
);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -7880,10 +7966,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7900,10 +7986,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7938,22 +8024,22 @@ __DEV__ &&
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -7971,31 +8057,32 @@ __DEV__ &&
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if (
(pushPrimaryTreeSuspenseHandler(workInProgress),
isSuspenseInstanceFallback())
)
(showFallback = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = showFallback.digest),
(nextPrimaryChildren = showFallback.message),
(nextProps = showFallback.stack),
(showFallback = showFallback.componentStack),
(nextPrimaryChildren = nextPrimaryChildren
? Error(nextPrimaryChildren)
(nextPrimaryChildren = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = nextPrimaryChildren.digest),
(showFallback = nextPrimaryChildren.message),
(nextProps = nextPrimaryChildren.stack),
(nextPrimaryChildren = nextPrimaryChildren.componentStack),
(showFallback = showFallback
? Error(showFallback)
: Error(
"The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering."
)),
(nextPrimaryChildren.stack = nextProps || ""),
(nextPrimaryChildren.digest = JSCompiler_temp),
(JSCompiler_temp = void 0 === showFallback ? null : showFallback),
(showFallback.stack = nextProps || ""),
(showFallback.digest = JSCompiler_temp),
(JSCompiler_temp =
void 0 === nextPrimaryChildren ? null : nextPrimaryChildren),
(nextProps = {
value: nextPrimaryChildren,
value: showFallback,
source: null,
stack: JSCompiler_temp
}),
"string" === typeof JSCompiler_temp &&
CapturedStacks.set(nextPrimaryChildren, nextProps),
CapturedStacks.set(showFallback, nextProps),
null === hydrationErrors
? (hydrationErrors = [nextProps])
: hydrationErrors.push(nextProps),
@@ -8016,58 +8103,20 @@ __DEV__ &&
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(
JSCompiler_temp,
renderLanes
)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
isSuspenseInstancePending() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -8088,12 +8137,12 @@ __DEV__ &&
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -8106,27 +8155,27 @@ __DEV__ &&
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -8137,12 +8186,12 @@ __DEV__ &&
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -8546,6 +8595,14 @@ __DEV__ &&
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -8755,10 +8812,10 @@ __DEV__ &&
current.$$typeof === REACT_LAZY_TYPE &&
(workInProgress =
" Did you wrap a component in React.lazy() more than once?");
current = getComponentNameFromType(current) || current;
renderLanes = getComponentNameFromType(current) || current;
throw Error(
"Element type is invalid. Received a promise that resolves to: " +
current +
renderLanes +
". Lazy element type must resolve to a class or function." +
workInProgress
);
@@ -9031,40 +9088,83 @@ __DEV__ &&
renderLanes
);
case 31:
return (
(renderLanes = workInProgress.pendingProps),
(returnFiber = renderLanes.hidden),
void 0 !== returnFiber &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === returnFiber
? "hidden"
: !1 === returnFiber
? "hidden={false}"
: "hidden={...}",
returnFiber ? 'mode="hidden"' : 'mode="visible"'
),
(returnFiber = workInProgress.mode),
(renderLanes = {
mode: renderLanes.mode,
children: renderLanes.children
}),
null === current
? ((current = mountWorkInProgressOffscreenFiber(
prevSibling = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, prevSibling);
else if (
((returnFiber = current.memoizedState), null !== returnFiber)
)
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
returnFiber
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
prevSibling = workInProgressRoot;
if (
null !== prevSibling &&
((nextProps = getBumpedLaneForHydration(
prevSibling,
renderLanes
)),
0 !== nextProps && nextProps !== returnFiber.retryLane)
)
throw (
((returnFiber.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(prevSibling, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
} else
(workInProgress = mountActivityChildren(
workInProgress,
prevSibling
)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current))
: ((current = createWorkInProgress(current.child, renderLanes)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current)),
workInProgress
);
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: prevSibling.mode,
children: prevSibling.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -9493,7 +9593,7 @@ __DEV__ &&
workInProgress
);
enableLazyPublicInstanceInFabric
? (newProps = {
? (current = {
node: keepChildren,
canonical: {
nativeTag: current,
@@ -9511,7 +9611,7 @@ __DEV__ &&
workInProgress,
renderLanes.publicInstance
)),
(newProps = {
(current = {
node: keepChildren,
canonical: {
nativeTag: current,
@@ -9522,8 +9622,8 @@ __DEV__ &&
}
}));
markCloned(workInProgress);
appendAllChildren(newProps, workInProgress, !1, !1);
workInProgress.stateNode = newProps;
appendAllChildren(current, workInProgress, !1, !1);
workInProgress.stateNode = current;
}
bubbleProperties(workInProgress);
workInProgress.flags &= -16777217;
@@ -9563,7 +9663,48 @@ __DEV__ &&
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
newProps = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== newProps) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(newProps = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -=
current.treeBaseDuration));
current = !1;
} else
(newProps = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = newProps),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -9571,7 +9712,8 @@ __DEV__ &&
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
_type2 = newProps;
if (null !== _type2 && null !== _type2.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -9582,11 +9724,11 @@ __DEV__ &&
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(_type2 = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== _type2 &&
((_type2 = workInProgress.child),
null !== _type2 &&
(workInProgress.treeBaseDuration -= _type2.treeBaseDuration));
@@ -9636,9 +9778,9 @@ __DEV__ &&
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
newProps &&
((newProps = workInProgress.child),
null !== newProps &&
(workInProgress.treeBaseDuration -= newProps.treeBaseDuration));
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -= current.treeBaseDuration));
return null;
case 4:
return (
@@ -9678,14 +9820,14 @@ __DEV__ &&
if (null !== keepChildren) {
workInProgress.flags |= 128;
cutOffTailIfNeeded(_type2, !1);
newProps = keepChildren.updateQueue;
workInProgress.updateQueue = newProps;
scheduleRetryEffect(workInProgress, newProps);
current = keepChildren.updateQueue;
workInProgress.updateQueue = current;
scheduleRetryEffect(workInProgress, current);
workInProgress.subtreeFlags = 0;
newProps = renderLanes;
for (current = workInProgress.child; null !== current; )
resetWorkInProgress(current, newProps),
(current = current.sibling);
current = renderLanes;
for (newProps = workInProgress.child; null !== newProps; )
resetWorkInProgress(newProps, current),
(newProps = newProps.sibling);
push(
suspenseStackCursor,
(suspenseStackCursor.current &
@@ -9840,6 +9982,22 @@ __DEV__ &&
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress),
null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -9905,6 +10063,10 @@ __DEV__ &&
case 4:
popHostContainer(interruptedWork);
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -10585,6 +10747,9 @@ __DEV__ &&
}
} else recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -10791,6 +10956,7 @@ __DEV__ &&
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -10945,6 +11111,15 @@ __DEV__ &&
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((root = finishedWork.updateQueue),
null !== root &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, root)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -11185,6 +11360,13 @@ __DEV__ &&
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -11347,6 +11529,14 @@ __DEV__ &&
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -13309,6 +13499,7 @@ __DEV__ &&
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -17156,10 +17347,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<03241a570bc9dd4dca371a4ae7758542>>
* @generated SignedSource<<9fc1ce3cfcc10981145f460fa861c321>>
*/
"use strict";
@@ -1245,7 +1245,7 @@ eventPluginOrder = Array.prototype.slice.call([
"ReactNativeBridgeEventPlugin"
]);
recomputePluginOrdering();
var injectedNamesToPlugins$jscomp$inline_280 = {
var injectedNamesToPlugins$jscomp$inline_286 = {
ResponderEventPlugin: ResponderEventPlugin,
ReactNativeBridgeEventPlugin: {
eventTypes: {},
@@ -1291,32 +1291,32 @@ var injectedNamesToPlugins$jscomp$inline_280 = {
}
}
},
isOrderingDirty$jscomp$inline_281 = !1,
pluginName$jscomp$inline_282;
for (pluginName$jscomp$inline_282 in injectedNamesToPlugins$jscomp$inline_280)
isOrderingDirty$jscomp$inline_287 = !1,
pluginName$jscomp$inline_288;
for (pluginName$jscomp$inline_288 in injectedNamesToPlugins$jscomp$inline_286)
if (
injectedNamesToPlugins$jscomp$inline_280.hasOwnProperty(
pluginName$jscomp$inline_282
injectedNamesToPlugins$jscomp$inline_286.hasOwnProperty(
pluginName$jscomp$inline_288
)
) {
var pluginModule$jscomp$inline_283 =
injectedNamesToPlugins$jscomp$inline_280[pluginName$jscomp$inline_282];
var pluginModule$jscomp$inline_289 =
injectedNamesToPlugins$jscomp$inline_286[pluginName$jscomp$inline_288];
if (
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_282) ||
namesToPlugins[pluginName$jscomp$inline_282] !==
pluginModule$jscomp$inline_283
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_288) ||
namesToPlugins[pluginName$jscomp$inline_288] !==
pluginModule$jscomp$inline_289
) {
if (namesToPlugins[pluginName$jscomp$inline_282])
if (namesToPlugins[pluginName$jscomp$inline_288])
throw Error(
"EventPluginRegistry: Cannot inject two different event plugins using the same name, `" +
(pluginName$jscomp$inline_282 + "`.")
(pluginName$jscomp$inline_288 + "`.")
);
namesToPlugins[pluginName$jscomp$inline_282] =
pluginModule$jscomp$inline_283;
isOrderingDirty$jscomp$inline_281 = !0;
namesToPlugins[pluginName$jscomp$inline_288] =
pluginModule$jscomp$inline_289;
isOrderingDirty$jscomp$inline_287 = !0;
}
}
isOrderingDirty$jscomp$inline_281 && recomputePluginOrdering();
isOrderingDirty$jscomp$inline_287 && recomputePluginOrdering();
var emptyObject = {},
removedKeys = null,
removedKeyCount = 0,
@@ -1906,6 +1906,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function lanesToEventPriority(lanes) {
lanes &= -lanes;
return 2 < lanes
@@ -3872,6 +3916,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -5502,6 +5551,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -5852,6 +5902,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -6221,10 +6293,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6241,10 +6312,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6273,22 +6343,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -6306,7 +6376,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -6330,58 +6400,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -6402,12 +6431,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -6415,27 +6444,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -6446,12 +6475,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6727,10 +6756,18 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
workInProgress.memoizedProps.value
);
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
var state = workInProgress.memoizedState;
if (null !== state) {
if (null !== state.dehydrated)
var state$78 = workInProgress.memoizedState;
if (null !== state$78) {
if (null !== state$78.dehydrated)
return (
pushPrimaryTreeSuspenseHandler(workInProgress),
(workInProgress.flags |= 128),
@@ -6750,17 +6787,17 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
break;
case 19:
var didSuspendBefore = 0 !== (current.flags & 128);
state = 0 !== (renderLanes & workInProgress.childLanes);
state ||
state$78 = 0 !== (renderLanes & workInProgress.childLanes);
state$78 ||
(propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
),
(state = 0 !== (renderLanes & workInProgress.childLanes)));
(state$78 = 0 !== (renderLanes & workInProgress.childLanes)));
if (didSuspendBefore) {
if (state)
if (state$78)
return updateSuspenseListComponent(
current,
workInProgress,
@@ -6774,7 +6811,7 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
(didSuspendBefore.tail = null),
(didSuspendBefore.lastEffect = null));
push(suspenseStackCursor, suspenseStackCursor.current);
if (state) break;
if (state$78) break;
else return null;
case 22:
return (
@@ -7097,29 +7134,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -7328,14 +7411,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$96 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$96 = lastTailNode),
for (var lastTailNode$97 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$97 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$96
null === lastTailNode$97
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$96.sibling = null);
: (lastTailNode$97.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -7345,19 +7428,19 @@ function bubbleProperties(completedWork) {
newChildLanes = 0,
subtreeFlags = 0;
if (didBailout)
for (var child$97 = completedWork.child; null !== child$97; )
(newChildLanes |= child$97.lanes | child$97.childLanes),
(subtreeFlags |= child$97.subtreeFlags & 65011712),
(subtreeFlags |= child$97.flags & 65011712),
(child$97.return = completedWork),
(child$97 = child$97.sibling);
for (var child$98 = completedWork.child; null !== child$98; )
(newChildLanes |= child$98.lanes | child$98.childLanes),
(subtreeFlags |= child$98.subtreeFlags & 65011712),
(subtreeFlags |= child$98.flags & 65011712),
(child$98.return = completedWork),
(child$98 = child$98.sibling);
else
for (child$97 = completedWork.child; null !== child$97; )
(newChildLanes |= child$97.lanes | child$97.childLanes),
(subtreeFlags |= child$97.subtreeFlags),
(subtreeFlags |= child$97.flags),
(child$97.return = completedWork),
(child$97 = child$97.sibling);
for (child$98 = completedWork.child; null !== child$98; )
(newChildLanes |= child$98.lanes | child$98.childLanes),
(subtreeFlags |= child$98.subtreeFlags),
(subtreeFlags |= child$98.flags),
(child$98.return = completedWork),
(child$98 = child$98.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -7494,7 +7577,7 @@ function completeWork(current, workInProgress, renderLanes) {
workInProgress
);
enableLazyPublicInstanceInFabric
? (newProps = {
? (current = {
node: oldProps,
canonical: {
nativeTag: current,
@@ -7511,7 +7594,7 @@ function completeWork(current, workInProgress, renderLanes) {
workInProgress,
renderLanes.publicInstance
)),
(newProps = {
(current = {
node: oldProps,
canonical: {
nativeTag: current,
@@ -7522,8 +7605,8 @@ function completeWork(current, workInProgress, renderLanes) {
}
}));
markCloned(workInProgress);
appendAllChildren(newProps, workInProgress, !1, !1);
workInProgress.stateNode = newProps;
appendAllChildren(current, workInProgress, !1, !1);
workInProgress.stateNode = current;
}
bubbleProperties(workInProgress);
workInProgress.flags &= -16777217;
@@ -7560,7 +7643,41 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
newProps = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== newProps) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
current = !1;
} else
(newProps = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = newProps),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -7654,14 +7771,14 @@ function completeWork(current, workInProgress, renderLanes) {
if (null !== oldProps) {
workInProgress.flags |= 128;
cutOffTailIfNeeded(type, !1);
newProps = oldProps.updateQueue;
workInProgress.updateQueue = newProps;
scheduleRetryEffect(workInProgress, newProps);
current = oldProps.updateQueue;
workInProgress.updateQueue = current;
scheduleRetryEffect(workInProgress, current);
workInProgress.subtreeFlags = 0;
newProps = renderLanes;
for (current = workInProgress.child; null !== current; )
resetWorkInProgress(current, newProps),
(current = current.sibling);
current = renderLanes;
for (newProps = workInProgress.child; null !== newProps; )
resetWorkInProgress(newProps, current),
(newProps = newProps.sibling);
push(
suspenseStackCursor,
(suspenseStackCursor.current & 1) | 2
@@ -7802,6 +7919,18 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128), workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -7862,6 +7991,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -7891,9 +8024,9 @@ function commitHookEffectListMount(flags, finishedWork) {
do {
if ((updateQueue.tag & flags) === flags) {
lastEffect = void 0;
var create$120 = updateQueue.create,
var create$124 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$120();
lastEffect = create$124();
inst.destroy = lastEffect;
}
updateQueue = updateQueue.next;
@@ -8009,8 +8142,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
else if ("function" === typeof ref)
try {
ref(null);
} catch (error$122) {
captureCommitPhaseError(current, nearestMountedAncestor, error$122);
} catch (error$126) {
captureCommitPhaseError(current, nearestMountedAncestor, error$126);
}
else ref.current = null;
}
@@ -8140,11 +8273,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$121) {
} catch (error$125) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$121
error$125
);
}
}
@@ -8184,6 +8317,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
case 12:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -8358,6 +8494,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -8479,6 +8616,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -8690,6 +8836,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -8830,6 +8983,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -9725,8 +9886,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
exitStatus = workInProgressRootExitStatus;
break;
} catch (thrownValue$134) {
handleThrow(root, thrownValue$134);
} catch (thrownValue$139) {
handleThrow(root, thrownValue$139);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -9841,8 +10002,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$136) {
handleThrow(root, thrownValue$136);
} catch (thrownValue$141) {
handleThrow(root, thrownValue$141);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -10355,6 +10516,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -10931,26 +11093,26 @@ batchedUpdatesImpl = function (fn, a) {
}
};
var roots = new Map(),
internals$jscomp$inline_1223 = {
internals$jscomp$inline_1235 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1223.rendererConfig = extraDevToolsConfig);
(internals$jscomp$inline_1235.rendererConfig = extraDevToolsConfig);
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1536 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1553 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1536.isDisabled &&
hook$jscomp$inline_1536.supportsFiber
!hook$jscomp$inline_1553.isDisabled &&
hook$jscomp$inline_1553.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1536.inject(
internals$jscomp$inline_1223
(rendererID = hook$jscomp$inline_1553.inject(
internals$jscomp$inline_1235
)),
(injectedHook = hook$jscomp$inline_1536);
(injectedHook = hook$jscomp$inline_1553);
} catch (err) {}
}
exports.createPortal = function (children, containerTag) {
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<c104fd2344190dd688cfe690ddffbff9>>
* @generated SignedSource<<8e5d50cba591328e019d978d314ecedf>>
*/
"use strict";
@@ -1249,7 +1249,7 @@ eventPluginOrder = Array.prototype.slice.call([
"ReactNativeBridgeEventPlugin"
]);
recomputePluginOrdering();
var injectedNamesToPlugins$jscomp$inline_296 = {
var injectedNamesToPlugins$jscomp$inline_304 = {
ResponderEventPlugin: ResponderEventPlugin,
ReactNativeBridgeEventPlugin: {
eventTypes: {},
@@ -1295,32 +1295,32 @@ var injectedNamesToPlugins$jscomp$inline_296 = {
}
}
},
isOrderingDirty$jscomp$inline_297 = !1,
pluginName$jscomp$inline_298;
for (pluginName$jscomp$inline_298 in injectedNamesToPlugins$jscomp$inline_296)
isOrderingDirty$jscomp$inline_305 = !1,
pluginName$jscomp$inline_306;
for (pluginName$jscomp$inline_306 in injectedNamesToPlugins$jscomp$inline_304)
if (
injectedNamesToPlugins$jscomp$inline_296.hasOwnProperty(
pluginName$jscomp$inline_298
injectedNamesToPlugins$jscomp$inline_304.hasOwnProperty(
pluginName$jscomp$inline_306
)
) {
var pluginModule$jscomp$inline_299 =
injectedNamesToPlugins$jscomp$inline_296[pluginName$jscomp$inline_298];
var pluginModule$jscomp$inline_307 =
injectedNamesToPlugins$jscomp$inline_304[pluginName$jscomp$inline_306];
if (
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_298) ||
namesToPlugins[pluginName$jscomp$inline_298] !==
pluginModule$jscomp$inline_299
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_306) ||
namesToPlugins[pluginName$jscomp$inline_306] !==
pluginModule$jscomp$inline_307
) {
if (namesToPlugins[pluginName$jscomp$inline_298])
if (namesToPlugins[pluginName$jscomp$inline_306])
throw Error(
"EventPluginRegistry: Cannot inject two different event plugins using the same name, `" +
(pluginName$jscomp$inline_298 + "`.")
(pluginName$jscomp$inline_306 + "`.")
);
namesToPlugins[pluginName$jscomp$inline_298] =
pluginModule$jscomp$inline_299;
isOrderingDirty$jscomp$inline_297 = !0;
namesToPlugins[pluginName$jscomp$inline_306] =
pluginModule$jscomp$inline_307;
isOrderingDirty$jscomp$inline_305 = !0;
}
}
isOrderingDirty$jscomp$inline_297 && recomputePluginOrdering();
isOrderingDirty$jscomp$inline_305 && recomputePluginOrdering();
var emptyObject = {},
removedKeys = null,
removedKeyCount = 0,
@@ -1958,6 +1958,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function addFiberToLanesMap(root, fiber, lanes) {
if (isDevToolsPresent)
for (root = root.pendingUpdatersLaneMap; 0 < lanes; ) {
@@ -4022,6 +4066,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -5661,6 +5710,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -6013,6 +6063,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -6393,10 +6465,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6413,10 +6484,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6445,22 +6515,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -6478,7 +6548,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -6502,58 +6572,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -6574,12 +6603,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -6592,27 +6621,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue2),
(didSuspend =
@@ -6623,12 +6652,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6918,6 +6947,14 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -7295,29 +7332,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -7526,14 +7609,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$99 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$99 = lastTailNode),
for (var lastTailNode$100 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$100 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$99
null === lastTailNode$100
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$99.sibling = null);
: (lastTailNode$100.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -7545,53 +7628,53 @@ function bubbleProperties(completedWork) {
if (didBailout)
if (0 !== (completedWork.mode & 2)) {
for (
var treeBaseDuration$101 = completedWork.selfBaseDuration,
child$102 = completedWork.child;
null !== child$102;
var treeBaseDuration$102 = completedWork.selfBaseDuration,
child$103 = completedWork.child;
null !== child$103;
)
(newChildLanes |= child$102.lanes | child$102.childLanes),
(subtreeFlags |= child$102.subtreeFlags & 65011712),
(subtreeFlags |= child$102.flags & 65011712),
(treeBaseDuration$101 += child$102.treeBaseDuration),
(child$102 = child$102.sibling);
completedWork.treeBaseDuration = treeBaseDuration$101;
(newChildLanes |= child$103.lanes | child$103.childLanes),
(subtreeFlags |= child$103.subtreeFlags & 65011712),
(subtreeFlags |= child$103.flags & 65011712),
(treeBaseDuration$102 += child$103.treeBaseDuration),
(child$103 = child$103.sibling);
completedWork.treeBaseDuration = treeBaseDuration$102;
} else
for (
treeBaseDuration$101 = completedWork.child;
null !== treeBaseDuration$101;
treeBaseDuration$102 = completedWork.child;
null !== treeBaseDuration$102;
)
(newChildLanes |=
treeBaseDuration$101.lanes | treeBaseDuration$101.childLanes),
(subtreeFlags |= treeBaseDuration$101.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$101.flags & 65011712),
(treeBaseDuration$101.return = completedWork),
(treeBaseDuration$101 = treeBaseDuration$101.sibling);
treeBaseDuration$102.lanes | treeBaseDuration$102.childLanes),
(subtreeFlags |= treeBaseDuration$102.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$102.flags & 65011712),
(treeBaseDuration$102.return = completedWork),
(treeBaseDuration$102 = treeBaseDuration$102.sibling);
else if (0 !== (completedWork.mode & 2)) {
treeBaseDuration$101 = completedWork.actualDuration;
child$102 = completedWork.selfBaseDuration;
treeBaseDuration$102 = completedWork.actualDuration;
child$103 = completedWork.selfBaseDuration;
for (var child = completedWork.child; null !== child; )
(newChildLanes |= child.lanes | child.childLanes),
(subtreeFlags |= child.subtreeFlags),
(subtreeFlags |= child.flags),
(treeBaseDuration$101 += child.actualDuration),
(child$102 += child.treeBaseDuration),
(treeBaseDuration$102 += child.actualDuration),
(child$103 += child.treeBaseDuration),
(child = child.sibling);
completedWork.actualDuration = treeBaseDuration$101;
completedWork.treeBaseDuration = child$102;
completedWork.actualDuration = treeBaseDuration$102;
completedWork.treeBaseDuration = child$103;
} else
for (
treeBaseDuration$101 = completedWork.child;
null !== treeBaseDuration$101;
treeBaseDuration$102 = completedWork.child;
null !== treeBaseDuration$102;
)
(newChildLanes |=
treeBaseDuration$101.lanes | treeBaseDuration$101.childLanes),
(subtreeFlags |= treeBaseDuration$101.subtreeFlags),
(subtreeFlags |= treeBaseDuration$101.flags),
(treeBaseDuration$101.return = completedWork),
(treeBaseDuration$101 = treeBaseDuration$101.sibling);
treeBaseDuration$102.lanes | treeBaseDuration$102.childLanes),
(subtreeFlags |= treeBaseDuration$102.subtreeFlags),
(subtreeFlags |= treeBaseDuration$102.flags),
(treeBaseDuration$102.return = completedWork),
(treeBaseDuration$102 = treeBaseDuration$102.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -7794,7 +7877,46 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
newProps = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== newProps) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(newProps = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -= current.treeBaseDuration));
current = !1;
} else
(newProps = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = newProps),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -7802,7 +7924,8 @@ function completeWork(current, workInProgress, renderLanes) {
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
type = newProps;
if (null !== type && null !== type.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -7812,11 +7935,11 @@ function completeWork(current, workInProgress, renderLanes) {
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(type = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== type &&
((type = workInProgress.child),
null !== type &&
(workInProgress.treeBaseDuration -= type.treeBaseDuration));
@@ -8054,6 +8177,21 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -8120,6 +8258,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -8192,9 +8334,9 @@ function commitHookEffectListMount(flags, finishedWork) {
finishedWork
);
lastEffect = void 0;
var create$128 = updateQueue.create,
var create$134 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$128();
lastEffect = create$134();
inst.destroy = lastEffect;
0 !== (flags & 8)
? null !== injectedProfilingHooks &&
@@ -8334,8 +8476,8 @@ function safelyCallComponentWillUnmount(
} else
try {
instance.componentWillUnmount();
} catch (error$132) {
captureCommitPhaseError(current, nearestMountedAncestor, error$132);
} catch (error$138) {
captureCommitPhaseError(current, nearestMountedAncestor, error$138);
}
}
function safelyAttachRef(current, nearestMountedAncestor) {
@@ -8397,8 +8539,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
recordEffectDuration(current);
}
else ref(null);
} catch (error$133) {
captureCommitPhaseError(current, nearestMountedAncestor, error$133);
} catch (error$139) {
captureCommitPhaseError(current, nearestMountedAncestor, error$139);
}
else ref.current = null;
}
@@ -8553,11 +8695,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
} else
try {
finishedRoot.componentDidMount();
} catch (error$129) {
} catch (error$135) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$129
error$135
);
}
else {
@@ -8574,11 +8716,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$130) {
} catch (error$136) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$130
error$136
);
}
recordEffectDuration();
@@ -8589,11 +8731,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$131) {
} catch (error$137) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$131
error$137
);
}
}
@@ -8643,6 +8785,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
))
: recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -8820,6 +8965,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -8960,6 +9106,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((root = finishedWork.updateQueue),
null !== root &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, root)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -9191,6 +9346,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -9342,6 +9504,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -10297,8 +10467,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
memoizedUpdaters = workInProgressRootExitStatus;
break;
} catch (thrownValue$149) {
handleThrow(root, thrownValue$149);
} catch (thrownValue$156) {
handleThrow(root, thrownValue$156);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -10421,8 +10591,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$151) {
handleThrow(root, thrownValue$151);
} catch (thrownValue$158) {
handleThrow(root, thrownValue$158);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -11018,6 +11188,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -11623,20 +11794,20 @@ batchedUpdatesImpl = function (fn, a) {
}
};
var roots = new Map(),
internals$jscomp$inline_1318 = {
internals$jscomp$inline_1336 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1318.rendererConfig = extraDevToolsConfig);
internals$jscomp$inline_1318.getLaneLabelMap = function () {
(internals$jscomp$inline_1336.rendererConfig = extraDevToolsConfig);
internals$jscomp$inline_1336.getLaneLabelMap = function () {
for (
var map = new Map(), lane = 1, index$155 = 0;
31 > index$155;
index$155++
var map = new Map(), lane = 1, index$162 = 0;
31 > index$162;
index$162++
) {
var label = getLabelForLane(lane);
map.set(lane, label);
@@ -11644,20 +11815,20 @@ internals$jscomp$inline_1318.getLaneLabelMap = function () {
}
return map;
};
internals$jscomp$inline_1318.injectProfilingHooks = function (profilingHooks) {
internals$jscomp$inline_1336.injectProfilingHooks = function (profilingHooks) {
injectedProfilingHooks = profilingHooks;
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1597 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1620 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1597.isDisabled &&
hook$jscomp$inline_1597.supportsFiber
!hook$jscomp$inline_1620.isDisabled &&
hook$jscomp$inline_1620.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1597.inject(
internals$jscomp$inline_1318
(rendererID = hook$jscomp$inline_1620.inject(
internals$jscomp$inline_1336
)),
(injectedHook = hook$jscomp$inline_1597);
(injectedHook = hook$jscomp$inline_1620);
} catch (err) {}
}
exports.createPortal = function (children, containerTag) {
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<e57086168337bbd4c954e33abdfeca98>>
* @generated SignedSource<<5766de66d75c0edf7da351d3a588c452>>
*/
"use strict";
@@ -1975,6 +1975,50 @@ __DEV__ &&
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function addFiberToLanesMap(root, fiber, lanes) {
if (isDevToolsPresent)
for (root = root.pendingUpdatersLaneMap; 0 < lanes; ) {
@@ -5027,6 +5071,11 @@ __DEV__ &&
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current, fiber);
push(suspenseHandlerStackCursor, fiber, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current, fiber),
@@ -7141,6 +7190,7 @@ __DEV__ &&
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -7517,6 +7567,42 @@ __DEV__ &&
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
var hiddenProp = nextProps.hidden;
void 0 !== hiddenProp &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === hiddenProp
? "hidden"
: !1 === hiddenProp
? "hidden={false}"
: "hidden={...}",
hiddenProp ? 'mode="hidden"' : 'mode="visible"'
);
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(
workInProgress,
workInProgress.pendingProps
);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -8004,10 +8090,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -8024,10 +8110,10 @@ __DEV__ &&
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
(showFallback = workInProgress.child),
(showFallback.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -8062,22 +8148,22 @@ __DEV__ &&
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -8095,31 +8181,32 @@ __DEV__ &&
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if (
(pushPrimaryTreeSuspenseHandler(workInProgress),
isSuspenseInstanceFallback())
)
(showFallback = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = showFallback.digest),
(nextPrimaryChildren = showFallback.message),
(nextProps = showFallback.stack),
(showFallback = showFallback.componentStack),
(nextPrimaryChildren = nextPrimaryChildren
? Error(nextPrimaryChildren)
(nextPrimaryChildren = getSuspenseInstanceFallbackErrorDetails()),
(JSCompiler_temp = nextPrimaryChildren.digest),
(showFallback = nextPrimaryChildren.message),
(nextProps = nextPrimaryChildren.stack),
(nextPrimaryChildren = nextPrimaryChildren.componentStack),
(showFallback = showFallback
? Error(showFallback)
: Error(
"The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering."
)),
(nextPrimaryChildren.stack = nextProps || ""),
(nextPrimaryChildren.digest = JSCompiler_temp),
(JSCompiler_temp = void 0 === showFallback ? null : showFallback),
(showFallback.stack = nextProps || ""),
(showFallback.digest = JSCompiler_temp),
(JSCompiler_temp =
void 0 === nextPrimaryChildren ? null : nextPrimaryChildren),
(nextProps = {
value: nextPrimaryChildren,
value: showFallback,
source: null,
stack: JSCompiler_temp
}),
"string" === typeof JSCompiler_temp &&
CapturedStacks.set(nextPrimaryChildren, nextProps),
CapturedStacks.set(showFallback, nextProps),
null === hydrationErrors
? (hydrationErrors = [nextProps])
: hydrationErrors.push(nextProps),
@@ -8140,58 +8227,20 @@ __DEV__ &&
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(
JSCompiler_temp,
renderLanes
)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
isSuspenseInstancePending() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -8212,12 +8261,12 @@ __DEV__ &&
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -8230,27 +8279,27 @@ __DEV__ &&
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue),
(didSuspend =
@@ -8261,12 +8310,12 @@ __DEV__ &&
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -8670,6 +8719,14 @@ __DEV__ &&
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -8879,10 +8936,10 @@ __DEV__ &&
current.$$typeof === REACT_LAZY_TYPE &&
(workInProgress =
" Did you wrap a component in React.lazy() more than once?");
current = getComponentNameFromType(current) || current;
renderLanes = getComponentNameFromType(current) || current;
throw Error(
"Element type is invalid. Received a promise that resolves to: " +
current +
renderLanes +
". Lazy element type must resolve to a class or function." +
workInProgress
);
@@ -9155,40 +9212,83 @@ __DEV__ &&
renderLanes
);
case 31:
return (
(renderLanes = workInProgress.pendingProps),
(returnFiber = renderLanes.hidden),
void 0 !== returnFiber &&
console.error(
'<Activity> doesn\'t accept a hidden prop. Use mode="hidden" instead.\n- <Activity %s>\n+ <Activity %s>',
!0 === returnFiber
? "hidden"
: !1 === returnFiber
? "hidden={false}"
: "hidden={...}",
returnFiber ? 'mode="hidden"' : 'mode="visible"'
),
(returnFiber = workInProgress.mode),
(renderLanes = {
mode: renderLanes.mode,
children: renderLanes.children
}),
null === current
? ((current = mountWorkInProgressOffscreenFiber(
prevSibling = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, prevSibling);
else if (
((returnFiber = current.memoizedState), null !== returnFiber)
)
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
returnFiber
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
prevSibling = workInProgressRoot;
if (
null !== prevSibling &&
((nextProps = getBumpedLaneForHydration(
prevSibling,
renderLanes
)),
0 !== nextProps && nextProps !== returnFiber.retryLane)
)
throw (
((returnFiber.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(prevSibling, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
} else
(workInProgress = mountActivityChildren(
workInProgress,
prevSibling
)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current))
: ((current = createWorkInProgress(current.child, renderLanes)),
(current.ref = workInProgress.ref),
(workInProgress.child = current),
(current.return = workInProgress),
(workInProgress = current)),
workInProgress
);
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: prevSibling.mode,
children: prevSibling.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -9494,7 +9594,48 @@ __DEV__ &&
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(renderLanes = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== renderLanes &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -=
current.treeBaseDuration));
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -9502,7 +9643,8 @@ __DEV__ &&
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
key = newProps;
if (null !== key && null !== key.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -9513,11 +9655,11 @@ __DEV__ &&
}
emitPendingHydrationWarnings();
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(key = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== key &&
((key = workInProgress.child),
null !== key &&
(workInProgress.treeBaseDuration -= key.treeBaseDuration));
@@ -9772,6 +9914,22 @@ __DEV__ &&
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress),
null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -9837,6 +9995,10 @@ __DEV__ &&
case 4:
popHostContainer(interruptedWork);
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -10648,6 +10810,9 @@ __DEV__ &&
}
} else recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -10895,6 +11060,7 @@ __DEV__ &&
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -11113,6 +11279,15 @@ __DEV__ &&
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -11459,6 +11634,13 @@ __DEV__ &&
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -11621,6 +11803,14 @@ __DEV__ &&
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -13590,6 +13780,7 @@ __DEV__ &&
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -17373,11 +17564,11 @@ __DEV__ &&
shouldSuspendImpl = newShouldSuspendImpl;
};
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-17f88c80-20250422" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-3ef31d19-20250422" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-17f88c80-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-3ef31d19-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -17403,10 +17594,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<7cfad95784e7f37ec4510fa84f839770>>
* @generated SignedSource<<60721fd4efdec1604e530302fb948b0a>>
*/
"use strict";
@@ -1236,7 +1236,7 @@ eventPluginOrder = Array.prototype.slice.call([
"ReactNativeBridgeEventPlugin"
]);
recomputePluginOrdering();
var injectedNamesToPlugins$jscomp$inline_285 = {
var injectedNamesToPlugins$jscomp$inline_291 = {
ResponderEventPlugin: ResponderEventPlugin,
ReactNativeBridgeEventPlugin: {
eventTypes: {},
@@ -1282,32 +1282,32 @@ var injectedNamesToPlugins$jscomp$inline_285 = {
}
}
},
isOrderingDirty$jscomp$inline_286 = !1,
pluginName$jscomp$inline_287;
for (pluginName$jscomp$inline_287 in injectedNamesToPlugins$jscomp$inline_285)
isOrderingDirty$jscomp$inline_292 = !1,
pluginName$jscomp$inline_293;
for (pluginName$jscomp$inline_293 in injectedNamesToPlugins$jscomp$inline_291)
if (
injectedNamesToPlugins$jscomp$inline_285.hasOwnProperty(
pluginName$jscomp$inline_287
injectedNamesToPlugins$jscomp$inline_291.hasOwnProperty(
pluginName$jscomp$inline_293
)
) {
var pluginModule$jscomp$inline_288 =
injectedNamesToPlugins$jscomp$inline_285[pluginName$jscomp$inline_287];
var pluginModule$jscomp$inline_294 =
injectedNamesToPlugins$jscomp$inline_291[pluginName$jscomp$inline_293];
if (
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_287) ||
namesToPlugins[pluginName$jscomp$inline_287] !==
pluginModule$jscomp$inline_288
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_293) ||
namesToPlugins[pluginName$jscomp$inline_293] !==
pluginModule$jscomp$inline_294
) {
if (namesToPlugins[pluginName$jscomp$inline_287])
if (namesToPlugins[pluginName$jscomp$inline_293])
throw Error(
"EventPluginRegistry: Cannot inject two different event plugins using the same name, `" +
(pluginName$jscomp$inline_287 + "`.")
(pluginName$jscomp$inline_293 + "`.")
);
namesToPlugins[pluginName$jscomp$inline_287] =
pluginModule$jscomp$inline_288;
isOrderingDirty$jscomp$inline_286 = !0;
namesToPlugins[pluginName$jscomp$inline_293] =
pluginModule$jscomp$inline_294;
isOrderingDirty$jscomp$inline_292 = !0;
}
}
isOrderingDirty$jscomp$inline_286 && recomputePluginOrdering();
isOrderingDirty$jscomp$inline_292 && recomputePluginOrdering();
var instanceCache = new Map(),
instanceProps = new Map();
function getInstanceFromTag(tag) {
@@ -2108,6 +2108,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function lanesToEventPriority(lanes) {
lanes &= -lanes;
return 2 < lanes
@@ -4036,6 +4080,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -5666,6 +5715,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -6016,6 +6066,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -6385,10 +6457,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6405,10 +6476,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6437,22 +6507,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -6470,7 +6540,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -6494,58 +6564,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -6566,12 +6595,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -6579,27 +6608,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue),
(didSuspend =
@@ -6610,12 +6639,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6891,10 +6920,18 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
workInProgress.memoizedProps.value
);
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
var state = workInProgress.memoizedState;
if (null !== state) {
if (null !== state.dehydrated)
var state$79 = workInProgress.memoizedState;
if (null !== state$79) {
if (null !== state$79.dehydrated)
return (
pushPrimaryTreeSuspenseHandler(workInProgress),
(workInProgress.flags |= 128),
@@ -6914,17 +6951,17 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
break;
case 19:
var didSuspendBefore = 0 !== (current.flags & 128);
state = 0 !== (renderLanes & workInProgress.childLanes);
state ||
state$79 = 0 !== (renderLanes & workInProgress.childLanes);
state$79 ||
(propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
),
(state = 0 !== (renderLanes & workInProgress.childLanes)));
(state$79 = 0 !== (renderLanes & workInProgress.childLanes)));
if (didSuspendBefore) {
if (state)
if (state$79)
return updateSuspenseListComponent(
current,
workInProgress,
@@ -6938,7 +6975,7 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
(didSuspendBefore.tail = null),
(didSuspendBefore.lastEffect = null));
push(suspenseStackCursor, suspenseStackCursor.current);
if (state) break;
if (state$79) break;
else return null;
case 22:
return (
@@ -7261,29 +7298,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -7373,14 +7456,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$95 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$95 = lastTailNode),
for (var lastTailNode$96 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$96 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$95
null === lastTailNode$96
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$95.sibling = null);
: (lastTailNode$96.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -7390,19 +7473,19 @@ function bubbleProperties(completedWork) {
newChildLanes = 0,
subtreeFlags = 0;
if (didBailout)
for (var child$96 = completedWork.child; null !== child$96; )
(newChildLanes |= child$96.lanes | child$96.childLanes),
(subtreeFlags |= child$96.subtreeFlags & 65011712),
(subtreeFlags |= child$96.flags & 65011712),
(child$96.return = completedWork),
(child$96 = child$96.sibling);
for (var child$97 = completedWork.child; null !== child$97; )
(newChildLanes |= child$97.lanes | child$97.childLanes),
(subtreeFlags |= child$97.subtreeFlags & 65011712),
(subtreeFlags |= child$97.flags & 65011712),
(child$97.return = completedWork),
(child$97 = child$97.sibling);
else
for (child$96 = completedWork.child; null !== child$96; )
(newChildLanes |= child$96.lanes | child$96.childLanes),
(subtreeFlags |= child$96.subtreeFlags),
(subtreeFlags |= child$96.flags),
(child$96.return = completedWork),
(child$96 = child$96.sibling);
for (child$97 = completedWork.child; null !== child$97; )
(newChildLanes |= child$97.lanes | child$97.childLanes),
(subtreeFlags |= child$97.subtreeFlags),
(subtreeFlags |= child$97.flags),
(child$97.return = completedWork),
(child$97 = child$97.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -7537,7 +7620,41 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -7778,6 +7895,18 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128), workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -7838,6 +7967,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -7867,9 +8000,9 @@ function commitHookEffectListMount(flags, finishedWork) {
do {
if ((updateQueue.tag & flags) === flags) {
lastEffect = void 0;
var create$119 = updateQueue.create,
var create$123 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$119();
lastEffect = create$123();
inst.destroy = lastEffect;
}
updateQueue = updateQueue.next;
@@ -7985,8 +8118,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
else if ("function" === typeof ref)
try {
ref(null);
} catch (error$121) {
captureCommitPhaseError(current, nearestMountedAncestor, error$121);
} catch (error$125) {
captureCommitPhaseError(current, nearestMountedAncestor, error$125);
}
else ref.current = null;
}
@@ -8196,11 +8329,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$120) {
} catch (error$124) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$120
error$124
);
}
}
@@ -8239,6 +8372,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
case 12:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -8465,6 +8601,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -8639,6 +8776,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -8844,12 +8990,12 @@ function commitReconciliationEffects(finishedWork) {
break;
case 3:
case 4:
var parent$122 = hostParentFiber.stateNode.containerInfo,
before$123 = getHostSibling(finishedWork);
var parent$126 = hostParentFiber.stateNode.containerInfo,
before$127 = getHostSibling(finishedWork);
insertOrAppendPlacementNodeIntoContainer(
finishedWork,
before$123,
parent$122
before$127,
parent$126
);
break;
default:
@@ -8986,6 +9132,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -9126,6 +9279,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -10023,8 +10184,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
exitStatus = workInProgressRootExitStatus;
break;
} catch (thrownValue$137) {
handleThrow(root, thrownValue$137);
} catch (thrownValue$142) {
handleThrow(root, thrownValue$142);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -10139,8 +10300,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$139) {
handleThrow(root, thrownValue$139);
} catch (thrownValue$144) {
handleThrow(root, thrownValue$144);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -10653,6 +10814,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -11035,11 +11197,11 @@ function updateContainer(element, container, parentComponent, callback) {
return lane;
}
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-17f88c80-20250422" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-3ef31d19-20250422" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-17f88c80-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-3ef31d19-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -11086,26 +11248,26 @@ batchedUpdatesImpl = function (fn, a) {
}
};
var roots = new Map(),
internals$jscomp$inline_1286 = {
internals$jscomp$inline_1298 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1286.rendererConfig = extraDevToolsConfig);
(internals$jscomp$inline_1298.rendererConfig = extraDevToolsConfig);
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1627 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1644 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1627.isDisabled &&
hook$jscomp$inline_1627.supportsFiber
!hook$jscomp$inline_1644.isDisabled &&
hook$jscomp$inline_1644.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1627.inject(
internals$jscomp$inline_1286
(rendererID = hook$jscomp$inline_1644.inject(
internals$jscomp$inline_1298
)),
(injectedHook = hook$jscomp$inline_1627);
(injectedHook = hook$jscomp$inline_1644);
} catch (err) {}
}
exports.createPortal = function (children, containerTag) {
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<18f8c983be0fd26198908340ac3a6a48>>
* @generated SignedSource<<881e881b2539a7fdf36025e8d9f53ba5>>
*/
"use strict";
@@ -1240,7 +1240,7 @@ eventPluginOrder = Array.prototype.slice.call([
"ReactNativeBridgeEventPlugin"
]);
recomputePluginOrdering();
var injectedNamesToPlugins$jscomp$inline_301 = {
var injectedNamesToPlugins$jscomp$inline_309 = {
ResponderEventPlugin: ResponderEventPlugin,
ReactNativeBridgeEventPlugin: {
eventTypes: {},
@@ -1286,32 +1286,32 @@ var injectedNamesToPlugins$jscomp$inline_301 = {
}
}
},
isOrderingDirty$jscomp$inline_302 = !1,
pluginName$jscomp$inline_303;
for (pluginName$jscomp$inline_303 in injectedNamesToPlugins$jscomp$inline_301)
isOrderingDirty$jscomp$inline_310 = !1,
pluginName$jscomp$inline_311;
for (pluginName$jscomp$inline_311 in injectedNamesToPlugins$jscomp$inline_309)
if (
injectedNamesToPlugins$jscomp$inline_301.hasOwnProperty(
pluginName$jscomp$inline_303
injectedNamesToPlugins$jscomp$inline_309.hasOwnProperty(
pluginName$jscomp$inline_311
)
) {
var pluginModule$jscomp$inline_304 =
injectedNamesToPlugins$jscomp$inline_301[pluginName$jscomp$inline_303];
var pluginModule$jscomp$inline_312 =
injectedNamesToPlugins$jscomp$inline_309[pluginName$jscomp$inline_311];
if (
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_303) ||
namesToPlugins[pluginName$jscomp$inline_303] !==
pluginModule$jscomp$inline_304
!namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_311) ||
namesToPlugins[pluginName$jscomp$inline_311] !==
pluginModule$jscomp$inline_312
) {
if (namesToPlugins[pluginName$jscomp$inline_303])
if (namesToPlugins[pluginName$jscomp$inline_311])
throw Error(
"EventPluginRegistry: Cannot inject two different event plugins using the same name, `" +
(pluginName$jscomp$inline_303 + "`.")
(pluginName$jscomp$inline_311 + "`.")
);
namesToPlugins[pluginName$jscomp$inline_303] =
pluginModule$jscomp$inline_304;
isOrderingDirty$jscomp$inline_302 = !0;
namesToPlugins[pluginName$jscomp$inline_311] =
pluginModule$jscomp$inline_312;
isOrderingDirty$jscomp$inline_310 = !0;
}
}
isOrderingDirty$jscomp$inline_302 && recomputePluginOrdering();
isOrderingDirty$jscomp$inline_310 && recomputePluginOrdering();
var instanceCache = new Map(),
instanceProps = new Map();
function getInstanceFromTag(tag) {
@@ -2160,6 +2160,50 @@ function markRootEntangled(root, entangledLanes) {
rootEntangledLanes &= ~lane;
}
}
function getBumpedLaneForHydration(root, renderLanes) {
var renderLane = renderLanes & -renderLanes;
if (0 !== (renderLane & 42)) renderLane = 1;
else
switch (renderLane) {
case 2:
renderLane = 1;
break;
case 8:
renderLane = 4;
break;
case 32:
renderLane = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
renderLane = 128;
break;
case 268435456:
renderLane = 134217728;
break;
default:
renderLane = 0;
}
return 0 !== (renderLane & (root.suspendedLanes | renderLanes))
? 0
: renderLane;
}
function addFiberToLanesMap(root, fiber, lanes) {
if (isDevToolsPresent)
for (root = root.pendingUpdatersLaneMap; 0 < lanes; ) {
@@ -4186,6 +4230,11 @@ function pushPrimaryTreeSuspenseHandler(handler) {
? (shellBoundary = handler)
: null !== current.memoizedState && (shellBoundary = handler));
}
function pushDehydratedActivitySuspenseHandler(fiber) {
push(suspenseStackCursor, suspenseStackCursor.current);
push(suspenseHandlerStackCursor, fiber);
null === shellBoundary && (shellBoundary = fiber);
}
function pushOffscreenSuspenseHandler(fiber) {
22 === fiber.tag
? (push(suspenseStackCursor, suspenseStackCursor.current),
@@ -5825,6 +5874,7 @@ function throwException(
currentSourceFiber = suspenseHandlerStackCursor.current;
if (null !== currentSourceFiber) {
switch (currentSourceFiber.tag) {
case 31:
case 13:
return (
sourceFiber.mode & 1 &&
@@ -6177,6 +6227,28 @@ function deferHiddenOffscreenComponent(
propagateParentContextChanges(current, workInProgress, renderLanes, !0);
return null;
}
function mountActivityChildren(workInProgress, nextProps) {
nextProps = mountWorkInProgressOffscreenFiber(
{ mode: nextProps.mode, children: nextProps.children },
workInProgress.mode
);
nextProps.ref = workInProgress.ref;
workInProgress.child = nextProps;
nextProps.return = workInProgress;
return nextProps;
}
function retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
) {
reconcileChildFibers(workInProgress, current.child, null, renderLanes);
current = mountActivityChildren(workInProgress, workInProgress.pendingProps);
current.flags |= 2;
popSuspenseHandler(workInProgress);
workInProgress.memoizedState = null;
return current;
}
function markRef(current, workInProgress) {
var ref = workInProgress.ref;
if (null === ref)
@@ -6557,10 +6629,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6577,10 +6648,9 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didSuspend,
renderLanes
)),
(nextPrimaryChildren = workInProgress.child),
(nextPrimaryChildren.memoizedState =
mountSuspenseOffscreenState(renderLanes)),
(nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
(showFallback = workInProgress.child),
(showFallback.memoizedState = mountSuspenseOffscreenState(renderLanes)),
(showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -6609,22 +6679,22 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
(workInProgress.flags |= 128),
(workInProgress = null))
: (reuseSuspenseHandlerOnStack(workInProgress),
(nextPrimaryChildren = nextProps.fallback),
(showFallback = workInProgress.mode),
(showFallback = nextProps.fallback),
(nextPrimaryChildren = workInProgress.mode),
(nextProps = mountWorkInProgressOffscreenFiber(
{ mode: "visible", children: nextProps.children },
showFallback
nextPrimaryChildren
)),
(nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
(showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2),
(showFallback.flags |= 2),
(nextProps.return = workInProgress),
(nextPrimaryChildren.return = workInProgress),
(nextProps.sibling = nextPrimaryChildren),
(showFallback.return = workInProgress),
(nextProps.sibling = showFallback),
(workInProgress.child = nextProps),
0 !== (workInProgress.mode & 1) &&
reconcileChildFibers(
@@ -6642,7 +6712,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
renderLanes
)),
(workInProgress.memoizedState = SUSPENDED_MARKER),
(workInProgress = nextPrimaryChildren));
(workInProgress = showFallback));
else if ((pushPrimaryTreeSuspenseHandler(workInProgress), shim$1()))
(JSCompiler_temp = shim$1().digest),
(nextProps = Error(
@@ -6666,58 +6736,17 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
didReceiveUpdate || JSCompiler_temp)
) {
JSCompiler_temp = workInProgressRoot;
if (null !== JSCompiler_temp) {
nextProps = renderLanes & -renderLanes;
if (0 !== (nextProps & 42)) nextProps = 1;
else
switch (nextProps) {
case 2:
nextProps = 1;
break;
case 8:
nextProps = 4;
break;
case 32:
nextProps = 16;
break;
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
nextProps = 128;
break;
case 268435456:
nextProps = 134217728;
break;
default:
nextProps = 0;
}
nextProps =
0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
? 0
: nextProps;
if (0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
}
if (
null !== JSCompiler_temp &&
((nextProps = getBumpedLaneForHydration(JSCompiler_temp, renderLanes)),
0 !== nextProps && nextProps !== nextPrimaryChildren.retryLane)
)
throw (
((nextPrimaryChildren.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
SelectiveHydrationException)
);
shim$1() || renderDidSuspendDelayIfPossible();
workInProgress = retrySuspenseComponentWithoutHydrating(
current,
@@ -6738,12 +6767,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
if (showFallback) {
reuseSuspenseHandlerOnStack(workInProgress);
nextPrimaryChildren = nextProps.fallback;
showFallback = workInProgress.mode;
showFallback = nextProps.fallback;
nextPrimaryChildren = workInProgress.mode;
didSuspend = current.child;
var currentFallbackChildFragment = didSuspend.sibling,
primaryChildProps = { mode: "hidden", children: nextProps.children };
0 === (showFallback & 1) && workInProgress.child !== didSuspend
0 === (nextPrimaryChildren & 1) && workInProgress.child !== didSuspend
? ((nextProps = workInProgress.child),
(nextProps.childLanes = 0),
(nextProps.pendingProps = primaryChildProps),
@@ -6756,27 +6785,27 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
: ((nextProps = createWorkInProgress(didSuspend, primaryChildProps)),
(nextProps.subtreeFlags = didSuspend.subtreeFlags & 65011712));
null !== currentFallbackChildFragment
? (nextPrimaryChildren = createWorkInProgress(
? (showFallback = createWorkInProgress(
currentFallbackChildFragment,
nextPrimaryChildren
showFallback
))
: ((nextPrimaryChildren = createFiberFromFragment(
nextPrimaryChildren,
: ((showFallback = createFiberFromFragment(
showFallback,
nextPrimaryChildren,
renderLanes,
null
)),
(nextPrimaryChildren.flags |= 2));
nextPrimaryChildren.return = workInProgress;
(showFallback.flags |= 2));
showFallback.return = workInProgress;
nextProps.return = workInProgress;
nextProps.sibling = nextPrimaryChildren;
nextProps.sibling = showFallback;
workInProgress.child = nextProps;
nextProps = nextPrimaryChildren;
nextPrimaryChildren = workInProgress.child;
showFallback = current.child.memoizedState;
null === showFallback
? (showFallback = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = showFallback.cachePool),
nextProps = showFallback;
showFallback = workInProgress.child;
nextPrimaryChildren = current.child.memoizedState;
null === nextPrimaryChildren
? (nextPrimaryChildren = mountSuspenseOffscreenState(renderLanes))
: ((didSuspend = nextPrimaryChildren.cachePool),
null !== didSuspend
? ((currentFallbackChildFragment = CacheContext._currentValue),
(didSuspend =
@@ -6787,12 +6816,12 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
}
: didSuspend))
: (didSuspend = getSuspendedCache()),
(showFallback = {
baseLanes: showFallback.baseLanes | renderLanes,
(nextPrimaryChildren = {
baseLanes: nextPrimaryChildren.baseLanes | renderLanes,
cachePool: didSuspend
}));
nextPrimaryChildren.memoizedState = showFallback;
nextPrimaryChildren.childLanes = getRemainingWorkInPrimaryTree(
showFallback.memoizedState = nextPrimaryChildren;
showFallback.childLanes = getRemainingWorkInPrimaryTree(
current,
JSCompiler_temp,
renderLanes
@@ -7082,6 +7111,14 @@ function attemptEarlyBailoutIfNoScheduledUpdate(
stateNode.effectDuration = -0;
stateNode.passiveEffectDuration = -0;
break;
case 31:
if (null !== workInProgress.memoizedState)
return (
(workInProgress.flags |= 128),
pushDehydratedActivitySuspenseHandler(workInProgress),
null
);
break;
case 13:
stateNode = workInProgress.memoizedState;
if (null !== stateNode) {
@@ -7459,29 +7496,75 @@ function beginWork(current, workInProgress, renderLanes) {
case 19:
return updateSuspenseListComponent(current, workInProgress, renderLanes);
case 31:
return (
(elementType = workInProgress.pendingProps),
(renderLanes = workInProgress.mode),
(elementType = {
mode: elementType.mode,
children: elementType.children
}),
null === current
? ((renderLanes = mountWorkInProgressOffscreenFiber(
elementType,
init = workInProgress.pendingProps;
nextProps = 0 !== (workInProgress.flags & 128);
workInProgress.flags &= -129;
if (null === current)
workInProgress = mountActivityChildren(workInProgress, init);
else if (((elementType = current.memoizedState), null !== elementType))
b: {
pushDehydratedActivitySuspenseHandler(workInProgress);
if (nextProps) {
if (workInProgress.flags & 256) {
workInProgress.flags &= -257;
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
);
break b;
}
if (null !== workInProgress.memoizedState) {
workInProgress.child = current.child;
workInProgress.flags |= 128;
workInProgress = null;
break b;
}
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
didReceiveUpdate ||
propagateParentContextChanges(
current,
workInProgress,
renderLanes,
!1
);
nextProps = 0 !== (renderLanes & current.childLanes);
if (didReceiveUpdate || nextProps) {
init = workInProgressRoot;
if (
null !== init &&
((nextProps = getBumpedLaneForHydration(init, renderLanes)),
0 !== nextProps && nextProps !== elementType.retryLane)
)
throw (
((elementType.retryLane = nextProps),
enqueueConcurrentRenderForLane(current, nextProps),
scheduleUpdateOnFiber(init, current, nextProps),
SelectiveHydrationException)
);
renderDidSuspendDelayIfPossible();
workInProgress = retryActivityComponentWithoutHydrating(
current,
workInProgress,
renderLanes
)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes))
: ((renderLanes = createWorkInProgress(current.child, elementType)),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes)),
workInProgress
);
);
} else
(workInProgress = mountActivityChildren(workInProgress, init)),
(workInProgress.flags |= 4096);
}
else
(renderLanes = createWorkInProgress(current.child, {
mode: init.mode,
children: init.children
})),
(renderLanes.ref = workInProgress.ref),
(workInProgress.child = renderLanes),
(renderLanes.return = workInProgress),
(workInProgress = renderLanes);
return workInProgress;
case 22:
return updateOffscreenComponent(
current,
@@ -7571,14 +7654,14 @@ function cutOffTailIfNeeded(renderState, hasRenderedATailFallback) {
break;
case "collapsed":
lastTailNode = renderState.tail;
for (var lastTailNode$98 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$98 = lastTailNode),
for (var lastTailNode$99 = null; null !== lastTailNode; )
null !== lastTailNode.alternate && (lastTailNode$99 = lastTailNode),
(lastTailNode = lastTailNode.sibling);
null === lastTailNode$98
null === lastTailNode$99
? hasRenderedATailFallback || null === renderState.tail
? (renderState.tail = null)
: (renderState.tail.sibling = null)
: (lastTailNode$98.sibling = null);
: (lastTailNode$99.sibling = null);
}
}
function bubbleProperties(completedWork) {
@@ -7590,53 +7673,53 @@ function bubbleProperties(completedWork) {
if (didBailout)
if (0 !== (completedWork.mode & 2)) {
for (
var treeBaseDuration$100 = completedWork.selfBaseDuration,
child$101 = completedWork.child;
null !== child$101;
var treeBaseDuration$101 = completedWork.selfBaseDuration,
child$102 = completedWork.child;
null !== child$102;
)
(newChildLanes |= child$101.lanes | child$101.childLanes),
(subtreeFlags |= child$101.subtreeFlags & 65011712),
(subtreeFlags |= child$101.flags & 65011712),
(treeBaseDuration$100 += child$101.treeBaseDuration),
(child$101 = child$101.sibling);
completedWork.treeBaseDuration = treeBaseDuration$100;
(newChildLanes |= child$102.lanes | child$102.childLanes),
(subtreeFlags |= child$102.subtreeFlags & 65011712),
(subtreeFlags |= child$102.flags & 65011712),
(treeBaseDuration$101 += child$102.treeBaseDuration),
(child$102 = child$102.sibling);
completedWork.treeBaseDuration = treeBaseDuration$101;
} else
for (
treeBaseDuration$100 = completedWork.child;
null !== treeBaseDuration$100;
treeBaseDuration$101 = completedWork.child;
null !== treeBaseDuration$101;
)
(newChildLanes |=
treeBaseDuration$100.lanes | treeBaseDuration$100.childLanes),
(subtreeFlags |= treeBaseDuration$100.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$100.flags & 65011712),
(treeBaseDuration$100.return = completedWork),
(treeBaseDuration$100 = treeBaseDuration$100.sibling);
treeBaseDuration$101.lanes | treeBaseDuration$101.childLanes),
(subtreeFlags |= treeBaseDuration$101.subtreeFlags & 65011712),
(subtreeFlags |= treeBaseDuration$101.flags & 65011712),
(treeBaseDuration$101.return = completedWork),
(treeBaseDuration$101 = treeBaseDuration$101.sibling);
else if (0 !== (completedWork.mode & 2)) {
treeBaseDuration$100 = completedWork.actualDuration;
child$101 = completedWork.selfBaseDuration;
treeBaseDuration$101 = completedWork.actualDuration;
child$102 = completedWork.selfBaseDuration;
for (var child = completedWork.child; null !== child; )
(newChildLanes |= child.lanes | child.childLanes),
(subtreeFlags |= child.subtreeFlags),
(subtreeFlags |= child.flags),
(treeBaseDuration$100 += child.actualDuration),
(child$101 += child.treeBaseDuration),
(treeBaseDuration$101 += child.actualDuration),
(child$102 += child.treeBaseDuration),
(child = child.sibling);
completedWork.actualDuration = treeBaseDuration$100;
completedWork.treeBaseDuration = child$101;
completedWork.actualDuration = treeBaseDuration$101;
completedWork.treeBaseDuration = child$102;
} else
for (
treeBaseDuration$100 = completedWork.child;
null !== treeBaseDuration$100;
treeBaseDuration$101 = completedWork.child;
null !== treeBaseDuration$101;
)
(newChildLanes |=
treeBaseDuration$100.lanes | treeBaseDuration$100.childLanes),
(subtreeFlags |= treeBaseDuration$100.subtreeFlags),
(subtreeFlags |= treeBaseDuration$100.flags),
(treeBaseDuration$100.return = completedWork),
(treeBaseDuration$100 = treeBaseDuration$100.sibling);
treeBaseDuration$101.lanes | treeBaseDuration$101.childLanes),
(subtreeFlags |= treeBaseDuration$101.subtreeFlags),
(subtreeFlags |= treeBaseDuration$101.flags),
(treeBaseDuration$101.return = completedWork),
(treeBaseDuration$101 = treeBaseDuration$101.sibling);
completedWork.subtreeFlags |= subtreeFlags;
completedWork.childLanes = newChildLanes;
return didBailout;
@@ -7771,7 +7854,46 @@ function completeWork(current, workInProgress, renderLanes) {
bubbleProperties(workInProgress);
return null;
case 31:
return bubbleProperties(workInProgress), null;
renderLanes = workInProgress.memoizedState;
if (null === current || null !== current.memoizedState) {
if (null !== renderLanes) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
);
throw Error(
"Expected prepareToHydrateHostActivityInstance() to never be called. This error is likely caused by a bug in React. Please file an issue."
);
}
0 === (workInProgress.flags & 128) &&
(renderLanes = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== renderLanes &&
((current = workInProgress.child),
null !== current &&
(workInProgress.treeBaseDuration -= current.treeBaseDuration));
current = !1;
} else
(renderLanes = upgradeHydrationErrorsToRecoverable()),
null !== current &&
null !== current.memoizedState &&
(current.memoizedState.hydrationErrors = renderLanes),
(current = !0);
if (!current) {
if (workInProgress.flags & 256)
return popSuspenseHandler(workInProgress), workInProgress;
popSuspenseHandler(workInProgress);
return null;
}
if (0 !== (workInProgress.flags & 128))
throw Error(
"Client rendering an Activity suspended it again. This is a bug in React."
);
}
bubbleProperties(workInProgress);
return null;
case 13:
newProps = workInProgress.memoizedState;
if (
@@ -7779,7 +7901,8 @@ function completeWork(current, workInProgress, renderLanes) {
(null !== current.memoizedState &&
null !== current.memoizedState.dehydrated)
) {
if (null !== newProps && null !== newProps.dehydrated) {
type = newProps;
if (null !== type && null !== type.dehydrated) {
if (null === current) {
throw Error(
"A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React."
@@ -7789,11 +7912,11 @@ function completeWork(current, workInProgress, renderLanes) {
);
}
0 === (workInProgress.flags & 128) &&
(workInProgress.memoizedState = null);
(type = workInProgress.memoizedState = null);
workInProgress.flags |= 4;
bubbleProperties(workInProgress);
0 !== (workInProgress.mode & 2) &&
null !== newProps &&
null !== type &&
((type = workInProgress.child),
null !== type &&
(workInProgress.treeBaseDuration -= type.treeBaseDuration));
@@ -8030,6 +8153,21 @@ function unwindWork(current, workInProgress) {
case 27:
case 5:
return popHostContext(workInProgress), null;
case 31:
if (
null !== workInProgress.memoizedState &&
(popSuspenseHandler(workInProgress), null === workInProgress.alternate)
)
throw Error(
"Threw in newly mounted dehydrated component. This is likely a bug in React. Please file an issue."
);
current = workInProgress.flags;
return current & 65536
? ((workInProgress.flags = (current & -65537) | 128),
0 !== (workInProgress.mode & 2) &&
transferActualDuration(workInProgress),
workInProgress)
: null;
case 13:
popSuspenseHandler(workInProgress);
current = workInProgress.memoizedState;
@@ -8096,6 +8234,10 @@ function unwindInterruptedWork(current, interruptedWork) {
case 4:
popHostContainer();
break;
case 31:
null !== interruptedWork.memoizedState &&
popSuspenseHandler(interruptedWork);
break;
case 13:
popSuspenseHandler(interruptedWork);
break;
@@ -8168,9 +8310,9 @@ function commitHookEffectListMount(flags, finishedWork) {
finishedWork
);
lastEffect = void 0;
var create$127 = updateQueue.create,
var create$133 = updateQueue.create,
inst = updateQueue.inst;
lastEffect = create$127();
lastEffect = create$133();
inst.destroy = lastEffect;
0 !== (flags & 8)
? null !== injectedProfilingHooks &&
@@ -8310,8 +8452,8 @@ function safelyCallComponentWillUnmount(
} else
try {
instance.componentWillUnmount();
} catch (error$131) {
captureCommitPhaseError(current, nearestMountedAncestor, error$131);
} catch (error$137) {
captureCommitPhaseError(current, nearestMountedAncestor, error$137);
}
}
function safelyAttachRef(current, nearestMountedAncestor) {
@@ -8373,8 +8515,8 @@ function safelyDetachRef(current, nearestMountedAncestor) {
recordEffectDuration(current);
}
else ref(null);
} catch (error$132) {
captureCommitPhaseError(current, nearestMountedAncestor, error$132);
} catch (error$138) {
captureCommitPhaseError(current, nearestMountedAncestor, error$138);
}
else ref.current = null;
}
@@ -8609,11 +8751,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
} else
try {
finishedRoot.componentDidMount();
} catch (error$128) {
} catch (error$134) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$128
error$134
);
}
else {
@@ -8630,11 +8772,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$129) {
} catch (error$135) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$129
error$135
);
}
recordEffectDuration();
@@ -8645,11 +8787,11 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
current,
finishedRoot.__reactInternalSnapshotBeforeUpdate
);
} catch (error$130) {
} catch (error$136) {
captureCommitPhaseError(
finishedWork,
finishedWork.return,
error$130
error$136
);
}
}
@@ -8698,6 +8840,9 @@ function commitLayoutEffectOnFiber(finishedRoot, current, finishedWork) {
))
: recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 31:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
break;
case 13:
recursivelyTraverseLayoutEffects(finishedRoot, finishedWork);
flags & 64 &&
@@ -8927,6 +9072,7 @@ function commitDeletionEffectsOnFiber(
}
function getRetryCache(finishedWork) {
switch (finishedWork.tag) {
case 31:
case 13:
case 19:
var retryCache = finishedWork.stateNode;
@@ -9118,6 +9264,15 @@ function commitMutationEffectsOnFiber(finishedWork, root) {
finishedWork.stateNode.effectDuration +=
bubbleNestedEffectDurations(flags);
break;
case 31:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
flags & 4 &&
((flags = finishedWork.updateQueue),
null !== flags &&
((finishedWork.updateQueue = null),
attachSuspenseRetryListeners(finishedWork, flags)));
break;
case 13:
recursivelyTraverseMutationEffects(root, finishedWork);
commitReconciliationEffects(finishedWork);
@@ -9324,12 +9479,12 @@ function commitReconciliationEffects(finishedWork) {
break;
case 3:
case 4:
var parent$133 = hostParentFiber.stateNode.containerInfo,
before$134 = getHostSibling(finishedWork);
var parent$139 = hostParentFiber.stateNode.containerInfo,
before$140 = getHostSibling(finishedWork);
insertOrAppendPlacementNodeIntoContainer(
finishedWork,
before$134,
parent$133
before$140,
parent$139
);
break;
default:
@@ -9485,6 +9640,13 @@ function recursivelyTraverseReappearLayoutEffects(
includeWorkInProgressEffects
);
break;
case 31:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
finishedWork,
includeWorkInProgressEffects
);
break;
case 13:
recursivelyTraverseReappearLayoutEffects(
finishedRoot,
@@ -9636,6 +9798,14 @@ function commitPassiveMountOnFiber(
committedTransitions
);
break;
case 31:
recursivelyTraversePassiveMountEffects(
finishedRoot,
finishedWork,
committedLanes,
committedTransitions
);
break;
case 13:
recursivelyTraversePassiveMountEffects(
finishedRoot,
@@ -10593,8 +10763,8 @@ function renderRootSync(root, lanes, shouldYieldForPrerendering) {
workLoopSync();
memoizedUpdaters = workInProgressRootExitStatus;
break;
} catch (thrownValue$152) {
handleThrow(root, thrownValue$152);
} catch (thrownValue$159) {
handleThrow(root, thrownValue$159);
}
while (1);
lanes && root.shellSuspendCounter++;
@@ -10717,8 +10887,8 @@ function renderRootConcurrent(root, lanes) {
}
workLoopConcurrentByScheduler();
break;
} catch (thrownValue$154) {
handleThrow(root, thrownValue$154);
} catch (thrownValue$161) {
handleThrow(root, thrownValue$161);
}
while (1);
lastContextDependency = currentlyRenderingFiber$1 = null;
@@ -11314,6 +11484,7 @@ function retryDehydratedSuspenseBoundary(boundaryFiber) {
function resolveRetryWakeable(boundaryFiber, wakeable) {
var retryLane = 0;
switch (boundaryFiber.tag) {
case 31:
case 13:
var retryCache = boundaryFiber.stateNode;
var suspenseState = boundaryFiber.memoizedState;
@@ -11725,11 +11896,11 @@ function updateContainer(element, container, parentComponent, callback) {
return lane;
}
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-17f88c80-20250422" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-3ef31d19-20250422" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-17f88c80-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-3ef31d19-20250422\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -11776,20 +11947,20 @@ batchedUpdatesImpl = function (fn, a) {
}
};
var roots = new Map(),
internals$jscomp$inline_1381 = {
internals$jscomp$inline_1399 = {
bundleType: 0,
version: "19.2.0-native-fb-17f88c80-20250422",
version: "19.2.0-native-fb-3ef31d19-20250422",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-17f88c80-20250422"
reconcilerVersion: "19.2.0-native-fb-3ef31d19-20250422"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1381.rendererConfig = extraDevToolsConfig);
internals$jscomp$inline_1381.getLaneLabelMap = function () {
(internals$jscomp$inline_1399.rendererConfig = extraDevToolsConfig);
internals$jscomp$inline_1399.getLaneLabelMap = function () {
for (
var map = new Map(), lane = 1, index$158 = 0;
31 > index$158;
index$158++
var map = new Map(), lane = 1, index$165 = 0;
31 > index$165;
index$165++
) {
var label = getLabelForLane(lane);
map.set(lane, label);
@@ -11797,20 +11968,20 @@ internals$jscomp$inline_1381.getLaneLabelMap = function () {
}
return map;
};
internals$jscomp$inline_1381.injectProfilingHooks = function (profilingHooks) {
internals$jscomp$inline_1399.injectProfilingHooks = function (profilingHooks) {
injectedProfilingHooks = profilingHooks;
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1688 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_1711 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_1688.isDisabled &&
hook$jscomp$inline_1688.supportsFiber
!hook$jscomp$inline_1711.isDisabled &&
hook$jscomp$inline_1711.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_1688.inject(
internals$jscomp$inline_1381
(rendererID = hook$jscomp$inline_1711.inject(
internals$jscomp$inline_1399
)),
(injectedHook = hook$jscomp$inline_1688);
(injectedHook = hook$jscomp$inline_1711);
} catch (err) {}
}
exports.createPortal = function (children, containerTag) {