diff --git a/compiled-rn/VERSION_NATIVE_FB b/compiled-rn/VERSION_NATIVE_FB index 0906d89d0897a..8555dbf861e23 100644 --- a/compiled-rn/VERSION_NATIVE_FB +++ b/compiled-rn/VERSION_NATIVE_FB @@ -1 +1 @@ -19.0.0-native-fb-5c56b873-20241107 \ No newline at end of file +19.0.0-native-fb-989af12f-20241108 \ No newline at end of file diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-dev.js index bf8e1229f4f0f..e361e36d2b0b1 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<5c9a804b7140967367e1adde199edc5b>> + * @generated SignedSource<> */ "use strict"; @@ -420,5 +420,5 @@ __DEV__ && exports.useFormStatus = function () { return resolveDispatcher().useHostTransitionStatus(); }; - exports.version = "19.0.0-native-fb-5c56b873-20241107"; + exports.version = "19.0.0-native-fb-989af12f-20241108"; })(); diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-prod.js index 51294ad179152..0c9aa9a307dce 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactSharedInternals.H.useHostTransitionStatus(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-profiling.js index 51294ad179152..0c9aa9a307dce 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOM-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactSharedInternals.H.useHostTransitionStatus(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-dev.js index a400ee0a3e983..7508090a18226 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<94fea17857c9333f3d426c5d8101ee03>> + * @generated SignedSource<<261a27b186e17869cdcd7a66d14f2fcf>> */ /* @@ -1077,6 +1077,14 @@ __DEV__ && ? wipLanes : nextLanes; } + function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); + } function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -8979,32 +8987,32 @@ __DEV__ && return current; } function updateSuspenseComponent(current, workInProgress, renderLanes) { - var JSCompiler_object_inline_digest_2324; - var JSCompiler_object_inline_stack_2325 = workInProgress.pendingProps; + var JSCompiler_object_inline_digest_2326; + var JSCompiler_object_inline_stack_2327 = workInProgress.pendingProps; shouldSuspendImpl(workInProgress) && (workInProgress.flags |= 128); - var JSCompiler_object_inline_componentStack_2326 = !1; + var JSCompiler_object_inline_componentStack_2328 = !1; var didSuspend = 0 !== (workInProgress.flags & 128); - (JSCompiler_object_inline_digest_2324 = didSuspend) || - (JSCompiler_object_inline_digest_2324 = + (JSCompiler_object_inline_digest_2326 = didSuspend) || + (JSCompiler_object_inline_digest_2326 = null !== current && null === current.memoizedState ? !1 : 0 !== (suspenseStackCursor.current & ForceSuspenseFallback)); - JSCompiler_object_inline_digest_2324 && - ((JSCompiler_object_inline_componentStack_2326 = !0), + JSCompiler_object_inline_digest_2326 && + ((JSCompiler_object_inline_componentStack_2328 = !0), (workInProgress.flags &= -129)); - JSCompiler_object_inline_digest_2324 = 0 !== (workInProgress.flags & 32); + JSCompiler_object_inline_digest_2326 = 0 !== (workInProgress.flags & 32); workInProgress.flags &= -33; if (null === current) { if (isHydrating) { - JSCompiler_object_inline_componentStack_2326 + JSCompiler_object_inline_componentStack_2328 ? pushPrimaryTreeSuspenseHandler(workInProgress) : reuseSuspenseHandlerOnStack(workInProgress); if (isHydrating) { - var JSCompiler_object_inline_message_2323 = nextHydratableInstance; + var JSCompiler_object_inline_message_2325 = nextHydratableInstance; var JSCompiler_temp; - if (!(JSCompiler_temp = !JSCompiler_object_inline_message_2323)) { + if (!(JSCompiler_temp = !JSCompiler_object_inline_message_2325)) { c: { - var instance = JSCompiler_object_inline_message_2323; + var instance = JSCompiler_object_inline_message_2325; for ( JSCompiler_temp = rootOrSingletonContext; 8 !== instance.nodeType; @@ -9045,19 +9053,19 @@ __DEV__ && JSCompiler_temp && (warnNonHydratedInstance( workInProgress, - JSCompiler_object_inline_message_2323 + JSCompiler_object_inline_message_2325 ), throwOnHydrationMismatch(workInProgress)); } - JSCompiler_object_inline_message_2323 = workInProgress.memoizedState; + JSCompiler_object_inline_message_2325 = workInProgress.memoizedState; if ( - null !== JSCompiler_object_inline_message_2323 && - ((JSCompiler_object_inline_message_2323 = - JSCompiler_object_inline_message_2323.dehydrated), - null !== JSCompiler_object_inline_message_2323) + null !== JSCompiler_object_inline_message_2325 && + ((JSCompiler_object_inline_message_2325 = + JSCompiler_object_inline_message_2325.dehydrated), + null !== JSCompiler_object_inline_message_2325) ) return ( - JSCompiler_object_inline_message_2323.data === + JSCompiler_object_inline_message_2325.data === SUSPENSE_FALLBACK_START_DATA ? (workInProgress.lanes = 16) : (workInProgress.lanes = 536870912), @@ -9065,70 +9073,70 @@ __DEV__ && ); popSuspenseHandler(workInProgress); } - JSCompiler_object_inline_message_2323 = - JSCompiler_object_inline_stack_2325.children; - JSCompiler_temp = JSCompiler_object_inline_stack_2325.fallback; - if (JSCompiler_object_inline_componentStack_2326) + JSCompiler_object_inline_message_2325 = + JSCompiler_object_inline_stack_2327.children; + JSCompiler_temp = JSCompiler_object_inline_stack_2327.fallback; + if (JSCompiler_object_inline_componentStack_2328) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_stack_2325 = + (JSCompiler_object_inline_stack_2327 = mountSuspenseFallbackChildren( workInProgress, - JSCompiler_object_inline_message_2323, + JSCompiler_object_inline_message_2325, JSCompiler_temp, renderLanes )), - (JSCompiler_object_inline_componentStack_2326 = + (JSCompiler_object_inline_componentStack_2328 = workInProgress.child), - (JSCompiler_object_inline_componentStack_2326.memoizedState = + (JSCompiler_object_inline_componentStack_2328.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_componentStack_2326.childLanes = + (JSCompiler_object_inline_componentStack_2328.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_stack_2327 ); if ( "number" === - typeof JSCompiler_object_inline_stack_2325.unstable_expectedLoadTime + typeof JSCompiler_object_inline_stack_2327.unstable_expectedLoadTime ) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_stack_2325 = + (JSCompiler_object_inline_stack_2327 = mountSuspenseFallbackChildren( workInProgress, - JSCompiler_object_inline_message_2323, + JSCompiler_object_inline_message_2325, JSCompiler_temp, renderLanes )), - (JSCompiler_object_inline_componentStack_2326 = + (JSCompiler_object_inline_componentStack_2328 = workInProgress.child), - (JSCompiler_object_inline_componentStack_2326.memoizedState = + (JSCompiler_object_inline_componentStack_2328.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_componentStack_2326.childLanes = + (JSCompiler_object_inline_componentStack_2328.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), (workInProgress.lanes = 4194304), - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_stack_2327 ); pushPrimaryTreeSuspenseHandler(workInProgress); return mountSuspensePrimaryChildren( workInProgress, - JSCompiler_object_inline_message_2323 + JSCompiler_object_inline_message_2325 ); } var prevState = current.memoizedState; if ( null !== prevState && - ((JSCompiler_object_inline_message_2323 = prevState.dehydrated), - null !== JSCompiler_object_inline_message_2323) + ((JSCompiler_object_inline_message_2325 = prevState.dehydrated), + null !== JSCompiler_object_inline_message_2325) ) { if (didSuspend) workInProgress.flags & 256 @@ -9145,32 +9153,32 @@ __DEV__ && (workInProgress.flags |= 128), (workInProgress = null)) : (reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_componentStack_2326 = - JSCompiler_object_inline_stack_2325.fallback), - (JSCompiler_object_inline_message_2323 = workInProgress.mode), - (JSCompiler_object_inline_stack_2325 = createFiberFromOffscreen( + (JSCompiler_object_inline_componentStack_2328 = + JSCompiler_object_inline_stack_2327.fallback), + (JSCompiler_object_inline_message_2325 = workInProgress.mode), + (JSCompiler_object_inline_stack_2327 = createFiberFromOffscreen( { mode: "visible", - children: JSCompiler_object_inline_stack_2325.children + children: JSCompiler_object_inline_stack_2327.children }, - JSCompiler_object_inline_message_2323, + JSCompiler_object_inline_message_2325, 0, null )), - (JSCompiler_object_inline_componentStack_2326 = + (JSCompiler_object_inline_componentStack_2328 = createFiberFromFragment( - JSCompiler_object_inline_componentStack_2326, - JSCompiler_object_inline_message_2323, + JSCompiler_object_inline_componentStack_2328, + JSCompiler_object_inline_message_2325, renderLanes, null )), - (JSCompiler_object_inline_componentStack_2326.flags |= 2), - (JSCompiler_object_inline_stack_2325.return = workInProgress), - (JSCompiler_object_inline_componentStack_2326.return = + (JSCompiler_object_inline_componentStack_2328.flags |= 2), + (JSCompiler_object_inline_stack_2327.return = workInProgress), + (JSCompiler_object_inline_componentStack_2328.return = workInProgress), - (JSCompiler_object_inline_stack_2325.sibling = - JSCompiler_object_inline_componentStack_2326), - (workInProgress.child = JSCompiler_object_inline_stack_2325), + (JSCompiler_object_inline_stack_2327.sibling = + JSCompiler_object_inline_componentStack_2328), + (workInProgress.child = JSCompiler_object_inline_stack_2327), (workInProgress.mode & ConcurrentMode) !== NoMode && reconcileChildFibers( workInProgress, @@ -9178,64 +9186,64 @@ __DEV__ && null, renderLanes ), - (JSCompiler_object_inline_stack_2325 = workInProgress.child), - (JSCompiler_object_inline_stack_2325.memoizedState = + (JSCompiler_object_inline_stack_2327 = workInProgress.child), + (JSCompiler_object_inline_stack_2327.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_stack_2325.childLanes = + (JSCompiler_object_inline_stack_2327.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), (workInProgress = - JSCompiler_object_inline_componentStack_2326)); + JSCompiler_object_inline_componentStack_2328)); else if ( (pushPrimaryTreeSuspenseHandler(workInProgress), isHydrating && error$jscomp$0( "We should not be hydrating here. This is a bug in React. Please file a bug." ), - JSCompiler_object_inline_message_2323.data === + JSCompiler_object_inline_message_2325.data === SUSPENSE_FALLBACK_START_DATA) ) { - JSCompiler_object_inline_digest_2324 = - JSCompiler_object_inline_message_2323.nextSibling && - JSCompiler_object_inline_message_2323.nextSibling.dataset; - if (JSCompiler_object_inline_digest_2324) { - JSCompiler_temp = JSCompiler_object_inline_digest_2324.dgst; - var message = JSCompiler_object_inline_digest_2324.msg; - instance = JSCompiler_object_inline_digest_2324.stck; - var componentStack = JSCompiler_object_inline_digest_2324.cstck; + JSCompiler_object_inline_digest_2326 = + JSCompiler_object_inline_message_2325.nextSibling && + JSCompiler_object_inline_message_2325.nextSibling.dataset; + if (JSCompiler_object_inline_digest_2326) { + JSCompiler_temp = JSCompiler_object_inline_digest_2326.dgst; + var message = JSCompiler_object_inline_digest_2326.msg; + instance = JSCompiler_object_inline_digest_2326.stck; + var componentStack = JSCompiler_object_inline_digest_2326.cstck; } - JSCompiler_object_inline_message_2323 = message; - JSCompiler_object_inline_digest_2324 = JSCompiler_temp; - JSCompiler_object_inline_stack_2325 = instance; - JSCompiler_temp = JSCompiler_object_inline_componentStack_2326 = + JSCompiler_object_inline_message_2325 = message; + JSCompiler_object_inline_digest_2326 = JSCompiler_temp; + JSCompiler_object_inline_stack_2327 = instance; + JSCompiler_temp = JSCompiler_object_inline_componentStack_2328 = componentStack; - JSCompiler_object_inline_componentStack_2326 = - JSCompiler_object_inline_message_2323 - ? Error(JSCompiler_object_inline_message_2323) + JSCompiler_object_inline_componentStack_2328 = + JSCompiler_object_inline_message_2325 + ? Error(JSCompiler_object_inline_message_2325) : Error( "The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering." ); - JSCompiler_object_inline_componentStack_2326.stack = - JSCompiler_object_inline_stack_2325 || ""; - JSCompiler_object_inline_componentStack_2326.digest = - JSCompiler_object_inline_digest_2324; - JSCompiler_object_inline_digest_2324 = + JSCompiler_object_inline_componentStack_2328.stack = + JSCompiler_object_inline_stack_2327 || ""; + JSCompiler_object_inline_componentStack_2328.digest = + JSCompiler_object_inline_digest_2326; + JSCompiler_object_inline_digest_2326 = void 0 === JSCompiler_temp ? null : JSCompiler_temp; - JSCompiler_object_inline_stack_2325 = { - value: JSCompiler_object_inline_componentStack_2326, + JSCompiler_object_inline_stack_2327 = { + value: JSCompiler_object_inline_componentStack_2328, source: null, - stack: JSCompiler_object_inline_digest_2324 + stack: JSCompiler_object_inline_digest_2326 }; - "string" === typeof JSCompiler_object_inline_digest_2324 && + "string" === typeof JSCompiler_object_inline_digest_2326 && CapturedStacks.set( - JSCompiler_object_inline_componentStack_2326, - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_componentStack_2328, + JSCompiler_object_inline_stack_2327 ); - queueHydrationError(JSCompiler_object_inline_stack_2325); + queueHydrationError(JSCompiler_object_inline_stack_2327); workInProgress = retrySuspenseComponentWithoutHydrating( current, workInProgress, @@ -9249,25 +9257,25 @@ __DEV__ && renderLanes, !1 ), - (JSCompiler_object_inline_digest_2324 = + (JSCompiler_object_inline_digest_2326 = 0 !== (renderLanes & current.childLanes)), - didReceiveUpdate || JSCompiler_object_inline_digest_2324) + didReceiveUpdate || JSCompiler_object_inline_digest_2326) ) { - JSCompiler_object_inline_digest_2324 = workInProgressRoot; - if (null !== JSCompiler_object_inline_digest_2324) { - JSCompiler_object_inline_stack_2325 = renderLanes & -renderLanes; - if (0 !== (JSCompiler_object_inline_stack_2325 & 42)) - JSCompiler_object_inline_stack_2325 = 1; + JSCompiler_object_inline_digest_2326 = workInProgressRoot; + if (null !== JSCompiler_object_inline_digest_2326) { + JSCompiler_object_inline_stack_2327 = renderLanes & -renderLanes; + if (0 !== (JSCompiler_object_inline_stack_2327 & 42)) + JSCompiler_object_inline_stack_2327 = 1; else - switch (JSCompiler_object_inline_stack_2325) { + switch (JSCompiler_object_inline_stack_2327) { case 2: - JSCompiler_object_inline_stack_2325 = 1; + JSCompiler_object_inline_stack_2327 = 1; break; case 8: - JSCompiler_object_inline_stack_2325 = 4; + JSCompiler_object_inline_stack_2327 = 4; break; case 32: - JSCompiler_object_inline_stack_2325 = 16; + JSCompiler_object_inline_stack_2327 = 16; break; case 128: case 256: @@ -9288,40 +9296,40 @@ __DEV__ && case 8388608: case 16777216: case 33554432: - JSCompiler_object_inline_stack_2325 = 64; + JSCompiler_object_inline_stack_2327 = 64; break; case 268435456: - JSCompiler_object_inline_stack_2325 = 134217728; + JSCompiler_object_inline_stack_2327 = 134217728; break; default: - JSCompiler_object_inline_stack_2325 = 0; + JSCompiler_object_inline_stack_2327 = 0; } - JSCompiler_object_inline_stack_2325 = + JSCompiler_object_inline_stack_2327 = 0 !== - (JSCompiler_object_inline_stack_2325 & - (JSCompiler_object_inline_digest_2324.suspendedLanes | + (JSCompiler_object_inline_stack_2327 & + (JSCompiler_object_inline_digest_2326.suspendedLanes | renderLanes)) ? 0 - : JSCompiler_object_inline_stack_2325; + : JSCompiler_object_inline_stack_2327; if ( - 0 !== JSCompiler_object_inline_stack_2325 && - JSCompiler_object_inline_stack_2325 !== prevState.retryLane + 0 !== JSCompiler_object_inline_stack_2327 && + JSCompiler_object_inline_stack_2327 !== prevState.retryLane ) throw ( - ((prevState.retryLane = JSCompiler_object_inline_stack_2325), + ((prevState.retryLane = JSCompiler_object_inline_stack_2327), enqueueConcurrentRenderForLane( current, - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_stack_2327 ), scheduleUpdateOnFiber( - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326, current, - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_stack_2327 ), SelectiveHydrationException) ); } - JSCompiler_object_inline_message_2323.data === + JSCompiler_object_inline_message_2325.data === SUSPENSE_PENDING_START_DATA || renderDidSuspendDelayIfPossible(); workInProgress = retrySuspenseComponentWithoutHydrating( current, @@ -9329,7 +9337,7 @@ __DEV__ && renderLanes ); } else - JSCompiler_object_inline_message_2323.data === + JSCompiler_object_inline_message_2325.data === SUSPENSE_PENDING_START_DATA ? ((workInProgress.flags |= 128), (workInProgress.child = current.child), @@ -9337,12 +9345,12 @@ __DEV__ && null, current )), - (JSCompiler_object_inline_message_2323._reactRetry = + (JSCompiler_object_inline_message_2325._reactRetry = workInProgress), (workInProgress = null)) : ((renderLanes = prevState.treeContext), (nextHydratableInstance = getNextHydratable( - JSCompiler_object_inline_message_2323.nextSibling + JSCompiler_object_inline_message_2325.nextSibling )), (hydrationParentFiber = workInProgress), (isHydrating = !0), @@ -9360,72 +9368,72 @@ __DEV__ && (treeContextProvider = workInProgress)), (workInProgress = mountSuspensePrimaryChildren( workInProgress, - JSCompiler_object_inline_stack_2325.children + JSCompiler_object_inline_stack_2327.children )), (workInProgress.flags |= 4096)); return workInProgress; } - if (JSCompiler_object_inline_componentStack_2326) + if (JSCompiler_object_inline_componentStack_2328) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_componentStack_2326 = - JSCompiler_object_inline_stack_2325.fallback), - (JSCompiler_object_inline_message_2323 = workInProgress.mode), + (JSCompiler_object_inline_componentStack_2328 = + JSCompiler_object_inline_stack_2327.fallback), + (JSCompiler_object_inline_message_2325 = workInProgress.mode), (JSCompiler_temp = current.child), (instance = JSCompiler_temp.sibling), (componentStack = { mode: "hidden", - children: JSCompiler_object_inline_stack_2325.children + children: JSCompiler_object_inline_stack_2327.children }), - (JSCompiler_object_inline_message_2323 & ConcurrentMode) === NoMode && + (JSCompiler_object_inline_message_2325 & ConcurrentMode) === NoMode && workInProgress.child !== JSCompiler_temp - ? ((JSCompiler_object_inline_stack_2325 = workInProgress.child), - (JSCompiler_object_inline_stack_2325.childLanes = 0), - (JSCompiler_object_inline_stack_2325.pendingProps = + ? ((JSCompiler_object_inline_stack_2327 = workInProgress.child), + (JSCompiler_object_inline_stack_2327.childLanes = 0), + (JSCompiler_object_inline_stack_2327.pendingProps = componentStack), workInProgress.mode & ProfileMode && - ((JSCompiler_object_inline_stack_2325.actualDuration = -0), - (JSCompiler_object_inline_stack_2325.actualStartTime = -1.1), - (JSCompiler_object_inline_stack_2325.selfBaseDuration = + ((JSCompiler_object_inline_stack_2327.actualDuration = -0), + (JSCompiler_object_inline_stack_2327.actualStartTime = -1.1), + (JSCompiler_object_inline_stack_2327.selfBaseDuration = JSCompiler_temp.selfBaseDuration), - (JSCompiler_object_inline_stack_2325.treeBaseDuration = + (JSCompiler_object_inline_stack_2327.treeBaseDuration = JSCompiler_temp.treeBaseDuration)), (workInProgress.deletions = null)) - : ((JSCompiler_object_inline_stack_2325 = createWorkInProgress( + : ((JSCompiler_object_inline_stack_2327 = createWorkInProgress( JSCompiler_temp, componentStack )), - (JSCompiler_object_inline_stack_2325.subtreeFlags = + (JSCompiler_object_inline_stack_2327.subtreeFlags = JSCompiler_temp.subtreeFlags & 31457280)), null !== instance - ? (JSCompiler_object_inline_componentStack_2326 = + ? (JSCompiler_object_inline_componentStack_2328 = createWorkInProgress( instance, - JSCompiler_object_inline_componentStack_2326 + JSCompiler_object_inline_componentStack_2328 )) - : ((JSCompiler_object_inline_componentStack_2326 = + : ((JSCompiler_object_inline_componentStack_2328 = createFiberFromFragment( - JSCompiler_object_inline_componentStack_2326, - JSCompiler_object_inline_message_2323, + JSCompiler_object_inline_componentStack_2328, + JSCompiler_object_inline_message_2325, renderLanes, null )), - (JSCompiler_object_inline_componentStack_2326.flags |= 2)), - (JSCompiler_object_inline_componentStack_2326.return = + (JSCompiler_object_inline_componentStack_2328.flags |= 2)), + (JSCompiler_object_inline_componentStack_2328.return = workInProgress), - (JSCompiler_object_inline_stack_2325.return = workInProgress), - (JSCompiler_object_inline_stack_2325.sibling = - JSCompiler_object_inline_componentStack_2326), - (workInProgress.child = JSCompiler_object_inline_stack_2325), - (JSCompiler_object_inline_stack_2325 = - JSCompiler_object_inline_componentStack_2326), - (JSCompiler_object_inline_componentStack_2326 = workInProgress.child), - (JSCompiler_object_inline_message_2323 = current.child.memoizedState), - null === JSCompiler_object_inline_message_2323 - ? (JSCompiler_object_inline_message_2323 = + (JSCompiler_object_inline_stack_2327.return = workInProgress), + (JSCompiler_object_inline_stack_2327.sibling = + JSCompiler_object_inline_componentStack_2328), + (workInProgress.child = JSCompiler_object_inline_stack_2327), + (JSCompiler_object_inline_stack_2327 = + JSCompiler_object_inline_componentStack_2328), + (JSCompiler_object_inline_componentStack_2328 = workInProgress.child), + (JSCompiler_object_inline_message_2325 = current.child.memoizedState), + null === JSCompiler_object_inline_message_2325 + ? (JSCompiler_object_inline_message_2325 = mountSuspenseOffscreenState(renderLanes)) : ((JSCompiler_temp = - JSCompiler_object_inline_message_2323.cachePool), + JSCompiler_object_inline_message_2325.cachePool), null !== JSCompiler_temp ? ((instance = CacheContext._currentValue), (JSCompiler_temp = @@ -9433,45 +9441,45 @@ __DEV__ && ? { parent: instance, pool: instance } : JSCompiler_temp)) : (JSCompiler_temp = getSuspendedCache()), - (JSCompiler_object_inline_message_2323 = { + (JSCompiler_object_inline_message_2325 = { baseLanes: - JSCompiler_object_inline_message_2323.baseLanes | renderLanes, + JSCompiler_object_inline_message_2325.baseLanes | renderLanes, cachePool: JSCompiler_temp })), - (JSCompiler_object_inline_componentStack_2326.memoizedState = - JSCompiler_object_inline_message_2323), - (JSCompiler_object_inline_componentStack_2326.childLanes = + (JSCompiler_object_inline_componentStack_2328.memoizedState = + JSCompiler_object_inline_message_2325), + (JSCompiler_object_inline_componentStack_2328.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), - JSCompiler_object_inline_stack_2325 + JSCompiler_object_inline_stack_2327 ); pushPrimaryTreeSuspenseHandler(workInProgress); - JSCompiler_object_inline_digest_2324 = current.child; - current = JSCompiler_object_inline_digest_2324.sibling; - JSCompiler_object_inline_digest_2324 = createWorkInProgress( - JSCompiler_object_inline_digest_2324, + JSCompiler_object_inline_digest_2326 = current.child; + current = JSCompiler_object_inline_digest_2326.sibling; + JSCompiler_object_inline_digest_2326 = createWorkInProgress( + JSCompiler_object_inline_digest_2326, { mode: "visible", - children: JSCompiler_object_inline_stack_2325.children + children: JSCompiler_object_inline_stack_2327.children } ); (workInProgress.mode & ConcurrentMode) === NoMode && - (JSCompiler_object_inline_digest_2324.lanes = renderLanes); - JSCompiler_object_inline_digest_2324.return = workInProgress; - JSCompiler_object_inline_digest_2324.sibling = null; + (JSCompiler_object_inline_digest_2326.lanes = renderLanes); + JSCompiler_object_inline_digest_2326.return = workInProgress; + JSCompiler_object_inline_digest_2326.sibling = null; null !== current && ((renderLanes = workInProgress.deletions), null === renderLanes ? ((workInProgress.deletions = [current]), (workInProgress.flags |= 16)) : renderLanes.push(current)); - workInProgress.child = JSCompiler_object_inline_digest_2324; + workInProgress.child = JSCompiler_object_inline_digest_2326; workInProgress.memoizedState = null; - return JSCompiler_object_inline_digest_2324; + return JSCompiler_object_inline_digest_2326; } function mountSuspensePrimaryChildren(workInProgress, primaryChildren) { primaryChildren = createFiberFromOffscreen( @@ -14950,7 +14958,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if ( @@ -14993,7 +15001,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 !== lane || @@ -15006,191 +15014,195 @@ __DEV__ && function performWorkOnRoot(root, lanes, forceSync) { if ((executionContext & (RenderContext | CommitContext)) !== NoContext) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && 0 === (lanes & 60) && 0 === (lanes & root.expiredLanes)) - ? renderRootConcurrent(root, lanes) - : renderRootSync(root, lanes); - if (exitStatus !== RootInProgress) { - var renderWasConcurrent = forceSync; - do { - if (exitStatus === RootDidNotComplete) - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root.tag && exitStatus === RootErrored) { - renderWasConcurrent = lanes; - if (root.errorRecoveryDisabledLanes & renderWasConcurrent) - var errorRetryLanes = 0; - else - (errorRetryLanes = root.pendingLanes & -536870913), - (errorRetryLanes = - 0 !== errorRetryLanes - ? errorRetryLanes - : errorRetryLanes & 536870912 - ? 536870912 - : 0); - if (0 !== errorRetryLanes) { - lanes = errorRetryLanes; - a: { - exitStatus = root; - var errorRetryLanes$jscomp$0 = errorRetryLanes; - errorRetryLanes = workInProgressRootConcurrentErrors; - var wasRootDehydrated = - exitStatus.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack( - exitStatus, - errorRetryLanes$jscomp$0 - ).flags |= 256); - errorRetryLanes$jscomp$0 = renderRootSync( + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root.expiredLanes)) || + (enableSiblingPrerendering && checkIfRootIsPrerendering(root, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root, lanes) + : renderRootSync(root, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (exitStatus === RootInProgress) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root, lanes, 0, !1); + break; + } else if (exitStatus === RootDidNotComplete) + markRootSuspended( + root, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root.tag && exitStatus === RootErrored) { + renderWasConcurrent = lanes; + if (root.errorRecoveryDisabledLanes & renderWasConcurrent) + var errorRetryLanes = 0; + else + (errorRetryLanes = root.pendingLanes & -536870913), + (errorRetryLanes = + 0 !== errorRetryLanes + ? errorRetryLanes + : errorRetryLanes & 536870912 + ? 536870912 + : 0); + if (0 !== errorRetryLanes) { + lanes = errorRetryLanes; + a: { + exitStatus = root; + var errorRetryLanes$jscomp$0 = errorRetryLanes; + errorRetryLanes = workInProgressRootConcurrentErrors; + var wasRootDehydrated = + exitStatus.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack( exitStatus, errorRetryLanes$jscomp$0 - ); - if (errorRetryLanes$jscomp$0 !== RootErrored) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - exitStatus.errorRecoveryDisabledLanes |= - renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = RootSuspendedWithDelay; - break a; - } - exitStatus = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = errorRetryLanes; - null !== exitStatus && queueRecoverableErrors(exitStatus); + ).flags |= 256); + errorRetryLanes$jscomp$0 = renderRootSync( + exitStatus, + errorRetryLanes$jscomp$0, + !1 + ); + if (errorRetryLanes$jscomp$0 !== RootErrored) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + exitStatus.errorRecoveryDisabledLanes |= + renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = RootSuspendedWithDelay; + break a; } - exitStatus = errorRetryLanes$jscomp$0; + exitStatus = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = errorRetryLanes; + null !== exitStatus && queueRecoverableErrors(exitStatus); } - renderWasConcurrent = !1; - if (exitStatus !== RootErrored) continue; + exitStatus = errorRetryLanes$jscomp$0; } + renderWasConcurrent = !1; + if (exitStatus !== RootErrored) continue; } - if (exitStatus === RootFatalErrored) { - prepareFreshStack(root, 0); - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - break; - } - a: { - renderWasConcurrent = root; - switch (exitStatus) { - case RootInProgress: - case RootFatalErrored: - throw Error("Root did not complete. This is a bug in React."); - case RootSuspendedWithDelay: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case RootErrored: - workInProgressRootRecoverableErrors = null; - break; - case RootSuspended: - case RootCompleted: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if (null !== ReactSharedInternals.actQueue) - commitRoot( - renderWasConcurrent, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - IMMEDIATE_COMMIT, - renderStartTime, - 0 - ); - else { - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || exitStatus === RootSuspended) && - ((exitStatus = - globalMostRecentFallbackTime + - FALLBACK_THROTTLE_MS - - now$1()), - 10 < exitStatus) - ) { + } + if (exitStatus === RootFatalErrored) { + prepareFreshStack(root, 0); + markRootSuspended(root, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root; + switch (exitStatus) { + case RootInProgress: + case RootFatalErrored: + throw Error("Root did not complete. This is a bug in React."); + case RootSuspendedWithDelay: + if ((lanes & 4194176) === lanes) { markRootSuspended( - renderWasConcurrent, + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - THROTTLED_COMMIT, - renderStartTime, - 0 - ), - exitStatus + !workInProgressRootDidSkipSuspendedSiblings ); break a; } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, + break; + case RootErrored: + workInProgressRootRecoverableErrors = null; + break; + case RootSuspended: + case RootCompleted: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if (null !== ReactSharedInternals.actQueue) + commitRoot( + shouldTimeSlice, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + IMMEDIATE_COMMIT, + renderStartTime, + 0 + ); + else { + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || exitStatus === RootSuspended) && + ((exitStatus = + globalMostRecentFallbackTime + + FALLBACK_THROTTLE_MS - + now$1()), + 10 < exitStatus) + ) { + markRootSuspended( + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - IMMEDIATE_COMMIT, - renderStartTime, - 0 + !workInProgressRootDidSkipSuspendedSiblings ); + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + THROTTLED_COMMIT, + renderStartTime, + 0 + ), + exitStatus + ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + IMMEDIATE_COMMIT, + renderStartTime, + 0 + ); } } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root); } function queueRecoverableErrors(errors) { @@ -15239,7 +15251,12 @@ __DEV__ && completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended( + root, + lanes, + spawnedLane, + !didSkipSuspendedSiblings + ); return; } commitRoot( @@ -15293,20 +15310,20 @@ __DEV__ && root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index = 31 - clz32(lanes), lane = 1 << index; - didSkipSuspendedSiblings[index] = -1; + didAttemptEntireTree[index] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -15350,11 +15367,7 @@ __DEV__ && workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressRootExitStatus = RootInProgress; workInProgressSuspendedRetryLanes = @@ -15477,7 +15490,9 @@ __DEV__ && function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = RootSuspendedWithDelay; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -15486,10 +15501,10 @@ __DEV__ && workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } - function renderRootSync(root, lanes) { + function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(), @@ -15510,37 +15525,46 @@ __DEV__ && } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if ( workInProgressSuspendedReason !== NotSuspended && null !== workInProgress ) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case SuspendedOnHydration: resetWorkInProgressStack(); - workInProgressRootExitStatus = RootDidNotComplete; + memoizedUpdaters = RootDidNotComplete; break a; case SuspendedOnImmediate: case SuspendedOnData: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case SuspendedOnDeprecatedThrowPromise: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; - throwAndUnwindWorkLoop( - root, - memoizedUpdaters, - thrownValue, - reason - ); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = RootInProgress; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = NotSuspended), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; } catch (thrownValue$42) { handleThrow(root, thrownValue$42); @@ -15551,15 +15575,12 @@ __DEV__ && executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -15584,12 +15605,10 @@ __DEV__ && workInProgressRootRenderTargetTime = now$1() + RENDER_TIMEOUT_MS; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + ); markRenderStarted(lanes); a: do try { @@ -16560,7 +16579,8 @@ __DEV__ && root, root === workInProgressRoot ? nextLanes : 0 )), - 0 !== (nextLanes & 3) && + 0 === (nextLanes & 3) || + checkIfRootIsPrerendering(root, nextLanes) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, nextLanes)); root = root.next; @@ -16634,45 +16654,46 @@ __DEV__ && (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && cancelCallback(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; if ( - currentTime !== root.callbackPriority || - (null !== ReactSharedInternals.actQueue && - pingedLanes !== fakeActCallbackNode) - ) - cancelCallback(pingedLanes); - else return currentTime; - switch (lanesToEventPriority(suspendedLanes)) { - case DiscreteEventPriority: - suspendedLanes = ImmediatePriority; - break; - case ContinuousEventPriority: - suspendedLanes = UserBlockingPriority; - break; - case DefaultEventPriority: - suspendedLanes = NormalPriority$1; - break; - case IdleEventPriority: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - null !== ReactSharedInternals.actQueue - ? (ReactSharedInternals.actQueue.push(pingedLanes), - (suspendedLanes = fakeActCallbackNode)) - : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if ( + currentTime !== root.callbackPriority || + (null !== ReactSharedInternals.actQueue && + pingedLanes !== fakeActCallbackNode) + ) + cancelCallback(pingedLanes); + else return currentTime; + switch (lanesToEventPriority(suspendedLanes)) { + case DiscreteEventPriority: + case ContinuousEventPriority: + suspendedLanes = UserBlockingPriority; + break; + case DefaultEventPriority: + suspendedLanes = NormalPriority$1; + break; + case IdleEventPriority: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + null !== ReactSharedInternals.actQueue + ? (ReactSharedInternals.actQueue.push(pingedLanes), + (suspendedLanes = fakeActCallbackNode)) + : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && cancelCallback(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -25330,11 +25351,11 @@ __DEV__ && }; (function () { var isomorphicReactPackageVersion = React.version; - if ("19.0.0-native-fb-5c56b873-20241107" !== isomorphicReactPackageVersion) + if ("19.0.0-native-fb-989af12f-20241108" !== isomorphicReactPackageVersion) throw Error( 'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' + (isomorphicReactPackageVersion + - "\n - react-dom: 19.0.0-native-fb-5c56b873-20241107\nLearn more: https://react.dev/warnings/version-mismatch") + "\n - react-dom: 19.0.0-native-fb-989af12f-20241108\nLearn more: https://react.dev/warnings/version-mismatch") ); })(); ("function" === typeof Map && @@ -25371,11 +25392,11 @@ __DEV__ && !(function () { var internals = { bundleType: 1, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; internals.overrideHookState = overrideHookState; internals.overrideHookStateDeletePath = overrideHookStateDeletePath; @@ -25519,5 +25540,5 @@ __DEV__ && listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; - exports.version = "19.0.0-native-fb-5c56b873-20241107"; + exports.version = "19.0.0-native-fb-989af12f-20241108"; })(); diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-prod.js index 0c9e465a8df92..b771bb3211244 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<97be0d694c4e259ac6b44ee1dc9e92f0>> */ /* @@ -703,6 +703,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2063,19 +2071,19 @@ function getTargetInstForChangeEvent(domEventName, targetInst) { } var isInputEventSupported = !1; if (canUseDOM) { - var JSCompiler_inline_result$jscomp$289; + var JSCompiler_inline_result$jscomp$294; if (canUseDOM) { - var isSupported$jscomp$inline_422 = "oninput" in document; - if (!isSupported$jscomp$inline_422) { - var element$jscomp$inline_423 = document.createElement("div"); - element$jscomp$inline_423.setAttribute("oninput", "return;"); - isSupported$jscomp$inline_422 = - "function" === typeof element$jscomp$inline_423.oninput; + var isSupported$jscomp$inline_427 = "oninput" in document; + if (!isSupported$jscomp$inline_427) { + var element$jscomp$inline_428 = document.createElement("div"); + element$jscomp$inline_428.setAttribute("oninput", "return;"); + isSupported$jscomp$inline_427 = + "function" === typeof element$jscomp$inline_428.oninput; } - JSCompiler_inline_result$jscomp$289 = isSupported$jscomp$inline_422; - } else JSCompiler_inline_result$jscomp$289 = !1; + JSCompiler_inline_result$jscomp$294 = isSupported$jscomp$inline_427; + } else JSCompiler_inline_result$jscomp$294 = !1; isInputEventSupported = - JSCompiler_inline_result$jscomp$289 && + JSCompiler_inline_result$jscomp$294 && (!document.documentMode || 9 < document.documentMode); } function stopWatchingForValueChange() { @@ -10770,7 +10778,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -10782,7 +10790,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -10793,172 +10801,174 @@ function scheduleUpdateOnFiber(root, fiber, lane) { } function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327)); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - var wasRootDehydrated = root.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack(root, JSCompiler_inline_result).flags |= - 256); - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + var wasRootDehydrated = root.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack(root, JSCompiler_inline_result).flags |= 256); + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error(formatProdErrorMessage(345)); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error(formatProdErrorMessage(329)); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error(formatProdErrorMessage(345)); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error(formatProdErrorMessage(329)); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -11007,7 +11017,7 @@ function commitRootWhenReady( completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended(root, lanes, spawnedLane, !didSkipSuspendedSiblings); return; } commitRoot( @@ -11061,20 +11071,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$6 = 31 - clz32(lanes), lane = 1 << index$6; - didSkipSuspendedSiblings[index$6] = -1; + didAttemptEntireTree[index$6] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -11118,9 +11128,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -11208,7 +11216,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -11217,10 +11227,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -11228,6 +11238,7 @@ function renderRootSync(root, lanes) { if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -11236,24 +11247,37 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + exitStatus = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$170) { - handleThrow(root, thrownValue$170); + } catch (thrownValue$175) { + handleThrow(root, thrownValue$175); } while (1); lanes && root.shellSuspendCounter++; @@ -11261,11 +11285,11 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) throw Error(formatProdErrorMessage(261)); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -11279,12 +11303,10 @@ function renderRootConcurrent(root, lanes) { ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), prepareFreshStack(root, lanes)) - : workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + : (workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + )); a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -11368,8 +11390,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$172) { - handleThrow(root, thrownValue$172); + } catch (thrownValue$177) { + handleThrow(root, thrownValue$177); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -11687,7 +11709,7 @@ function releaseRootPooledCache(root, remainingLanes) { } function flushPassiveEffects() { if (null !== rootWithPendingPassiveEffects) { - var root$176 = rootWithPendingPassiveEffects, + var root$181 = rootWithPendingPassiveEffects, remainingLanes = pendingPassiveEffectsRemainingLanes; pendingPassiveEffectsRemainingLanes = 0; var renderPriority = lanesToEventPriority(pendingPassiveEffectsLanes), @@ -11726,7 +11748,7 @@ function flushPassiveEffects() { } finally { (ReactDOMSharedInternals.p = previousPriority), (ReactSharedInternals.T = prevTransition), - releaseRootPooledCache(root$176, remainingLanes); + releaseRootPooledCache(root$181, remainingLanes); } } return !1; @@ -11870,14 +11892,14 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { isFlushingWork = !0; do { var didPerformSomeWork = !1; - for (var root$178 = firstScheduledRoot; null !== root$178; ) { - if (!onlyLegacy || 0 === root$178.tag) + for (var root$183 = firstScheduledRoot; null !== root$183; ) { + if (!onlyLegacy || 0 === root$183.tag) if (0 !== syncTransitionLanes) { - var pendingLanes = root$178.pendingLanes; + var pendingLanes = root$183.pendingLanes; if (0 === pendingLanes) var JSCompiler_inline_result = 0; else { - var suspendedLanes = root$178.suspendedLanes, - pingedLanes = root$178.pingedLanes; + var suspendedLanes = root$183.suspendedLanes, + pingedLanes = root$183.pingedLanes; JSCompiler_inline_result = (1 << (31 - clz32(42 | syncTransitionLanes) + 1)) - 1; JSCompiler_inline_result &= @@ -11891,17 +11913,18 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { } 0 !== JSCompiler_inline_result && ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$178, JSCompiler_inline_result)); + performSyncWorkOnRoot(root$183, JSCompiler_inline_result)); } else (JSCompiler_inline_result = workInProgressRootRenderLanes), (JSCompiler_inline_result = getNextLanes( - root$178, - root$178 === workInProgressRoot ? JSCompiler_inline_result : 0 + root$183, + root$183 === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root$183, JSCompiler_inline_result) || ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$178, JSCompiler_inline_result)); - root$178 = root$178.next; + performSyncWorkOnRoot(root$183, JSCompiler_inline_result)); + root$183 = root$183.next; } } while (didPerformSomeWork); isFlushingWork = !1; @@ -11970,39 +11993,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { var originalCallbackNode = root.callbackNode; @@ -12131,20 +12153,20 @@ function extractEvents$1( } } for ( - var i$jscomp$inline_1448 = 0; - i$jscomp$inline_1448 < simpleEventPluginEvents.length; - i$jscomp$inline_1448++ + var i$jscomp$inline_1455 = 0; + i$jscomp$inline_1455 < simpleEventPluginEvents.length; + i$jscomp$inline_1455++ ) { - var eventName$jscomp$inline_1449 = - simpleEventPluginEvents[i$jscomp$inline_1448], - domEventName$jscomp$inline_1450 = - eventName$jscomp$inline_1449.toLowerCase(), - capitalizedEvent$jscomp$inline_1451 = - eventName$jscomp$inline_1449[0].toUpperCase() + - eventName$jscomp$inline_1449.slice(1); + var eventName$jscomp$inline_1456 = + simpleEventPluginEvents[i$jscomp$inline_1455], + domEventName$jscomp$inline_1457 = + eventName$jscomp$inline_1456.toLowerCase(), + capitalizedEvent$jscomp$inline_1458 = + eventName$jscomp$inline_1456[0].toUpperCase() + + eventName$jscomp$inline_1456.slice(1); registerSimpleEvent( - domEventName$jscomp$inline_1450, - "on" + capitalizedEvent$jscomp$inline_1451 + domEventName$jscomp$inline_1457, + "on" + capitalizedEvent$jscomp$inline_1458 ); } registerSimpleEvent(ANIMATION_END, "onAnimationEnd"); @@ -13327,34 +13349,34 @@ function setInitialProperties(domElement, tag, props) { defaultChecked = null; for (hasSrc in props) if (props.hasOwnProperty(hasSrc)) { - var propValue$192 = props[hasSrc]; - if (null != propValue$192) + var propValue$197 = props[hasSrc]; + if (null != propValue$197) switch (hasSrc) { case "name": - hasSrcSet = propValue$192; + hasSrcSet = propValue$197; break; case "type": - propValue = propValue$192; + propValue = propValue$197; break; case "checked": - checked = propValue$192; + checked = propValue$197; break; case "defaultChecked": - defaultChecked = propValue$192; + defaultChecked = propValue$197; break; case "value": - propKey = propValue$192; + propKey = propValue$197; break; case "defaultValue": - defaultValue = propValue$192; + defaultValue = propValue$197; break; case "children": case "dangerouslySetInnerHTML": - if (null != propValue$192) + if (null != propValue$197) throw Error(formatProdErrorMessage(137, tag)); break; default: - setProp(domElement, tag, hasSrc, propValue$192, props, null); + setProp(domElement, tag, hasSrc, propValue$197, props, null); } } initInput( @@ -13491,14 +13513,14 @@ function setInitialProperties(domElement, tag, props) { return; default: if (isCustomElement(tag)) { - for (propValue$192 in props) - props.hasOwnProperty(propValue$192) && - ((hasSrc = props[propValue$192]), + for (propValue$197 in props) + props.hasOwnProperty(propValue$197) && + ((hasSrc = props[propValue$197]), void 0 !== hasSrc && setPropOnCustomElement( domElement, tag, - propValue$192, + propValue$197, hasSrc, props, void 0 @@ -13546,14 +13568,14 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp(domElement, tag, propKey, null, nextProps, lastProp); } } - for (var propKey$209 in nextProps) { - var propKey = nextProps[propKey$209]; - lastProp = lastProps[propKey$209]; + for (var propKey$214 in nextProps) { + var propKey = nextProps[propKey$214]; + lastProp = lastProps[propKey$214]; if ( - nextProps.hasOwnProperty(propKey$209) && + nextProps.hasOwnProperty(propKey$214) && (null != propKey || null != lastProp) ) - switch (propKey$209) { + switch (propKey$214) { case "type": type = propKey; break; @@ -13582,7 +13604,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$209, + propKey$214, propKey, nextProps, lastProp @@ -13601,7 +13623,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ); return; case "select": - propKey = value = defaultValue = propKey$209 = null; + propKey = value = defaultValue = propKey$214 = null; for (type in lastProps) if ( ((lastDefaultValue = lastProps[type]), @@ -13632,7 +13654,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (name) { case "value": - propKey$209 = type; + propKey$214 = type; break; case "defaultValue": defaultValue = type; @@ -13653,15 +13675,15 @@ function updateProperties(domElement, tag, lastProps, nextProps) { tag = defaultValue; lastProps = value; nextProps = propKey; - null != propKey$209 - ? updateOptions(domElement, !!lastProps, propKey$209, !1) + null != propKey$214 + ? updateOptions(domElement, !!lastProps, propKey$214, !1) : !!nextProps !== !!lastProps && (null != tag ? updateOptions(domElement, !!lastProps, tag, !0) : updateOptions(domElement, !!lastProps, lastProps ? [] : "", !1)); return; case "textarea": - propKey = propKey$209 = null; + propKey = propKey$214 = null; for (defaultValue in lastProps) if ( ((name = lastProps[defaultValue]), @@ -13685,7 +13707,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (value) { case "value": - propKey$209 = name; + propKey$214 = name; break; case "defaultValue": propKey = name; @@ -13699,17 +13721,17 @@ function updateProperties(domElement, tag, lastProps, nextProps) { name !== type && setProp(domElement, tag, value, name, nextProps, type); } - updateTextarea(domElement, propKey$209, propKey); + updateTextarea(domElement, propKey$214, propKey); return; case "option": - for (var propKey$225 in lastProps) + for (var propKey$230 in lastProps) if ( - ((propKey$209 = lastProps[propKey$225]), - lastProps.hasOwnProperty(propKey$225) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$225)) + ((propKey$214 = lastProps[propKey$230]), + lastProps.hasOwnProperty(propKey$230) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$230)) ) - switch (propKey$225) { + switch (propKey$230) { case "selected": domElement.selected = !1; break; @@ -13717,33 +13739,33 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$225, + propKey$230, null, nextProps, - propKey$209 + propKey$214 ); } for (lastDefaultValue in nextProps) if ( - ((propKey$209 = nextProps[lastDefaultValue]), + ((propKey$214 = nextProps[lastDefaultValue]), (propKey = lastProps[lastDefaultValue]), nextProps.hasOwnProperty(lastDefaultValue) && - propKey$209 !== propKey && - (null != propKey$209 || null != propKey)) + propKey$214 !== propKey && + (null != propKey$214 || null != propKey)) ) switch (lastDefaultValue) { case "selected": domElement.selected = - propKey$209 && - "function" !== typeof propKey$209 && - "symbol" !== typeof propKey$209; + propKey$214 && + "function" !== typeof propKey$214 && + "symbol" !== typeof propKey$214; break; default: setProp( domElement, tag, lastDefaultValue, - propKey$209, + propKey$214, nextProps, propKey ); @@ -13764,24 +13786,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { case "track": case "wbr": case "menuitem": - for (var propKey$230 in lastProps) - (propKey$209 = lastProps[propKey$230]), - lastProps.hasOwnProperty(propKey$230) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$230) && - setProp(domElement, tag, propKey$230, null, nextProps, propKey$209); + for (var propKey$235 in lastProps) + (propKey$214 = lastProps[propKey$235]), + lastProps.hasOwnProperty(propKey$235) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$235) && + setProp(domElement, tag, propKey$235, null, nextProps, propKey$214); for (checked in nextProps) if ( - ((propKey$209 = nextProps[checked]), + ((propKey$214 = nextProps[checked]), (propKey = lastProps[checked]), nextProps.hasOwnProperty(checked) && - propKey$209 !== propKey && - (null != propKey$209 || null != propKey)) + propKey$214 !== propKey && + (null != propKey$214 || null != propKey)) ) switch (checked) { case "children": case "dangerouslySetInnerHTML": - if (null != propKey$209) + if (null != propKey$214) throw Error(formatProdErrorMessage(137, tag)); break; default: @@ -13789,7 +13811,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { domElement, tag, checked, - propKey$209, + propKey$214, nextProps, propKey ); @@ -13797,49 +13819,49 @@ function updateProperties(domElement, tag, lastProps, nextProps) { return; default: if (isCustomElement(tag)) { - for (var propKey$235 in lastProps) - (propKey$209 = lastProps[propKey$235]), - lastProps.hasOwnProperty(propKey$235) && - void 0 !== propKey$209 && - !nextProps.hasOwnProperty(propKey$235) && + for (var propKey$240 in lastProps) + (propKey$214 = lastProps[propKey$240]), + lastProps.hasOwnProperty(propKey$240) && + void 0 !== propKey$214 && + !nextProps.hasOwnProperty(propKey$240) && setPropOnCustomElement( domElement, tag, - propKey$235, + propKey$240, void 0, nextProps, - propKey$209 + propKey$214 ); for (defaultChecked in nextProps) - (propKey$209 = nextProps[defaultChecked]), + (propKey$214 = nextProps[defaultChecked]), (propKey = lastProps[defaultChecked]), !nextProps.hasOwnProperty(defaultChecked) || - propKey$209 === propKey || - (void 0 === propKey$209 && void 0 === propKey) || + propKey$214 === propKey || + (void 0 === propKey$214 && void 0 === propKey) || setPropOnCustomElement( domElement, tag, defaultChecked, - propKey$209, + propKey$214, nextProps, propKey ); return; } } - for (var propKey$240 in lastProps) - (propKey$209 = lastProps[propKey$240]), - lastProps.hasOwnProperty(propKey$240) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$240) && - setProp(domElement, tag, propKey$240, null, nextProps, propKey$209); + for (var propKey$245 in lastProps) + (propKey$214 = lastProps[propKey$245]), + lastProps.hasOwnProperty(propKey$245) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$245) && + setProp(domElement, tag, propKey$245, null, nextProps, propKey$214); for (lastProp in nextProps) - (propKey$209 = nextProps[lastProp]), + (propKey$214 = nextProps[lastProp]), (propKey = lastProps[lastProp]), !nextProps.hasOwnProperty(lastProp) || - propKey$209 === propKey || - (null == propKey$209 && null == propKey) || - setProp(domElement, tag, lastProp, propKey$209, nextProps, propKey); + propKey$214 === propKey || + (null == propKey$214 && null == propKey) || + setProp(domElement, tag, lastProp, propKey$214, nextProps, propKey); } var eventsEnabled = null, selectionInformation = null; @@ -14379,26 +14401,26 @@ function getResource(type, currentProps, pendingProps, currentResource) { "string" === typeof pendingProps.precedence ) { type = getStyleKey(pendingProps.href); - var styles$248 = getResourcesFromRoot( + var styles$253 = getResourcesFromRoot( JSCompiler_inline_result ).hoistableStyles, - resource$249 = styles$248.get(type); - resource$249 || + resource$254 = styles$253.get(type); + resource$254 || ((JSCompiler_inline_result = JSCompiler_inline_result.ownerDocument || JSCompiler_inline_result), - (resource$249 = { + (resource$254 = { type: "stylesheet", instance: null, count: 0, state: { loading: 0, preload: null } }), - styles$248.set(type, resource$249), - (styles$248 = JSCompiler_inline_result.querySelector( + styles$253.set(type, resource$254), + (styles$253 = JSCompiler_inline_result.querySelector( getStylesheetSelectorFromKey(type) )) && - !styles$248._p && - ((resource$249.instance = styles$248), - (resource$249.state.loading = 5)), + !styles$253._p && + ((resource$254.instance = styles$253), + (resource$254.state.loading = 5)), preloadPropsMap.has(type) || ((pendingProps = { rel: "preload", @@ -14411,16 +14433,16 @@ function getResource(type, currentProps, pendingProps, currentResource) { referrerPolicy: pendingProps.referrerPolicy }), preloadPropsMap.set(type, pendingProps), - styles$248 || + styles$253 || preloadStylesheet( JSCompiler_inline_result, type, pendingProps, - resource$249.state + resource$254.state ))); if (currentProps && null === currentResource) throw Error(formatProdErrorMessage(528, "")); - return resource$249; + return resource$254; } if (currentProps && null !== currentResource) throw Error(formatProdErrorMessage(529, "")); @@ -14517,37 +14539,37 @@ function acquireResource(hoistableRoot, resource, props) { return (resource.instance = instance); case "stylesheet": styleProps = getStyleKey(props.href); - var instance$254 = hoistableRoot.querySelector( + var instance$259 = hoistableRoot.querySelector( getStylesheetSelectorFromKey(styleProps) ); - if (instance$254) + if (instance$259) return ( (resource.state.loading |= 4), - (resource.instance = instance$254), - markNodeAsHoistable(instance$254), - instance$254 + (resource.instance = instance$259), + markNodeAsHoistable(instance$259), + instance$259 ); instance = stylesheetPropsFromRawProps(props); (styleProps = preloadPropsMap.get(styleProps)) && adoptPreloadPropsForStylesheet(instance, styleProps); - instance$254 = ( + instance$259 = ( hoistableRoot.ownerDocument || hoistableRoot ).createElement("link"); - markNodeAsHoistable(instance$254); - var linkInstance = instance$254; + markNodeAsHoistable(instance$259); + var linkInstance = instance$259; linkInstance._p = new Promise(function (resolve, reject) { linkInstance.onload = resolve; linkInstance.onerror = reject; }); - setInitialProperties(instance$254, "link", instance); + setInitialProperties(instance$259, "link", instance); resource.state.loading |= 4; - insertStylesheet(instance$254, props.precedence, hoistableRoot); - return (resource.instance = instance$254); + insertStylesheet(instance$259, props.precedence, hoistableRoot); + return (resource.instance = instance$259); case "script": - instance$254 = getScriptKey(props.src); + instance$259 = getScriptKey(props.src); if ( (styleProps = hoistableRoot.querySelector( - getScriptSelectorFromKey(instance$254) + getScriptSelectorFromKey(instance$259) )) ) return ( @@ -14556,7 +14578,7 @@ function acquireResource(hoistableRoot, resource, props) { styleProps ); instance = props; - if ((styleProps = preloadPropsMap.get(instance$254))) + if ((styleProps = preloadPropsMap.get(instance$259))) (instance = assign({}, props)), adoptPreloadPropsForScript(instance, styleProps); hoistableRoot = hoistableRoot.ownerDocument || hoistableRoot; @@ -15614,16 +15636,16 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) { 0 === i && attemptExplicitHydrationTarget(target); } }; -var isomorphicReactPackageVersion$jscomp$inline_1691 = React.version; +var isomorphicReactPackageVersion$jscomp$inline_1698 = React.version; if ( - "19.0.0-native-fb-5c56b873-20241107" !== - isomorphicReactPackageVersion$jscomp$inline_1691 + "19.0.0-native-fb-989af12f-20241108" !== + isomorphicReactPackageVersion$jscomp$inline_1698 ) throw Error( formatProdErrorMessage( 527, - isomorphicReactPackageVersion$jscomp$inline_1691, - "19.0.0-native-fb-5c56b873-20241107" + isomorphicReactPackageVersion$jscomp$inline_1698, + "19.0.0-native-fb-989af12f-20241108" ) ); ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { @@ -15643,25 +15665,25 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { null === componentOrElement ? null : componentOrElement.stateNode; return componentOrElement; }; -var internals$jscomp$inline_2149 = { +var internals$jscomp$inline_2156 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_2150 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_2157 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_2150.isDisabled && - hook$jscomp$inline_2150.supportsFiber + !hook$jscomp$inline_2157.isDisabled && + hook$jscomp$inline_2157.supportsFiber ) try { - (rendererID = hook$jscomp$inline_2150.inject( - internals$jscomp$inline_2149 + (rendererID = hook$jscomp$inline_2157.inject( + internals$jscomp$inline_2156 )), - (injectedHook = hook$jscomp$inline_2150); + (injectedHook = hook$jscomp$inline_2157); } catch (err) {} } exports.createRoot = function (container, options) { @@ -15753,4 +15775,4 @@ exports.hydrateRoot = function (container, initialChildren, options) { listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-profiling.js index fa51f905696d4..1ca8ebca65efb 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMClient-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<7ca24359ee46367021a2eb5c0094771a>> + * @generated SignedSource<> */ /* @@ -768,6 +768,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2158,19 +2166,19 @@ function getTargetInstForChangeEvent(domEventName, targetInst) { } var isInputEventSupported = !1; if (canUseDOM) { - var JSCompiler_inline_result$jscomp$305; + var JSCompiler_inline_result$jscomp$310; if (canUseDOM) { - var isSupported$jscomp$inline_438 = "oninput" in document; - if (!isSupported$jscomp$inline_438) { - var element$jscomp$inline_439 = document.createElement("div"); - element$jscomp$inline_439.setAttribute("oninput", "return;"); - isSupported$jscomp$inline_438 = - "function" === typeof element$jscomp$inline_439.oninput; + var isSupported$jscomp$inline_443 = "oninput" in document; + if (!isSupported$jscomp$inline_443) { + var element$jscomp$inline_444 = document.createElement("div"); + element$jscomp$inline_444.setAttribute("oninput", "return;"); + isSupported$jscomp$inline_443 = + "function" === typeof element$jscomp$inline_444.oninput; } - JSCompiler_inline_result$jscomp$305 = isSupported$jscomp$inline_438; - } else JSCompiler_inline_result$jscomp$305 = !1; + JSCompiler_inline_result$jscomp$310 = isSupported$jscomp$inline_443; + } else JSCompiler_inline_result$jscomp$310 = !1; isInputEventSupported = - JSCompiler_inline_result$jscomp$305 && + JSCompiler_inline_result$jscomp$310 && (!document.documentMode || 9 < document.documentMode); } function stopWatchingForValueChange() { @@ -11307,7 +11315,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -11320,7 +11328,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -11331,172 +11339,174 @@ function scheduleUpdateOnFiber(root, fiber, lane) { } function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327)); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - var wasRootDehydrated = root.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack(root, JSCompiler_inline_result).flags |= - 256); - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + var wasRootDehydrated = root.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack(root, JSCompiler_inline_result).flags |= 256); + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error(formatProdErrorMessage(345)); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error(formatProdErrorMessage(329)); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now$1()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error(formatProdErrorMessage(345)); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error(formatProdErrorMessage(329)); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -11545,7 +11555,7 @@ function commitRootWhenReady( completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended(root, lanes, spawnedLane, !didSkipSuspendedSiblings); return; } commitRoot( @@ -11599,20 +11609,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$6 = 31 - clz32(lanes), lane = 1 << index$6; - didSkipSuspendedSiblings[index$6] = -1; + didAttemptEntireTree[index$6] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -11656,9 +11666,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -11775,7 +11783,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -11784,10 +11794,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -11805,32 +11815,46 @@ function renderRootSync(root, lanes) { } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + memoizedUpdaters = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - throwAndUnwindWorkLoop(root, memoizedUpdaters, thrownValue, reason); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; - } catch (thrownValue$185) { - handleThrow(root, thrownValue$185); + } catch (thrownValue$190) { + handleThrow(root, thrownValue$190); } while (1); lanes && root.shellSuspendCounter++; @@ -11838,12 +11862,12 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) throw Error(formatProdErrorMessage(261)); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -11865,12 +11889,7 @@ function renderRootConcurrent(root, lanes) { workInProgressRootRenderTargetTime = now$1() + 500; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -11956,8 +11975,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$187) { - handleThrow(root, thrownValue$187); + } catch (thrownValue$192) { + handleThrow(root, thrownValue$192); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -12315,7 +12334,7 @@ function releaseRootPooledCache(root, remainingLanes) { } function flushPassiveEffects() { if (null !== rootWithPendingPassiveEffects) { - var root$191 = rootWithPendingPassiveEffects, + var root$196 = rootWithPendingPassiveEffects, remainingLanes = pendingPassiveEffectsRemainingLanes; pendingPassiveEffectsRemainingLanes = 0; var renderPriority = lanesToEventPriority(pendingPassiveEffectsLanes), @@ -12365,7 +12384,7 @@ function flushPassiveEffects() { } finally { (ReactDOMSharedInternals.p = previousPriority), (ReactSharedInternals.T = prevTransition), - releaseRootPooledCache(root$191, remainingLanes); + releaseRootPooledCache(root$196, remainingLanes); } } return !1; @@ -12516,14 +12535,14 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { isFlushingWork = !0; do { var didPerformSomeWork = !1; - for (var root$193 = firstScheduledRoot; null !== root$193; ) { - if (!onlyLegacy || 0 === root$193.tag) + for (var root$198 = firstScheduledRoot; null !== root$198; ) { + if (!onlyLegacy || 0 === root$198.tag) if (0 !== syncTransitionLanes) { - var pendingLanes = root$193.pendingLanes; + var pendingLanes = root$198.pendingLanes; if (0 === pendingLanes) var JSCompiler_inline_result = 0; else { - var suspendedLanes = root$193.suspendedLanes, - pingedLanes = root$193.pingedLanes; + var suspendedLanes = root$198.suspendedLanes, + pingedLanes = root$198.pingedLanes; JSCompiler_inline_result = (1 << (31 - clz32(42 | syncTransitionLanes) + 1)) - 1; JSCompiler_inline_result &= @@ -12537,17 +12556,18 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { } 0 !== JSCompiler_inline_result && ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$193, JSCompiler_inline_result)); + performSyncWorkOnRoot(root$198, JSCompiler_inline_result)); } else (JSCompiler_inline_result = workInProgressRootRenderLanes), (JSCompiler_inline_result = getNextLanes( - root$193, - root$193 === workInProgressRoot ? JSCompiler_inline_result : 0 + root$198, + root$198 === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root$198, JSCompiler_inline_result) || ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$193, JSCompiler_inline_result)); - root$193 = root$193.next; + performSyncWorkOnRoot(root$198, JSCompiler_inline_result)); + root$198 = root$198.next; } } while (didPerformSomeWork); isFlushingWork = !1; @@ -12616,39 +12636,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -12780,20 +12799,20 @@ function extractEvents$1( } } for ( - var i$jscomp$inline_1536 = 0; - i$jscomp$inline_1536 < simpleEventPluginEvents.length; - i$jscomp$inline_1536++ + var i$jscomp$inline_1543 = 0; + i$jscomp$inline_1543 < simpleEventPluginEvents.length; + i$jscomp$inline_1543++ ) { - var eventName$jscomp$inline_1537 = - simpleEventPluginEvents[i$jscomp$inline_1536], - domEventName$jscomp$inline_1538 = - eventName$jscomp$inline_1537.toLowerCase(), - capitalizedEvent$jscomp$inline_1539 = - eventName$jscomp$inline_1537[0].toUpperCase() + - eventName$jscomp$inline_1537.slice(1); + var eventName$jscomp$inline_1544 = + simpleEventPluginEvents[i$jscomp$inline_1543], + domEventName$jscomp$inline_1545 = + eventName$jscomp$inline_1544.toLowerCase(), + capitalizedEvent$jscomp$inline_1546 = + eventName$jscomp$inline_1544[0].toUpperCase() + + eventName$jscomp$inline_1544.slice(1); registerSimpleEvent( - domEventName$jscomp$inline_1538, - "on" + capitalizedEvent$jscomp$inline_1539 + domEventName$jscomp$inline_1545, + "on" + capitalizedEvent$jscomp$inline_1546 ); } registerSimpleEvent(ANIMATION_END, "onAnimationEnd"); @@ -13976,34 +13995,34 @@ function setInitialProperties(domElement, tag, props) { defaultChecked = null; for (hasSrc in props) if (props.hasOwnProperty(hasSrc)) { - var propValue$207 = props[hasSrc]; - if (null != propValue$207) + var propValue$212 = props[hasSrc]; + if (null != propValue$212) switch (hasSrc) { case "name": - hasSrcSet = propValue$207; + hasSrcSet = propValue$212; break; case "type": - propValue = propValue$207; + propValue = propValue$212; break; case "checked": - checked = propValue$207; + checked = propValue$212; break; case "defaultChecked": - defaultChecked = propValue$207; + defaultChecked = propValue$212; break; case "value": - propKey = propValue$207; + propKey = propValue$212; break; case "defaultValue": - defaultValue = propValue$207; + defaultValue = propValue$212; break; case "children": case "dangerouslySetInnerHTML": - if (null != propValue$207) + if (null != propValue$212) throw Error(formatProdErrorMessage(137, tag)); break; default: - setProp(domElement, tag, hasSrc, propValue$207, props, null); + setProp(domElement, tag, hasSrc, propValue$212, props, null); } } initInput( @@ -14140,14 +14159,14 @@ function setInitialProperties(domElement, tag, props) { return; default: if (isCustomElement(tag)) { - for (propValue$207 in props) - props.hasOwnProperty(propValue$207) && - ((hasSrc = props[propValue$207]), + for (propValue$212 in props) + props.hasOwnProperty(propValue$212) && + ((hasSrc = props[propValue$212]), void 0 !== hasSrc && setPropOnCustomElement( domElement, tag, - propValue$207, + propValue$212, hasSrc, props, void 0 @@ -14195,14 +14214,14 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp(domElement, tag, propKey, null, nextProps, lastProp); } } - for (var propKey$224 in nextProps) { - var propKey = nextProps[propKey$224]; - lastProp = lastProps[propKey$224]; + for (var propKey$229 in nextProps) { + var propKey = nextProps[propKey$229]; + lastProp = lastProps[propKey$229]; if ( - nextProps.hasOwnProperty(propKey$224) && + nextProps.hasOwnProperty(propKey$229) && (null != propKey || null != lastProp) ) - switch (propKey$224) { + switch (propKey$229) { case "type": type = propKey; break; @@ -14231,7 +14250,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$224, + propKey$229, propKey, nextProps, lastProp @@ -14250,7 +14269,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ); return; case "select": - propKey = value = defaultValue = propKey$224 = null; + propKey = value = defaultValue = propKey$229 = null; for (type in lastProps) if ( ((lastDefaultValue = lastProps[type]), @@ -14281,7 +14300,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (name) { case "value": - propKey$224 = type; + propKey$229 = type; break; case "defaultValue": defaultValue = type; @@ -14302,15 +14321,15 @@ function updateProperties(domElement, tag, lastProps, nextProps) { tag = defaultValue; lastProps = value; nextProps = propKey; - null != propKey$224 - ? updateOptions(domElement, !!lastProps, propKey$224, !1) + null != propKey$229 + ? updateOptions(domElement, !!lastProps, propKey$229, !1) : !!nextProps !== !!lastProps && (null != tag ? updateOptions(domElement, !!lastProps, tag, !0) : updateOptions(domElement, !!lastProps, lastProps ? [] : "", !1)); return; case "textarea": - propKey = propKey$224 = null; + propKey = propKey$229 = null; for (defaultValue in lastProps) if ( ((name = lastProps[defaultValue]), @@ -14334,7 +14353,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (value) { case "value": - propKey$224 = name; + propKey$229 = name; break; case "defaultValue": propKey = name; @@ -14348,17 +14367,17 @@ function updateProperties(domElement, tag, lastProps, nextProps) { name !== type && setProp(domElement, tag, value, name, nextProps, type); } - updateTextarea(domElement, propKey$224, propKey); + updateTextarea(domElement, propKey$229, propKey); return; case "option": - for (var propKey$240 in lastProps) + for (var propKey$245 in lastProps) if ( - ((propKey$224 = lastProps[propKey$240]), - lastProps.hasOwnProperty(propKey$240) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$240)) + ((propKey$229 = lastProps[propKey$245]), + lastProps.hasOwnProperty(propKey$245) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$245)) ) - switch (propKey$240) { + switch (propKey$245) { case "selected": domElement.selected = !1; break; @@ -14366,33 +14385,33 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$240, + propKey$245, null, nextProps, - propKey$224 + propKey$229 ); } for (lastDefaultValue in nextProps) if ( - ((propKey$224 = nextProps[lastDefaultValue]), + ((propKey$229 = nextProps[lastDefaultValue]), (propKey = lastProps[lastDefaultValue]), nextProps.hasOwnProperty(lastDefaultValue) && - propKey$224 !== propKey && - (null != propKey$224 || null != propKey)) + propKey$229 !== propKey && + (null != propKey$229 || null != propKey)) ) switch (lastDefaultValue) { case "selected": domElement.selected = - propKey$224 && - "function" !== typeof propKey$224 && - "symbol" !== typeof propKey$224; + propKey$229 && + "function" !== typeof propKey$229 && + "symbol" !== typeof propKey$229; break; default: setProp( domElement, tag, lastDefaultValue, - propKey$224, + propKey$229, nextProps, propKey ); @@ -14413,24 +14432,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { case "track": case "wbr": case "menuitem": - for (var propKey$245 in lastProps) - (propKey$224 = lastProps[propKey$245]), - lastProps.hasOwnProperty(propKey$245) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$245) && - setProp(domElement, tag, propKey$245, null, nextProps, propKey$224); + for (var propKey$250 in lastProps) + (propKey$229 = lastProps[propKey$250]), + lastProps.hasOwnProperty(propKey$250) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$250) && + setProp(domElement, tag, propKey$250, null, nextProps, propKey$229); for (checked in nextProps) if ( - ((propKey$224 = nextProps[checked]), + ((propKey$229 = nextProps[checked]), (propKey = lastProps[checked]), nextProps.hasOwnProperty(checked) && - propKey$224 !== propKey && - (null != propKey$224 || null != propKey)) + propKey$229 !== propKey && + (null != propKey$229 || null != propKey)) ) switch (checked) { case "children": case "dangerouslySetInnerHTML": - if (null != propKey$224) + if (null != propKey$229) throw Error(formatProdErrorMessage(137, tag)); break; default: @@ -14438,7 +14457,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { domElement, tag, checked, - propKey$224, + propKey$229, nextProps, propKey ); @@ -14446,49 +14465,49 @@ function updateProperties(domElement, tag, lastProps, nextProps) { return; default: if (isCustomElement(tag)) { - for (var propKey$250 in lastProps) - (propKey$224 = lastProps[propKey$250]), - lastProps.hasOwnProperty(propKey$250) && - void 0 !== propKey$224 && - !nextProps.hasOwnProperty(propKey$250) && + for (var propKey$255 in lastProps) + (propKey$229 = lastProps[propKey$255]), + lastProps.hasOwnProperty(propKey$255) && + void 0 !== propKey$229 && + !nextProps.hasOwnProperty(propKey$255) && setPropOnCustomElement( domElement, tag, - propKey$250, + propKey$255, void 0, nextProps, - propKey$224 + propKey$229 ); for (defaultChecked in nextProps) - (propKey$224 = nextProps[defaultChecked]), + (propKey$229 = nextProps[defaultChecked]), (propKey = lastProps[defaultChecked]), !nextProps.hasOwnProperty(defaultChecked) || - propKey$224 === propKey || - (void 0 === propKey$224 && void 0 === propKey) || + propKey$229 === propKey || + (void 0 === propKey$229 && void 0 === propKey) || setPropOnCustomElement( domElement, tag, defaultChecked, - propKey$224, + propKey$229, nextProps, propKey ); return; } } - for (var propKey$255 in lastProps) - (propKey$224 = lastProps[propKey$255]), - lastProps.hasOwnProperty(propKey$255) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$255) && - setProp(domElement, tag, propKey$255, null, nextProps, propKey$224); + for (var propKey$260 in lastProps) + (propKey$229 = lastProps[propKey$260]), + lastProps.hasOwnProperty(propKey$260) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$260) && + setProp(domElement, tag, propKey$260, null, nextProps, propKey$229); for (lastProp in nextProps) - (propKey$224 = nextProps[lastProp]), + (propKey$229 = nextProps[lastProp]), (propKey = lastProps[lastProp]), !nextProps.hasOwnProperty(lastProp) || - propKey$224 === propKey || - (null == propKey$224 && null == propKey) || - setProp(domElement, tag, lastProp, propKey$224, nextProps, propKey); + propKey$229 === propKey || + (null == propKey$229 && null == propKey) || + setProp(domElement, tag, lastProp, propKey$229, nextProps, propKey); } var eventsEnabled = null, selectionInformation = null; @@ -15028,26 +15047,26 @@ function getResource(type, currentProps, pendingProps, currentResource) { "string" === typeof pendingProps.precedence ) { type = getStyleKey(pendingProps.href); - var styles$263 = getResourcesFromRoot( + var styles$268 = getResourcesFromRoot( JSCompiler_inline_result ).hoistableStyles, - resource$264 = styles$263.get(type); - resource$264 || + resource$269 = styles$268.get(type); + resource$269 || ((JSCompiler_inline_result = JSCompiler_inline_result.ownerDocument || JSCompiler_inline_result), - (resource$264 = { + (resource$269 = { type: "stylesheet", instance: null, count: 0, state: { loading: 0, preload: null } }), - styles$263.set(type, resource$264), - (styles$263 = JSCompiler_inline_result.querySelector( + styles$268.set(type, resource$269), + (styles$268 = JSCompiler_inline_result.querySelector( getStylesheetSelectorFromKey(type) )) && - !styles$263._p && - ((resource$264.instance = styles$263), - (resource$264.state.loading = 5)), + !styles$268._p && + ((resource$269.instance = styles$268), + (resource$269.state.loading = 5)), preloadPropsMap.has(type) || ((pendingProps = { rel: "preload", @@ -15060,16 +15079,16 @@ function getResource(type, currentProps, pendingProps, currentResource) { referrerPolicy: pendingProps.referrerPolicy }), preloadPropsMap.set(type, pendingProps), - styles$263 || + styles$268 || preloadStylesheet( JSCompiler_inline_result, type, pendingProps, - resource$264.state + resource$269.state ))); if (currentProps && null === currentResource) throw Error(formatProdErrorMessage(528, "")); - return resource$264; + return resource$269; } if (currentProps && null !== currentResource) throw Error(formatProdErrorMessage(529, "")); @@ -15166,37 +15185,37 @@ function acquireResource(hoistableRoot, resource, props) { return (resource.instance = instance); case "stylesheet": styleProps = getStyleKey(props.href); - var instance$269 = hoistableRoot.querySelector( + var instance$274 = hoistableRoot.querySelector( getStylesheetSelectorFromKey(styleProps) ); - if (instance$269) + if (instance$274) return ( (resource.state.loading |= 4), - (resource.instance = instance$269), - markNodeAsHoistable(instance$269), - instance$269 + (resource.instance = instance$274), + markNodeAsHoistable(instance$274), + instance$274 ); instance = stylesheetPropsFromRawProps(props); (styleProps = preloadPropsMap.get(styleProps)) && adoptPreloadPropsForStylesheet(instance, styleProps); - instance$269 = ( + instance$274 = ( hoistableRoot.ownerDocument || hoistableRoot ).createElement("link"); - markNodeAsHoistable(instance$269); - var linkInstance = instance$269; + markNodeAsHoistable(instance$274); + var linkInstance = instance$274; linkInstance._p = new Promise(function (resolve, reject) { linkInstance.onload = resolve; linkInstance.onerror = reject; }); - setInitialProperties(instance$269, "link", instance); + setInitialProperties(instance$274, "link", instance); resource.state.loading |= 4; - insertStylesheet(instance$269, props.precedence, hoistableRoot); - return (resource.instance = instance$269); + insertStylesheet(instance$274, props.precedence, hoistableRoot); + return (resource.instance = instance$274); case "script": - instance$269 = getScriptKey(props.src); + instance$274 = getScriptKey(props.src); if ( (styleProps = hoistableRoot.querySelector( - getScriptSelectorFromKey(instance$269) + getScriptSelectorFromKey(instance$274) )) ) return ( @@ -15205,7 +15224,7 @@ function acquireResource(hoistableRoot, resource, props) { styleProps ); instance = props; - if ((styleProps = preloadPropsMap.get(instance$269))) + if ((styleProps = preloadPropsMap.get(instance$274))) (instance = assign({}, props)), adoptPreloadPropsForScript(instance, styleProps); hoistableRoot = hoistableRoot.ownerDocument || hoistableRoot; @@ -16271,16 +16290,16 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) { 0 === i && attemptExplicitHydrationTarget(target); } }; -var isomorphicReactPackageVersion$jscomp$inline_1781 = React.version; +var isomorphicReactPackageVersion$jscomp$inline_1788 = React.version; if ( - "19.0.0-native-fb-5c56b873-20241107" !== - isomorphicReactPackageVersion$jscomp$inline_1781 + "19.0.0-native-fb-989af12f-20241108" !== + isomorphicReactPackageVersion$jscomp$inline_1788 ) throw Error( formatProdErrorMessage( 527, - isomorphicReactPackageVersion$jscomp$inline_1781, - "19.0.0-native-fb-5c56b873-20241107" + isomorphicReactPackageVersion$jscomp$inline_1788, + "19.0.0-native-fb-989af12f-20241108" ) ); ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { @@ -16300,18 +16319,18 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { null === componentOrElement ? null : componentOrElement.stateNode; return componentOrElement; }; -var internals$jscomp$inline_1788 = { +var internals$jscomp$inline_1795 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107", + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108", getLaneLabelMap: function () { for ( - var map = new Map(), lane = 1, index$286 = 0; - 31 > index$286; - index$286++ + var map = new Map(), lane = 1, index$291 = 0; + 31 > index$291; + index$291++ ) { var label = getLabelForLane(lane); map.set(lane, label); @@ -16324,16 +16343,16 @@ var internals$jscomp$inline_1788 = { } }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_2201 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_2208 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_2201.isDisabled && - hook$jscomp$inline_2201.supportsFiber + !hook$jscomp$inline_2208.isDisabled && + hook$jscomp$inline_2208.supportsFiber ) try { - (rendererID = hook$jscomp$inline_2201.inject( - internals$jscomp$inline_1788 + (rendererID = hook$jscomp$inline_2208.inject( + internals$jscomp$inline_1795 )), - (injectedHook = hook$jscomp$inline_2201); + (injectedHook = hook$jscomp$inline_2208); } catch (err) {} } exports.createRoot = function (container, options) { @@ -16425,4 +16444,4 @@ exports.hydrateRoot = function (container, initialChildren, options) { listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-dev.js index cd720726e9590..ba0f52277bb3e 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<6cf36d550068fc1eff8d145f619445e6>> + * @generated SignedSource<<30d439ced802b7158cc5be4e5f13b01e>> */ /* @@ -1085,6 +1085,14 @@ __DEV__ && ? wipLanes : nextLanes; } + function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); + } function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -8987,32 +8995,32 @@ __DEV__ && return current; } function updateSuspenseComponent(current, workInProgress, renderLanes) { - var JSCompiler_object_inline_digest_2329; - var JSCompiler_object_inline_stack_2330 = workInProgress.pendingProps; + var JSCompiler_object_inline_digest_2331; + var JSCompiler_object_inline_stack_2332 = workInProgress.pendingProps; shouldSuspendImpl(workInProgress) && (workInProgress.flags |= 128); - var JSCompiler_object_inline_componentStack_2331 = !1; + var JSCompiler_object_inline_componentStack_2333 = !1; var didSuspend = 0 !== (workInProgress.flags & 128); - (JSCompiler_object_inline_digest_2329 = didSuspend) || - (JSCompiler_object_inline_digest_2329 = + (JSCompiler_object_inline_digest_2331 = didSuspend) || + (JSCompiler_object_inline_digest_2331 = null !== current && null === current.memoizedState ? !1 : 0 !== (suspenseStackCursor.current & ForceSuspenseFallback)); - JSCompiler_object_inline_digest_2329 && - ((JSCompiler_object_inline_componentStack_2331 = !0), + JSCompiler_object_inline_digest_2331 && + ((JSCompiler_object_inline_componentStack_2333 = !0), (workInProgress.flags &= -129)); - JSCompiler_object_inline_digest_2329 = 0 !== (workInProgress.flags & 32); + JSCompiler_object_inline_digest_2331 = 0 !== (workInProgress.flags & 32); workInProgress.flags &= -33; if (null === current) { if (isHydrating) { - JSCompiler_object_inline_componentStack_2331 + JSCompiler_object_inline_componentStack_2333 ? pushPrimaryTreeSuspenseHandler(workInProgress) : reuseSuspenseHandlerOnStack(workInProgress); if (isHydrating) { - var JSCompiler_object_inline_message_2328 = nextHydratableInstance; + var JSCompiler_object_inline_message_2330 = nextHydratableInstance; var JSCompiler_temp; - if (!(JSCompiler_temp = !JSCompiler_object_inline_message_2328)) { + if (!(JSCompiler_temp = !JSCompiler_object_inline_message_2330)) { c: { - var instance = JSCompiler_object_inline_message_2328; + var instance = JSCompiler_object_inline_message_2330; for ( JSCompiler_temp = rootOrSingletonContext; 8 !== instance.nodeType; @@ -9053,19 +9061,19 @@ __DEV__ && JSCompiler_temp && (warnNonHydratedInstance( workInProgress, - JSCompiler_object_inline_message_2328 + JSCompiler_object_inline_message_2330 ), throwOnHydrationMismatch(workInProgress)); } - JSCompiler_object_inline_message_2328 = workInProgress.memoizedState; + JSCompiler_object_inline_message_2330 = workInProgress.memoizedState; if ( - null !== JSCompiler_object_inline_message_2328 && - ((JSCompiler_object_inline_message_2328 = - JSCompiler_object_inline_message_2328.dehydrated), - null !== JSCompiler_object_inline_message_2328) + null !== JSCompiler_object_inline_message_2330 && + ((JSCompiler_object_inline_message_2330 = + JSCompiler_object_inline_message_2330.dehydrated), + null !== JSCompiler_object_inline_message_2330) ) return ( - JSCompiler_object_inline_message_2328.data === + JSCompiler_object_inline_message_2330.data === SUSPENSE_FALLBACK_START_DATA ? (workInProgress.lanes = 16) : (workInProgress.lanes = 536870912), @@ -9073,70 +9081,70 @@ __DEV__ && ); popSuspenseHandler(workInProgress); } - JSCompiler_object_inline_message_2328 = - JSCompiler_object_inline_stack_2330.children; - JSCompiler_temp = JSCompiler_object_inline_stack_2330.fallback; - if (JSCompiler_object_inline_componentStack_2331) + JSCompiler_object_inline_message_2330 = + JSCompiler_object_inline_stack_2332.children; + JSCompiler_temp = JSCompiler_object_inline_stack_2332.fallback; + if (JSCompiler_object_inline_componentStack_2333) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_stack_2330 = + (JSCompiler_object_inline_stack_2332 = mountSuspenseFallbackChildren( workInProgress, - JSCompiler_object_inline_message_2328, + JSCompiler_object_inline_message_2330, JSCompiler_temp, renderLanes )), - (JSCompiler_object_inline_componentStack_2331 = + (JSCompiler_object_inline_componentStack_2333 = workInProgress.child), - (JSCompiler_object_inline_componentStack_2331.memoizedState = + (JSCompiler_object_inline_componentStack_2333.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_componentStack_2331.childLanes = + (JSCompiler_object_inline_componentStack_2333.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_stack_2332 ); if ( "number" === - typeof JSCompiler_object_inline_stack_2330.unstable_expectedLoadTime + typeof JSCompiler_object_inline_stack_2332.unstable_expectedLoadTime ) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_stack_2330 = + (JSCompiler_object_inline_stack_2332 = mountSuspenseFallbackChildren( workInProgress, - JSCompiler_object_inline_message_2328, + JSCompiler_object_inline_message_2330, JSCompiler_temp, renderLanes )), - (JSCompiler_object_inline_componentStack_2331 = + (JSCompiler_object_inline_componentStack_2333 = workInProgress.child), - (JSCompiler_object_inline_componentStack_2331.memoizedState = + (JSCompiler_object_inline_componentStack_2333.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_componentStack_2331.childLanes = + (JSCompiler_object_inline_componentStack_2333.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), (workInProgress.lanes = 4194304), - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_stack_2332 ); pushPrimaryTreeSuspenseHandler(workInProgress); return mountSuspensePrimaryChildren( workInProgress, - JSCompiler_object_inline_message_2328 + JSCompiler_object_inline_message_2330 ); } var prevState = current.memoizedState; if ( null !== prevState && - ((JSCompiler_object_inline_message_2328 = prevState.dehydrated), - null !== JSCompiler_object_inline_message_2328) + ((JSCompiler_object_inline_message_2330 = prevState.dehydrated), + null !== JSCompiler_object_inline_message_2330) ) { if (didSuspend) workInProgress.flags & 256 @@ -9153,32 +9161,32 @@ __DEV__ && (workInProgress.flags |= 128), (workInProgress = null)) : (reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_componentStack_2331 = - JSCompiler_object_inline_stack_2330.fallback), - (JSCompiler_object_inline_message_2328 = workInProgress.mode), - (JSCompiler_object_inline_stack_2330 = createFiberFromOffscreen( + (JSCompiler_object_inline_componentStack_2333 = + JSCompiler_object_inline_stack_2332.fallback), + (JSCompiler_object_inline_message_2330 = workInProgress.mode), + (JSCompiler_object_inline_stack_2332 = createFiberFromOffscreen( { mode: "visible", - children: JSCompiler_object_inline_stack_2330.children + children: JSCompiler_object_inline_stack_2332.children }, - JSCompiler_object_inline_message_2328, + JSCompiler_object_inline_message_2330, 0, null )), - (JSCompiler_object_inline_componentStack_2331 = + (JSCompiler_object_inline_componentStack_2333 = createFiberFromFragment( - JSCompiler_object_inline_componentStack_2331, - JSCompiler_object_inline_message_2328, + JSCompiler_object_inline_componentStack_2333, + JSCompiler_object_inline_message_2330, renderLanes, null )), - (JSCompiler_object_inline_componentStack_2331.flags |= 2), - (JSCompiler_object_inline_stack_2330.return = workInProgress), - (JSCompiler_object_inline_componentStack_2331.return = + (JSCompiler_object_inline_componentStack_2333.flags |= 2), + (JSCompiler_object_inline_stack_2332.return = workInProgress), + (JSCompiler_object_inline_componentStack_2333.return = workInProgress), - (JSCompiler_object_inline_stack_2330.sibling = - JSCompiler_object_inline_componentStack_2331), - (workInProgress.child = JSCompiler_object_inline_stack_2330), + (JSCompiler_object_inline_stack_2332.sibling = + JSCompiler_object_inline_componentStack_2333), + (workInProgress.child = JSCompiler_object_inline_stack_2332), (workInProgress.mode & ConcurrentMode) !== NoMode && reconcileChildFibers( workInProgress, @@ -9186,64 +9194,64 @@ __DEV__ && null, renderLanes ), - (JSCompiler_object_inline_stack_2330 = workInProgress.child), - (JSCompiler_object_inline_stack_2330.memoizedState = + (JSCompiler_object_inline_stack_2332 = workInProgress.child), + (JSCompiler_object_inline_stack_2332.memoizedState = mountSuspenseOffscreenState(renderLanes)), - (JSCompiler_object_inline_stack_2330.childLanes = + (JSCompiler_object_inline_stack_2332.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), (workInProgress = - JSCompiler_object_inline_componentStack_2331)); + JSCompiler_object_inline_componentStack_2333)); else if ( (pushPrimaryTreeSuspenseHandler(workInProgress), isHydrating && error$jscomp$0( "We should not be hydrating here. This is a bug in React. Please file a bug." ), - JSCompiler_object_inline_message_2328.data === + JSCompiler_object_inline_message_2330.data === SUSPENSE_FALLBACK_START_DATA) ) { - JSCompiler_object_inline_digest_2329 = - JSCompiler_object_inline_message_2328.nextSibling && - JSCompiler_object_inline_message_2328.nextSibling.dataset; - if (JSCompiler_object_inline_digest_2329) { - JSCompiler_temp = JSCompiler_object_inline_digest_2329.dgst; - var message = JSCompiler_object_inline_digest_2329.msg; - instance = JSCompiler_object_inline_digest_2329.stck; - var componentStack = JSCompiler_object_inline_digest_2329.cstck; + JSCompiler_object_inline_digest_2331 = + JSCompiler_object_inline_message_2330.nextSibling && + JSCompiler_object_inline_message_2330.nextSibling.dataset; + if (JSCompiler_object_inline_digest_2331) { + JSCompiler_temp = JSCompiler_object_inline_digest_2331.dgst; + var message = JSCompiler_object_inline_digest_2331.msg; + instance = JSCompiler_object_inline_digest_2331.stck; + var componentStack = JSCompiler_object_inline_digest_2331.cstck; } - JSCompiler_object_inline_message_2328 = message; - JSCompiler_object_inline_digest_2329 = JSCompiler_temp; - JSCompiler_object_inline_stack_2330 = instance; - JSCompiler_temp = JSCompiler_object_inline_componentStack_2331 = + JSCompiler_object_inline_message_2330 = message; + JSCompiler_object_inline_digest_2331 = JSCompiler_temp; + JSCompiler_object_inline_stack_2332 = instance; + JSCompiler_temp = JSCompiler_object_inline_componentStack_2333 = componentStack; - JSCompiler_object_inline_componentStack_2331 = - JSCompiler_object_inline_message_2328 - ? Error(JSCompiler_object_inline_message_2328) + JSCompiler_object_inline_componentStack_2333 = + JSCompiler_object_inline_message_2330 + ? Error(JSCompiler_object_inline_message_2330) : Error( "The server could not finish this Suspense boundary, likely due to an error during server rendering. Switched to client rendering." ); - JSCompiler_object_inline_componentStack_2331.stack = - JSCompiler_object_inline_stack_2330 || ""; - JSCompiler_object_inline_componentStack_2331.digest = - JSCompiler_object_inline_digest_2329; - JSCompiler_object_inline_digest_2329 = + JSCompiler_object_inline_componentStack_2333.stack = + JSCompiler_object_inline_stack_2332 || ""; + JSCompiler_object_inline_componentStack_2333.digest = + JSCompiler_object_inline_digest_2331; + JSCompiler_object_inline_digest_2331 = void 0 === JSCompiler_temp ? null : JSCompiler_temp; - JSCompiler_object_inline_stack_2330 = { - value: JSCompiler_object_inline_componentStack_2331, + JSCompiler_object_inline_stack_2332 = { + value: JSCompiler_object_inline_componentStack_2333, source: null, - stack: JSCompiler_object_inline_digest_2329 + stack: JSCompiler_object_inline_digest_2331 }; - "string" === typeof JSCompiler_object_inline_digest_2329 && + "string" === typeof JSCompiler_object_inline_digest_2331 && CapturedStacks.set( - JSCompiler_object_inline_componentStack_2331, - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_componentStack_2333, + JSCompiler_object_inline_stack_2332 ); - queueHydrationError(JSCompiler_object_inline_stack_2330); + queueHydrationError(JSCompiler_object_inline_stack_2332); workInProgress = retrySuspenseComponentWithoutHydrating( current, workInProgress, @@ -9257,25 +9265,25 @@ __DEV__ && renderLanes, !1 ), - (JSCompiler_object_inline_digest_2329 = + (JSCompiler_object_inline_digest_2331 = 0 !== (renderLanes & current.childLanes)), - didReceiveUpdate || JSCompiler_object_inline_digest_2329) + didReceiveUpdate || JSCompiler_object_inline_digest_2331) ) { - JSCompiler_object_inline_digest_2329 = workInProgressRoot; - if (null !== JSCompiler_object_inline_digest_2329) { - JSCompiler_object_inline_stack_2330 = renderLanes & -renderLanes; - if (0 !== (JSCompiler_object_inline_stack_2330 & 42)) - JSCompiler_object_inline_stack_2330 = 1; + JSCompiler_object_inline_digest_2331 = workInProgressRoot; + if (null !== JSCompiler_object_inline_digest_2331) { + JSCompiler_object_inline_stack_2332 = renderLanes & -renderLanes; + if (0 !== (JSCompiler_object_inline_stack_2332 & 42)) + JSCompiler_object_inline_stack_2332 = 1; else - switch (JSCompiler_object_inline_stack_2330) { + switch (JSCompiler_object_inline_stack_2332) { case 2: - JSCompiler_object_inline_stack_2330 = 1; + JSCompiler_object_inline_stack_2332 = 1; break; case 8: - JSCompiler_object_inline_stack_2330 = 4; + JSCompiler_object_inline_stack_2332 = 4; break; case 32: - JSCompiler_object_inline_stack_2330 = 16; + JSCompiler_object_inline_stack_2332 = 16; break; case 128: case 256: @@ -9296,40 +9304,40 @@ __DEV__ && case 8388608: case 16777216: case 33554432: - JSCompiler_object_inline_stack_2330 = 64; + JSCompiler_object_inline_stack_2332 = 64; break; case 268435456: - JSCompiler_object_inline_stack_2330 = 134217728; + JSCompiler_object_inline_stack_2332 = 134217728; break; default: - JSCompiler_object_inline_stack_2330 = 0; + JSCompiler_object_inline_stack_2332 = 0; } - JSCompiler_object_inline_stack_2330 = + JSCompiler_object_inline_stack_2332 = 0 !== - (JSCompiler_object_inline_stack_2330 & - (JSCompiler_object_inline_digest_2329.suspendedLanes | + (JSCompiler_object_inline_stack_2332 & + (JSCompiler_object_inline_digest_2331.suspendedLanes | renderLanes)) ? 0 - : JSCompiler_object_inline_stack_2330; + : JSCompiler_object_inline_stack_2332; if ( - 0 !== JSCompiler_object_inline_stack_2330 && - JSCompiler_object_inline_stack_2330 !== prevState.retryLane + 0 !== JSCompiler_object_inline_stack_2332 && + JSCompiler_object_inline_stack_2332 !== prevState.retryLane ) throw ( - ((prevState.retryLane = JSCompiler_object_inline_stack_2330), + ((prevState.retryLane = JSCompiler_object_inline_stack_2332), enqueueConcurrentRenderForLane( current, - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_stack_2332 ), scheduleUpdateOnFiber( - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331, current, - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_stack_2332 ), SelectiveHydrationException) ); } - JSCompiler_object_inline_message_2328.data === + JSCompiler_object_inline_message_2330.data === SUSPENSE_PENDING_START_DATA || renderDidSuspendDelayIfPossible(); workInProgress = retrySuspenseComponentWithoutHydrating( current, @@ -9337,7 +9345,7 @@ __DEV__ && renderLanes ); } else - JSCompiler_object_inline_message_2328.data === + JSCompiler_object_inline_message_2330.data === SUSPENSE_PENDING_START_DATA ? ((workInProgress.flags |= 128), (workInProgress.child = current.child), @@ -9345,12 +9353,12 @@ __DEV__ && null, current )), - (JSCompiler_object_inline_message_2328._reactRetry = + (JSCompiler_object_inline_message_2330._reactRetry = workInProgress), (workInProgress = null)) : ((renderLanes = prevState.treeContext), (nextHydratableInstance = getNextHydratable( - JSCompiler_object_inline_message_2328.nextSibling + JSCompiler_object_inline_message_2330.nextSibling )), (hydrationParentFiber = workInProgress), (isHydrating = !0), @@ -9368,72 +9376,72 @@ __DEV__ && (treeContextProvider = workInProgress)), (workInProgress = mountSuspensePrimaryChildren( workInProgress, - JSCompiler_object_inline_stack_2330.children + JSCompiler_object_inline_stack_2332.children )), (workInProgress.flags |= 4096)); return workInProgress; } - if (JSCompiler_object_inline_componentStack_2331) + if (JSCompiler_object_inline_componentStack_2333) return ( reuseSuspenseHandlerOnStack(workInProgress), - (JSCompiler_object_inline_componentStack_2331 = - JSCompiler_object_inline_stack_2330.fallback), - (JSCompiler_object_inline_message_2328 = workInProgress.mode), + (JSCompiler_object_inline_componentStack_2333 = + JSCompiler_object_inline_stack_2332.fallback), + (JSCompiler_object_inline_message_2330 = workInProgress.mode), (JSCompiler_temp = current.child), (instance = JSCompiler_temp.sibling), (componentStack = { mode: "hidden", - children: JSCompiler_object_inline_stack_2330.children + children: JSCompiler_object_inline_stack_2332.children }), - (JSCompiler_object_inline_message_2328 & ConcurrentMode) === NoMode && + (JSCompiler_object_inline_message_2330 & ConcurrentMode) === NoMode && workInProgress.child !== JSCompiler_temp - ? ((JSCompiler_object_inline_stack_2330 = workInProgress.child), - (JSCompiler_object_inline_stack_2330.childLanes = 0), - (JSCompiler_object_inline_stack_2330.pendingProps = + ? ((JSCompiler_object_inline_stack_2332 = workInProgress.child), + (JSCompiler_object_inline_stack_2332.childLanes = 0), + (JSCompiler_object_inline_stack_2332.pendingProps = componentStack), workInProgress.mode & ProfileMode && - ((JSCompiler_object_inline_stack_2330.actualDuration = -0), - (JSCompiler_object_inline_stack_2330.actualStartTime = -1.1), - (JSCompiler_object_inline_stack_2330.selfBaseDuration = + ((JSCompiler_object_inline_stack_2332.actualDuration = -0), + (JSCompiler_object_inline_stack_2332.actualStartTime = -1.1), + (JSCompiler_object_inline_stack_2332.selfBaseDuration = JSCompiler_temp.selfBaseDuration), - (JSCompiler_object_inline_stack_2330.treeBaseDuration = + (JSCompiler_object_inline_stack_2332.treeBaseDuration = JSCompiler_temp.treeBaseDuration)), (workInProgress.deletions = null)) - : ((JSCompiler_object_inline_stack_2330 = createWorkInProgress( + : ((JSCompiler_object_inline_stack_2332 = createWorkInProgress( JSCompiler_temp, componentStack )), - (JSCompiler_object_inline_stack_2330.subtreeFlags = + (JSCompiler_object_inline_stack_2332.subtreeFlags = JSCompiler_temp.subtreeFlags & 31457280)), null !== instance - ? (JSCompiler_object_inline_componentStack_2331 = + ? (JSCompiler_object_inline_componentStack_2333 = createWorkInProgress( instance, - JSCompiler_object_inline_componentStack_2331 + JSCompiler_object_inline_componentStack_2333 )) - : ((JSCompiler_object_inline_componentStack_2331 = + : ((JSCompiler_object_inline_componentStack_2333 = createFiberFromFragment( - JSCompiler_object_inline_componentStack_2331, - JSCompiler_object_inline_message_2328, + JSCompiler_object_inline_componentStack_2333, + JSCompiler_object_inline_message_2330, renderLanes, null )), - (JSCompiler_object_inline_componentStack_2331.flags |= 2)), - (JSCompiler_object_inline_componentStack_2331.return = + (JSCompiler_object_inline_componentStack_2333.flags |= 2)), + (JSCompiler_object_inline_componentStack_2333.return = workInProgress), - (JSCompiler_object_inline_stack_2330.return = workInProgress), - (JSCompiler_object_inline_stack_2330.sibling = - JSCompiler_object_inline_componentStack_2331), - (workInProgress.child = JSCompiler_object_inline_stack_2330), - (JSCompiler_object_inline_stack_2330 = - JSCompiler_object_inline_componentStack_2331), - (JSCompiler_object_inline_componentStack_2331 = workInProgress.child), - (JSCompiler_object_inline_message_2328 = current.child.memoizedState), - null === JSCompiler_object_inline_message_2328 - ? (JSCompiler_object_inline_message_2328 = + (JSCompiler_object_inline_stack_2332.return = workInProgress), + (JSCompiler_object_inline_stack_2332.sibling = + JSCompiler_object_inline_componentStack_2333), + (workInProgress.child = JSCompiler_object_inline_stack_2332), + (JSCompiler_object_inline_stack_2332 = + JSCompiler_object_inline_componentStack_2333), + (JSCompiler_object_inline_componentStack_2333 = workInProgress.child), + (JSCompiler_object_inline_message_2330 = current.child.memoizedState), + null === JSCompiler_object_inline_message_2330 + ? (JSCompiler_object_inline_message_2330 = mountSuspenseOffscreenState(renderLanes)) : ((JSCompiler_temp = - JSCompiler_object_inline_message_2328.cachePool), + JSCompiler_object_inline_message_2330.cachePool), null !== JSCompiler_temp ? ((instance = CacheContext._currentValue), (JSCompiler_temp = @@ -9441,45 +9449,45 @@ __DEV__ && ? { parent: instance, pool: instance } : JSCompiler_temp)) : (JSCompiler_temp = getSuspendedCache()), - (JSCompiler_object_inline_message_2328 = { + (JSCompiler_object_inline_message_2330 = { baseLanes: - JSCompiler_object_inline_message_2328.baseLanes | renderLanes, + JSCompiler_object_inline_message_2330.baseLanes | renderLanes, cachePool: JSCompiler_temp })), - (JSCompiler_object_inline_componentStack_2331.memoizedState = - JSCompiler_object_inline_message_2328), - (JSCompiler_object_inline_componentStack_2331.childLanes = + (JSCompiler_object_inline_componentStack_2333.memoizedState = + JSCompiler_object_inline_message_2330), + (JSCompiler_object_inline_componentStack_2333.childLanes = getRemainingWorkInPrimaryTree( current, - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331, renderLanes )), (workInProgress.memoizedState = SUSPENDED_MARKER), - JSCompiler_object_inline_stack_2330 + JSCompiler_object_inline_stack_2332 ); pushPrimaryTreeSuspenseHandler(workInProgress); - JSCompiler_object_inline_digest_2329 = current.child; - current = JSCompiler_object_inline_digest_2329.sibling; - JSCompiler_object_inline_digest_2329 = createWorkInProgress( - JSCompiler_object_inline_digest_2329, + JSCompiler_object_inline_digest_2331 = current.child; + current = JSCompiler_object_inline_digest_2331.sibling; + JSCompiler_object_inline_digest_2331 = createWorkInProgress( + JSCompiler_object_inline_digest_2331, { mode: "visible", - children: JSCompiler_object_inline_stack_2330.children + children: JSCompiler_object_inline_stack_2332.children } ); (workInProgress.mode & ConcurrentMode) === NoMode && - (JSCompiler_object_inline_digest_2329.lanes = renderLanes); - JSCompiler_object_inline_digest_2329.return = workInProgress; - JSCompiler_object_inline_digest_2329.sibling = null; + (JSCompiler_object_inline_digest_2331.lanes = renderLanes); + JSCompiler_object_inline_digest_2331.return = workInProgress; + JSCompiler_object_inline_digest_2331.sibling = null; null !== current && ((renderLanes = workInProgress.deletions), null === renderLanes ? ((workInProgress.deletions = [current]), (workInProgress.flags |= 16)) : renderLanes.push(current)); - workInProgress.child = JSCompiler_object_inline_digest_2329; + workInProgress.child = JSCompiler_object_inline_digest_2331; workInProgress.memoizedState = null; - return JSCompiler_object_inline_digest_2329; + return JSCompiler_object_inline_digest_2331; } function mountSuspensePrimaryChildren(workInProgress, primaryChildren) { primaryChildren = createFiberFromOffscreen( @@ -14958,7 +14966,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if ( @@ -15001,7 +15009,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 !== lane || @@ -15014,191 +15022,195 @@ __DEV__ && function performWorkOnRoot(root, lanes, forceSync) { if ((executionContext & (RenderContext | CommitContext)) !== NoContext) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && 0 === (lanes & 60) && 0 === (lanes & root.expiredLanes)) - ? renderRootConcurrent(root, lanes) - : renderRootSync(root, lanes); - if (exitStatus !== RootInProgress) { - var renderWasConcurrent = forceSync; - do { - if (exitStatus === RootDidNotComplete) - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root.tag && exitStatus === RootErrored) { - renderWasConcurrent = lanes; - if (root.errorRecoveryDisabledLanes & renderWasConcurrent) - var errorRetryLanes = 0; - else - (errorRetryLanes = root.pendingLanes & -536870913), - (errorRetryLanes = - 0 !== errorRetryLanes - ? errorRetryLanes - : errorRetryLanes & 536870912 - ? 536870912 - : 0); - if (0 !== errorRetryLanes) { - lanes = errorRetryLanes; - a: { - exitStatus = root; - var errorRetryLanes$jscomp$0 = errorRetryLanes; - errorRetryLanes = workInProgressRootConcurrentErrors; - var wasRootDehydrated = - exitStatus.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack( - exitStatus, - errorRetryLanes$jscomp$0 - ).flags |= 256); - errorRetryLanes$jscomp$0 = renderRootSync( + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root.expiredLanes)) || + (enableSiblingPrerendering && checkIfRootIsPrerendering(root, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root, lanes) + : renderRootSync(root, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (exitStatus === RootInProgress) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root, lanes, 0, !1); + break; + } else if (exitStatus === RootDidNotComplete) + markRootSuspended( + root, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root.tag && exitStatus === RootErrored) { + renderWasConcurrent = lanes; + if (root.errorRecoveryDisabledLanes & renderWasConcurrent) + var errorRetryLanes = 0; + else + (errorRetryLanes = root.pendingLanes & -536870913), + (errorRetryLanes = + 0 !== errorRetryLanes + ? errorRetryLanes + : errorRetryLanes & 536870912 + ? 536870912 + : 0); + if (0 !== errorRetryLanes) { + lanes = errorRetryLanes; + a: { + exitStatus = root; + var errorRetryLanes$jscomp$0 = errorRetryLanes; + errorRetryLanes = workInProgressRootConcurrentErrors; + var wasRootDehydrated = + exitStatus.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack( exitStatus, errorRetryLanes$jscomp$0 - ); - if (errorRetryLanes$jscomp$0 !== RootErrored) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - exitStatus.errorRecoveryDisabledLanes |= - renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = RootSuspendedWithDelay; - break a; - } - exitStatus = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = errorRetryLanes; - null !== exitStatus && queueRecoverableErrors(exitStatus); + ).flags |= 256); + errorRetryLanes$jscomp$0 = renderRootSync( + exitStatus, + errorRetryLanes$jscomp$0, + !1 + ); + if (errorRetryLanes$jscomp$0 !== RootErrored) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + exitStatus.errorRecoveryDisabledLanes |= + renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = RootSuspendedWithDelay; + break a; } - exitStatus = errorRetryLanes$jscomp$0; + exitStatus = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = errorRetryLanes; + null !== exitStatus && queueRecoverableErrors(exitStatus); } - renderWasConcurrent = !1; - if (exitStatus !== RootErrored) continue; + exitStatus = errorRetryLanes$jscomp$0; } + renderWasConcurrent = !1; + if (exitStatus !== RootErrored) continue; } - if (exitStatus === RootFatalErrored) { - prepareFreshStack(root, 0); - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - break; - } - a: { - renderWasConcurrent = root; - switch (exitStatus) { - case RootInProgress: - case RootFatalErrored: - throw Error("Root did not complete. This is a bug in React."); - case RootSuspendedWithDelay: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case RootErrored: - workInProgressRootRecoverableErrors = null; - break; - case RootSuspended: - case RootCompleted: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if (null !== ReactSharedInternals.actQueue) - commitRoot( - renderWasConcurrent, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - IMMEDIATE_COMMIT, - renderStartTime, - 0 - ); - else { - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || exitStatus === RootSuspended) && - ((exitStatus = - globalMostRecentFallbackTime + - FALLBACK_THROTTLE_MS - - now$1()), - 10 < exitStatus) - ) { + } + if (exitStatus === RootFatalErrored) { + prepareFreshStack(root, 0); + markRootSuspended(root, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root; + switch (exitStatus) { + case RootInProgress: + case RootFatalErrored: + throw Error("Root did not complete. This is a bug in React."); + case RootSuspendedWithDelay: + if ((lanes & 4194176) === lanes) { markRootSuspended( - renderWasConcurrent, + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - THROTTLED_COMMIT, - renderStartTime, - 0 - ), - exitStatus + !workInProgressRootDidSkipSuspendedSiblings ); break a; } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, + break; + case RootErrored: + workInProgressRootRecoverableErrors = null; + break; + case RootSuspended: + case RootCompleted: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if (null !== ReactSharedInternals.actQueue) + commitRoot( + shouldTimeSlice, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + IMMEDIATE_COMMIT, + renderStartTime, + 0 + ); + else { + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || exitStatus === RootSuspended) && + ((exitStatus = + globalMostRecentFallbackTime + + FALLBACK_THROTTLE_MS - + now$1()), + 10 < exitStatus) + ) { + markRootSuspended( + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - IMMEDIATE_COMMIT, - renderStartTime, - 0 + !workInProgressRootDidSkipSuspendedSiblings ); + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + THROTTLED_COMMIT, + renderStartTime, + 0 + ), + exitStatus + ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + IMMEDIATE_COMMIT, + renderStartTime, + 0 + ); } } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root); } function queueRecoverableErrors(errors) { @@ -15251,7 +15263,12 @@ __DEV__ && completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended( + root, + lanes, + spawnedLane, + !didSkipSuspendedSiblings + ); return; } commitRoot( @@ -15305,20 +15322,20 @@ __DEV__ && root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index = 31 - clz32(lanes), lane = 1 << index; - didSkipSuspendedSiblings[index] = -1; + didAttemptEntireTree[index] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -15362,11 +15379,7 @@ __DEV__ && workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressRootExitStatus = RootInProgress; workInProgressSuspendedRetryLanes = @@ -15489,7 +15502,9 @@ __DEV__ && function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = RootSuspendedWithDelay; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -15498,10 +15513,10 @@ __DEV__ && workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } - function renderRootSync(root, lanes) { + function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(), @@ -15522,37 +15537,46 @@ __DEV__ && } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if ( workInProgressSuspendedReason !== NotSuspended && null !== workInProgress ) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case SuspendedOnHydration: resetWorkInProgressStack(); - workInProgressRootExitStatus = RootDidNotComplete; + memoizedUpdaters = RootDidNotComplete; break a; case SuspendedOnImmediate: case SuspendedOnData: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case SuspendedOnDeprecatedThrowPromise: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; - throwAndUnwindWorkLoop( - root, - memoizedUpdaters, - thrownValue, - reason - ); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = RootInProgress; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = NotSuspended), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; } catch (thrownValue$42) { handleThrow(root, thrownValue$42); @@ -15563,15 +15587,12 @@ __DEV__ && executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -15596,12 +15617,10 @@ __DEV__ && workInProgressRootRenderTargetTime = now$1() + RENDER_TIMEOUT_MS; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + ); markRenderStarted(lanes); a: do try { @@ -16572,7 +16591,8 @@ __DEV__ && root, root === workInProgressRoot ? nextLanes : 0 )), - 0 !== (nextLanes & 3) && + 0 === (nextLanes & 3) || + checkIfRootIsPrerendering(root, nextLanes) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, nextLanes)); root = root.next; @@ -16646,45 +16666,46 @@ __DEV__ && (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && cancelCallback(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; if ( - currentTime !== root.callbackPriority || - (null !== ReactSharedInternals.actQueue && - pingedLanes !== fakeActCallbackNode) - ) - cancelCallback(pingedLanes); - else return currentTime; - switch (lanesToEventPriority(suspendedLanes)) { - case DiscreteEventPriority: - suspendedLanes = ImmediatePriority; - break; - case ContinuousEventPriority: - suspendedLanes = UserBlockingPriority; - break; - case DefaultEventPriority: - suspendedLanes = NormalPriority$1; - break; - case IdleEventPriority: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - null !== ReactSharedInternals.actQueue - ? (ReactSharedInternals.actQueue.push(pingedLanes), - (suspendedLanes = fakeActCallbackNode)) - : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if ( + currentTime !== root.callbackPriority || + (null !== ReactSharedInternals.actQueue && + pingedLanes !== fakeActCallbackNode) + ) + cancelCallback(pingedLanes); + else return currentTime; + switch (lanesToEventPriority(suspendedLanes)) { + case DiscreteEventPriority: + case ContinuousEventPriority: + suspendedLanes = UserBlockingPriority; + break; + case DefaultEventPriority: + suspendedLanes = NormalPriority$1; + break; + case IdleEventPriority: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + null !== ReactSharedInternals.actQueue + ? (ReactSharedInternals.actQueue.push(pingedLanes), + (suspendedLanes = fakeActCallbackNode)) + : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && cancelCallback(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -25391,11 +25412,11 @@ __DEV__ && }; (function () { var isomorphicReactPackageVersion = React.version; - if ("19.0.0-native-fb-5c56b873-20241107" !== isomorphicReactPackageVersion) + if ("19.0.0-native-fb-989af12f-20241108" !== isomorphicReactPackageVersion) throw Error( 'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' + (isomorphicReactPackageVersion + - "\n - react-dom: 19.0.0-native-fb-5c56b873-20241107\nLearn more: https://react.dev/warnings/version-mismatch") + "\n - react-dom: 19.0.0-native-fb-989af12f-20241108\nLearn more: https://react.dev/warnings/version-mismatch") ); })(); ("function" === typeof Map && @@ -25432,11 +25453,11 @@ __DEV__ && !(function () { var internals = { bundleType: 1, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; internals.overrideHookState = overrideHookState; internals.overrideHookStateDeletePath = overrideHookStateDeletePath; @@ -25896,7 +25917,7 @@ __DEV__ && exports.useFormStatus = function () { return resolveDispatcher().useHostTransitionStatus(); }; - exports.version = "19.0.0-native-fb-5c56b873-20241107"; + exports.version = "19.0.0-native-fb-989af12f-20241108"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-prod.js index c153bca74824a..31859ab04cfdb 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<33e73d248be00fc8822953d7e4876584>> + * @generated SignedSource<<5a096c3eed520ec28b8b68efbfa07b0c>> */ /* @@ -703,6 +703,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2063,19 +2071,19 @@ function getTargetInstForChangeEvent(domEventName, targetInst) { } var isInputEventSupported = !1; if (canUseDOM) { - var JSCompiler_inline_result$jscomp$289; + var JSCompiler_inline_result$jscomp$294; if (canUseDOM) { - var isSupported$jscomp$inline_423 = "oninput" in document; - if (!isSupported$jscomp$inline_423) { - var element$jscomp$inline_424 = document.createElement("div"); - element$jscomp$inline_424.setAttribute("oninput", "return;"); - isSupported$jscomp$inline_423 = - "function" === typeof element$jscomp$inline_424.oninput; + var isSupported$jscomp$inline_428 = "oninput" in document; + if (!isSupported$jscomp$inline_428) { + var element$jscomp$inline_429 = document.createElement("div"); + element$jscomp$inline_429.setAttribute("oninput", "return;"); + isSupported$jscomp$inline_428 = + "function" === typeof element$jscomp$inline_429.oninput; } - JSCompiler_inline_result$jscomp$289 = isSupported$jscomp$inline_423; - } else JSCompiler_inline_result$jscomp$289 = !1; + JSCompiler_inline_result$jscomp$294 = isSupported$jscomp$inline_428; + } else JSCompiler_inline_result$jscomp$294 = !1; isInputEventSupported = - JSCompiler_inline_result$jscomp$289 && + JSCompiler_inline_result$jscomp$294 && (!document.documentMode || 9 < document.documentMode); } function stopWatchingForValueChange() { @@ -10770,7 +10778,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -10782,7 +10790,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -10793,172 +10801,174 @@ function scheduleUpdateOnFiber(root, fiber, lane) { } function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327)); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - var wasRootDehydrated = root.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack(root, JSCompiler_inline_result).flags |= - 256); - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + var wasRootDehydrated = root.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack(root, JSCompiler_inline_result).flags |= 256); + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error(formatProdErrorMessage(345)); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error(formatProdErrorMessage(329)); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error(formatProdErrorMessage(345)); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error(formatProdErrorMessage(329)); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -11007,7 +11017,7 @@ function commitRootWhenReady( completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended(root, lanes, spawnedLane, !didSkipSuspendedSiblings); return; } commitRoot( @@ -11061,20 +11071,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$6 = 31 - clz32(lanes), lane = 1 << index$6; - didSkipSuspendedSiblings[index$6] = -1; + didAttemptEntireTree[index$6] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -11118,9 +11128,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -11208,7 +11216,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -11217,10 +11227,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -11228,6 +11238,7 @@ function renderRootSync(root, lanes) { if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -11236,24 +11247,37 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + exitStatus = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$170) { - handleThrow(root, thrownValue$170); + } catch (thrownValue$175) { + handleThrow(root, thrownValue$175); } while (1); lanes && root.shellSuspendCounter++; @@ -11261,11 +11285,11 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) throw Error(formatProdErrorMessage(261)); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -11279,12 +11303,10 @@ function renderRootConcurrent(root, lanes) { ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), prepareFreshStack(root, lanes)) - : workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + : (workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + )); a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -11368,8 +11390,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$172) { - handleThrow(root, thrownValue$172); + } catch (thrownValue$177) { + handleThrow(root, thrownValue$177); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -11687,7 +11709,7 @@ function releaseRootPooledCache(root, remainingLanes) { } function flushPassiveEffects() { if (null !== rootWithPendingPassiveEffects) { - var root$176 = rootWithPendingPassiveEffects, + var root$181 = rootWithPendingPassiveEffects, remainingLanes = pendingPassiveEffectsRemainingLanes; pendingPassiveEffectsRemainingLanes = 0; var renderPriority = lanesToEventPriority(pendingPassiveEffectsLanes), @@ -11726,7 +11748,7 @@ function flushPassiveEffects() { } finally { (ReactDOMSharedInternals.p = previousPriority), (ReactSharedInternals.T = prevTransition), - releaseRootPooledCache(root$176, remainingLanes); + releaseRootPooledCache(root$181, remainingLanes); } } return !1; @@ -11870,14 +11892,14 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { isFlushingWork = !0; do { var didPerformSomeWork = !1; - for (var root$178 = firstScheduledRoot; null !== root$178; ) { - if (!onlyLegacy || 0 === root$178.tag) + for (var root$183 = firstScheduledRoot; null !== root$183; ) { + if (!onlyLegacy || 0 === root$183.tag) if (0 !== syncTransitionLanes) { - var pendingLanes = root$178.pendingLanes; + var pendingLanes = root$183.pendingLanes; if (0 === pendingLanes) var JSCompiler_inline_result = 0; else { - var suspendedLanes = root$178.suspendedLanes, - pingedLanes = root$178.pingedLanes; + var suspendedLanes = root$183.suspendedLanes, + pingedLanes = root$183.pingedLanes; JSCompiler_inline_result = (1 << (31 - clz32(42 | syncTransitionLanes) + 1)) - 1; JSCompiler_inline_result &= @@ -11891,17 +11913,18 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { } 0 !== JSCompiler_inline_result && ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$178, JSCompiler_inline_result)); + performSyncWorkOnRoot(root$183, JSCompiler_inline_result)); } else (JSCompiler_inline_result = workInProgressRootRenderLanes), (JSCompiler_inline_result = getNextLanes( - root$178, - root$178 === workInProgressRoot ? JSCompiler_inline_result : 0 + root$183, + root$183 === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root$183, JSCompiler_inline_result) || ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$178, JSCompiler_inline_result)); - root$178 = root$178.next; + performSyncWorkOnRoot(root$183, JSCompiler_inline_result)); + root$183 = root$183.next; } } while (didPerformSomeWork); isFlushingWork = !1; @@ -11970,39 +11993,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { var originalCallbackNode = root.callbackNode; @@ -12131,20 +12153,20 @@ function extractEvents$1( } } for ( - var i$jscomp$inline_1449 = 0; - i$jscomp$inline_1449 < simpleEventPluginEvents.length; - i$jscomp$inline_1449++ + var i$jscomp$inline_1456 = 0; + i$jscomp$inline_1456 < simpleEventPluginEvents.length; + i$jscomp$inline_1456++ ) { - var eventName$jscomp$inline_1450 = - simpleEventPluginEvents[i$jscomp$inline_1449], - domEventName$jscomp$inline_1451 = - eventName$jscomp$inline_1450.toLowerCase(), - capitalizedEvent$jscomp$inline_1452 = - eventName$jscomp$inline_1450[0].toUpperCase() + - eventName$jscomp$inline_1450.slice(1); + var eventName$jscomp$inline_1457 = + simpleEventPluginEvents[i$jscomp$inline_1456], + domEventName$jscomp$inline_1458 = + eventName$jscomp$inline_1457.toLowerCase(), + capitalizedEvent$jscomp$inline_1459 = + eventName$jscomp$inline_1457[0].toUpperCase() + + eventName$jscomp$inline_1457.slice(1); registerSimpleEvent( - domEventName$jscomp$inline_1451, - "on" + capitalizedEvent$jscomp$inline_1452 + domEventName$jscomp$inline_1458, + "on" + capitalizedEvent$jscomp$inline_1459 ); } registerSimpleEvent(ANIMATION_END, "onAnimationEnd"); @@ -13327,34 +13349,34 @@ function setInitialProperties(domElement, tag, props) { defaultChecked = null; for (hasSrc in props) if (props.hasOwnProperty(hasSrc)) { - var propValue$192 = props[hasSrc]; - if (null != propValue$192) + var propValue$197 = props[hasSrc]; + if (null != propValue$197) switch (hasSrc) { case "name": - hasSrcSet = propValue$192; + hasSrcSet = propValue$197; break; case "type": - propValue = propValue$192; + propValue = propValue$197; break; case "checked": - checked = propValue$192; + checked = propValue$197; break; case "defaultChecked": - defaultChecked = propValue$192; + defaultChecked = propValue$197; break; case "value": - propKey = propValue$192; + propKey = propValue$197; break; case "defaultValue": - defaultValue = propValue$192; + defaultValue = propValue$197; break; case "children": case "dangerouslySetInnerHTML": - if (null != propValue$192) + if (null != propValue$197) throw Error(formatProdErrorMessage(137, tag)); break; default: - setProp(domElement, tag, hasSrc, propValue$192, props, null); + setProp(domElement, tag, hasSrc, propValue$197, props, null); } } initInput( @@ -13491,14 +13513,14 @@ function setInitialProperties(domElement, tag, props) { return; default: if (isCustomElement(tag)) { - for (propValue$192 in props) - props.hasOwnProperty(propValue$192) && - ((hasSrc = props[propValue$192]), + for (propValue$197 in props) + props.hasOwnProperty(propValue$197) && + ((hasSrc = props[propValue$197]), void 0 !== hasSrc && setPropOnCustomElement( domElement, tag, - propValue$192, + propValue$197, hasSrc, props, void 0 @@ -13546,14 +13568,14 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp(domElement, tag, propKey, null, nextProps, lastProp); } } - for (var propKey$209 in nextProps) { - var propKey = nextProps[propKey$209]; - lastProp = lastProps[propKey$209]; + for (var propKey$214 in nextProps) { + var propKey = nextProps[propKey$214]; + lastProp = lastProps[propKey$214]; if ( - nextProps.hasOwnProperty(propKey$209) && + nextProps.hasOwnProperty(propKey$214) && (null != propKey || null != lastProp) ) - switch (propKey$209) { + switch (propKey$214) { case "type": type = propKey; break; @@ -13582,7 +13604,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$209, + propKey$214, propKey, nextProps, lastProp @@ -13601,7 +13623,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ); return; case "select": - propKey = value = defaultValue = propKey$209 = null; + propKey = value = defaultValue = propKey$214 = null; for (type in lastProps) if ( ((lastDefaultValue = lastProps[type]), @@ -13632,7 +13654,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (name) { case "value": - propKey$209 = type; + propKey$214 = type; break; case "defaultValue": defaultValue = type; @@ -13653,15 +13675,15 @@ function updateProperties(domElement, tag, lastProps, nextProps) { tag = defaultValue; lastProps = value; nextProps = propKey; - null != propKey$209 - ? updateOptions(domElement, !!lastProps, propKey$209, !1) + null != propKey$214 + ? updateOptions(domElement, !!lastProps, propKey$214, !1) : !!nextProps !== !!lastProps && (null != tag ? updateOptions(domElement, !!lastProps, tag, !0) : updateOptions(domElement, !!lastProps, lastProps ? [] : "", !1)); return; case "textarea": - propKey = propKey$209 = null; + propKey = propKey$214 = null; for (defaultValue in lastProps) if ( ((name = lastProps[defaultValue]), @@ -13685,7 +13707,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (value) { case "value": - propKey$209 = name; + propKey$214 = name; break; case "defaultValue": propKey = name; @@ -13699,17 +13721,17 @@ function updateProperties(domElement, tag, lastProps, nextProps) { name !== type && setProp(domElement, tag, value, name, nextProps, type); } - updateTextarea(domElement, propKey$209, propKey); + updateTextarea(domElement, propKey$214, propKey); return; case "option": - for (var propKey$225 in lastProps) + for (var propKey$230 in lastProps) if ( - ((propKey$209 = lastProps[propKey$225]), - lastProps.hasOwnProperty(propKey$225) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$225)) + ((propKey$214 = lastProps[propKey$230]), + lastProps.hasOwnProperty(propKey$230) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$230)) ) - switch (propKey$225) { + switch (propKey$230) { case "selected": domElement.selected = !1; break; @@ -13717,33 +13739,33 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$225, + propKey$230, null, nextProps, - propKey$209 + propKey$214 ); } for (lastDefaultValue in nextProps) if ( - ((propKey$209 = nextProps[lastDefaultValue]), + ((propKey$214 = nextProps[lastDefaultValue]), (propKey = lastProps[lastDefaultValue]), nextProps.hasOwnProperty(lastDefaultValue) && - propKey$209 !== propKey && - (null != propKey$209 || null != propKey)) + propKey$214 !== propKey && + (null != propKey$214 || null != propKey)) ) switch (lastDefaultValue) { case "selected": domElement.selected = - propKey$209 && - "function" !== typeof propKey$209 && - "symbol" !== typeof propKey$209; + propKey$214 && + "function" !== typeof propKey$214 && + "symbol" !== typeof propKey$214; break; default: setProp( domElement, tag, lastDefaultValue, - propKey$209, + propKey$214, nextProps, propKey ); @@ -13764,24 +13786,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { case "track": case "wbr": case "menuitem": - for (var propKey$230 in lastProps) - (propKey$209 = lastProps[propKey$230]), - lastProps.hasOwnProperty(propKey$230) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$230) && - setProp(domElement, tag, propKey$230, null, nextProps, propKey$209); + for (var propKey$235 in lastProps) + (propKey$214 = lastProps[propKey$235]), + lastProps.hasOwnProperty(propKey$235) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$235) && + setProp(domElement, tag, propKey$235, null, nextProps, propKey$214); for (checked in nextProps) if ( - ((propKey$209 = nextProps[checked]), + ((propKey$214 = nextProps[checked]), (propKey = lastProps[checked]), nextProps.hasOwnProperty(checked) && - propKey$209 !== propKey && - (null != propKey$209 || null != propKey)) + propKey$214 !== propKey && + (null != propKey$214 || null != propKey)) ) switch (checked) { case "children": case "dangerouslySetInnerHTML": - if (null != propKey$209) + if (null != propKey$214) throw Error(formatProdErrorMessage(137, tag)); break; default: @@ -13789,7 +13811,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { domElement, tag, checked, - propKey$209, + propKey$214, nextProps, propKey ); @@ -13797,49 +13819,49 @@ function updateProperties(domElement, tag, lastProps, nextProps) { return; default: if (isCustomElement(tag)) { - for (var propKey$235 in lastProps) - (propKey$209 = lastProps[propKey$235]), - lastProps.hasOwnProperty(propKey$235) && - void 0 !== propKey$209 && - !nextProps.hasOwnProperty(propKey$235) && + for (var propKey$240 in lastProps) + (propKey$214 = lastProps[propKey$240]), + lastProps.hasOwnProperty(propKey$240) && + void 0 !== propKey$214 && + !nextProps.hasOwnProperty(propKey$240) && setPropOnCustomElement( domElement, tag, - propKey$235, + propKey$240, void 0, nextProps, - propKey$209 + propKey$214 ); for (defaultChecked in nextProps) - (propKey$209 = nextProps[defaultChecked]), + (propKey$214 = nextProps[defaultChecked]), (propKey = lastProps[defaultChecked]), !nextProps.hasOwnProperty(defaultChecked) || - propKey$209 === propKey || - (void 0 === propKey$209 && void 0 === propKey) || + propKey$214 === propKey || + (void 0 === propKey$214 && void 0 === propKey) || setPropOnCustomElement( domElement, tag, defaultChecked, - propKey$209, + propKey$214, nextProps, propKey ); return; } } - for (var propKey$240 in lastProps) - (propKey$209 = lastProps[propKey$240]), - lastProps.hasOwnProperty(propKey$240) && - null != propKey$209 && - !nextProps.hasOwnProperty(propKey$240) && - setProp(domElement, tag, propKey$240, null, nextProps, propKey$209); + for (var propKey$245 in lastProps) + (propKey$214 = lastProps[propKey$245]), + lastProps.hasOwnProperty(propKey$245) && + null != propKey$214 && + !nextProps.hasOwnProperty(propKey$245) && + setProp(domElement, tag, propKey$245, null, nextProps, propKey$214); for (lastProp in nextProps) - (propKey$209 = nextProps[lastProp]), + (propKey$214 = nextProps[lastProp]), (propKey = lastProps[lastProp]), !nextProps.hasOwnProperty(lastProp) || - propKey$209 === propKey || - (null == propKey$209 && null == propKey) || - setProp(domElement, tag, lastProp, propKey$209, nextProps, propKey); + propKey$214 === propKey || + (null == propKey$214 && null == propKey) || + setProp(domElement, tag, lastProp, propKey$214, nextProps, propKey); } var eventsEnabled = null, selectionInformation = null; @@ -14379,26 +14401,26 @@ function getResource(type, currentProps, pendingProps, currentResource) { "string" === typeof pendingProps.precedence ) { type = getStyleKey(pendingProps.href); - var styles$248 = getResourcesFromRoot( + var styles$253 = getResourcesFromRoot( JSCompiler_inline_result ).hoistableStyles, - resource$249 = styles$248.get(type); - resource$249 || + resource$254 = styles$253.get(type); + resource$254 || ((JSCompiler_inline_result = JSCompiler_inline_result.ownerDocument || JSCompiler_inline_result), - (resource$249 = { + (resource$254 = { type: "stylesheet", instance: null, count: 0, state: { loading: 0, preload: null } }), - styles$248.set(type, resource$249), - (styles$248 = JSCompiler_inline_result.querySelector( + styles$253.set(type, resource$254), + (styles$253 = JSCompiler_inline_result.querySelector( getStylesheetSelectorFromKey(type) )) && - !styles$248._p && - ((resource$249.instance = styles$248), - (resource$249.state.loading = 5)), + !styles$253._p && + ((resource$254.instance = styles$253), + (resource$254.state.loading = 5)), preloadPropsMap.has(type) || ((pendingProps = { rel: "preload", @@ -14411,16 +14433,16 @@ function getResource(type, currentProps, pendingProps, currentResource) { referrerPolicy: pendingProps.referrerPolicy }), preloadPropsMap.set(type, pendingProps), - styles$248 || + styles$253 || preloadStylesheet( JSCompiler_inline_result, type, pendingProps, - resource$249.state + resource$254.state ))); if (currentProps && null === currentResource) throw Error(formatProdErrorMessage(528, "")); - return resource$249; + return resource$254; } if (currentProps && null !== currentResource) throw Error(formatProdErrorMessage(529, "")); @@ -14517,37 +14539,37 @@ function acquireResource(hoistableRoot, resource, props) { return (resource.instance = instance); case "stylesheet": styleProps = getStyleKey(props.href); - var instance$254 = hoistableRoot.querySelector( + var instance$259 = hoistableRoot.querySelector( getStylesheetSelectorFromKey(styleProps) ); - if (instance$254) + if (instance$259) return ( (resource.state.loading |= 4), - (resource.instance = instance$254), - markNodeAsHoistable(instance$254), - instance$254 + (resource.instance = instance$259), + markNodeAsHoistable(instance$259), + instance$259 ); instance = stylesheetPropsFromRawProps(props); (styleProps = preloadPropsMap.get(styleProps)) && adoptPreloadPropsForStylesheet(instance, styleProps); - instance$254 = ( + instance$259 = ( hoistableRoot.ownerDocument || hoistableRoot ).createElement("link"); - markNodeAsHoistable(instance$254); - var linkInstance = instance$254; + markNodeAsHoistable(instance$259); + var linkInstance = instance$259; linkInstance._p = new Promise(function (resolve, reject) { linkInstance.onload = resolve; linkInstance.onerror = reject; }); - setInitialProperties(instance$254, "link", instance); + setInitialProperties(instance$259, "link", instance); resource.state.loading |= 4; - insertStylesheet(instance$254, props.precedence, hoistableRoot); - return (resource.instance = instance$254); + insertStylesheet(instance$259, props.precedence, hoistableRoot); + return (resource.instance = instance$259); case "script": - instance$254 = getScriptKey(props.src); + instance$259 = getScriptKey(props.src); if ( (styleProps = hoistableRoot.querySelector( - getScriptSelectorFromKey(instance$254) + getScriptSelectorFromKey(instance$259) )) ) return ( @@ -14556,7 +14578,7 @@ function acquireResource(hoistableRoot, resource, props) { styleProps ); instance = props; - if ((styleProps = preloadPropsMap.get(instance$254))) + if ((styleProps = preloadPropsMap.get(instance$259))) (instance = assign({}, props)), adoptPreloadPropsForScript(instance, styleProps); hoistableRoot = hoistableRoot.ownerDocument || hoistableRoot; @@ -15625,16 +15647,16 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) { 0 === i && attemptExplicitHydrationTarget(target); } }; -var isomorphicReactPackageVersion$jscomp$inline_1692 = React.version; +var isomorphicReactPackageVersion$jscomp$inline_1699 = React.version; if ( - "19.0.0-native-fb-5c56b873-20241107" !== - isomorphicReactPackageVersion$jscomp$inline_1692 + "19.0.0-native-fb-989af12f-20241108" !== + isomorphicReactPackageVersion$jscomp$inline_1699 ) throw Error( formatProdErrorMessage( 527, - isomorphicReactPackageVersion$jscomp$inline_1692, - "19.0.0-native-fb-5c56b873-20241107" + isomorphicReactPackageVersion$jscomp$inline_1699, + "19.0.0-native-fb-989af12f-20241108" ) ); ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { @@ -15654,25 +15676,25 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { null === componentOrElement ? null : componentOrElement.stateNode; return componentOrElement; }; -var internals$jscomp$inline_2152 = { +var internals$jscomp$inline_2159 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_2153 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_2160 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_2153.isDisabled && - hook$jscomp$inline_2153.supportsFiber + !hook$jscomp$inline_2160.isDisabled && + hook$jscomp$inline_2160.supportsFiber ) try { - (rendererID = hook$jscomp$inline_2153.inject( - internals$jscomp$inline_2152 + (rendererID = hook$jscomp$inline_2160.inject( + internals$jscomp$inline_2159 )), - (injectedHook = hook$jscomp$inline_2153); + (injectedHook = hook$jscomp$inline_2160); } catch (err) {} } function noop() {} @@ -15918,4 +15940,4 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactSharedInternals.H.useHostTransitionStatus(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-profiling.js index d75ede54064f0..218e2c370276c 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-dom/cjs/ReactDOMProfiling-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ /* @@ -772,6 +772,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2162,19 +2170,19 @@ function getTargetInstForChangeEvent(domEventName, targetInst) { } var isInputEventSupported = !1; if (canUseDOM) { - var JSCompiler_inline_result$jscomp$305; + var JSCompiler_inline_result$jscomp$310; if (canUseDOM) { - var isSupported$jscomp$inline_439 = "oninput" in document; - if (!isSupported$jscomp$inline_439) { - var element$jscomp$inline_440 = document.createElement("div"); - element$jscomp$inline_440.setAttribute("oninput", "return;"); - isSupported$jscomp$inline_439 = - "function" === typeof element$jscomp$inline_440.oninput; + var isSupported$jscomp$inline_444 = "oninput" in document; + if (!isSupported$jscomp$inline_444) { + var element$jscomp$inline_445 = document.createElement("div"); + element$jscomp$inline_445.setAttribute("oninput", "return;"); + isSupported$jscomp$inline_444 = + "function" === typeof element$jscomp$inline_445.oninput; } - JSCompiler_inline_result$jscomp$305 = isSupported$jscomp$inline_439; - } else JSCompiler_inline_result$jscomp$305 = !1; + JSCompiler_inline_result$jscomp$310 = isSupported$jscomp$inline_444; + } else JSCompiler_inline_result$jscomp$310 = !1; isInputEventSupported = - JSCompiler_inline_result$jscomp$305 && + JSCompiler_inline_result$jscomp$310 && (!document.documentMode || 9 < document.documentMode); } function stopWatchingForValueChange() { @@ -11311,7 +11319,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -11324,7 +11332,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -11335,172 +11343,174 @@ function scheduleUpdateOnFiber(root, fiber, lane) { } function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327)); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - var wasRootDehydrated = root.current.memoizedState.isDehydrated; - wasRootDehydrated && - (prepareFreshStack(root, JSCompiler_inline_result).flags |= - 256); - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + var wasRootDehydrated = root.current.memoizedState.isDehydrated; + wasRootDehydrated && + (prepareFreshStack(root, JSCompiler_inline_result).flags |= 256); + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error(formatProdErrorMessage(345)); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error(formatProdErrorMessage(329)); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now$1()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error(formatProdErrorMessage(345)); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error(formatProdErrorMessage(329)); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -11549,7 +11559,7 @@ function commitRootWhenReady( completedRenderEndTime ) ); - markRootSuspended(root, lanes, spawnedLane, didSkipSuspendedSiblings); + markRootSuspended(root, lanes, spawnedLane, !didSkipSuspendedSiblings); return; } commitRoot( @@ -11603,20 +11613,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$6 = 31 - clz32(lanes), lane = 1 << index$6; - didSkipSuspendedSiblings[index$6] = -1; + didAttemptEntireTree[index$6] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -11660,9 +11670,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -11779,7 +11787,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -11788,10 +11798,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -11809,32 +11819,46 @@ function renderRootSync(root, lanes) { } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + memoizedUpdaters = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - throwAndUnwindWorkLoop(root, memoizedUpdaters, thrownValue, reason); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; - } catch (thrownValue$185) { - handleThrow(root, thrownValue$185); + } catch (thrownValue$190) { + handleThrow(root, thrownValue$190); } while (1); lanes && root.shellSuspendCounter++; @@ -11842,12 +11866,12 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) throw Error(formatProdErrorMessage(261)); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -11869,12 +11893,7 @@ function renderRootConcurrent(root, lanes) { workInProgressRootRenderTargetTime = now$1() + 500; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -11960,8 +11979,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$187) { - handleThrow(root, thrownValue$187); + } catch (thrownValue$192) { + handleThrow(root, thrownValue$192); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -12319,7 +12338,7 @@ function releaseRootPooledCache(root, remainingLanes) { } function flushPassiveEffects() { if (null !== rootWithPendingPassiveEffects) { - var root$191 = rootWithPendingPassiveEffects, + var root$196 = rootWithPendingPassiveEffects, remainingLanes = pendingPassiveEffectsRemainingLanes; pendingPassiveEffectsRemainingLanes = 0; var renderPriority = lanesToEventPriority(pendingPassiveEffectsLanes), @@ -12369,7 +12388,7 @@ function flushPassiveEffects() { } finally { (ReactDOMSharedInternals.p = previousPriority), (ReactSharedInternals.T = prevTransition), - releaseRootPooledCache(root$191, remainingLanes); + releaseRootPooledCache(root$196, remainingLanes); } } return !1; @@ -12520,14 +12539,14 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { isFlushingWork = !0; do { var didPerformSomeWork = !1; - for (var root$193 = firstScheduledRoot; null !== root$193; ) { - if (!onlyLegacy || 0 === root$193.tag) + for (var root$198 = firstScheduledRoot; null !== root$198; ) { + if (!onlyLegacy || 0 === root$198.tag) if (0 !== syncTransitionLanes) { - var pendingLanes = root$193.pendingLanes; + var pendingLanes = root$198.pendingLanes; if (0 === pendingLanes) var JSCompiler_inline_result = 0; else { - var suspendedLanes = root$193.suspendedLanes, - pingedLanes = root$193.pingedLanes; + var suspendedLanes = root$198.suspendedLanes, + pingedLanes = root$198.pingedLanes; JSCompiler_inline_result = (1 << (31 - clz32(42 | syncTransitionLanes) + 1)) - 1; JSCompiler_inline_result &= @@ -12541,17 +12560,18 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { } 0 !== JSCompiler_inline_result && ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$193, JSCompiler_inline_result)); + performSyncWorkOnRoot(root$198, JSCompiler_inline_result)); } else (JSCompiler_inline_result = workInProgressRootRenderLanes), (JSCompiler_inline_result = getNextLanes( - root$193, - root$193 === workInProgressRoot ? JSCompiler_inline_result : 0 + root$198, + root$198 === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root$198, JSCompiler_inline_result) || ((didPerformSomeWork = !0), - performSyncWorkOnRoot(root$193, JSCompiler_inline_result)); - root$193 = root$193.next; + performSyncWorkOnRoot(root$198, JSCompiler_inline_result)); + root$198 = root$198.next; } } while (didPerformSomeWork); isFlushingWork = !1; @@ -12620,39 +12640,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -12784,20 +12803,20 @@ function extractEvents$1( } } for ( - var i$jscomp$inline_1537 = 0; - i$jscomp$inline_1537 < simpleEventPluginEvents.length; - i$jscomp$inline_1537++ + var i$jscomp$inline_1544 = 0; + i$jscomp$inline_1544 < simpleEventPluginEvents.length; + i$jscomp$inline_1544++ ) { - var eventName$jscomp$inline_1538 = - simpleEventPluginEvents[i$jscomp$inline_1537], - domEventName$jscomp$inline_1539 = - eventName$jscomp$inline_1538.toLowerCase(), - capitalizedEvent$jscomp$inline_1540 = - eventName$jscomp$inline_1538[0].toUpperCase() + - eventName$jscomp$inline_1538.slice(1); + var eventName$jscomp$inline_1545 = + simpleEventPluginEvents[i$jscomp$inline_1544], + domEventName$jscomp$inline_1546 = + eventName$jscomp$inline_1545.toLowerCase(), + capitalizedEvent$jscomp$inline_1547 = + eventName$jscomp$inline_1545[0].toUpperCase() + + eventName$jscomp$inline_1545.slice(1); registerSimpleEvent( - domEventName$jscomp$inline_1539, - "on" + capitalizedEvent$jscomp$inline_1540 + domEventName$jscomp$inline_1546, + "on" + capitalizedEvent$jscomp$inline_1547 ); } registerSimpleEvent(ANIMATION_END, "onAnimationEnd"); @@ -13980,34 +13999,34 @@ function setInitialProperties(domElement, tag, props) { defaultChecked = null; for (hasSrc in props) if (props.hasOwnProperty(hasSrc)) { - var propValue$207 = props[hasSrc]; - if (null != propValue$207) + var propValue$212 = props[hasSrc]; + if (null != propValue$212) switch (hasSrc) { case "name": - hasSrcSet = propValue$207; + hasSrcSet = propValue$212; break; case "type": - propValue = propValue$207; + propValue = propValue$212; break; case "checked": - checked = propValue$207; + checked = propValue$212; break; case "defaultChecked": - defaultChecked = propValue$207; + defaultChecked = propValue$212; break; case "value": - propKey = propValue$207; + propKey = propValue$212; break; case "defaultValue": - defaultValue = propValue$207; + defaultValue = propValue$212; break; case "children": case "dangerouslySetInnerHTML": - if (null != propValue$207) + if (null != propValue$212) throw Error(formatProdErrorMessage(137, tag)); break; default: - setProp(domElement, tag, hasSrc, propValue$207, props, null); + setProp(domElement, tag, hasSrc, propValue$212, props, null); } } initInput( @@ -14144,14 +14163,14 @@ function setInitialProperties(domElement, tag, props) { return; default: if (isCustomElement(tag)) { - for (propValue$207 in props) - props.hasOwnProperty(propValue$207) && - ((hasSrc = props[propValue$207]), + for (propValue$212 in props) + props.hasOwnProperty(propValue$212) && + ((hasSrc = props[propValue$212]), void 0 !== hasSrc && setPropOnCustomElement( domElement, tag, - propValue$207, + propValue$212, hasSrc, props, void 0 @@ -14199,14 +14218,14 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp(domElement, tag, propKey, null, nextProps, lastProp); } } - for (var propKey$224 in nextProps) { - var propKey = nextProps[propKey$224]; - lastProp = lastProps[propKey$224]; + for (var propKey$229 in nextProps) { + var propKey = nextProps[propKey$229]; + lastProp = lastProps[propKey$229]; if ( - nextProps.hasOwnProperty(propKey$224) && + nextProps.hasOwnProperty(propKey$229) && (null != propKey || null != lastProp) ) - switch (propKey$224) { + switch (propKey$229) { case "type": type = propKey; break; @@ -14235,7 +14254,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$224, + propKey$229, propKey, nextProps, lastProp @@ -14254,7 +14273,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ); return; case "select": - propKey = value = defaultValue = propKey$224 = null; + propKey = value = defaultValue = propKey$229 = null; for (type in lastProps) if ( ((lastDefaultValue = lastProps[type]), @@ -14285,7 +14304,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (name) { case "value": - propKey$224 = type; + propKey$229 = type; break; case "defaultValue": defaultValue = type; @@ -14306,15 +14325,15 @@ function updateProperties(domElement, tag, lastProps, nextProps) { tag = defaultValue; lastProps = value; nextProps = propKey; - null != propKey$224 - ? updateOptions(domElement, !!lastProps, propKey$224, !1) + null != propKey$229 + ? updateOptions(domElement, !!lastProps, propKey$229, !1) : !!nextProps !== !!lastProps && (null != tag ? updateOptions(domElement, !!lastProps, tag, !0) : updateOptions(domElement, !!lastProps, lastProps ? [] : "", !1)); return; case "textarea": - propKey = propKey$224 = null; + propKey = propKey$229 = null; for (defaultValue in lastProps) if ( ((name = lastProps[defaultValue]), @@ -14338,7 +14357,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { ) switch (value) { case "value": - propKey$224 = name; + propKey$229 = name; break; case "defaultValue": propKey = name; @@ -14352,17 +14371,17 @@ function updateProperties(domElement, tag, lastProps, nextProps) { name !== type && setProp(domElement, tag, value, name, nextProps, type); } - updateTextarea(domElement, propKey$224, propKey); + updateTextarea(domElement, propKey$229, propKey); return; case "option": - for (var propKey$240 in lastProps) + for (var propKey$245 in lastProps) if ( - ((propKey$224 = lastProps[propKey$240]), - lastProps.hasOwnProperty(propKey$240) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$240)) + ((propKey$229 = lastProps[propKey$245]), + lastProps.hasOwnProperty(propKey$245) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$245)) ) - switch (propKey$240) { + switch (propKey$245) { case "selected": domElement.selected = !1; break; @@ -14370,33 +14389,33 @@ function updateProperties(domElement, tag, lastProps, nextProps) { setProp( domElement, tag, - propKey$240, + propKey$245, null, nextProps, - propKey$224 + propKey$229 ); } for (lastDefaultValue in nextProps) if ( - ((propKey$224 = nextProps[lastDefaultValue]), + ((propKey$229 = nextProps[lastDefaultValue]), (propKey = lastProps[lastDefaultValue]), nextProps.hasOwnProperty(lastDefaultValue) && - propKey$224 !== propKey && - (null != propKey$224 || null != propKey)) + propKey$229 !== propKey && + (null != propKey$229 || null != propKey)) ) switch (lastDefaultValue) { case "selected": domElement.selected = - propKey$224 && - "function" !== typeof propKey$224 && - "symbol" !== typeof propKey$224; + propKey$229 && + "function" !== typeof propKey$229 && + "symbol" !== typeof propKey$229; break; default: setProp( domElement, tag, lastDefaultValue, - propKey$224, + propKey$229, nextProps, propKey ); @@ -14417,24 +14436,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { case "track": case "wbr": case "menuitem": - for (var propKey$245 in lastProps) - (propKey$224 = lastProps[propKey$245]), - lastProps.hasOwnProperty(propKey$245) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$245) && - setProp(domElement, tag, propKey$245, null, nextProps, propKey$224); + for (var propKey$250 in lastProps) + (propKey$229 = lastProps[propKey$250]), + lastProps.hasOwnProperty(propKey$250) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$250) && + setProp(domElement, tag, propKey$250, null, nextProps, propKey$229); for (checked in nextProps) if ( - ((propKey$224 = nextProps[checked]), + ((propKey$229 = nextProps[checked]), (propKey = lastProps[checked]), nextProps.hasOwnProperty(checked) && - propKey$224 !== propKey && - (null != propKey$224 || null != propKey)) + propKey$229 !== propKey && + (null != propKey$229 || null != propKey)) ) switch (checked) { case "children": case "dangerouslySetInnerHTML": - if (null != propKey$224) + if (null != propKey$229) throw Error(formatProdErrorMessage(137, tag)); break; default: @@ -14442,7 +14461,7 @@ function updateProperties(domElement, tag, lastProps, nextProps) { domElement, tag, checked, - propKey$224, + propKey$229, nextProps, propKey ); @@ -14450,49 +14469,49 @@ function updateProperties(domElement, tag, lastProps, nextProps) { return; default: if (isCustomElement(tag)) { - for (var propKey$250 in lastProps) - (propKey$224 = lastProps[propKey$250]), - lastProps.hasOwnProperty(propKey$250) && - void 0 !== propKey$224 && - !nextProps.hasOwnProperty(propKey$250) && + for (var propKey$255 in lastProps) + (propKey$229 = lastProps[propKey$255]), + lastProps.hasOwnProperty(propKey$255) && + void 0 !== propKey$229 && + !nextProps.hasOwnProperty(propKey$255) && setPropOnCustomElement( domElement, tag, - propKey$250, + propKey$255, void 0, nextProps, - propKey$224 + propKey$229 ); for (defaultChecked in nextProps) - (propKey$224 = nextProps[defaultChecked]), + (propKey$229 = nextProps[defaultChecked]), (propKey = lastProps[defaultChecked]), !nextProps.hasOwnProperty(defaultChecked) || - propKey$224 === propKey || - (void 0 === propKey$224 && void 0 === propKey) || + propKey$229 === propKey || + (void 0 === propKey$229 && void 0 === propKey) || setPropOnCustomElement( domElement, tag, defaultChecked, - propKey$224, + propKey$229, nextProps, propKey ); return; } } - for (var propKey$255 in lastProps) - (propKey$224 = lastProps[propKey$255]), - lastProps.hasOwnProperty(propKey$255) && - null != propKey$224 && - !nextProps.hasOwnProperty(propKey$255) && - setProp(domElement, tag, propKey$255, null, nextProps, propKey$224); + for (var propKey$260 in lastProps) + (propKey$229 = lastProps[propKey$260]), + lastProps.hasOwnProperty(propKey$260) && + null != propKey$229 && + !nextProps.hasOwnProperty(propKey$260) && + setProp(domElement, tag, propKey$260, null, nextProps, propKey$229); for (lastProp in nextProps) - (propKey$224 = nextProps[lastProp]), + (propKey$229 = nextProps[lastProp]), (propKey = lastProps[lastProp]), !nextProps.hasOwnProperty(lastProp) || - propKey$224 === propKey || - (null == propKey$224 && null == propKey) || - setProp(domElement, tag, lastProp, propKey$224, nextProps, propKey); + propKey$229 === propKey || + (null == propKey$229 && null == propKey) || + setProp(domElement, tag, lastProp, propKey$229, nextProps, propKey); } var eventsEnabled = null, selectionInformation = null; @@ -15032,26 +15051,26 @@ function getResource(type, currentProps, pendingProps, currentResource) { "string" === typeof pendingProps.precedence ) { type = getStyleKey(pendingProps.href); - var styles$263 = getResourcesFromRoot( + var styles$268 = getResourcesFromRoot( JSCompiler_inline_result ).hoistableStyles, - resource$264 = styles$263.get(type); - resource$264 || + resource$269 = styles$268.get(type); + resource$269 || ((JSCompiler_inline_result = JSCompiler_inline_result.ownerDocument || JSCompiler_inline_result), - (resource$264 = { + (resource$269 = { type: "stylesheet", instance: null, count: 0, state: { loading: 0, preload: null } }), - styles$263.set(type, resource$264), - (styles$263 = JSCompiler_inline_result.querySelector( + styles$268.set(type, resource$269), + (styles$268 = JSCompiler_inline_result.querySelector( getStylesheetSelectorFromKey(type) )) && - !styles$263._p && - ((resource$264.instance = styles$263), - (resource$264.state.loading = 5)), + !styles$268._p && + ((resource$269.instance = styles$268), + (resource$269.state.loading = 5)), preloadPropsMap.has(type) || ((pendingProps = { rel: "preload", @@ -15064,16 +15083,16 @@ function getResource(type, currentProps, pendingProps, currentResource) { referrerPolicy: pendingProps.referrerPolicy }), preloadPropsMap.set(type, pendingProps), - styles$263 || + styles$268 || preloadStylesheet( JSCompiler_inline_result, type, pendingProps, - resource$264.state + resource$269.state ))); if (currentProps && null === currentResource) throw Error(formatProdErrorMessage(528, "")); - return resource$264; + return resource$269; } if (currentProps && null !== currentResource) throw Error(formatProdErrorMessage(529, "")); @@ -15170,37 +15189,37 @@ function acquireResource(hoistableRoot, resource, props) { return (resource.instance = instance); case "stylesheet": styleProps = getStyleKey(props.href); - var instance$269 = hoistableRoot.querySelector( + var instance$274 = hoistableRoot.querySelector( getStylesheetSelectorFromKey(styleProps) ); - if (instance$269) + if (instance$274) return ( (resource.state.loading |= 4), - (resource.instance = instance$269), - markNodeAsHoistable(instance$269), - instance$269 + (resource.instance = instance$274), + markNodeAsHoistable(instance$274), + instance$274 ); instance = stylesheetPropsFromRawProps(props); (styleProps = preloadPropsMap.get(styleProps)) && adoptPreloadPropsForStylesheet(instance, styleProps); - instance$269 = ( + instance$274 = ( hoistableRoot.ownerDocument || hoistableRoot ).createElement("link"); - markNodeAsHoistable(instance$269); - var linkInstance = instance$269; + markNodeAsHoistable(instance$274); + var linkInstance = instance$274; linkInstance._p = new Promise(function (resolve, reject) { linkInstance.onload = resolve; linkInstance.onerror = reject; }); - setInitialProperties(instance$269, "link", instance); + setInitialProperties(instance$274, "link", instance); resource.state.loading |= 4; - insertStylesheet(instance$269, props.precedence, hoistableRoot); - return (resource.instance = instance$269); + insertStylesheet(instance$274, props.precedence, hoistableRoot); + return (resource.instance = instance$274); case "script": - instance$269 = getScriptKey(props.src); + instance$274 = getScriptKey(props.src); if ( (styleProps = hoistableRoot.querySelector( - getScriptSelectorFromKey(instance$269) + getScriptSelectorFromKey(instance$274) )) ) return ( @@ -15209,7 +15228,7 @@ function acquireResource(hoistableRoot, resource, props) { styleProps ); instance = props; - if ((styleProps = preloadPropsMap.get(instance$269))) + if ((styleProps = preloadPropsMap.get(instance$274))) (instance = assign({}, props)), adoptPreloadPropsForScript(instance, styleProps); hoistableRoot = hoistableRoot.ownerDocument || hoistableRoot; @@ -16286,16 +16305,16 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) { 0 === i && attemptExplicitHydrationTarget(target); } }; -var isomorphicReactPackageVersion$jscomp$inline_1782 = React.version; +var isomorphicReactPackageVersion$jscomp$inline_1789 = React.version; if ( - "19.0.0-native-fb-5c56b873-20241107" !== - isomorphicReactPackageVersion$jscomp$inline_1782 + "19.0.0-native-fb-989af12f-20241108" !== + isomorphicReactPackageVersion$jscomp$inline_1789 ) throw Error( formatProdErrorMessage( 527, - isomorphicReactPackageVersion$jscomp$inline_1782, - "19.0.0-native-fb-5c56b873-20241107" + isomorphicReactPackageVersion$jscomp$inline_1789, + "19.0.0-native-fb-989af12f-20241108" ) ); ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { @@ -16315,18 +16334,18 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) { null === componentOrElement ? null : componentOrElement.stateNode; return componentOrElement; }; -var internals$jscomp$inline_1789 = { +var internals$jscomp$inline_1796 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-dom", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getClosestInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107", + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108", getLaneLabelMap: function () { for ( - var map = new Map(), lane = 1, index$286 = 0; - 31 > index$286; - index$286++ + var map = new Map(), lane = 1, index$291 = 0; + 31 > index$291; + index$291++ ) { var label = getLabelForLane(lane); map.set(lane, label); @@ -16339,16 +16358,16 @@ var internals$jscomp$inline_1789 = { } }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_2204 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_2211 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_2204.isDisabled && - hook$jscomp$inline_2204.supportsFiber + !hook$jscomp$inline_2211.isDisabled && + hook$jscomp$inline_2211.supportsFiber ) try { - (rendererID = hook$jscomp$inline_2204.inject( - internals$jscomp$inline_1789 + (rendererID = hook$jscomp$inline_2211.inject( + internals$jscomp$inline_1796 )), - (injectedHook = hook$jscomp$inline_2204); + (injectedHook = hook$jscomp$inline_2211); } catch (err) {} } function noop() {} @@ -16594,7 +16613,7 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactSharedInternals.H.useHostTransitionStatus(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-dev.js index 66ee1704169de..6fd10e75082eb 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<3ee488c28e1b365e60a99135499c52e1>> */ "use strict"; @@ -871,6 +871,14 @@ __DEV__ && ? wipLanes : nextLanes; } + function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); + } function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -1910,7 +1918,8 @@ __DEV__ && root, root === workInProgressRoot ? nextLanes : 0 )), - 0 !== (nextLanes & 3) && + 0 === (nextLanes & 3) || + checkIfRootIsPrerendering(root, nextLanes) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, nextLanes)); root = root.next; @@ -1995,8 +2004,6 @@ __DEV__ && else return currentTime; switch (lanesToEventPriority(suspendedLanes)) { case DiscreteEventPriority: - suspendedLanes = ImmediatePriority; - break; case ContinuousEventPriority: suspendedLanes = UserBlockingPriority; break; @@ -10836,187 +10843,190 @@ __DEV__ && if ((executionContext & (RenderContext | CommitContext)) !== NoContext) throw Error("Should not already be working."); var exitStatus = (forceSync = - !forceSync && 0 === (lanes & 60) && 0 === (lanes & root.expiredLanes)) - ? renderRootConcurrent(root, lanes) - : renderRootSync(root, lanes); - if (exitStatus !== RootInProgress) { - var renderWasConcurrent = forceSync; - do { - if (exitStatus === RootDidNotComplete) - markRootSuspended(root, lanes, 0); - else { - forceSync = root.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root.tag && exitStatus === RootErrored) { - var lanesThatJustErrored = lanes; - root.errorRecoveryDisabledLanes & lanesThatJustErrored - ? (renderWasConcurrent = 0) - : ((renderWasConcurrent = root.pendingLanes & -536870913), - (renderWasConcurrent = - 0 !== renderWasConcurrent - ? renderWasConcurrent - : renderWasConcurrent & 536870912 - ? 536870912 - : 0)); - if (0 !== renderWasConcurrent) { - lanes = renderWasConcurrent; - a: { - exitStatus = root; - var originallyAttemptedLanes = lanesThatJustErrored; - lanesThatJustErrored = workInProgressRootConcurrentErrors; - renderWasConcurrent = renderRootSync( - exitStatus, - renderWasConcurrent - ); - if (renderWasConcurrent !== RootErrored) { - if (workInProgressRootDidAttachPingListener) { - exitStatus.errorRecoveryDisabledLanes |= - originallyAttemptedLanes; - workInProgressRootInterleavedUpdatedLanes |= - originallyAttemptedLanes; - exitStatus = RootSuspendedWithDelay; - break a; - } - exitStatus = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = lanesThatJustErrored; - null !== exitStatus && queueRecoverableErrors(exitStatus); + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root.expiredLanes)) || + !1) + ? renderRootConcurrent(root, lanes) + : renderRootSync(root, lanes, !0), + renderWasConcurrent = forceSync; + do { + if (exitStatus === RootInProgress) break; + else if (exitStatus === RootDidNotComplete) + markRootSuspended(root, lanes, 0); + else { + forceSync = root.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root.tag && exitStatus === RootErrored) { + var lanesThatJustErrored = lanes; + root.errorRecoveryDisabledLanes & lanesThatJustErrored + ? (renderWasConcurrent = 0) + : ((renderWasConcurrent = root.pendingLanes & -536870913), + (renderWasConcurrent = + 0 !== renderWasConcurrent + ? renderWasConcurrent + : renderWasConcurrent & 536870912 + ? 536870912 + : 0)); + if (0 !== renderWasConcurrent) { + lanes = renderWasConcurrent; + a: { + exitStatus = root; + var originallyAttemptedLanes = lanesThatJustErrored; + lanesThatJustErrored = workInProgressRootConcurrentErrors; + renderWasConcurrent = renderRootSync( + exitStatus, + renderWasConcurrent, + !1 + ); + if (renderWasConcurrent !== RootErrored) { + if (workInProgressRootDidAttachPingListener) { + exitStatus.errorRecoveryDisabledLanes |= + originallyAttemptedLanes; + workInProgressRootInterleavedUpdatedLanes |= + originallyAttemptedLanes; + exitStatus = RootSuspendedWithDelay; + break a; } - exitStatus = renderWasConcurrent; + exitStatus = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = lanesThatJustErrored; + null !== exitStatus && queueRecoverableErrors(exitStatus); } - renderWasConcurrent = !1; - if (exitStatus !== RootErrored) continue; + exitStatus = renderWasConcurrent; } + renderWasConcurrent = !1; + if (exitStatus !== RootErrored) continue; } - if (exitStatus === RootFatalErrored) { - prepareFreshStack(root, 0); - markRootSuspended(root, lanes, 0); - break; - } - a: { - renderWasConcurrent = root; - switch (exitStatus) { - case RootInProgress: - case RootFatalErrored: - throw Error("Root did not complete. This is a bug in React."); - case RootSuspendedWithDelay: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane - ); - break a; - } - break; - case RootErrored: - workInProgressRootRecoverableErrors = null; - break; - case RootSuspended: - case RootCompleted: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if (null !== ReactSharedInternals.actQueue) { - lanes = renderWasConcurrent; - forceSync = workInProgressRootRecoverableErrors; - exitStatus = workInProgressTransitions; - renderWasConcurrent = - workInProgressRootDidIncludeRecursiveRenderUpdate; - lanesThatJustErrored = workInProgressDeferredLane; - originallyAttemptedLanes = - workInProgressRootInterleavedUpdatedLanes; - var suspendedRetryLanes = workInProgressSuspendedRetryLanes, - suspendedCommitReason = IMMEDIATE_COMMIT, - prevTransition = ReactSharedInternals.T, - previousUpdateLanePriority = currentUpdatePriority; - try { - (currentUpdatePriority = DiscreteEventPriority), - (ReactSharedInternals.T = null), - commitRootImpl( - lanes, - forceSync, - exitStatus, - renderWasConcurrent, - previousUpdateLanePriority, - lanesThatJustErrored, - originallyAttemptedLanes, - suspendedRetryLanes, - suspendedCommitReason, - -0, - 0 - ); - } finally { - (ReactSharedInternals.T = prevTransition), - (currentUpdatePriority = previousUpdateLanePriority); - } - } else { - if ( - (lanes & 62914560) === lanes && - exitStatus === RootSuspended && - ((exitStatus = - globalMostRecentFallbackTime + - FALLBACK_THROTTLE_MS - - now$1()), - 10 < exitStatus) - ) { + } + if (exitStatus === RootFatalErrored) { + prepareFreshStack(root, 0); + markRootSuspended(root, lanes, 0); + break; + } + a: { + renderWasConcurrent = root; + switch (exitStatus) { + case RootInProgress: + case RootFatalErrored: + throw Error("Root did not complete. This is a bug in React."); + case RootSuspendedWithDelay: + if ((lanes & 4194176) === lanes) { markRootSuspended( renderWasConcurrent, lanes, workInProgressDeferredLane ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - THROTTLED_COMMIT, - -0, - 0 - ), - exitStatus - ); break a; } - commitRootWhenReady( + break; + case RootErrored: + workInProgressRootRecoverableErrors = null; + break; + case RootSuspended: + case RootCompleted: + break; + default: + throw Error("Unknown root exit status."); + } + renderWasConcurrent.finishedWork = forceSync; + renderWasConcurrent.finishedLanes = lanes; + if (null !== ReactSharedInternals.actQueue) { + lanes = renderWasConcurrent; + forceSync = workInProgressRootRecoverableErrors; + exitStatus = workInProgressTransitions; + renderWasConcurrent = + workInProgressRootDidIncludeRecursiveRenderUpdate; + lanesThatJustErrored = workInProgressDeferredLane; + originallyAttemptedLanes = + workInProgressRootInterleavedUpdatedLanes; + var suspendedRetryLanes = workInProgressSuspendedRetryLanes, + suspendedCommitReason = IMMEDIATE_COMMIT, + prevTransition = ReactSharedInternals.T, + previousUpdateLanePriority = currentUpdatePriority; + try { + (currentUpdatePriority = DiscreteEventPriority), + (ReactSharedInternals.T = null), + commitRootImpl( + lanes, + forceSync, + exitStatus, + renderWasConcurrent, + previousUpdateLanePriority, + lanesThatJustErrored, + originallyAttemptedLanes, + suspendedRetryLanes, + suspendedCommitReason, + -0, + 0 + ); + } finally { + (ReactSharedInternals.T = prevTransition), + (currentUpdatePriority = previousUpdateLanePriority); + } + } else { + if ( + (lanes & 62914560) === lanes && + exitStatus === RootSuspended && + ((exitStatus = + globalMostRecentFallbackTime + + FALLBACK_THROTTLE_MS - + now$1()), + 10 < exitStatus) + ) { + markRootSuspended( renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - IMMEDIATE_COMMIT, - -0, - 0 + workInProgressDeferredLane ); + if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; + renderWasConcurrent.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + THROTTLED_COMMIT, + -0, + 0 + ), + exitStatus + ); + break a; } + commitRootWhenReady( + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + IMMEDIATE_COMMIT, + -0, + 0 + ); } } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root); } function queueRecoverableErrors(errors) { @@ -11181,8 +11191,9 @@ __DEV__ && workInProgressRootRenderLanes = lanes; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; - workInProgressRootDidAttachPingListener = - workInProgressRootDidSkipSuspendedSiblings = !1; + workInProgressRootDidSkipSuspendedSiblings = !1; + checkIfRootIsPrerendering(root, lanes); + workInProgressRootDidAttachPingListener = !1; workInProgressRootExitStatus = RootInProgress; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -11317,6 +11328,7 @@ __DEV__ && (workInProgressTransitions = null), prepareFreshStack(root, lanes); markRenderStarted(lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if ( @@ -11328,21 +11340,26 @@ __DEV__ && switch (workInProgressSuspendedReason) { case SuspendedOnHydration: resetWorkInProgressStack(); - workInProgressRootExitStatus = RootDidNotComplete; + exitStatus = RootDidNotComplete; break a; case SuspendedOnImmediate: case SuspendedOnData: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case SuspendedOnDeprecatedThrowPromise: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = NotSuspended), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; } catch (thrownValue$33) { handleThrow(root, thrownValue$33); @@ -11353,15 +11370,12 @@ __DEV__ && executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -11371,13 +11385,11 @@ __DEV__ && executionContext |= RenderContext; var prevDispatcher = pushDispatcher(), prevAsyncDispatcher = pushAsyncDispatcher(); - if ( - workInProgressRoot !== root || - workInProgressRootRenderLanes !== lanes - ) - (workInProgressTransitions = null), + workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes + ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now$1() + RENDER_TIMEOUT_MS), - prepareFreshStack(root, lanes); + prepareFreshStack(root, lanes)) + : checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -15114,11 +15126,11 @@ __DEV__ && (function () { var internals = { bundleType: 1, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-test-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; internals.overrideHookState = overrideHookState; internals.overrideHookStateDeletePath = overrideHookStateDeletePath; @@ -15263,5 +15275,5 @@ __DEV__ && flushSyncWorkAcrossRoots_impl(0, !0)); } }; - exports.version = "19.0.0-native-fb-5c56b873-20241107"; + exports.version = "19.0.0-native-fb-989af12f-20241108"; })(); diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-prod.js index f1e694bf8bb06..d22e1a04ca6b0 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<88bd63cbc28ccc9f9f6fb119247414eb>> + * @generated SignedSource<> */ "use strict"; @@ -564,6 +564,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -1023,7 +1031,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -1103,8 +1112,6 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { null !== pingedLanes && cancelCallback$1(pingedLanes); switch (lanesToEventPriority(suspendedLanes)) { case 2: - suspendedLanes = ImmediatePriority; - break; case 8: suspendedLanes = UserBlockingPriority; break; @@ -7831,151 +7838,151 @@ function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) markRootSuspended(root$jscomp$0, lanes, 0); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + !1) + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = forceSync; + do { + if (0 === exitStatus) break; + else if (6 === exitStatus) markRootSuspended(root$jscomp$0, lanes, 0); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); - markRootSuspended(root$jscomp$0, lanes, 0); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - 3 === exitStatus && - ((exitStatus = globalMostRecentFallbackTime + 300 - now()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0); + break; + } + a: { + renderWasConcurrent = root$jscomp$0; + switch (exitStatus) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( + workInProgressDeferredLane + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + renderWasConcurrent.finishedWork = forceSync; + renderWasConcurrent.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + 3 === exitStatus && + ((exitStatus = globalMostRecentFallbackTime + 300 - now()), + 10 < exitStatus) + ) { + markRootSuspended( renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressDeferredLane ); + if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; + renderWasConcurrent.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + exitStatus + ); + break a; } + commitRootWhenReady( + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -8129,8 +8136,9 @@ function prepareFreshStack(root, lanes) { workInProgressRootRenderLanes = lanes; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - workInProgressRootDidAttachPingListener = - workInProgressRootDidSkipSuspendedSiblings = !1; + workInProgressRootDidSkipSuspendedSiblings = !1; + checkIfRootIsPrerendering(root, lanes); + workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = workInProgressRootPingedLanes = @@ -8226,6 +8234,7 @@ function renderRootSync(root, lanes) { if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -8234,24 +8243,29 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$122) { - handleThrow(root, thrownValue$122); + } catch (thrownValue$123) { + handleThrow(root, thrownValue$123); } while (1); lanes && root.shellSuspendCounter++; @@ -8259,14 +8273,11 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -8276,10 +8287,11 @@ function renderRootConcurrent(root, lanes) { executionContext |= 2; var prevDispatcher = pushDispatcher(), prevAsyncDispatcher = pushAsyncDispatcher(); - if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) - (workInProgressTransitions = null), + workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes + ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), - prepareFreshStack(root, lanes); + prepareFreshStack(root, lanes)) + : checkIfRootIsPrerendering(root, lanes); a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -8363,8 +8375,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$124) { - handleThrow(root, thrownValue$124); + } catch (thrownValue$125) { + handleThrow(root, thrownValue$125); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -9467,28 +9479,28 @@ function wrapFiber(fiber) { fiberToWrapper.set(fiber, wrapper)); return wrapper; } -var internals$jscomp$inline_1348 = { +var internals$jscomp$inline_1349 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-test-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: function (mockNode) { mockNode = nodeToInstanceMap.get(mockNode); return void 0 !== mockNode ? mockNode.internalInstanceHandle : null; }, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1349 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1350 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1349.isDisabled && - hook$jscomp$inline_1349.supportsFiber + !hook$jscomp$inline_1350.isDisabled && + hook$jscomp$inline_1350.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1349.inject( - internals$jscomp$inline_1348 + (rendererID = hook$jscomp$inline_1350.inject( + internals$jscomp$inline_1349 )), - (injectedHook = hook$jscomp$inline_1349); + (injectedHook = hook$jscomp$inline_1350); } catch (err) {} } exports._Scheduler = Scheduler; @@ -9612,4 +9624,4 @@ exports.unstable_batchedUpdates = function (fn, a) { flushSyncWorkAcrossRoots_impl(0, !0)); } }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-profiling.js index f762ebe2763d3..39cf2765abd2a 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react-test-renderer/cjs/ReactTestRenderer-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<8c1a68ae8463083be92e86ebd871dad8>> + * @generated SignedSource<<70606b3e20bfb66b098bc622c94ed72c>> */ "use strict"; @@ -629,6 +629,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -1142,7 +1150,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -1222,8 +1231,6 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { null !== pingedLanes && cancelCallback$1(pingedLanes); switch (lanesToEventPriority(suspendedLanes)) { case 2: - suspendedLanes = ImmediatePriority; - break; case 8: suspendedLanes = UserBlockingPriority; break; @@ -8301,151 +8308,151 @@ function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) markRootSuspended(root$jscomp$0, lanes, 0); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + !1) + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = forceSync; + do { + if (0 === exitStatus) break; + else if (6 === exitStatus) markRootSuspended(root$jscomp$0, lanes, 0); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); - markRootSuspended(root$jscomp$0, lanes, 0); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - 3 === exitStatus && - ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0); + break; + } + a: { + renderWasConcurrent = root$jscomp$0; + switch (exitStatus) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( + workInProgressDeferredLane + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + renderWasConcurrent.finishedWork = forceSync; + renderWasConcurrent.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + 3 === exitStatus && + ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), + 10 < exitStatus) + ) { + markRootSuspended( renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressDeferredLane ); + if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; + renderWasConcurrent.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + exitStatus + ); + break a; } + commitRootWhenReady( + renderWasConcurrent, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -8599,8 +8606,9 @@ function prepareFreshStack(root, lanes) { workInProgressRootRenderLanes = lanes; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - workInProgressRootDidAttachPingListener = - workInProgressRootDidSkipSuspendedSiblings = !1; + workInProgressRootDidSkipSuspendedSiblings = !1; + checkIfRootIsPrerendering(root, lanes); + workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = workInProgressRootPingedLanes = @@ -8725,6 +8733,7 @@ function renderRootSync(root, lanes) { (workInProgressTransitions = null), prepareFreshStack(root, lanes); markRenderStarted(lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -8733,24 +8742,29 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$135) { - handleThrow(root, thrownValue$135); + } catch (thrownValue$136) { + handleThrow(root, thrownValue$136); } while (1); lanes && root.shellSuspendCounter++; @@ -8758,15 +8772,12 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -8776,10 +8787,11 @@ function renderRootConcurrent(root, lanes) { executionContext |= 2; var prevDispatcher = pushDispatcher(), prevAsyncDispatcher = pushAsyncDispatcher(); - if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) - (workInProgressTransitions = null), + workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes + ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now$1() + 500), - prepareFreshStack(root, lanes); + prepareFreshStack(root, lanes)) + : checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -8864,8 +8876,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$137) { - handleThrow(root, thrownValue$137); + } catch (thrownValue$138) { + handleThrow(root, thrownValue$138); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -10035,21 +10047,21 @@ function wrapFiber(fiber) { fiberToWrapper.set(fiber, wrapper)); return wrapper; } -var internals$jscomp$inline_1158 = { +var internals$jscomp$inline_1159 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-test-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: function (mockNode) { mockNode = nodeToInstanceMap.get(mockNode); return void 0 !== mockNode ? mockNode.internalInstanceHandle : null; }, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107", + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108", getLaneLabelMap: function () { for ( - var map = new Map(), lane = 1, index$141 = 0; - 31 > index$141; - index$141++ + var map = new Map(), lane = 1, index$142 = 0; + 31 > index$142; + index$142++ ) { var label = getLabelForLane(lane); map.set(lane, label); @@ -10062,16 +10074,16 @@ var internals$jscomp$inline_1158 = { } }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1405 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1406 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1405.isDisabled && - hook$jscomp$inline_1405.supportsFiber + !hook$jscomp$inline_1406.isDisabled && + hook$jscomp$inline_1406.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1405.inject( - internals$jscomp$inline_1158 + (rendererID = hook$jscomp$inline_1406.inject( + internals$jscomp$inline_1159 )), - (injectedHook = hook$jscomp$inline_1405); + (injectedHook = hook$jscomp$inline_1406); } catch (err) {} } exports._Scheduler = Scheduler; @@ -10195,4 +10207,4 @@ exports.unstable_batchedUpdates = function (fn, a) { flushSyncWorkAcrossRoots_impl(0, !0)); } }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-dev.js index e3498a91a5cd4..1e68edfbcb79a 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<397c2d99785af31f076b2112a8d0dbe9>> + * @generated SignedSource<<9f11c239f827a7701664ca94ecfb18a9>> */ "use strict"; @@ -1694,7 +1694,7 @@ __DEV__ && exports.useTransition = function () { return resolveDispatcher().useTransition(); }; - exports.version = "19.0.0-native-fb-5c56b873-20241107"; + exports.version = "19.0.0-native-fb-989af12f-20241108"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-prod.js index 8582ea84f4e7a..2e38332503fdc 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<4fea6a59facc2588fd80f5fd28231bdd>> + * @generated SignedSource<> */ "use strict"; @@ -580,4 +580,4 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactSharedInternals.H.useTransition(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-profiling.js index 72f1f8a13787e..118d07176c942 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/react/cjs/React-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -584,7 +584,7 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactSharedInternals.H.useTransition(); }; -exports.version = "19.0.0-native-fb-5c56b873-20241107"; +exports.version = "19.0.0-native-fb-989af12f-20241108"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION index aea1846e0d335..0aea09c8962ed 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/REVISION @@ -1 +1 @@ -5c56b873efb300b4d1afc4ba6f16acf17e4e5800 +989af12f72080c17db03ead91d99b6394a215564 diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-dev.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-dev.fb.js index b457b45749261..5bee1c1c04b15 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-dev.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-dev.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -1632,6 +1632,14 @@ __DEV__ && ? wipLanes : nextLanes; } + function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); + } function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2768,7 +2776,8 @@ __DEV__ && root, root === workInProgressRoot ? nextLanes : 0 )), - 0 !== (nextLanes & 3) && + 0 === (nextLanes & 3) || + checkIfRootIsPrerendering(root, nextLanes) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, nextLanes)); root = root.next; @@ -2836,45 +2845,46 @@ __DEV__ && (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && cancelCallback(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; if ( - currentTime !== root.callbackPriority || - (null !== ReactSharedInternals.actQueue && - pingedLanes !== fakeActCallbackNode$1) - ) - cancelCallback(pingedLanes); - else return currentTime; - switch (lanesToEventPriority(suspendedLanes)) { - case DiscreteEventPriority: - suspendedLanes = ImmediatePriority; - break; - case ContinuousEventPriority: - suspendedLanes = UserBlockingPriority; - break; - case DefaultEventPriority: - suspendedLanes = NormalPriority$1; - break; - case IdleEventPriority: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if ( + currentTime !== root.callbackPriority || + (null !== ReactSharedInternals.actQueue && + pingedLanes !== fakeActCallbackNode$1) + ) + cancelCallback(pingedLanes); + else return currentTime; + switch (lanesToEventPriority(suspendedLanes)) { + case DiscreteEventPriority: + case ContinuousEventPriority: + suspendedLanes = UserBlockingPriority; + break; + case DefaultEventPriority: + suspendedLanes = NormalPriority$1; + break; + case IdleEventPriority: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + null !== ReactSharedInternals.actQueue + ? (ReactSharedInternals.actQueue.push(pingedLanes), + (suspendedLanes = fakeActCallbackNode$1)) + : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - null !== ReactSharedInternals.actQueue - ? (ReactSharedInternals.actQueue.push(pingedLanes), - (suspendedLanes = fakeActCallbackNode$1)) - : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + null !== pingedLanes && cancelCallback(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -11696,7 +11706,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if ( @@ -11739,7 +11749,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 !== lane || @@ -11752,204 +11762,209 @@ __DEV__ && function performWorkOnRoot(root, lanes, forceSync) { if ((executionContext & (RenderContext | CommitContext)) !== NoContext) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && 0 === (lanes & 60) && 0 === (lanes & root.expiredLanes)) - ? renderRootConcurrent(root, lanes) - : renderRootSync(root, lanes); - if (exitStatus !== RootInProgress) { - var renderWasConcurrent = forceSync; - do { - if (exitStatus === RootDidNotComplete) - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root.tag && exitStatus === RootErrored) { - var lanesThatJustErrored = lanes; - root.errorRecoveryDisabledLanes & lanesThatJustErrored - ? (renderWasConcurrent = 0) - : ((renderWasConcurrent = root.pendingLanes & -536870913), - (renderWasConcurrent = - 0 !== renderWasConcurrent - ? renderWasConcurrent - : renderWasConcurrent & 536870912 - ? 536870912 - : 0)); - if (0 !== renderWasConcurrent) { - lanes = renderWasConcurrent; - a: { - exitStatus = root; - var originallyAttemptedLanes = lanesThatJustErrored; - lanesThatJustErrored = workInProgressRootConcurrentErrors; - var wasRootDehydrated = supportsHydration; - renderWasConcurrent = renderRootSync( - exitStatus, - renderWasConcurrent - ); - if (renderWasConcurrent !== RootErrored) { - if ( - workInProgressRootDidAttachPingListener && - !wasRootDehydrated - ) { - exitStatus.errorRecoveryDisabledLanes |= - originallyAttemptedLanes; - workInProgressRootInterleavedUpdatedLanes |= - originallyAttemptedLanes; - exitStatus = RootSuspendedWithDelay; - break a; - } - exitStatus = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = lanesThatJustErrored; - null !== exitStatus && queueRecoverableErrors(exitStatus); + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root.expiredLanes)) || + (enableSiblingPrerendering && checkIfRootIsPrerendering(root, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root, lanes) + : renderRootSync(root, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (exitStatus === RootInProgress) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root, lanes, 0, !1); + break; + } else if (exitStatus === RootDidNotComplete) + markRootSuspended( + root, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root.tag && exitStatus === RootErrored) { + var lanesThatJustErrored = lanes; + root.errorRecoveryDisabledLanes & lanesThatJustErrored + ? (renderWasConcurrent = 0) + : ((renderWasConcurrent = root.pendingLanes & -536870913), + (renderWasConcurrent = + 0 !== renderWasConcurrent + ? renderWasConcurrent + : renderWasConcurrent & 536870912 + ? 536870912 + : 0)); + if (0 !== renderWasConcurrent) { + lanes = renderWasConcurrent; + a: { + exitStatus = root; + var originallyAttemptedLanes = lanesThatJustErrored; + lanesThatJustErrored = workInProgressRootConcurrentErrors; + var wasRootDehydrated = supportsHydration; + renderWasConcurrent = renderRootSync( + exitStatus, + renderWasConcurrent, + !1 + ); + if (renderWasConcurrent !== RootErrored) { + if ( + workInProgressRootDidAttachPingListener && + !wasRootDehydrated + ) { + exitStatus.errorRecoveryDisabledLanes |= + originallyAttemptedLanes; + workInProgressRootInterleavedUpdatedLanes |= + originallyAttemptedLanes; + exitStatus = RootSuspendedWithDelay; + break a; } - exitStatus = renderWasConcurrent; + exitStatus = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = lanesThatJustErrored; + null !== exitStatus && queueRecoverableErrors(exitStatus); } - renderWasConcurrent = !1; - if (exitStatus !== RootErrored) continue; + exitStatus = renderWasConcurrent; } + renderWasConcurrent = !1; + if (exitStatus !== RootErrored) continue; } - if (exitStatus === RootFatalErrored) { - prepareFreshStack(root, 0); - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - break; - } - a: { - renderWasConcurrent = root; - switch (exitStatus) { - case RootInProgress: - case RootFatalErrored: - throw Error("Root did not complete. This is a bug in React."); - case RootSuspendedWithDelay: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case RootErrored: - workInProgressRootRecoverableErrors = null; - break; - case RootSuspended: - case RootCompleted: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if (null !== ReactSharedInternals.actQueue) { - lanes = renderWasConcurrent; - forceSync = workInProgressRootRecoverableErrors; - exitStatus = workInProgressTransitions; - renderWasConcurrent = - workInProgressRootDidIncludeRecursiveRenderUpdate; - lanesThatJustErrored = workInProgressDeferredLane; - originallyAttemptedLanes = - workInProgressRootInterleavedUpdatedLanes; - wasRootDehydrated = workInProgressSuspendedRetryLanes; - var suspendedCommitReason = IMMEDIATE_COMMIT, - prevTransition = ReactSharedInternals.T, - previousUpdateLanePriority = currentUpdatePriority; - try { - (currentUpdatePriority = DiscreteEventPriority), - (ReactSharedInternals.T = null), - commitRootImpl( - lanes, - forceSync, - exitStatus, - renderWasConcurrent, - previousUpdateLanePriority, - lanesThatJustErrored, - originallyAttemptedLanes, - wasRootDehydrated, - suspendedCommitReason, - -0, - 0 - ); - } finally { - (ReactSharedInternals.T = prevTransition), - (currentUpdatePriority = previousUpdateLanePriority); - } - } else { - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || exitStatus === RootSuspended) && - ((exitStatus = - globalMostRecentFallbackTime + - FALLBACK_THROTTLE_MS - - now$1()), - 10 < exitStatus) - ) { + } + if (exitStatus === RootFatalErrored) { + prepareFreshStack(root, 0); + markRootSuspended(root, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case RootInProgress: + case RootFatalErrored: + throw Error("Root did not complete. This is a bug in React."); + case RootSuspendedWithDelay: + if ((lanes & 4194176) === lanes) { markRootSuspended( - renderWasConcurrent, + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - THROTTLED_COMMIT, - -0, - 0 - ), - exitStatus + !workInProgressRootDidSkipSuspendedSiblings ); break a; } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, + break; + case RootErrored: + workInProgressRootRecoverableErrors = null; + break; + case RootSuspended: + case RootCompleted: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if (null !== ReactSharedInternals.actQueue) { + lanes = shouldTimeSlice; + forceSync = workInProgressRootRecoverableErrors; + shouldTimeSlice = workInProgressTransitions; + renderWasConcurrent = + workInProgressRootDidIncludeRecursiveRenderUpdate; + exitStatus = workInProgressDeferredLane; + lanesThatJustErrored = workInProgressRootInterleavedUpdatedLanes; + originallyAttemptedLanes = workInProgressSuspendedRetryLanes; + wasRootDehydrated = IMMEDIATE_COMMIT; + var prevTransition = ReactSharedInternals.T, + previousUpdateLanePriority = currentUpdatePriority; + try { + (currentUpdatePriority = DiscreteEventPriority), + (ReactSharedInternals.T = null), + commitRootImpl( + lanes, + forceSync, + shouldTimeSlice, + renderWasConcurrent, + previousUpdateLanePriority, + exitStatus, + lanesThatJustErrored, + originallyAttemptedLanes, + wasRootDehydrated, + -0, + 0 + ); + } finally { + (ReactSharedInternals.T = prevTransition), + (currentUpdatePriority = previousUpdateLanePriority); + } + } else { + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || + renderWasConcurrent === RootSuspended) && + ((renderWasConcurrent = + globalMostRecentFallbackTime + + FALLBACK_THROTTLE_MS - + now$1()), + 10 < renderWasConcurrent) + ) { + markRootSuspended( + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - IMMEDIATE_COMMIT, - -0, - 0 + !workInProgressRootDidSkipSuspendedSiblings + ); + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + THROTTLED_COMMIT, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + IMMEDIATE_COMMIT, + -0, + 0 + ); } } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root); } function queueRecoverableErrors(errors) { @@ -12039,20 +12054,20 @@ __DEV__ && root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index = 31 - clz32(lanes), lane = 1 << index; - didSkipSuspendedSiblings[index] = -1; + didAttemptEntireTree[index] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -12096,11 +12111,7 @@ __DEV__ && workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressRootExitStatus = RootInProgress; workInProgressSuspendedRetryLanes = @@ -12224,7 +12235,9 @@ __DEV__ && function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = RootSuspendedWithDelay; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -12233,10 +12246,10 @@ __DEV__ && workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } - function renderRootSync(root, lanes) { + function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(), @@ -12257,37 +12270,46 @@ __DEV__ && } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if ( workInProgressSuspendedReason !== NotSuspended && null !== workInProgress ) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case SuspendedOnHydration: resetWorkInProgressStack(); - workInProgressRootExitStatus = RootDidNotComplete; + memoizedUpdaters = RootDidNotComplete; break a; case SuspendedOnImmediate: case SuspendedOnData: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case SuspendedOnDeprecatedThrowPromise: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; - throwAndUnwindWorkLoop( - root, - memoizedUpdaters, - thrownValue, - reason - ); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = RootInProgress; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = NotSuspended), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; } catch (thrownValue$30) { handleThrow(root, thrownValue$30); @@ -12298,15 +12320,12 @@ __DEV__ && executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -12331,12 +12350,10 @@ __DEV__ && workInProgressRootRenderTargetTime = now$1() + RENDER_TIMEOUT_MS; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + ); markRenderStarted(lanes); a: do try { @@ -16953,11 +16970,11 @@ __DEV__ && (function () { var internals = { bundleType: 1, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && (internals.rendererConfig = extraDevToolsConfig); diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-prod.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-prod.fb.js index 92dd452422581..f779b96955bb6 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-prod.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-prod.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -1232,7 +1232,7 @@ eventPluginOrder = Array.prototype.slice.call([ "ReactNativeBridgeEventPlugin" ]); recomputePluginOrdering(); -var injectedNamesToPlugins$jscomp$inline_282 = { +var injectedNamesToPlugins$jscomp$inline_287 = { ResponderEventPlugin: ResponderEventPlugin, ReactNativeBridgeEventPlugin: { eventTypes: {}, @@ -1278,32 +1278,32 @@ var injectedNamesToPlugins$jscomp$inline_282 = { } } }, - isOrderingDirty$jscomp$inline_283 = !1, - pluginName$jscomp$inline_284; -for (pluginName$jscomp$inline_284 in injectedNamesToPlugins$jscomp$inline_282) + isOrderingDirty$jscomp$inline_288 = !1, + pluginName$jscomp$inline_289; +for (pluginName$jscomp$inline_289 in injectedNamesToPlugins$jscomp$inline_287) if ( - injectedNamesToPlugins$jscomp$inline_282.hasOwnProperty( - pluginName$jscomp$inline_284 + injectedNamesToPlugins$jscomp$inline_287.hasOwnProperty( + pluginName$jscomp$inline_289 ) ) { - var pluginModule$jscomp$inline_285 = - injectedNamesToPlugins$jscomp$inline_282[pluginName$jscomp$inline_284]; + var pluginModule$jscomp$inline_290 = + injectedNamesToPlugins$jscomp$inline_287[pluginName$jscomp$inline_289]; if ( - !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_284) || - namesToPlugins[pluginName$jscomp$inline_284] !== - pluginModule$jscomp$inline_285 + !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_289) || + namesToPlugins[pluginName$jscomp$inline_289] !== + pluginModule$jscomp$inline_290 ) { - if (namesToPlugins[pluginName$jscomp$inline_284]) + if (namesToPlugins[pluginName$jscomp$inline_289]) throw Error( "EventPluginRegistry: Cannot inject two different event plugins using the same name, `" + - (pluginName$jscomp$inline_284 + "`.") + (pluginName$jscomp$inline_289 + "`.") ); - namesToPlugins[pluginName$jscomp$inline_284] = - pluginModule$jscomp$inline_285; - isOrderingDirty$jscomp$inline_283 = !0; + namesToPlugins[pluginName$jscomp$inline_289] = + pluginModule$jscomp$inline_290; + isOrderingDirty$jscomp$inline_288 = !0; } } -isOrderingDirty$jscomp$inline_283 && recomputePluginOrdering(); +isOrderingDirty$jscomp$inline_288 && recomputePluginOrdering(); var emptyObject$1 = {}, removedKeys = null, removedKeyCount = 0, @@ -1769,6 +1769,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2302,7 +2310,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -2368,39 +2377,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { var originalCallbackNode = root.callbackNode; @@ -9146,7 +9154,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -9158,7 +9166,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -9170,165 +9178,168 @@ function scheduleUpdateOnFiber(root, fiber, lane) { function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -9417,20 +9428,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$9 = 31 - clz32(lanes), lane = 1 << index$9; - didSkipSuspendedSiblings[index$9] = -1; + didAttemptEntireTree[index$9] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -9469,9 +9480,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -9560,7 +9569,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -9569,10 +9580,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -9580,6 +9591,7 @@ function renderRootSync(root, lanes) { if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -9588,24 +9600,37 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + exitStatus = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$127) { - handleThrow(root, thrownValue$127); + } catch (thrownValue$132) { + handleThrow(root, thrownValue$132); } while (1); lanes && root.shellSuspendCounter++; @@ -9613,14 +9638,11 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -9634,12 +9656,10 @@ function renderRootConcurrent(root, lanes) { ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), prepareFreshStack(root, lanes)) - : workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + : (workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + )); a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -9723,8 +9743,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$129) { - handleThrow(root, thrownValue$129); + } catch (thrownValue$134) { + handleThrow(root, thrownValue$134); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -10884,27 +10904,27 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - internals$jscomp$inline_1170 = { + internals$jscomp$inline_1177 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && - (internals$jscomp$inline_1170.rendererConfig = extraDevToolsConfig); + (internals$jscomp$inline_1177.rendererConfig = extraDevToolsConfig); if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1486 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1493 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1486.isDisabled && - hook$jscomp$inline_1486.supportsFiber + !hook$jscomp$inline_1493.isDisabled && + hook$jscomp$inline_1493.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1486.inject( - internals$jscomp$inline_1170 + (rendererID = hook$jscomp$inline_1493.inject( + internals$jscomp$inline_1177 )), - (injectedHook = hook$jscomp$inline_1486); + (injectedHook = hook$jscomp$inline_1493); } catch (err) {} } exports.createPortal = function (children, containerTag) { diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-profiling.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-profiling.fb.js index 396febab84605..2b397ca01a6f9 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-profiling.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-profiling.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<951a89a341aca42bf2a5c4ce5459ed2d>> */ "use strict"; @@ -1236,7 +1236,7 @@ eventPluginOrder = Array.prototype.slice.call([ "ReactNativeBridgeEventPlugin" ]); recomputePluginOrdering(); -var injectedNamesToPlugins$jscomp$inline_298 = { +var injectedNamesToPlugins$jscomp$inline_303 = { ResponderEventPlugin: ResponderEventPlugin, ReactNativeBridgeEventPlugin: { eventTypes: {}, @@ -1282,32 +1282,32 @@ var injectedNamesToPlugins$jscomp$inline_298 = { } } }, - isOrderingDirty$jscomp$inline_299 = !1, - pluginName$jscomp$inline_300; -for (pluginName$jscomp$inline_300 in injectedNamesToPlugins$jscomp$inline_298) + isOrderingDirty$jscomp$inline_304 = !1, + pluginName$jscomp$inline_305; +for (pluginName$jscomp$inline_305 in injectedNamesToPlugins$jscomp$inline_303) if ( - injectedNamesToPlugins$jscomp$inline_298.hasOwnProperty( - pluginName$jscomp$inline_300 + injectedNamesToPlugins$jscomp$inline_303.hasOwnProperty( + pluginName$jscomp$inline_305 ) ) { - var pluginModule$jscomp$inline_301 = - injectedNamesToPlugins$jscomp$inline_298[pluginName$jscomp$inline_300]; + var pluginModule$jscomp$inline_306 = + injectedNamesToPlugins$jscomp$inline_303[pluginName$jscomp$inline_305]; if ( - !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_300) || - namesToPlugins[pluginName$jscomp$inline_300] !== - pluginModule$jscomp$inline_301 + !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_305) || + namesToPlugins[pluginName$jscomp$inline_305] !== + pluginModule$jscomp$inline_306 ) { - if (namesToPlugins[pluginName$jscomp$inline_300]) + if (namesToPlugins[pluginName$jscomp$inline_305]) throw Error( "EventPluginRegistry: Cannot inject two different event plugins using the same name, `" + - (pluginName$jscomp$inline_300 + "`.") + (pluginName$jscomp$inline_305 + "`.") ); - namesToPlugins[pluginName$jscomp$inline_300] = - pluginModule$jscomp$inline_301; - isOrderingDirty$jscomp$inline_299 = !0; + namesToPlugins[pluginName$jscomp$inline_305] = + pluginModule$jscomp$inline_306; + isOrderingDirty$jscomp$inline_304 = !0; } } -isOrderingDirty$jscomp$inline_299 && recomputePluginOrdering(); +isOrderingDirty$jscomp$inline_304 && recomputePluginOrdering(); var emptyObject$1 = {}, removedKeys = null, removedKeyCount = 0, @@ -1838,6 +1838,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2455,7 +2463,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -2521,39 +2530,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -9675,7 +9683,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -9688,7 +9696,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -9700,165 +9708,168 @@ function scheduleUpdateOnFiber(root, fiber, lane) { function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now$1()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -9947,20 +9958,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$9 = 31 - clz32(lanes), lane = 1 << index$9; - didSkipSuspendedSiblings[index$9] = -1; + didAttemptEntireTree[index$9] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -9999,9 +10010,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -10119,7 +10128,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -10128,10 +10139,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -10149,32 +10160,46 @@ function renderRootSync(root, lanes) { } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + memoizedUpdaters = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - throwAndUnwindWorkLoop(root, memoizedUpdaters, thrownValue, reason); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; - } catch (thrownValue$142) { - handleThrow(root, thrownValue$142); + } catch (thrownValue$147) { + handleThrow(root, thrownValue$147); } while (1); lanes && root.shellSuspendCounter++; @@ -10182,15 +10207,12 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -10212,12 +10234,7 @@ function renderRootConcurrent(root, lanes) { workInProgressRootRenderTargetTime = now$1() + 500; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -10303,8 +10320,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$144) { - handleThrow(root, thrownValue$144); + } catch (thrownValue$149) { + handleThrow(root, thrownValue$149); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -11545,21 +11562,21 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - internals$jscomp$inline_1258 = { + internals$jscomp$inline_1265 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromNode, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && - (internals$jscomp$inline_1258.rendererConfig = extraDevToolsConfig); -internals$jscomp$inline_1258.getLaneLabelMap = function () { + (internals$jscomp$inline_1265.rendererConfig = extraDevToolsConfig); +internals$jscomp$inline_1265.getLaneLabelMap = function () { for ( - var map = new Map(), lane = 1, index$148 = 0; - 31 > index$148; - index$148++ + var map = new Map(), lane = 1, index$153 = 0; + 31 > index$153; + index$153++ ) { var label = getLabelForLane(lane); map.set(lane, label); @@ -11567,20 +11584,20 @@ internals$jscomp$inline_1258.getLaneLabelMap = function () { } return map; }; -internals$jscomp$inline_1258.injectProfilingHooks = function (profilingHooks) { +internals$jscomp$inline_1265.injectProfilingHooks = function (profilingHooks) { injectedProfilingHooks = profilingHooks; }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1537 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1544 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1537.isDisabled && - hook$jscomp$inline_1537.supportsFiber + !hook$jscomp$inline_1544.isDisabled && + hook$jscomp$inline_1544.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1537.inject( - internals$jscomp$inline_1258 + (rendererID = hook$jscomp$inline_1544.inject( + internals$jscomp$inline_1265 )), - (injectedHook = hook$jscomp$inline_1537); + (injectedHook = hook$jscomp$inline_1544); } catch (err) {} } exports.createPortal = function (children, containerTag) { diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-dev.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-dev.fb.js index a030ab328251c..6c6dcaf30352c 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-dev.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-dev.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<8d25d38a7b7418a4e54d32f321473a20>> + * @generated SignedSource<<98ed471744ddd1068da11f9a0f379340>> */ "use strict"; @@ -1728,6 +1728,14 @@ __DEV__ && ? wipLanes : nextLanes; } + function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); + } function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -3003,7 +3011,8 @@ __DEV__ && root, root === workInProgressRoot ? nextLanes : 0 )), - 0 !== (nextLanes & 3) && + 0 === (nextLanes & 3) || + checkIfRootIsPrerendering(root, nextLanes) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, nextLanes)); root = root.next; @@ -3071,45 +3080,46 @@ __DEV__ && (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && cancelCallback(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; if ( - currentTime !== root.callbackPriority || - (null !== ReactSharedInternals.actQueue && - pingedLanes !== fakeActCallbackNode$1) - ) - cancelCallback(pingedLanes); - else return currentTime; - switch (lanesToEventPriority(suspendedLanes)) { - case DiscreteEventPriority: - suspendedLanes = ImmediatePriority; - break; - case ContinuousEventPriority: - suspendedLanes = UserBlockingPriority; - break; - case DefaultEventPriority: - suspendedLanes = NormalPriority$1; - break; - case IdleEventPriority: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if ( + currentTime !== root.callbackPriority || + (null !== ReactSharedInternals.actQueue && + pingedLanes !== fakeActCallbackNode$1) + ) + cancelCallback(pingedLanes); + else return currentTime; + switch (lanesToEventPriority(suspendedLanes)) { + case DiscreteEventPriority: + case ContinuousEventPriority: + suspendedLanes = UserBlockingPriority; + break; + case DefaultEventPriority: + suspendedLanes = NormalPriority$1; + break; + case IdleEventPriority: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + null !== ReactSharedInternals.actQueue + ? (ReactSharedInternals.actQueue.push(pingedLanes), + (suspendedLanes = fakeActCallbackNode$1)) + : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - null !== ReactSharedInternals.actQueue - ? (ReactSharedInternals.actQueue.push(pingedLanes), - (suspendedLanes = fakeActCallbackNode$1)) - : (suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes)); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + null !== pingedLanes && cancelCallback(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -12062,7 +12072,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if ( @@ -12105,7 +12115,7 @@ __DEV__ && root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 !== lane || @@ -12118,200 +12128,202 @@ __DEV__ && function performWorkOnRoot(root, lanes, forceSync) { if ((executionContext & (RenderContext | CommitContext)) !== NoContext) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && 0 === (lanes & 60) && 0 === (lanes & root.expiredLanes)) - ? renderRootConcurrent(root, lanes) - : renderRootSync(root, lanes); - if (exitStatus !== RootInProgress) { - var renderWasConcurrent = forceSync; - do { - if (exitStatus === RootDidNotComplete) - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root.tag && exitStatus === RootErrored) { - var lanesThatJustErrored = lanes; - root.errorRecoveryDisabledLanes & lanesThatJustErrored - ? (renderWasConcurrent = 0) - : ((renderWasConcurrent = root.pendingLanes & -536870913), - (renderWasConcurrent = - 0 !== renderWasConcurrent - ? renderWasConcurrent - : renderWasConcurrent & 536870912 - ? 536870912 - : 0)); - if (0 !== renderWasConcurrent) { - lanes = renderWasConcurrent; - a: { - exitStatus = root; - var originallyAttemptedLanes = lanesThatJustErrored; - lanesThatJustErrored = workInProgressRootConcurrentErrors; - renderWasConcurrent = renderRootSync( - exitStatus, - renderWasConcurrent - ); - if (renderWasConcurrent !== RootErrored) { - if (workInProgressRootDidAttachPingListener) { - exitStatus.errorRecoveryDisabledLanes |= - originallyAttemptedLanes; - workInProgressRootInterleavedUpdatedLanes |= - originallyAttemptedLanes; - exitStatus = RootSuspendedWithDelay; - break a; - } - exitStatus = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = lanesThatJustErrored; - null !== exitStatus && queueRecoverableErrors(exitStatus); + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root.expiredLanes)) || + (enableSiblingPrerendering && checkIfRootIsPrerendering(root, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root, lanes) + : renderRootSync(root, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (exitStatus === RootInProgress) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root, lanes, 0, !1); + break; + } else if (exitStatus === RootDidNotComplete) + markRootSuspended( + root, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root.tag && exitStatus === RootErrored) { + var lanesThatJustErrored = lanes; + root.errorRecoveryDisabledLanes & lanesThatJustErrored + ? (renderWasConcurrent = 0) + : ((renderWasConcurrent = root.pendingLanes & -536870913), + (renderWasConcurrent = + 0 !== renderWasConcurrent + ? renderWasConcurrent + : renderWasConcurrent & 536870912 + ? 536870912 + : 0)); + if (0 !== renderWasConcurrent) { + lanes = renderWasConcurrent; + a: { + exitStatus = root; + var originallyAttemptedLanes = lanesThatJustErrored; + lanesThatJustErrored = workInProgressRootConcurrentErrors; + renderWasConcurrent = renderRootSync( + exitStatus, + renderWasConcurrent, + !1 + ); + if (renderWasConcurrent !== RootErrored) { + if (workInProgressRootDidAttachPingListener) { + exitStatus.errorRecoveryDisabledLanes |= + originallyAttemptedLanes; + workInProgressRootInterleavedUpdatedLanes |= + originallyAttemptedLanes; + exitStatus = RootSuspendedWithDelay; + break a; } - exitStatus = renderWasConcurrent; + exitStatus = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = lanesThatJustErrored; + null !== exitStatus && queueRecoverableErrors(exitStatus); } - renderWasConcurrent = !1; - if (exitStatus !== RootErrored) continue; + exitStatus = renderWasConcurrent; } + renderWasConcurrent = !1; + if (exitStatus !== RootErrored) continue; } - if (exitStatus === RootFatalErrored) { - prepareFreshStack(root, 0); - markRootSuspended( - root, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - break; - } - a: { - renderWasConcurrent = root; - switch (exitStatus) { - case RootInProgress: - case RootFatalErrored: - throw Error("Root did not complete. This is a bug in React."); - case RootSuspendedWithDelay: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case RootErrored: - workInProgressRootRecoverableErrors = null; - break; - case RootSuspended: - case RootCompleted: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if (null !== ReactSharedInternals.actQueue) { - lanes = renderWasConcurrent; - forceSync = workInProgressRootRecoverableErrors; - exitStatus = workInProgressTransitions; - renderWasConcurrent = - workInProgressRootDidIncludeRecursiveRenderUpdate; - lanesThatJustErrored = workInProgressDeferredLane; - originallyAttemptedLanes = - workInProgressRootInterleavedUpdatedLanes; - var suspendedRetryLanes = workInProgressSuspendedRetryLanes, - suspendedCommitReason = IMMEDIATE_COMMIT, - prevTransition = ReactSharedInternals.T, - previousUpdateLanePriority = currentUpdatePriority; - try { - (currentUpdatePriority = DiscreteEventPriority), - (ReactSharedInternals.T = null), - commitRootImpl( - lanes, - forceSync, - exitStatus, - renderWasConcurrent, - previousUpdateLanePriority, - lanesThatJustErrored, - originallyAttemptedLanes, - suspendedRetryLanes, - suspendedCommitReason, - -0, - 0 - ); - } finally { - (ReactSharedInternals.T = prevTransition), - (currentUpdatePriority = previousUpdateLanePriority); - } - } else { - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || exitStatus === RootSuspended) && - ((exitStatus = - globalMostRecentFallbackTime + - FALLBACK_THROTTLE_MS - - now$1()), - 10 < exitStatus) - ) { + } + if (exitStatus === RootFatalErrored) { + prepareFreshStack(root, 0); + markRootSuspended(root, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root; + switch (exitStatus) { + case RootInProgress: + case RootFatalErrored: + throw Error("Root did not complete. This is a bug in React."); + case RootSuspendedWithDelay: + if ((lanes & 4194176) === lanes) { markRootSuspended( - renderWasConcurrent, + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - THROTTLED_COMMIT, - -0, - 0 - ), - exitStatus + !workInProgressRootDidSkipSuspendedSiblings ); break a; } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, + break; + case RootErrored: + workInProgressRootRecoverableErrors = null; + break; + case RootSuspended: + case RootCompleted: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if (null !== ReactSharedInternals.actQueue) { + lanes = shouldTimeSlice; + forceSync = workInProgressRootRecoverableErrors; + shouldTimeSlice = workInProgressTransitions; + exitStatus = workInProgressRootDidIncludeRecursiveRenderUpdate; + renderWasConcurrent = workInProgressDeferredLane; + lanesThatJustErrored = workInProgressRootInterleavedUpdatedLanes; + originallyAttemptedLanes = workInProgressSuspendedRetryLanes; + var suspendedCommitReason = IMMEDIATE_COMMIT, + prevTransition = ReactSharedInternals.T, + previousUpdateLanePriority = currentUpdatePriority; + try { + (currentUpdatePriority = DiscreteEventPriority), + (ReactSharedInternals.T = null), + commitRootImpl( + lanes, + forceSync, + shouldTimeSlice, + exitStatus, + previousUpdateLanePriority, + renderWasConcurrent, + lanesThatJustErrored, + originallyAttemptedLanes, + suspendedCommitReason, + -0, + 0 + ); + } finally { + (ReactSharedInternals.T = prevTransition), + (currentUpdatePriority = previousUpdateLanePriority); + } + } else { + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || exitStatus === RootSuspended) && + ((exitStatus = + globalMostRecentFallbackTime + + FALLBACK_THROTTLE_MS - + now$1()), + 10 < exitStatus) + ) { + markRootSuspended( + shouldTimeSlice, lanes, workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - IMMEDIATE_COMMIT, - -0, - 0 + !workInProgressRootDidSkipSuspendedSiblings + ); + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + THROTTLED_COMMIT, + -0, + 0 + ), + exitStatus ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + IMMEDIATE_COMMIT, + -0, + 0 + ); } } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root); } function queueRecoverableErrors(errors) { @@ -12401,20 +12413,20 @@ __DEV__ && root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index = 31 - clz32(lanes), lane = 1 << index; - didSkipSuspendedSiblings[index] = -1; + didAttemptEntireTree[index] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -12458,11 +12470,7 @@ __DEV__ && workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressRootExitStatus = RootInProgress; workInProgressSuspendedRetryLanes = @@ -12586,7 +12594,9 @@ __DEV__ && function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = RootSuspendedWithDelay; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -12595,10 +12605,10 @@ __DEV__ && workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } - function renderRootSync(root, lanes) { + function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(), @@ -12619,37 +12629,46 @@ __DEV__ && } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if ( workInProgressSuspendedReason !== NotSuspended && null !== workInProgress ) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case SuspendedOnHydration: resetWorkInProgressStack(); - workInProgressRootExitStatus = RootDidNotComplete; + memoizedUpdaters = RootDidNotComplete; break a; case SuspendedOnImmediate: case SuspendedOnData: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case SuspendedOnDeprecatedThrowPromise: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = NotSuspended; workInProgressThrownValue = null; - throwAndUnwindWorkLoop( - root, - memoizedUpdaters, - thrownValue, - reason - ); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = RootInProgress; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = NotSuspended), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; } catch (thrownValue$35) { handleThrow(root, thrownValue$35); @@ -12660,15 +12679,12 @@ __DEV__ && executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -12693,12 +12709,10 @@ __DEV__ && workInProgressRootRenderTargetTime = now$1() + RENDER_TIMEOUT_MS; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + ); markRenderStarted(lanes); a: do try { @@ -17174,11 +17188,11 @@ __DEV__ && shouldSuspendImpl = newShouldSuspendImpl; }; var isomorphicReactPackageVersion = React.version; - if ("19.0.0-native-fb-5c56b873-20241107" !== isomorphicReactPackageVersion) + if ("19.0.0-native-fb-989af12f-20241108" !== 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.0.0-native-fb-5c56b873-20241107\nLearn more: https://react.dev/warnings/version-mismatch") + "\n - react-native-renderer: 19.0.0-native-fb-989af12f-20241108\nLearn more: https://react.dev/warnings/version-mismatch") ); if ( "function" !== @@ -17204,11 +17218,11 @@ __DEV__ && (function () { var internals = { bundleType: 1, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromTag, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && (internals.rendererConfig = extraDevToolsConfig); diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-prod.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-prod.fb.js index e328842ffc203..5be8623597e7e 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-prod.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-prod.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<49c61290df76b7ee1ed2ca67aa183762>> + * @generated SignedSource<> */ "use strict"; @@ -1227,7 +1227,7 @@ eventPluginOrder = Array.prototype.slice.call([ "ReactNativeBridgeEventPlugin" ]); recomputePluginOrdering(); -var injectedNamesToPlugins$jscomp$inline_289 = { +var injectedNamesToPlugins$jscomp$inline_294 = { ResponderEventPlugin: ResponderEventPlugin, ReactNativeBridgeEventPlugin: { eventTypes: {}, @@ -1273,32 +1273,32 @@ var injectedNamesToPlugins$jscomp$inline_289 = { } } }, - isOrderingDirty$jscomp$inline_290 = !1, - pluginName$jscomp$inline_291; -for (pluginName$jscomp$inline_291 in injectedNamesToPlugins$jscomp$inline_289) + isOrderingDirty$jscomp$inline_295 = !1, + pluginName$jscomp$inline_296; +for (pluginName$jscomp$inline_296 in injectedNamesToPlugins$jscomp$inline_294) if ( - injectedNamesToPlugins$jscomp$inline_289.hasOwnProperty( - pluginName$jscomp$inline_291 + injectedNamesToPlugins$jscomp$inline_294.hasOwnProperty( + pluginName$jscomp$inline_296 ) ) { - var pluginModule$jscomp$inline_292 = - injectedNamesToPlugins$jscomp$inline_289[pluginName$jscomp$inline_291]; + var pluginModule$jscomp$inline_297 = + injectedNamesToPlugins$jscomp$inline_294[pluginName$jscomp$inline_296]; if ( - !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_291) || - namesToPlugins[pluginName$jscomp$inline_291] !== - pluginModule$jscomp$inline_292 + !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_296) || + namesToPlugins[pluginName$jscomp$inline_296] !== + pluginModule$jscomp$inline_297 ) { - if (namesToPlugins[pluginName$jscomp$inline_291]) + if (namesToPlugins[pluginName$jscomp$inline_296]) throw Error( "EventPluginRegistry: Cannot inject two different event plugins using the same name, `" + - (pluginName$jscomp$inline_291 + "`.") + (pluginName$jscomp$inline_296 + "`.") ); - namesToPlugins[pluginName$jscomp$inline_291] = - pluginModule$jscomp$inline_292; - isOrderingDirty$jscomp$inline_290 = !0; + namesToPlugins[pluginName$jscomp$inline_296] = + pluginModule$jscomp$inline_297; + isOrderingDirty$jscomp$inline_295 = !0; } } -isOrderingDirty$jscomp$inline_290 && recomputePluginOrdering(); +isOrderingDirty$jscomp$inline_295 && recomputePluginOrdering(); var instanceCache = new Map(), instanceProps = new Map(); function getInstanceFromTag(tag) { @@ -1976,6 +1976,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2606,7 +2614,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -2672,39 +2681,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { var originalCallbackNode = root.callbackNode; @@ -9580,7 +9588,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -9592,7 +9600,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -9604,165 +9612,168 @@ function scheduleUpdateOnFiber(root, fiber, lane) { function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -9851,20 +9862,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$11 = 31 - clz32(lanes), lane = 1 << index$11; - didSkipSuspendedSiblings[index$11] = -1; + didAttemptEntireTree[index$11] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -9903,9 +9914,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -9994,7 +10003,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -10003,10 +10014,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -10014,6 +10025,7 @@ function renderRootSync(root, lanes) { if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; + var exitStatus = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -10022,24 +10034,37 @@ function renderRootSync(root, lanes) { switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + exitStatus = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + exitStatus = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + exitStatus = workInProgressRootExitStatus; break; - } catch (thrownValue$131) { - handleThrow(root, thrownValue$131); + } catch (thrownValue$136) { + handleThrow(root, thrownValue$136); } while (1); lanes && root.shellSuspendCounter++; @@ -10047,14 +10072,11 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return exitStatus; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -10068,12 +10090,10 @@ function renderRootConcurrent(root, lanes) { ? ((workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), prepareFreshStack(root, lanes)) - : workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + : (workInProgressRootIsPrerendering = checkIfRootIsPrerendering( + root, + lanes + )); a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { @@ -10157,8 +10177,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$133) { - handleThrow(root, thrownValue$133); + } catch (thrownValue$138) { + handleThrow(root, thrownValue$138); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -11017,11 +11037,11 @@ function updateContainer(element, container, parentComponent, callback) { return lane; } var isomorphicReactPackageVersion = React.version; -if ("19.0.0-native-fb-5c56b873-20241107" !== isomorphicReactPackageVersion) +if ("19.0.0-native-fb-989af12f-20241108" !== 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.0.0-native-fb-5c56b873-20241107\nLearn more: https://react.dev/warnings/version-mismatch") + "\n - react-native-renderer: 19.0.0-native-fb-989af12f-20241108\nLearn more: https://react.dev/warnings/version-mismatch") ); if ( "function" !== @@ -11068,27 +11088,27 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - internals$jscomp$inline_1236 = { + internals$jscomp$inline_1243 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromTag, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && - (internals$jscomp$inline_1236.rendererConfig = extraDevToolsConfig); + (internals$jscomp$inline_1243.rendererConfig = extraDevToolsConfig); if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1573 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1580 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1573.isDisabled && - hook$jscomp$inline_1573.supportsFiber + !hook$jscomp$inline_1580.isDisabled && + hook$jscomp$inline_1580.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1573.inject( - internals$jscomp$inline_1236 + (rendererID = hook$jscomp$inline_1580.inject( + internals$jscomp$inline_1243 )), - (injectedHook = hook$jscomp$inline_1573); + (injectedHook = hook$jscomp$inline_1580); } catch (err) {} } exports.createPortal = function (children, containerTag) { diff --git a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.fb.js b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.fb.js index 3536c71ac9586..e9b97c72349d2 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.fb.js +++ b/compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.fb.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<49a7b48186a108bf5826f33cd1dcfa8b>> + * @generated SignedSource<<84f7fafbd90c5d95b6eb25b2c29653ad>> */ "use strict"; @@ -1231,7 +1231,7 @@ eventPluginOrder = Array.prototype.slice.call([ "ReactNativeBridgeEventPlugin" ]); recomputePluginOrdering(); -var injectedNamesToPlugins$jscomp$inline_305 = { +var injectedNamesToPlugins$jscomp$inline_310 = { ResponderEventPlugin: ResponderEventPlugin, ReactNativeBridgeEventPlugin: { eventTypes: {}, @@ -1277,32 +1277,32 @@ var injectedNamesToPlugins$jscomp$inline_305 = { } } }, - isOrderingDirty$jscomp$inline_306 = !1, - pluginName$jscomp$inline_307; -for (pluginName$jscomp$inline_307 in injectedNamesToPlugins$jscomp$inline_305) + isOrderingDirty$jscomp$inline_311 = !1, + pluginName$jscomp$inline_312; +for (pluginName$jscomp$inline_312 in injectedNamesToPlugins$jscomp$inline_310) if ( - injectedNamesToPlugins$jscomp$inline_305.hasOwnProperty( - pluginName$jscomp$inline_307 + injectedNamesToPlugins$jscomp$inline_310.hasOwnProperty( + pluginName$jscomp$inline_312 ) ) { - var pluginModule$jscomp$inline_308 = - injectedNamesToPlugins$jscomp$inline_305[pluginName$jscomp$inline_307]; + var pluginModule$jscomp$inline_313 = + injectedNamesToPlugins$jscomp$inline_310[pluginName$jscomp$inline_312]; if ( - !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_307) || - namesToPlugins[pluginName$jscomp$inline_307] !== - pluginModule$jscomp$inline_308 + !namesToPlugins.hasOwnProperty(pluginName$jscomp$inline_312) || + namesToPlugins[pluginName$jscomp$inline_312] !== + pluginModule$jscomp$inline_313 ) { - if (namesToPlugins[pluginName$jscomp$inline_307]) + if (namesToPlugins[pluginName$jscomp$inline_312]) throw Error( "EventPluginRegistry: Cannot inject two different event plugins using the same name, `" + - (pluginName$jscomp$inline_307 + "`.") + (pluginName$jscomp$inline_312 + "`.") ); - namesToPlugins[pluginName$jscomp$inline_307] = - pluginModule$jscomp$inline_308; - isOrderingDirty$jscomp$inline_306 = !0; + namesToPlugins[pluginName$jscomp$inline_312] = + pluginModule$jscomp$inline_313; + isOrderingDirty$jscomp$inline_311 = !0; } } -isOrderingDirty$jscomp$inline_306 && recomputePluginOrdering(); +isOrderingDirty$jscomp$inline_311 && recomputePluginOrdering(); var instanceCache = new Map(), instanceProps = new Map(); function getInstanceFromTag(tag) { @@ -2045,6 +2045,14 @@ function getNextLanes(root, wipLanes) { ? wipLanes : nextLanes; } +function checkIfRootIsPrerendering(root, renderLanes) { + return ( + 0 === + (root.pendingLanes & + ~(root.suspendedLanes & ~root.pingedLanes) & + renderLanes) + ); +} function computeExpirationTime(lane, currentTime) { switch (lane) { case 1: @@ -2759,7 +2767,8 @@ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) { root, root === workInProgressRoot ? JSCompiler_inline_result : 0 )), - 0 !== (JSCompiler_inline_result & 3) && + 0 === (JSCompiler_inline_result & 3) || + checkIfRootIsPrerendering(root, JSCompiler_inline_result) || ((didPerformSomeWork = !0), performSyncWorkOnRoot(root, JSCompiler_inline_result)); root = root.next; @@ -2825,39 +2834,38 @@ function scheduleTaskForRootDuringMicrotask(root, currentTime) { (root.callbackNode = null), (root.callbackPriority = 0) ); - if (0 !== (suspendedLanes & 3)) - return ( - null !== pingedLanes && - null !== pingedLanes && - cancelCallback$1(pingedLanes), - (root.callbackPriority = 2), - (root.callbackNode = null), - 2 - ); - currentTime = suspendedLanes & -suspendedLanes; - if (currentTime === root.callbackPriority) return currentTime; - null !== pingedLanes && cancelCallback$1(pingedLanes); - switch (lanesToEventPriority(suspendedLanes)) { - case 2: - suspendedLanes = ImmediatePriority; - break; - case 8: - suspendedLanes = UserBlockingPriority; - break; - case 32: - suspendedLanes = NormalPriority$1; - break; - case 268435456: - suspendedLanes = IdlePriority; - break; - default: - suspendedLanes = NormalPriority$1; - } - pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); - suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); - root.callbackPriority = currentTime; - root.callbackNode = suspendedLanes; - return currentTime; + if ( + 0 === (suspendedLanes & 3) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root, suspendedLanes)) + ) { + currentTime = suspendedLanes & -suspendedLanes; + if (currentTime === root.callbackPriority) return currentTime; + null !== pingedLanes && cancelCallback$1(pingedLanes); + switch (lanesToEventPriority(suspendedLanes)) { + case 2: + case 8: + suspendedLanes = UserBlockingPriority; + break; + case 32: + suspendedLanes = NormalPriority$1; + break; + case 268435456: + suspendedLanes = IdlePriority; + break; + default: + suspendedLanes = NormalPriority$1; + } + pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root); + suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes); + root.callbackPriority = currentTime; + root.callbackNode = suspendedLanes; + return currentTime; + } + null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes); + root.callbackPriority = 2; + root.callbackNode = null; + return 2; } function performWorkOnRootViaSchedulerTask(root, didTimeout) { nestedUpdateScheduled = currentUpdateIsNested = !1; @@ -10108,7 +10116,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); markRootUpdated$1(root, lane); if (0 === (executionContext & 2) || root !== workInProgressRoot) @@ -10121,7 +10129,7 @@ function scheduleUpdateOnFiber(root, fiber, lane) { root, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 )), ensureRootIsScheduled(root), 2 === lane && @@ -10133,165 +10141,168 @@ function scheduleUpdateOnFiber(root, fiber, lane) { function performWorkOnRoot(root$jscomp$0, lanes, forceSync) { if (0 !== (executionContext & 6)) throw Error("Should not already be working."); - var exitStatus = (forceSync = - !forceSync && - 0 === (lanes & 60) && - 0 === (lanes & root$jscomp$0.expiredLanes)) - ? renderRootConcurrent(root$jscomp$0, lanes) - : renderRootSync(root$jscomp$0, lanes); - if (0 !== exitStatus) { - var renderWasConcurrent = forceSync; - do { - if (6 === exitStatus) - markRootSuspended( - root$jscomp$0, - lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings - ); - else { - forceSync = root$jscomp$0.current.alternate; - if ( - renderWasConcurrent && - !isRenderConsistentWithExternalStores(forceSync) - ) { - exitStatus = renderRootSync(root$jscomp$0, lanes); - renderWasConcurrent = !1; - continue; - } - if (0 !== root$jscomp$0.tag && 2 === exitStatus) { - renderWasConcurrent = lanes; - if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) - var JSCompiler_inline_result = 0; - else + var shouldTimeSlice = + (!forceSync && + 0 === (lanes & 60) && + 0 === (lanes & root$jscomp$0.expiredLanes)) || + (enableSiblingPrerendering && + checkIfRootIsPrerendering(root$jscomp$0, lanes)), + exitStatus = shouldTimeSlice + ? renderRootConcurrent(root$jscomp$0, lanes) + : renderRootSync(root$jscomp$0, lanes, !0), + renderWasConcurrent = shouldTimeSlice; + do { + if (0 === exitStatus) { + enableSiblingPrerendering && + workInProgressRootIsPrerendering && + !shouldTimeSlice && + markRootSuspended(root$jscomp$0, lanes, 0, !1); + break; + } else if (6 === exitStatus) + markRootSuspended( + root$jscomp$0, + lanes, + 0, + !workInProgressRootDidSkipSuspendedSiblings + ); + else { + forceSync = root$jscomp$0.current.alternate; + if ( + renderWasConcurrent && + !isRenderConsistentWithExternalStores(forceSync) + ) { + exitStatus = renderRootSync(root$jscomp$0, lanes, !1); + renderWasConcurrent = !1; + continue; + } + if (0 !== root$jscomp$0.tag && 2 === exitStatus) { + renderWasConcurrent = lanes; + if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent) + var JSCompiler_inline_result = 0; + else + (JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913), (JSCompiler_inline_result = - root$jscomp$0.pendingLanes & -536870913), - (JSCompiler_inline_result = - 0 !== JSCompiler_inline_result - ? JSCompiler_inline_result - : JSCompiler_inline_result & 536870912 - ? 536870912 - : 0); - if (0 !== JSCompiler_inline_result) { - lanes = JSCompiler_inline_result; - a: { - var root = root$jscomp$0; - exitStatus = workInProgressRootConcurrentErrors; - JSCompiler_inline_result = renderRootSync( - root, - JSCompiler_inline_result - ); - if (2 !== JSCompiler_inline_result) { - if (workInProgressRootDidAttachPingListener) { - root.errorRecoveryDisabledLanes |= renderWasConcurrent; - workInProgressRootInterleavedUpdatedLanes |= - renderWasConcurrent; - exitStatus = 4; - break a; - } - renderWasConcurrent = workInProgressRootRecoverableErrors; - workInProgressRootRecoverableErrors = exitStatus; - null !== renderWasConcurrent && - queueRecoverableErrors(renderWasConcurrent); + 0 !== JSCompiler_inline_result + ? JSCompiler_inline_result + : JSCompiler_inline_result & 536870912 + ? 536870912 + : 0); + if (0 !== JSCompiler_inline_result) { + lanes = JSCompiler_inline_result; + a: { + var root = root$jscomp$0; + exitStatus = workInProgressRootConcurrentErrors; + JSCompiler_inline_result = renderRootSync( + root, + JSCompiler_inline_result, + !1 + ); + if (2 !== JSCompiler_inline_result) { + if (workInProgressRootDidAttachPingListener) { + root.errorRecoveryDisabledLanes |= renderWasConcurrent; + workInProgressRootInterleavedUpdatedLanes |= + renderWasConcurrent; + exitStatus = 4; + break a; } - exitStatus = JSCompiler_inline_result; + renderWasConcurrent = workInProgressRootRecoverableErrors; + workInProgressRootRecoverableErrors = exitStatus; + null !== renderWasConcurrent && + queueRecoverableErrors(renderWasConcurrent); } - renderWasConcurrent = !1; - if (2 !== exitStatus) continue; + exitStatus = JSCompiler_inline_result; } + renderWasConcurrent = !1; + if (2 !== exitStatus) continue; } - if (1 === exitStatus) { - prepareFreshStack(root$jscomp$0, 0); + } + if (1 === exitStatus) { + prepareFreshStack(root$jscomp$0, 0); + markRootSuspended(root$jscomp$0, lanes, 0, !0); + break; + } + a: { + shouldTimeSlice = root$jscomp$0; + renderWasConcurrent = exitStatus; + switch (renderWasConcurrent) { + case 0: + case 1: + throw Error("Root did not complete. This is a bug in React."); + case 4: + if ((lanes & 4194176) === lanes) { + markRootSuspended( + shouldTimeSlice, + lanes, + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings + ); + break a; + } + break; + case 2: + workInProgressRootRecoverableErrors = null; + break; + case 3: + case 5: + break; + default: + throw Error("Unknown root exit status."); + } + shouldTimeSlice.finishedWork = forceSync; + shouldTimeSlice.finishedLanes = lanes; + if ( + (lanes & 62914560) === lanes && + (alwaysThrottleRetries || 3 === renderWasConcurrent) && + ((renderWasConcurrent = globalMostRecentFallbackTime + 300 - now$1()), + 10 < renderWasConcurrent) + ) { markRootSuspended( - root$jscomp$0, + shouldTimeSlice, lanes, - 0, - workInProgressRootDidSkipSuspendedSiblings + workInProgressDeferredLane, + !workInProgressRootDidSkipSuspendedSiblings ); - break; - } - a: { - renderWasConcurrent = root$jscomp$0; - switch (exitStatus) { - case 0: - case 1: - throw Error("Root did not complete. This is a bug in React."); - case 4: - if ((lanes & 4194176) === lanes) { - markRootSuspended( - renderWasConcurrent, - lanes, - workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - break a; - } - break; - case 2: - workInProgressRootRecoverableErrors = null; - break; - case 3: - case 5: - break; - default: - throw Error("Unknown root exit status."); - } - renderWasConcurrent.finishedWork = forceSync; - renderWasConcurrent.finishedLanes = lanes; - if ( - (lanes & 62914560) === lanes && - (alwaysThrottleRetries || 3 === exitStatus) && - ((exitStatus = globalMostRecentFallbackTime + 300 - now$1()), - 10 < exitStatus) - ) { - markRootSuspended( - renderWasConcurrent, + if (0 !== getNextLanes(shouldTimeSlice, 0)) break a; + shouldTimeSlice.timeoutHandle = scheduleTimeout( + commitRootWhenReady.bind( + null, + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, lanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings - ); - if (0 !== getNextLanes(renderWasConcurrent, 0)) break a; - renderWasConcurrent.timeoutHandle = scheduleTimeout( - commitRootWhenReady.bind( - null, - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 2, - -0, - 0 - ), - exitStatus - ); - break a; - } - commitRootWhenReady( - renderWasConcurrent, - forceSync, - workInProgressRootRecoverableErrors, - workInProgressTransitions, - workInProgressRootDidIncludeRecursiveRenderUpdate, - lanes, - workInProgressDeferredLane, - workInProgressRootInterleavedUpdatedLanes, - workInProgressSuspendedRetryLanes, - workInProgressRootDidSkipSuspendedSiblings, - 0, - -0, - 0 + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 2, + -0, + 0 + ), + renderWasConcurrent ); + break a; } + commitRootWhenReady( + shouldTimeSlice, + forceSync, + workInProgressRootRecoverableErrors, + workInProgressTransitions, + workInProgressRootDidIncludeRecursiveRenderUpdate, + lanes, + workInProgressDeferredLane, + workInProgressRootInterleavedUpdatedLanes, + workInProgressSuspendedRetryLanes, + workInProgressRootDidSkipSuspendedSiblings, + 0, + -0, + 0 + ); } - break; - } while (1); - } + } + break; + } while (1); ensureRootIsScheduled(root$jscomp$0); } function queueRecoverableErrors(errors) { @@ -10380,20 +10391,20 @@ function markRootSuspended( root, suspendedLanes, spawnedLane, - didSkipSuspendedSiblings + didAttemptEntireTree ) { suspendedLanes &= ~workInProgressRootPingedLanes; suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes; root.suspendedLanes |= suspendedLanes; root.pingedLanes &= ~suspendedLanes; enableSiblingPrerendering && - !didSkipSuspendedSiblings && + didAttemptEntireTree && (root.warmLanes |= suspendedLanes); - didSkipSuspendedSiblings = root.expirationTimes; + didAttemptEntireTree = root.expirationTimes; for (var lanes = suspendedLanes; 0 < lanes; ) { var index$11 = 31 - clz32(lanes), lane = 1 << index$11; - didSkipSuspendedSiblings[index$11] = -1; + didAttemptEntireTree[index$11] = -1; lanes &= ~lane; } 0 !== spawnedLane && @@ -10432,9 +10443,7 @@ function prepareFreshStack(root, lanes) { workInProgressSuspendedReason = 0; workInProgressThrownValue = null; workInProgressRootDidSkipSuspendedSiblings = !1; - workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & ~(root.suspendedLanes & ~root.pingedLanes) & lanes); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); workInProgressRootDidAttachPingListener = !1; workInProgressSuspendedRetryLanes = workInProgressDeferredLane = @@ -10552,7 +10561,9 @@ function pushAsyncDispatcher() { function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; workInProgressRootDidSkipSuspendedSiblings || - 0 !== (workInProgressRootRenderLanes & 60) || + ((workInProgressRootRenderLanes & 4194176) !== + workInProgressRootRenderLanes && + null !== suspenseHandlerStackCursor.current) || (workInProgressRootIsPrerendering = !0); (0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727)) || @@ -10561,10 +10572,10 @@ function renderDidSuspendDelayIfPossible() { workInProgressRoot, workInProgressRootRenderLanes, workInProgressDeferredLane, - workInProgressRootDidSkipSuspendedSiblings + !1 ); } -function renderRootSync(root, lanes) { +function renderRootSync(root, lanes, shouldYieldForPrerendering) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), @@ -10582,32 +10593,46 @@ function renderRootSync(root, lanes) { } markRenderStarted(lanes); lanes = !1; + memoizedUpdaters = workInProgressRootExitStatus; a: do try { if (0 !== workInProgressSuspendedReason && null !== workInProgress) { - memoizedUpdaters = workInProgress; - var thrownValue = workInProgressThrownValue; + var unitOfWork = workInProgress, + thrownValue = workInProgressThrownValue; switch (workInProgressSuspendedReason) { case 8: resetWorkInProgressStack(); - workInProgressRootExitStatus = 6; + memoizedUpdaters = 6; break a; case 3: case 2: - lanes || - null !== suspenseHandlerStackCursor.current || - (lanes = !0); - default: + case 6: + null === suspenseHandlerStackCursor.current && (lanes = !0); var reason = workInProgressSuspendedReason; workInProgressSuspendedReason = 0; workInProgressThrownValue = null; - throwAndUnwindWorkLoop(root, memoizedUpdaters, thrownValue, reason); + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); + if ( + enableSiblingPrerendering && + shouldYieldForPrerendering && + workInProgressRootIsPrerendering + ) { + memoizedUpdaters = 0; + break a; + } + break; + default: + (reason = workInProgressSuspendedReason), + (workInProgressSuspendedReason = 0), + (workInProgressThrownValue = null), + throwAndUnwindWorkLoop(root, unitOfWork, thrownValue, reason); } } workLoopSync(); + memoizedUpdaters = workInProgressRootExitStatus; break; - } catch (thrownValue$146) { - handleThrow(root, thrownValue$146); + } catch (thrownValue$151) { + handleThrow(root, thrownValue$151); } while (1); lanes && root.shellSuspendCounter++; @@ -10615,15 +10640,12 @@ function renderRootSync(root, lanes) { executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; ReactSharedInternals.A = prevAsyncDispatcher; - if (null !== workInProgress) - throw Error( - "Cannot commit an incomplete root. This error is likely caused by a bug in React. Please file an issue." - ); markRenderStopped(); - workInProgressRoot = null; - workInProgressRootRenderLanes = 0; - finishQueueingConcurrentUpdates(); - return workInProgressRootExitStatus; + null === workInProgress && + ((workInProgressRoot = null), + (workInProgressRootRenderLanes = 0), + finishQueueingConcurrentUpdates()); + return memoizedUpdaters; } function workLoopSync() { for (; null !== workInProgress; ) performUnitOfWork(workInProgress); @@ -10645,12 +10667,7 @@ function renderRootConcurrent(root, lanes) { workInProgressRootRenderTargetTime = now$1() + 500; prepareFreshStack(root, lanes); } else - workInProgressRootIsPrerendering && - (workInProgressRootIsPrerendering = - 0 === - (root.pendingLanes & - ~(root.suspendedLanes & ~root.pingedLanes) & - lanes)); + workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root, lanes); markRenderStarted(lanes); a: do try { @@ -10736,8 +10753,8 @@ function renderRootConcurrent(root, lanes) { } workLoopConcurrent(); break; - } catch (thrownValue$148) { - handleThrow(root, thrownValue$148); + } catch (thrownValue$153) { + handleThrow(root, thrownValue$153); } while (1); lastContextDependency = currentlyRenderingFiber = null; @@ -11677,11 +11694,11 @@ function updateContainer(element, container, parentComponent, callback) { return lane; } var isomorphicReactPackageVersion = React.version; -if ("19.0.0-native-fb-5c56b873-20241107" !== isomorphicReactPackageVersion) +if ("19.0.0-native-fb-989af12f-20241108" !== 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.0.0-native-fb-5c56b873-20241107\nLearn more: https://react.dev/warnings/version-mismatch") + "\n - react-native-renderer: 19.0.0-native-fb-989af12f-20241108\nLearn more: https://react.dev/warnings/version-mismatch") ); if ( "function" !== @@ -11728,21 +11745,21 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - internals$jscomp$inline_1324 = { + internals$jscomp$inline_1331 = { bundleType: 0, - version: "19.0.0-native-fb-5c56b873-20241107", + version: "19.0.0-native-fb-989af12f-20241108", rendererPackageName: "react-native-renderer", currentDispatcherRef: ReactSharedInternals, findFiberByHostInstance: getInstanceFromTag, - reconcilerVersion: "19.0.0-native-fb-5c56b873-20241107" + reconcilerVersion: "19.0.0-native-fb-989af12f-20241108" }; null !== extraDevToolsConfig && - (internals$jscomp$inline_1324.rendererConfig = extraDevToolsConfig); -internals$jscomp$inline_1324.getLaneLabelMap = function () { + (internals$jscomp$inline_1331.rendererConfig = extraDevToolsConfig); +internals$jscomp$inline_1331.getLaneLabelMap = function () { for ( - var map = new Map(), lane = 1, index$152 = 0; - 31 > index$152; - index$152++ + var map = new Map(), lane = 1, index$157 = 0; + 31 > index$157; + index$157++ ) { var label = getLabelForLane(lane); map.set(lane, label); @@ -11750,20 +11767,20 @@ internals$jscomp$inline_1324.getLaneLabelMap = function () { } return map; }; -internals$jscomp$inline_1324.injectProfilingHooks = function (profilingHooks) { +internals$jscomp$inline_1331.injectProfilingHooks = function (profilingHooks) { injectedProfilingHooks = profilingHooks; }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1624 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1631 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1624.isDisabled && - hook$jscomp$inline_1624.supportsFiber + !hook$jscomp$inline_1631.isDisabled && + hook$jscomp$inline_1631.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1624.inject( - internals$jscomp$inline_1324 + (rendererID = hook$jscomp$inline_1631.inject( + internals$jscomp$inline_1331 )), - (injectedHook = hook$jscomp$inline_1624); + (injectedHook = hook$jscomp$inline_1631); } catch (err) {} } exports.createPortal = function (children, containerTag) {