From e4c6e4af17f1b69365584447ecec77c99168037f Mon Sep 17 00:00:00 2001 From: gnoff Date: Thu, 25 Apr 2024 17:45:25 +0000 Subject: [PATCH] (Land #28798) Move Current Owner (and Cache) to an Async Dispatcher (#28912) Rebasing and landing https://github.com/facebook/react/pull/28798 This PR was approved already but held back to give time for the sync. Rebased and landing here without pushing to seb's remote to avoid possibility of lost updates --------- Co-authored-by: Sebastian Markbage DiffTrain build for commit https://github.com/facebook/react/commit/94eed63c49d989861ae7cd62e111de6d717f0a10. --- .../cjs/ReactTestRenderer-dev.js | 55 ++++++++------ .../cjs/ReactTestRenderer-prod.js | 68 +++++++++--------- .../cjs/ReactTestRenderer-profiling.js | 54 +++++++------- .../vendor/react/cjs/JSXDEVRuntime-dev.js | 35 ++++++--- .../vendor/react/cjs/JSXRuntime-dev.js | 35 ++++++--- .../vendor/react/cjs/JSXRuntime-prod.js | 11 ++- .../vendor/react/cjs/JSXRuntime-profiling.js | 11 ++- .../RKJSModules/vendor/react/cjs/React-dev.js | 51 ++++++++----- .../vendor/react/cjs/React-prod.js | 40 ++++------- .../vendor/react/cjs/React-profiling.js | 40 ++++------- .../Libraries/Renderer/REVISION | 2 +- .../implementations/ReactFabric-dev.fb.js | 59 ++++++++------- .../implementations/ReactFabric-prod.fb.js | 64 +++++++++-------- .../ReactFabric-profiling.fb.js | 50 +++++++------ .../ReactNativeRenderer-dev.fb.js | 59 ++++++++------- .../ReactNativeRenderer-prod.fb.js | 72 ++++++++++--------- .../ReactNativeRenderer-profiling.fb.js | 58 ++++++++------- 17 files changed, 425 insertions(+), 339 deletions(-) diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js index d899798dba3df..26ec83f5a263b 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<000c06a477839c734ee52d10d49394b6>> */ 'use strict'; @@ -562,6 +562,11 @@ var PassiveMask = Passive$1 | Visibility | ChildDeletion; // Union of tags that var StaticMask = LayoutStatic | PassiveStatic | RefStatic | MaySuspendCommit; +var currentOwner = null; +function setCurrentOwner(fiber) { + currentOwner = fiber; +} + function getNearestMountedFiber(fiber) { var node = fiber; var nearestMounted = fiber; @@ -605,7 +610,7 @@ function isFiberMounted(fiber) { } function isMounted(component) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.tag === ClassComponent) { var ownerFiber = owner; @@ -11897,7 +11902,7 @@ function updateForwardRef(current, workInProgress, Component, nextProps, renderL } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, render, propsWithoutRef, ref, renderLanes); setIsRendering(false); @@ -12380,7 +12385,7 @@ function updateFunctionComponent(current, workInProgress, Component, nextProps, } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, Component, nextProps, context, renderLanes); setIsRendering(false); @@ -12532,7 +12537,7 @@ function finishClassComponent(current, workInProgress, Component, shouldUpdate, var instance = workInProgress.stateNode; // Rerender { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); } var nextChildren; @@ -13851,7 +13856,7 @@ function updateContextConsumer(current, workInProgress, renderLanes) { var newChildren; { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); newChildren = render(newValue); setIsRendering(false); @@ -19158,10 +19163,16 @@ function getCacheForType(resourceType) { return cacheForType; } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: getCacheForType }; +{ + DefaultAsyncDispatcher.getOwner = function () { + return currentOwner; + }; +} + if (typeof Symbol === 'function' && Symbol.for) { var symbolFor = Symbol.for; symbolFor('selector.component'); @@ -20114,7 +20125,7 @@ function handleThrow(root, thrownValue) { resetCurrentFiber(); { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } if (thrownValue === SuspenseException) { @@ -20270,17 +20281,17 @@ function popDispatcher(prevDispatcher) { ReactSharedInternals.H = prevDispatcher; } -function pushCacheDispatcher() { +function pushAsyncDispatcher() { { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } } -function popCacheDispatcher(prevCacheDispatcher) { +function popAsyncDispatcher(prevAsyncDispatcher) { { - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; } } @@ -20338,7 +20349,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -20418,7 +20429,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); if (workInProgress !== null) { // This is a sync render, so we should have finished the whole tree. @@ -20451,7 +20462,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -20664,7 +20675,7 @@ function renderRootConcurrent(root, lanes) { resetContextDependencies(); popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); executionContext = prevExecutionContext; @@ -20728,7 +20739,7 @@ function performUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -20828,7 +20839,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -21156,7 +21167,7 @@ function commitRootImpl(root, recoverableErrors, transitions, didIncludeRenderPh executionContext |= CommitContext; // Reset this to null before calling lifecycles { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } // The commit phase is broken into several sub-phases. We do a separate pass // of the effect list for each phase: all mutation effects come before all // layout effects, and so on. @@ -22978,7 +22989,7 @@ identifierPrefix, onUncaughtError, onCaughtError, onRecoverableError, transition return root; } -var ReactVersion = '19.0.0-beta-6e32de0b'; +var ReactVersion = '19.0.0-beta-fd8f46d6'; /* * The `'' + value` pattern (used in perf-sensitive code) throws for Symbol diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js index cf0a3e0483b08..61e872d49e661 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<20cadeef827c3ff3286e46c141479566>> + * @generated SignedSource<<319337dda022f270f64882a507f3fb81>> */ "use strict"; @@ -29,8 +29,6 @@ function _createClass(Constructor, protoProps, staticProps) { return Constructor; } var assign = Object.assign, - ReactSharedInternals = - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), @@ -167,6 +165,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -272,6 +271,8 @@ function findCurrentHostFiberImpl(node) { return null; } var isArrayImpl = Array.isArray, + ReactSharedInternals = + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, scheduleCallback$3 = Scheduler$1.unstable_scheduleCallback, cancelCallback$1 = Scheduler$1.unstable_cancelCallback, shouldYield = Scheduler$1.unstable_shouldYield, @@ -4254,7 +4255,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; var nextChildren = didCaptureError && "function" !== typeof Component.getDerivedStateFromError ? null @@ -7382,7 +7383,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -7390,6 +7391,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -7815,7 +7819,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -7857,10 +7861,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -7877,7 +7881,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; @@ -7912,7 +7916,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -7929,7 +7933,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), @@ -8019,7 +8023,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return 0; workInProgressRoot = null; @@ -8035,7 +8039,7 @@ function performUnitOfWork(unitOfWork) { var next = beginWork(unitOfWork.alternate, unitOfWork, entangledRenderLanes); unitOfWork.memoizedProps = unitOfWork.pendingProps; null === next ? completeUnitOfWork(unitOfWork) : (workInProgress = next); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate; @@ -8089,7 +8093,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -8243,7 +8247,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitMutationEffectsOnFiber(finishedWork, root); root.current = finishedWork; @@ -9145,19 +9149,19 @@ function wrapFiber(fiber) { fiberToWrapper.set(fiber, wrapper)); return wrapper; } -var devToolsConfig$jscomp$inline_1027 = { +var devToolsConfig$jscomp$inline_1037 = { findFiberByHostInstance: function () { throw Error("TestRenderer does not support findFiberByHostInstance()"); }, bundleType: 0, - version: "19.0.0-beta-bf8434d4", + version: "19.0.0-beta-3efac47e", rendererPackageName: "react-test-renderer" }; -var internals$jscomp$inline_1246 = { - bundleType: devToolsConfig$jscomp$inline_1027.bundleType, - version: devToolsConfig$jscomp$inline_1027.version, - rendererPackageName: devToolsConfig$jscomp$inline_1027.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1027.rendererConfig, +var internals$jscomp$inline_1256 = { + bundleType: devToolsConfig$jscomp$inline_1037.bundleType, + version: devToolsConfig$jscomp$inline_1037.version, + rendererPackageName: devToolsConfig$jscomp$inline_1037.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1037.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -9174,26 +9178,26 @@ var internals$jscomp$inline_1246 = { return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1027.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1037.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-bf8434d4" + reconcilerVersion: "19.0.0-beta-3efac47e" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1247 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1257 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1247.isDisabled && - hook$jscomp$inline_1247.supportsFiber + !hook$jscomp$inline_1257.isDisabled && + hook$jscomp$inline_1257.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1247.inject( - internals$jscomp$inline_1246 + (rendererID = hook$jscomp$inline_1257.inject( + internals$jscomp$inline_1256 )), - (injectedHook = hook$jscomp$inline_1247); + (injectedHook = hook$jscomp$inline_1257); } catch (err) {} } exports._Scheduler = Scheduler; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js index 6ce9259af517b..9f0ea85768f56 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<7e2a599e341d8b9878a6db74c4348769>> + * @generated SignedSource<> */ "use strict"; @@ -29,8 +29,6 @@ function _createClass(Constructor, protoProps, staticProps) { return Constructor; } var assign = Object.assign, - ReactSharedInternals = - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), @@ -167,6 +165,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -272,6 +271,8 @@ function findCurrentHostFiberImpl(node) { return null; } var isArrayImpl = Array.isArray, + ReactSharedInternals = + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, scheduleCallback$3 = Scheduler$1.unstable_scheduleCallback, cancelCallback$1 = Scheduler$1.unstable_cancelCallback, shouldYield = Scheduler$1.unstable_shouldYield, @@ -4418,7 +4419,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; if ( didCaptureError && "function" !== typeof Component.getDerivedStateFromError @@ -7852,7 +7853,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -7860,6 +7861,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -8289,7 +8293,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -8360,10 +8364,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -8380,7 +8384,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); markRenderStarted(lanes); @@ -8416,7 +8420,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -8434,7 +8438,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now$1() + 500), @@ -8525,7 +8529,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return ( @@ -8555,7 +8559,7 @@ function performUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate, @@ -8612,7 +8616,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -8778,7 +8782,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitTime = now(); commitMutationEffectsOnFiber(finishedWork, root); @@ -9761,12 +9765,12 @@ function wrapFiber(fiber) { fiberToWrapper.set(fiber, wrapper)); return wrapper; } -var devToolsConfig$jscomp$inline_1109 = { +var devToolsConfig$jscomp$inline_1119 = { findFiberByHostInstance: function () { throw Error("TestRenderer does not support findFiberByHostInstance()"); }, bundleType: 0, - version: "19.0.0-beta-b8ced2d7", + version: "19.0.0-beta-70d95fed", rendererPackageName: "react-test-renderer" }; (function (internals) { @@ -9783,10 +9787,10 @@ var devToolsConfig$jscomp$inline_1109 = { } catch (err) {} return hook.checkDCE ? !0 : !1; })({ - bundleType: devToolsConfig$jscomp$inline_1109.bundleType, - version: devToolsConfig$jscomp$inline_1109.version, - rendererPackageName: devToolsConfig$jscomp$inline_1109.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1109.rendererConfig, + bundleType: devToolsConfig$jscomp$inline_1119.bundleType, + version: devToolsConfig$jscomp$inline_1119.version, + rendererPackageName: devToolsConfig$jscomp$inline_1119.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1119.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -9803,14 +9807,14 @@ var devToolsConfig$jscomp$inline_1109 = { return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1109.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1119.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-b8ced2d7" + reconcilerVersion: "19.0.0-beta-70d95fed" }); exports._Scheduler = Scheduler; exports.act = act; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXDEVRuntime-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXDEVRuntime-dev.js index 42ac7789f2534..8fcf2070f2396 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXDEVRuntime-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXDEVRuntime-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<4c8919e8adb15c1f31e630f08e73d86f>> */ 'use strict'; @@ -917,6 +917,19 @@ function getComponentNameFromFiber(fiber) { } var REACT_CLIENT_REFERENCE = Symbol.for('react.client.reference'); + +function getOwner() { + { + var dispatcher = ReactSharedInternals.A; + + if (dispatcher === null) { + return null; + } + + return dispatcher.getOwner(); + } +} + var specialPropKeyWarningShown; var specialPropRefWarningShown; var didWarnAboutStringRefs; @@ -955,11 +968,13 @@ function hasValidKey(config) { function warnIfStringRefCannotBeAutoConverted(config, self) { { - if (typeof config.ref === 'string' && ReactSharedInternals.owner && self && ReactSharedInternals.owner.stateNode !== self) { - var componentName = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner; + + if (typeof config.ref === 'string' && (owner = getOwner()) && self && owner.stateNode !== self) { + var componentName = getComponentNameFromType(owner.type); if (!didWarnAboutStringRefs[componentName]) { - error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(ReactSharedInternals.owner.type), config.ref); + error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(owner.type), config.ref); didWarnAboutStringRefs[componentName] = true; } @@ -1192,7 +1207,7 @@ function jsxDEV$1(type, config, maybeKey, isStaticChildren, source, self) { ref = config.ref; { - ref = coerceStringRef(ref, ReactSharedInternals.owner, type); + ref = coerceStringRef(ref, getOwner(), type); } } @@ -1244,7 +1259,7 @@ function jsxDEV$1(type, config, maybeKey, isStaticChildren, source, self) { } } - var element = ReactElement(type, key, ref, self, source, ReactSharedInternals.owner, props); + var element = ReactElement(type, key, ref, self, source, getOwner(), props); if (type === REACT_FRAGMENT_TYPE) { validateFragmentProps(element); @@ -1256,8 +1271,10 @@ function jsxDEV$1(type, config, maybeKey, isStaticChildren, source, self) { function getDeclarationErrorAddendum() { { - if (ReactSharedInternals.owner) { - var name = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner = getOwner(); + + if (owner) { + var name = getComponentNameFromType(owner.type); if (name) { return '\n\nCheck the render method of `' + name + '`.'; @@ -1364,7 +1381,7 @@ function validateExplicitKey(element, parentType) { var childOwner = ''; - if (element && element._owner != null && element._owner !== ReactSharedInternals.owner) { + if (element && element._owner != null && element._owner !== getOwner()) { var ownerName = null; if (typeof element._owner.tag === 'number') { diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-dev.js index 1a0c41ffbf842..8068ae2d2d37c 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<2c29550aadda1d8003d31abee3051694>> + * @generated SignedSource<<659c779c0ac134a5010cd8f6556b1b17>> */ 'use strict'; @@ -917,6 +917,19 @@ function getComponentNameFromFiber(fiber) { } var REACT_CLIENT_REFERENCE = Symbol.for('react.client.reference'); + +function getOwner() { + { + var dispatcher = ReactSharedInternals.A; + + if (dispatcher === null) { + return null; + } + + return dispatcher.getOwner(); + } +} + var specialPropKeyWarningShown; var specialPropRefWarningShown; var didWarnAboutStringRefs; @@ -955,11 +968,13 @@ function hasValidKey(config) { function warnIfStringRefCannotBeAutoConverted(config, self) { { - if (typeof config.ref === 'string' && ReactSharedInternals.owner && self && ReactSharedInternals.owner.stateNode !== self) { - var componentName = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner; + + if (typeof config.ref === 'string' && (owner = getOwner()) && self && owner.stateNode !== self) { + var componentName = getComponentNameFromType(owner.type); if (!didWarnAboutStringRefs[componentName]) { - error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(ReactSharedInternals.owner.type), config.ref); + error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(owner.type), config.ref); didWarnAboutStringRefs[componentName] = true; } @@ -1216,7 +1231,7 @@ function jsxDEV(type, config, maybeKey, isStaticChildren, source, self) { ref = config.ref; { - ref = coerceStringRef(ref, ReactSharedInternals.owner, type); + ref = coerceStringRef(ref, getOwner(), type); } } @@ -1268,7 +1283,7 @@ function jsxDEV(type, config, maybeKey, isStaticChildren, source, self) { } } - var element = ReactElement(type, key, ref, self, source, ReactSharedInternals.owner, props); + var element = ReactElement(type, key, ref, self, source, getOwner(), props); if (type === REACT_FRAGMENT_TYPE) { validateFragmentProps(element); @@ -1280,8 +1295,10 @@ function jsxDEV(type, config, maybeKey, isStaticChildren, source, self) { function getDeclarationErrorAddendum() { { - if (ReactSharedInternals.owner) { - var name = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner = getOwner(); + + if (owner) { + var name = getComponentNameFromType(owner.type); if (name) { return '\n\nCheck the render method of `' + name + '`.'; @@ -1388,7 +1405,7 @@ function validateExplicitKey(element, parentType) { var childOwner = ''; - if (element && element._owner != null && element._owner !== ReactSharedInternals.owner) { + if (element && element._owner != null && element._owner !== getOwner()) { var ownerName = null; if (typeof element._owner.tag === 'number') { diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-prod.js index 36af6a127d99d..f5c7cb7de3ae1 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<62661c1c6567dce2b9c9ba9b3170fc16>> + * @generated SignedSource<<33a22d7e025b0504577f8d6f9a29d73e>> */ "use strict"; @@ -34,6 +34,10 @@ function formatProdErrorMessage(code) { } var ReactSharedInternals = React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; +function getOwner() { + var dispatcher = ReactSharedInternals.A; + return null === dispatcher ? null : dispatcher.getOwner(); +} function jsxProd(type, config, maybeKey) { var key = null, ref = null; @@ -41,7 +45,7 @@ function jsxProd(type, config, maybeKey) { void 0 !== config.key && (key = "" + config.key); if (void 0 !== config.ref) a: { - (ref = config.ref), (maybeKey = ReactSharedInternals.owner); + (ref = config.ref), (maybeKey = getOwner()); if ("string" !== typeof ref) if ("number" === typeof ref || "boolean" === typeof ref) ref = "" + ref; else break a; @@ -62,13 +66,14 @@ function jsxProd(type, config, maybeKey) { void 0 === maybeKey[propName$0] && (maybeKey[propName$0] = config[propName$0]); } + propName$0 = getOwner(); return { $$typeof: REACT_LEGACY_ELEMENT_TYPE, type: type, key: key, ref: ref, props: maybeKey, - _owner: ReactSharedInternals.owner + _owner: propName$0 }; } function stringRefAsCallbackRef(stringRef, type, owner, value) { diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-profiling.js index 36af6a127d99d..f5c7cb7de3ae1 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<62661c1c6567dce2b9c9ba9b3170fc16>> + * @generated SignedSource<<33a22d7e025b0504577f8d6f9a29d73e>> */ "use strict"; @@ -34,6 +34,10 @@ function formatProdErrorMessage(code) { } var ReactSharedInternals = React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; +function getOwner() { + var dispatcher = ReactSharedInternals.A; + return null === dispatcher ? null : dispatcher.getOwner(); +} function jsxProd(type, config, maybeKey) { var key = null, ref = null; @@ -41,7 +45,7 @@ function jsxProd(type, config, maybeKey) { void 0 !== config.key && (key = "" + config.key); if (void 0 !== config.ref) a: { - (ref = config.ref), (maybeKey = ReactSharedInternals.owner); + (ref = config.ref), (maybeKey = getOwner()); if ("string" !== typeof ref) if ("number" === typeof ref || "boolean" === typeof ref) ref = "" + ref; else break a; @@ -62,13 +66,14 @@ function jsxProd(type, config, maybeKey) { void 0 === maybeKey[propName$0] && (maybeKey[propName$0] = config[propName$0]); } + propName$0 = getOwner(); return { $$typeof: REACT_LEGACY_ELEMENT_TYPE, type: type, key: key, ref: ref, props: maybeKey, - _owner: ReactSharedInternals.owner + _owner: propName$0 }; } function stringRefAsCallbackRef(stringRef, type, owner, value) { diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-dev.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-dev.js index 28fe3ae6988a7..e33c05932c703 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-dev.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-dev.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<<5657642071f954739542e489d20fe745>> + * @generated SignedSource<> */ 'use strict'; @@ -27,7 +27,7 @@ if ( } var dynamicFlagsUntyped = require('ReactNativeInternalFeatureFlags'); -var ReactVersion = '19.0.0-beta-bbf3fbcd'; +var ReactVersion = '19.0.0-beta-77a60a06'; // Re-export dynamic flags from the internal module. var dynamicFlags = dynamicFlagsUntyped; // We destructure each value before re-exporting to avoid a dynamic look-up on @@ -88,14 +88,10 @@ function getIteratorFn(maybeIterable) { var ReactSharedInternals = { H: null, - C: null, + A: null, T: null }; -{ - ReactSharedInternals.owner = null; -} - { ReactSharedInternals.actQueue = null; ReactSharedInternals.isBatchingLegacy = false; @@ -1217,6 +1213,19 @@ function getComponentNameFromFiber(fiber) { } var REACT_CLIENT_REFERENCE = Symbol.for('react.client.reference'); + +function getOwner() { + { + var dispatcher = ReactSharedInternals.A; + + if (dispatcher === null) { + return null; + } + + return dispatcher.getOwner(); + } +} + var specialPropKeyWarningShown; var specialPropRefWarningShown; var didWarnAboutStringRefs; @@ -1256,11 +1265,13 @@ function hasValidKey(config) { function warnIfStringRefCannotBeAutoConverted(config, self) { { - if (typeof config.ref === 'string' && ReactSharedInternals.owner && self && ReactSharedInternals.owner.stateNode !== self) { - var componentName = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner; + + if (typeof config.ref === 'string' && (owner = getOwner()) && self && owner.stateNode !== self) { + var componentName = getComponentNameFromType(owner.type); if (!didWarnAboutStringRefs[componentName]) { - error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(ReactSharedInternals.owner.type), config.ref); + error('Component "%s" contains the string ref "%s". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://react.dev/link/strict-mode-string-ref', getComponentNameFromType(owner.type), config.ref); didWarnAboutStringRefs[componentName] = true; } @@ -1517,7 +1528,7 @@ function jsxDEV$1(type, config, maybeKey, isStaticChildren, source, self) { ref = config.ref; { - ref = coerceStringRef(ref, ReactSharedInternals.owner, type); + ref = coerceStringRef(ref, getOwner(), type); } } @@ -1569,7 +1580,7 @@ function jsxDEV$1(type, config, maybeKey, isStaticChildren, source, self) { } } - var element = ReactElement(type, key, ref, self, source, ReactSharedInternals.owner, props); + var element = ReactElement(type, key, ref, self, source, getOwner(), props); if (type === REACT_FRAGMENT_TYPE) { validateFragmentProps(element); @@ -1649,7 +1660,7 @@ function createElement(type, config, children) { ref = config.ref; { - ref = coerceStringRef(ref, ReactSharedInternals.owner, type); + ref = coerceStringRef(ref, getOwner(), type); } } @@ -1728,7 +1739,7 @@ function createElement(type, config, children) { } } - var element = ReactElement(type, key, ref, undefined, undefined, ReactSharedInternals.owner, props); + var element = ReactElement(type, key, ref, undefined, undefined, getOwner(), props); if (type === REACT_FRAGMENT_TYPE) { validateFragmentProps(element); @@ -1762,7 +1773,7 @@ function cloneElement(element, config, children) { if (config != null) { if (hasValidRef(config)) { - owner = ReactSharedInternals.owner; + owner = getOwner() ; { // Silently steal the ref from the parent. @@ -1840,8 +1851,10 @@ function cloneElement(element, config, children) { function getDeclarationErrorAddendum() { { - if (ReactSharedInternals.owner) { - var name = getComponentNameFromType(ReactSharedInternals.owner.type); + var owner = getOwner(); + + if (owner) { + var name = getComponentNameFromType(owner.type); if (name) { return '\n\nCheck the render method of `' + name + '`.'; @@ -1948,7 +1961,7 @@ function validateExplicitKey(element, parentType) { var childOwner = ''; - if (element && element._owner != null && element._owner !== ReactSharedInternals.owner) { + if (element && element._owner != null && element._owner !== getOwner()) { var ownerName = null; if (typeof element._owner.tag === 'number') { @@ -2780,7 +2793,7 @@ function resolveDispatcher() { } function getCacheForType(resourceType) { - var dispatcher = ReactSharedInternals.C; + var dispatcher = ReactSharedInternals.A; if (!dispatcher) { // If there is no dispatcher, then we treat this as not being cached. diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-prod.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-prod.js index 78a9c8503d5e5..94efb3640ab1f 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-prod.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-prod.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<> */ "use strict"; @@ -86,8 +86,12 @@ pureComponentPrototype.constructor = PureComponent; assign(pureComponentPrototype, Component.prototype); pureComponentPrototype.isPureReactComponent = !0; var isArrayImpl = Array.isArray, - ReactSharedInternals = { H: null, C: null, T: null, owner: null }, + ReactSharedInternals = { H: null, A: null, T: null }, hasOwnProperty = Object.prototype.hasOwnProperty; +function getOwner() { + var dispatcher = ReactSharedInternals.A; + return null === dispatcher ? null : dispatcher.getOwner(); +} function ReactElement(type, key, _ref, self, source, owner, props) { return { $$typeof: REACT_LEGACY_ELEMENT_TYPE, @@ -104,8 +108,7 @@ function jsxProd(type, config, maybeKey) { void 0 !== maybeKey && (key = "" + maybeKey); void 0 !== config.key && (key = "" + config.key); void 0 !== config.ref && - ((ref = config.ref), - (ref = coerceStringRef(ref, ReactSharedInternals.owner, type))); + ((ref = config.ref), (ref = coerceStringRef(ref, getOwner(), type))); maybeKey = {}; for (var propName in config) "key" !== propName && @@ -117,15 +120,7 @@ function jsxProd(type, config, maybeKey) { void 0 === maybeKey[propName$0] && (maybeKey[propName$0] = config[propName$0]); } - return ReactElement( - type, - key, - ref, - void 0, - void 0, - ReactSharedInternals.owner, - maybeKey - ); + return ReactElement(type, key, ref, void 0, void 0, getOwner(), maybeKey); } function cloneAndReplaceKey(oldElement, newKey) { return ReactElement( @@ -451,7 +446,7 @@ exports.cloneElement = function (element, config, children) { owner = element._owner; if (null != config) { void 0 !== config.ref && - ((owner = ReactSharedInternals.owner), + ((owner = getOwner()), (ref = config.ref), (ref = coerceStringRef(ref, owner, element.type))); void 0 !== config.key && (key = "" + config.key); @@ -512,8 +507,7 @@ exports.createElement = function (type, config, children) { ref = null; if (null != config) for (propName in (void 0 !== config.ref && - ((ref = config.ref), - (ref = coerceStringRef(ref, ReactSharedInternals.owner, type))), + ((ref = config.ref), (ref = coerceStringRef(ref, getOwner(), type))), void 0 !== config.key && (key = "" + config.key), config)) hasOwnProperty.call(config, propName) && @@ -533,15 +527,7 @@ exports.createElement = function (type, config, children) { for (propName in ((childrenLength = type.defaultProps), childrenLength)) void 0 === props[propName] && (props[propName] = childrenLength[propName]); - return ReactElement( - type, - key, - ref, - void 0, - void 0, - ReactSharedInternals.owner, - props - ); + return ReactElement(type, key, ref, void 0, void 0, getOwner(), props); }; exports.createRef = function () { return { current: null }; @@ -604,7 +590,7 @@ exports.unstable_Scope = REACT_SCOPE_TYPE; exports.unstable_SuspenseList = REACT_SUSPENSE_LIST_TYPE; exports.unstable_TracingMarker = REACT_TRACING_MARKER_TYPE; exports.unstable_getCacheForType = function (resourceType) { - var dispatcher = ReactSharedInternals.C; + var dispatcher = ReactSharedInternals.A; return dispatcher ? dispatcher.getCacheForType(resourceType) : resourceType(); }; exports.unstable_useCacheRefresh = function () { @@ -679,4 +665,4 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactSharedInternals.H.useTransition(); }; -exports.version = "19.0.0-beta-55ecd63c"; +exports.version = "19.0.0-beta-f9776c99"; diff --git a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-profiling.js b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-profiling.js index 9565545c85d3b..7533fdda13ede 100644 --- a/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-profiling.js +++ b/compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-profiling.js @@ -7,7 +7,7 @@ * @noflow * @nolint * @preventMunge - * @generated SignedSource<> + * @generated SignedSource<<32d5e348978f815554e5015b9471046b>> */ "use strict"; @@ -90,8 +90,12 @@ pureComponentPrototype.constructor = PureComponent; assign(pureComponentPrototype, Component.prototype); pureComponentPrototype.isPureReactComponent = !0; var isArrayImpl = Array.isArray, - ReactSharedInternals = { H: null, C: null, T: null, owner: null }, + ReactSharedInternals = { H: null, A: null, T: null }, hasOwnProperty = Object.prototype.hasOwnProperty; +function getOwner() { + var dispatcher = ReactSharedInternals.A; + return null === dispatcher ? null : dispatcher.getOwner(); +} function ReactElement(type, key, _ref, self, source, owner, props) { return { $$typeof: REACT_LEGACY_ELEMENT_TYPE, @@ -108,8 +112,7 @@ function jsxProd(type, config, maybeKey) { void 0 !== maybeKey && (key = "" + maybeKey); void 0 !== config.key && (key = "" + config.key); void 0 !== config.ref && - ((ref = config.ref), - (ref = coerceStringRef(ref, ReactSharedInternals.owner, type))); + ((ref = config.ref), (ref = coerceStringRef(ref, getOwner(), type))); maybeKey = {}; for (var propName in config) "key" !== propName && @@ -121,15 +124,7 @@ function jsxProd(type, config, maybeKey) { void 0 === maybeKey[propName$0] && (maybeKey[propName$0] = config[propName$0]); } - return ReactElement( - type, - key, - ref, - void 0, - void 0, - ReactSharedInternals.owner, - maybeKey - ); + return ReactElement(type, key, ref, void 0, void 0, getOwner(), maybeKey); } function cloneAndReplaceKey(oldElement, newKey) { return ReactElement( @@ -455,7 +450,7 @@ exports.cloneElement = function (element, config, children) { owner = element._owner; if (null != config) { void 0 !== config.ref && - ((owner = ReactSharedInternals.owner), + ((owner = getOwner()), (ref = config.ref), (ref = coerceStringRef(ref, owner, element.type))); void 0 !== config.key && (key = "" + config.key); @@ -516,8 +511,7 @@ exports.createElement = function (type, config, children) { ref = null; if (null != config) for (propName in (void 0 !== config.ref && - ((ref = config.ref), - (ref = coerceStringRef(ref, ReactSharedInternals.owner, type))), + ((ref = config.ref), (ref = coerceStringRef(ref, getOwner(), type))), void 0 !== config.key && (key = "" + config.key), config)) hasOwnProperty.call(config, propName) && @@ -537,15 +531,7 @@ exports.createElement = function (type, config, children) { for (propName in ((childrenLength = type.defaultProps), childrenLength)) void 0 === props[propName] && (props[propName] = childrenLength[propName]); - return ReactElement( - type, - key, - ref, - void 0, - void 0, - ReactSharedInternals.owner, - props - ); + return ReactElement(type, key, ref, void 0, void 0, getOwner(), props); }; exports.createRef = function () { return { current: null }; @@ -608,7 +594,7 @@ exports.unstable_Scope = REACT_SCOPE_TYPE; exports.unstable_SuspenseList = REACT_SUSPENSE_LIST_TYPE; exports.unstable_TracingMarker = REACT_TRACING_MARKER_TYPE; exports.unstable_getCacheForType = function (resourceType) { - var dispatcher = ReactSharedInternals.C; + var dispatcher = ReactSharedInternals.A; return dispatcher ? dispatcher.getCacheForType(resourceType) : resourceType(); }; exports.unstable_useCacheRefresh = function () { @@ -683,7 +669,7 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactSharedInternals.H.useTransition(); }; -exports.version = "19.0.0-beta-966142ac"; +exports.version = "19.0.0-beta-0c71ce9a"; "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 afe92bfebf54c..e1be9607575bf 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 @@ -f8a8eac86bac406724f327325f804e65e594dd68 +94eed63c49d989861ae7cd62e111de6d717f0a10 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 16803383f38cf..c57c822898aaa 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<<2b452522ba377c277e98a65fb11b3ba0>> + * @generated SignedSource<<3b1926ec8be22ff21a461aebe15a8dec>> */ 'use strict'; @@ -4746,6 +4746,11 @@ function getComponentNameFromFiber(fiber) { return null; } +var currentOwner = null; +function setCurrentOwner(fiber) { + currentOwner = fiber; +} + function getNearestMountedFiber(fiber) { var node = fiber; var nearestMounted = fiber; @@ -4789,7 +4794,7 @@ function isFiberMounted(fiber) { } function isMounted(component) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.tag === ClassComponent) { var ownerFiber = owner; @@ -14946,7 +14951,7 @@ function updateForwardRef(current, workInProgress, Component, nextProps, renderL } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, render, propsWithoutRef, ref, renderLanes); setIsRendering(false); @@ -15429,7 +15434,7 @@ function updateFunctionComponent(current, workInProgress, Component, nextProps, } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, Component, nextProps, context, renderLanes); setIsRendering(false); @@ -15581,7 +15586,7 @@ function finishClassComponent(current, workInProgress, Component, shouldUpdate, var instance = workInProgress.stateNode; // Rerender { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); } var nextChildren; @@ -16915,7 +16920,7 @@ function updateContextConsumer(current, workInProgress, renderLanes) { var newChildren; { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); newChildren = render(newValue); setIsRendering(false); @@ -22085,10 +22090,16 @@ function getCacheForType(resourceType) { return cacheForType; } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: getCacheForType }; +{ + DefaultAsyncDispatcher.getOwner = function () { + return currentOwner; + }; +} + if (typeof Symbol === 'function' && Symbol.for) { var symbolFor = Symbol.for; symbolFor('selector.component'); @@ -23038,7 +23049,7 @@ function handleThrow(root, thrownValue) { resetCurrentFiber(); { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } if (thrownValue === SuspenseException) { @@ -23194,17 +23205,17 @@ function popDispatcher(prevDispatcher) { ReactSharedInternals.H = prevDispatcher; } -function pushCacheDispatcher() { +function pushAsyncDispatcher() { { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } } -function popCacheDispatcher(prevCacheDispatcher) { +function popAsyncDispatcher(prevAsyncDispatcher) { { - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; } } @@ -23262,7 +23273,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -23358,7 +23369,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); if (workInProgress !== null) { // This is a sync render, so we should have finished the whole tree. @@ -23391,7 +23402,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -23620,7 +23631,7 @@ function renderRootConcurrent(root, lanes) { resetContextDependencies(); popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); executionContext = prevExecutionContext; @@ -23684,7 +23695,7 @@ function performUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -23784,7 +23795,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -24114,7 +24125,7 @@ function commitRootImpl(root, recoverableErrors, transitions, didIncludeRenderPh executionContext |= CommitContext; // Reset this to null before calling lifecycles { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } // The commit phase is broken into several sub-phases. We do a separate pass // of the effect list for each phase: all mutation effects come before all // layout effects, and so on. @@ -26064,7 +26075,7 @@ identifierPrefix, onUncaughtError, onCaughtError, onRecoverableError, transition return root; } -var ReactVersion = '19.0.0-beta-86571a2a'; +var ReactVersion = '19.0.0-beta-197956b7'; /* * The `'' + value` pattern (used in perf-sensitive code) throws for Symbol @@ -26620,7 +26631,7 @@ function getInstanceFromTag(tag) { function findHostInstance_DEPRECATED(componentOrHandle) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.stateNode !== null) { if (!owner.stateNode._warnedAboutRefsInRender) { @@ -26661,7 +26672,7 @@ function findHostInstance_DEPRECATED(componentOrHandle) { } function findNodeHandle(componentOrHandle) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.stateNode !== null) { if (!owner.stateNode._warnedAboutRefsInRender) { 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 762eeca387d33..c3d76d4f2ee59 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<<06016018fb347358b18b57d695069089>> + * @generated SignedSource<> */ "use strict"; @@ -1799,6 +1799,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -5821,7 +5822,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; var nextChildren = didCaptureError && "function" !== typeof Component.getDerivedStateFromError ? null @@ -8964,7 +8965,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -8972,6 +8973,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -9395,7 +9399,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -9437,10 +9441,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -9457,7 +9461,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; @@ -9492,7 +9496,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -9509,7 +9513,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), @@ -9599,7 +9603,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return 0; workInProgressRoot = null; @@ -9615,7 +9619,7 @@ function performUnitOfWork(unitOfWork) { var next = beginWork(unitOfWork.alternate, unitOfWork, entangledRenderLanes); unitOfWork.memoizedProps = unitOfWork.pendingProps; null === next ? completeUnitOfWork(unitOfWork) : (workInProgress = next); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate; @@ -9671,7 +9675,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -9826,7 +9830,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitMutationEffectsOnFiber(finishedWork, root); root.current = finishedWork; @@ -10606,10 +10610,10 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - devToolsConfig$jscomp$inline_1108 = { + devToolsConfig$jscomp$inline_1118 = { findFiberByHostInstance: getInstanceFromNode, bundleType: 0, - version: "19.0.0-beta-b5226534", + version: "19.0.0-beta-9a489885", rendererPackageName: "react-native-renderer", rendererConfig: { getInspectorDataForInstance: getInspectorDataForInstance, @@ -10625,11 +10629,11 @@ var roots = new Map(), }.bind(null, findNodeHandle) } }; -var internals$jscomp$inline_1375 = { - bundleType: devToolsConfig$jscomp$inline_1108.bundleType, - version: devToolsConfig$jscomp$inline_1108.version, - rendererPackageName: devToolsConfig$jscomp$inline_1108.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1108.rendererConfig, +var internals$jscomp$inline_1385 = { + bundleType: devToolsConfig$jscomp$inline_1118.bundleType, + version: devToolsConfig$jscomp$inline_1118.version, + rendererPackageName: devToolsConfig$jscomp$inline_1118.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1118.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -10645,26 +10649,26 @@ var internals$jscomp$inline_1375 = { return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1108.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1118.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-b5226534" + reconcilerVersion: "19.0.0-beta-9a489885" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1376 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1386 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1376.isDisabled && - hook$jscomp$inline_1376.supportsFiber + !hook$jscomp$inline_1386.isDisabled && + hook$jscomp$inline_1386.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1376.inject( - internals$jscomp$inline_1375 + (rendererID = hook$jscomp$inline_1386.inject( + internals$jscomp$inline_1385 )), - (injectedHook = hook$jscomp$inline_1376); + (injectedHook = hook$jscomp$inline_1386); } 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 e2c1ee63e4aa0..b3416886fcf42 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<<0348b9e6ebecc00eaa767ca2f98fb9d8>> + * @generated SignedSource<<0cb20923f97d85199b33fe4f36251a51>> */ "use strict"; @@ -1921,6 +1921,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -6020,7 +6021,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; if ( didCaptureError && "function" !== typeof Component.getDerivedStateFromError @@ -9491,7 +9492,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -9499,6 +9500,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -9927,7 +9931,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -9998,10 +10002,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -10018,7 +10022,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { if (isDevToolsPresent) { var memoizedUpdaters = root.memoizedUpdaters; @@ -10063,7 +10067,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -10081,7 +10085,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { if (isDevToolsPresent) { var memoizedUpdaters = root.memoizedUpdaters; @@ -10181,7 +10185,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return ( @@ -10211,7 +10215,7 @@ function performUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate, @@ -10270,7 +10274,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -10437,7 +10441,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitTime = now(); commitMutationEffects(root, finishedWork, lanes); @@ -11311,10 +11315,10 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - devToolsConfig$jscomp$inline_1188 = { + devToolsConfig$jscomp$inline_1198 = { findFiberByHostInstance: getInstanceFromNode, bundleType: 0, - version: "19.0.0-beta-7c054062", + version: "19.0.0-beta-781ecc88", rendererPackageName: "react-native-renderer", rendererConfig: { getInspectorDataForInstance: getInspectorDataForInstance, @@ -11344,10 +11348,10 @@ var roots = new Map(), } catch (err) {} return hook.checkDCE ? !0 : !1; })({ - bundleType: devToolsConfig$jscomp$inline_1188.bundleType, - version: devToolsConfig$jscomp$inline_1188.version, - rendererPackageName: devToolsConfig$jscomp$inline_1188.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1188.rendererConfig, + bundleType: devToolsConfig$jscomp$inline_1198.bundleType, + version: devToolsConfig$jscomp$inline_1198.version, + rendererPackageName: devToolsConfig$jscomp$inline_1198.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1198.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -11363,14 +11367,14 @@ var roots = new Map(), return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1188.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1198.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-7c054062" + reconcilerVersion: "19.0.0-beta-781ecc88" }); exports.createPortal = function (children, containerTag) { return createPortal$1( 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 7f6abeddda6ef..13023703e2c96 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<> + * @generated SignedSource<> */ 'use strict'; @@ -2768,6 +2768,11 @@ var PassiveMask = Passive$1 | Visibility | ChildDeletion; // Union of tags that var StaticMask = LayoutStatic | PassiveStatic | RefStatic | MaySuspendCommit; +var currentOwner = null; +function setCurrentOwner(fiber) { + currentOwner = fiber; +} + function getNearestMountedFiber(fiber) { var node = fiber; var nearestMounted = fiber; @@ -2811,7 +2816,7 @@ function isFiberMounted(fiber) { } function isMounted(component) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.tag === ClassComponent) { var ownerFiber = owner; @@ -15185,7 +15190,7 @@ function updateForwardRef(current, workInProgress, Component, nextProps, renderL } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, render, propsWithoutRef, ref, renderLanes); setIsRendering(false); @@ -15668,7 +15673,7 @@ function updateFunctionComponent(current, workInProgress, Component, nextProps, } { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); nextChildren = renderWithHooks(current, workInProgress, Component, nextProps, context, renderLanes); setIsRendering(false); @@ -15820,7 +15825,7 @@ function finishClassComponent(current, workInProgress, Component, shouldUpdate, var instance = workInProgress.stateNode; // Rerender { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); } var nextChildren; @@ -17154,7 +17159,7 @@ function updateContextConsumer(current, workInProgress, renderLanes) { var newChildren; { - ReactSharedInternals.owner = workInProgress; + setCurrentOwner(workInProgress); setIsRendering(true); newChildren = render(newValue); setIsRendering(false); @@ -22495,10 +22500,16 @@ function getCacheForType(resourceType) { return cacheForType; } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: getCacheForType }; +{ + DefaultAsyncDispatcher.getOwner = function () { + return currentOwner; + }; +} + if (typeof Symbol === 'function' && Symbol.for) { var symbolFor = Symbol.for; symbolFor('selector.component'); @@ -23450,7 +23461,7 @@ function handleThrow(root, thrownValue) { resetCurrentFiber(); { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } if (thrownValue === SuspenseException) { @@ -23606,17 +23617,17 @@ function popDispatcher(prevDispatcher) { ReactSharedInternals.H = prevDispatcher; } -function pushCacheDispatcher() { +function pushAsyncDispatcher() { { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } } -function popCacheDispatcher(prevCacheDispatcher) { +function popAsyncDispatcher(prevAsyncDispatcher) { { - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; } } @@ -23674,7 +23685,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -23770,7 +23781,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); if (workInProgress !== null) { // This is a sync render, so we should have finished the whole tree. @@ -23803,7 +23814,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= RenderContext; var prevDispatcher = pushDispatcher(); - var prevCacheDispatcher = pushCacheDispatcher(); // If the root or lanes have changed, throw out the existing stack + var prevAsyncDispatcher = pushAsyncDispatcher(); // If the root or lanes have changed, throw out the existing stack // and prepare a fresh one. Otherwise we'll continue where we left off. if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { @@ -24032,7 +24043,7 @@ function renderRootConcurrent(root, lanes) { resetContextDependencies(); popDispatcher(prevDispatcher); - popCacheDispatcher(prevCacheDispatcher); + popAsyncDispatcher(prevAsyncDispatcher); executionContext = prevExecutionContext; @@ -24096,7 +24107,7 @@ function performUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -24196,7 +24207,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { } { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } } @@ -24526,7 +24537,7 @@ function commitRootImpl(root, recoverableErrors, transitions, didIncludeRenderPh executionContext |= CommitContext; // Reset this to null before calling lifecycles { - ReactSharedInternals.owner = null; + setCurrentOwner(null); } // The commit phase is broken into several sub-phases. We do a separate pass // of the effect list for each phase: all mutation effects come before all // layout effects, and so on. @@ -26476,7 +26487,7 @@ identifierPrefix, onUncaughtError, onCaughtError, onRecoverableError, transition return root; } -var ReactVersion = '19.0.0-beta-a5fea518'; +var ReactVersion = '19.0.0-beta-0126d00e'; /* * The `'' + value` pattern (used in perf-sensitive code) throws for Symbol @@ -27026,7 +27037,7 @@ function injectIntoDevTools(devToolsConfig) { function findHostInstance_DEPRECATED(componentOrHandle) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.stateNode !== null) { if (!owner.stateNode._warnedAboutRefsInRender) { @@ -27067,7 +27078,7 @@ function findHostInstance_DEPRECATED(componentOrHandle) { } function findNodeHandle(componentOrHandle) { { - var owner = ReactSharedInternals.owner; + var owner = currentOwner; if (owner !== null && owner.stateNode !== null) { if (!owner.stateNode._warnedAboutRefsInRender) { 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 a77053f9e74c8..2b10d57430365 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<<6224a7e892eb62fd99b5ad51269d20b3>> + * @generated SignedSource<<29b6d6559ba3d8f7ff9f1592b99ed8f4>> */ "use strict"; @@ -1110,9 +1110,7 @@ ResponderEventPlugin.injection.injectGlobalResponderHandler({ : ReactNativePrivateInterface.UIManager.clearJSResponder(); } }); -var ReactSharedInternals = - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, - alwaysThrottleRetries = dynamicFlagsUntyped.alwaysThrottleRetries, +var alwaysThrottleRetries = dynamicFlagsUntyped.alwaysThrottleRetries, consoleManagedByDevToolsDuringStrictMode = dynamicFlagsUntyped.consoleManagedByDevToolsDuringStrictMode, enableAsyncActions = dynamicFlagsUntyped.enableAsyncActions, @@ -1275,6 +1273,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -1383,7 +1382,9 @@ function findCurrentHostFiberImpl(node) { } return null; } -var emptyObject$1 = {}, +var ReactSharedInternals = + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, + emptyObject$1 = {}, removedKeys = null, removedKeyCount = 0, deepDifferOptions = { unsafelyIgnoreFunctions: !0 }; @@ -5874,7 +5875,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; var nextChildren = didCaptureError && "function" !== typeof Component.getDerivedStateFromError ? null @@ -9176,7 +9177,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -9184,6 +9185,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -9609,7 +9613,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -9651,10 +9655,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -9671,7 +9675,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), prepareFreshStack(root, lanes); lanes = !1; @@ -9706,7 +9710,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -9723,7 +9727,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) (workInProgressTransitions = null), (workInProgressRootRenderTargetTime = now() + 500), @@ -9813,7 +9817,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return 0; workInProgressRoot = null; @@ -9829,7 +9833,7 @@ function performUnitOfWork(unitOfWork) { var next = beginWork(unitOfWork.alternate, unitOfWork, entangledRenderLanes); unitOfWork.memoizedProps = unitOfWork.pendingProps; null === next ? completeUnitOfWork(unitOfWork) : (workInProgress = next); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate; @@ -9885,7 +9889,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -10040,7 +10044,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitMutationEffectsOnFiber(finishedWork, root); root.current = finishedWork; @@ -10827,10 +10831,10 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - devToolsConfig$jscomp$inline_1176 = { + devToolsConfig$jscomp$inline_1186 = { findFiberByHostInstance: getInstanceFromTag, bundleType: 0, - version: "19.0.0-beta-7e594775", + version: "19.0.0-beta-8879f21c", rendererPackageName: "react-native-renderer", rendererConfig: { getInspectorDataForInstance: getInspectorDataForInstance, @@ -10846,11 +10850,11 @@ var roots = new Map(), }.bind(null, findNodeHandle) } }; -var internals$jscomp$inline_1460 = { - bundleType: devToolsConfig$jscomp$inline_1176.bundleType, - version: devToolsConfig$jscomp$inline_1176.version, - rendererPackageName: devToolsConfig$jscomp$inline_1176.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1176.rendererConfig, +var internals$jscomp$inline_1470 = { + bundleType: devToolsConfig$jscomp$inline_1186.bundleType, + version: devToolsConfig$jscomp$inline_1186.version, + rendererPackageName: devToolsConfig$jscomp$inline_1186.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1186.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -10866,26 +10870,26 @@ var internals$jscomp$inline_1460 = { return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1176.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1186.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-7e594775" + reconcilerVersion: "19.0.0-beta-8879f21c" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { - var hook$jscomp$inline_1461 = __REACT_DEVTOOLS_GLOBAL_HOOK__; + var hook$jscomp$inline_1471 = __REACT_DEVTOOLS_GLOBAL_HOOK__; if ( - !hook$jscomp$inline_1461.isDisabled && - hook$jscomp$inline_1461.supportsFiber + !hook$jscomp$inline_1471.isDisabled && + hook$jscomp$inline_1471.supportsFiber ) try { - (rendererID = hook$jscomp$inline_1461.inject( - internals$jscomp$inline_1460 + (rendererID = hook$jscomp$inline_1471.inject( + internals$jscomp$inline_1470 )), - (injectedHook = hook$jscomp$inline_1461); + (injectedHook = hook$jscomp$inline_1471); } catch (err) {} } exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = { 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 b0f8579c5ba11..1f6ebcb2901ab 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<> + * @generated SignedSource<<06820f12c0e85d0af8fe960e3776ec34>> */ "use strict"; @@ -1114,9 +1114,7 @@ ResponderEventPlugin.injection.injectGlobalResponderHandler({ : ReactNativePrivateInterface.UIManager.clearJSResponder(); } }); -var ReactSharedInternals = - React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, - alwaysThrottleRetries = dynamicFlagsUntyped.alwaysThrottleRetries, +var alwaysThrottleRetries = dynamicFlagsUntyped.alwaysThrottleRetries, consoleManagedByDevToolsDuringStrictMode = dynamicFlagsUntyped.consoleManagedByDevToolsDuringStrictMode, enableAsyncActions = dynamicFlagsUntyped.enableAsyncActions, @@ -1279,6 +1277,7 @@ function getComponentNameFromFiber(fiber) { } return null; } +var currentOwner = null; function getNearestMountedFiber(fiber) { var node = fiber, nearestMounted = fiber; @@ -1387,7 +1386,9 @@ function findCurrentHostFiberImpl(node) { } return null; } -var emptyObject$1 = {}, +var ReactSharedInternals = + React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, + emptyObject$1 = {}, removedKeys = null, removedKeyCount = 0, deepDifferOptions = { unsafelyIgnoreFunctions: !0 }; @@ -6073,7 +6074,7 @@ function finishClassComponent( bailoutOnAlreadyFinishedWork(current, workInProgress, renderLanes) ); shouldUpdate = workInProgress.stateNode; - ReactSharedInternals.owner = workInProgress; + currentOwner = workInProgress; if ( didCaptureError && "function" !== typeof Component.getDerivedStateFromError @@ -9704,7 +9705,7 @@ function commitPassiveUnmountEffectsInsideOfDeletedTree_begin( } } } -var DefaultCacheDispatcher = { +var DefaultAsyncDispatcher = { getCacheForType: function (resourceType) { var cache = readContext(CacheContext), cacheForType = cache.data.get(resourceType); @@ -9712,6 +9713,9 @@ var DefaultCacheDispatcher = { ((cacheForType = resourceType()), cache.data.set(resourceType, cacheForType)); return cacheForType; + }, + getOwner: function () { + return currentOwner; } }, PossiblyWeakMap = "function" === typeof WeakMap ? WeakMap : Map, @@ -10142,7 +10146,7 @@ function prepareFreshStack(root, lanes) { function handleThrow(root, thrownValue) { currentlyRenderingFiber$1 = null; ReactSharedInternals.H = ContextOnlyDispatcher; - ReactSharedInternals.owner = null; + currentOwner = null; if (thrownValue === SuspenseException) { thrownValue = getSuspendedThenable(); var handler = suspenseHandlerStackCursor.current; @@ -10213,10 +10217,10 @@ function pushDispatcher() { ReactSharedInternals.H = ContextOnlyDispatcher; return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher; } -function pushCacheDispatcher() { - var prevCacheDispatcher = ReactSharedInternals.C; - ReactSharedInternals.C = DefaultCacheDispatcher; - return prevCacheDispatcher; +function pushAsyncDispatcher() { + var prevAsyncDispatcher = ReactSharedInternals.A; + ReactSharedInternals.A = DefaultAsyncDispatcher; + return prevAsyncDispatcher; } function renderDidSuspendDelayIfPossible() { workInProgressRootExitStatus = 4; @@ -10233,7 +10237,7 @@ function renderRootSync(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { if (isDevToolsPresent) { var memoizedUpdaters = root.memoizedUpdaters; @@ -10278,7 +10282,7 @@ function renderRootSync(root, lanes) { resetContextDependencies(); executionContext = prevExecutionContext; ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + 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." @@ -10296,7 +10300,7 @@ function renderRootConcurrent(root, lanes) { var prevExecutionContext = executionContext; executionContext |= 2; var prevDispatcher = pushDispatcher(), - prevCacheDispatcher = pushCacheDispatcher(); + prevAsyncDispatcher = pushAsyncDispatcher(); if (workInProgressRoot !== root || workInProgressRootRenderLanes !== lanes) { if (isDevToolsPresent) { var memoizedUpdaters = root.memoizedUpdaters; @@ -10396,7 +10400,7 @@ function renderRootConcurrent(root, lanes) { while (1); resetContextDependencies(); ReactSharedInternals.H = prevDispatcher; - ReactSharedInternals.C = prevCacheDispatcher; + ReactSharedInternals.A = prevAsyncDispatcher; executionContext = prevExecutionContext; if (null !== workInProgress) return ( @@ -10426,7 +10430,7 @@ function performUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function replaySuspendedUnitOfWork(unitOfWork) { var current = unitOfWork.alternate, @@ -10485,7 +10489,7 @@ function replaySuspendedUnitOfWork(unitOfWork) { null === current ? completeUnitOfWork(unitOfWork) : (workInProgress = current); - ReactSharedInternals.owner = null; + currentOwner = null; } function throwAndUnwindWorkLoop(root, unitOfWork, thrownValue) { resetContextDependencies(); @@ -10652,7 +10656,7 @@ function commitRootImpl( currentUpdatePriority = 2; var prevExecutionContext = executionContext; executionContext |= 4; - ReactSharedInternals.owner = null; + currentOwner = null; commitBeforeMutationEffects(root, finishedWork); commitTime = now(); commitMutationEffects(root, finishedWork, lanes); @@ -11533,10 +11537,10 @@ batchedUpdatesImpl = function (fn, a) { } }; var roots = new Map(), - devToolsConfig$jscomp$inline_1256 = { + devToolsConfig$jscomp$inline_1266 = { findFiberByHostInstance: getInstanceFromTag, bundleType: 0, - version: "19.0.0-beta-8d977274", + version: "19.0.0-beta-2ba13034", rendererPackageName: "react-native-renderer", rendererConfig: { getInspectorDataForInstance: getInspectorDataForInstance, @@ -11566,10 +11570,10 @@ var roots = new Map(), } catch (err) {} return hook.checkDCE ? !0 : !1; })({ - bundleType: devToolsConfig$jscomp$inline_1256.bundleType, - version: devToolsConfig$jscomp$inline_1256.version, - rendererPackageName: devToolsConfig$jscomp$inline_1256.rendererPackageName, - rendererConfig: devToolsConfig$jscomp$inline_1256.rendererConfig, + bundleType: devToolsConfig$jscomp$inline_1266.bundleType, + version: devToolsConfig$jscomp$inline_1266.version, + rendererPackageName: devToolsConfig$jscomp$inline_1266.rendererPackageName, + rendererConfig: devToolsConfig$jscomp$inline_1266.rendererConfig, overrideHookState: null, overrideHookStateDeletePath: null, overrideHookStateRenamePath: null, @@ -11585,14 +11589,14 @@ var roots = new Map(), return null === fiber ? null : fiber.stateNode; }, findFiberByHostInstance: - devToolsConfig$jscomp$inline_1256.findFiberByHostInstance || + devToolsConfig$jscomp$inline_1266.findFiberByHostInstance || emptyFindFiberByHostInstance, findHostInstancesForRefresh: null, scheduleRefresh: null, scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "19.0.0-beta-8d977274" + reconcilerVersion: "19.0.0-beta-2ba13034" }); exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = { computeComponentStackForErrorReporting: function (reactTag) {