Delete unused eventTimes Fiber field (#26599)

DiffTrain build for [58742c21b8](https://github.com/facebook/react/commit/58742c21b8c3237e8b66c7df4e200504846a01ae)
This commit is contained in:
acdlite
2023-04-11 12:28:04 +00:00
parent be590ddd8f
commit e2c8a46604
18 changed files with 804 additions and 1468 deletions
+1 -1
View File
@@ -1 +1 @@
0b931f90e8964183f08ac328e7350d847abb08f9
58742c21b8c3237e8b66c7df4e200504846a01ae
+1 -1
View File
@@ -27,7 +27,7 @@ if (
}
"use strict";
var ReactVersion = "18.3.0-www-modern-d66c88c7";
var ReactVersion = "18.3.0-www-modern-c910362f";
// ATTENTION
// When adding new symbols to this file,
+29 -75
View File
@@ -69,7 +69,7 @@ function _assertThisInitialized(self) {
return self;
}
var ReactVersion = "18.3.0-www-classic-ab122236";
var ReactVersion = "18.3.0-www-classic-e55ff31a";
var LegacyRoot = 0;
var ConcurrentRoot = 1;
@@ -2161,7 +2161,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -2179,12 +2179,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -2217,7 +2211,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -2227,7 +2220,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -8790,7 +8782,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -9437,8 +9429,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -9492,8 +9483,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -9576,8 +9566,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -11064,8 +11053,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -11100,8 +11088,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -11136,8 +11123,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15081,16 +15067,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -20976,7 +20955,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -20997,7 +20976,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -23744,11 +23723,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -23760,20 +23735,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -23857,7 +23818,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -23883,7 +23844,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -23995,10 +23956,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -26246,10 +26205,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -26285,10 +26243,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -26414,11 +26371,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -27154,7 +27110,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -28048,7 +28004,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -28286,8 +28241,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -28435,7 +28389,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -28456,7 +28410,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -28477,7 +28431,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -28492,7 +28446,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28506,7 +28460,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28520,7 +28474,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28528,7 +28482,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
+29 -75
View File
@@ -69,7 +69,7 @@ function _assertThisInitialized(self) {
return self;
}
var ReactVersion = "18.3.0-www-modern-22d10e56";
var ReactVersion = "18.3.0-www-modern-f295753b";
var LegacyRoot = 0;
var ConcurrentRoot = 1;
@@ -2158,7 +2158,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -2176,12 +2176,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -2214,7 +2208,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -2224,7 +2217,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -8546,7 +8538,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -9193,8 +9185,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -9248,8 +9239,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -9332,8 +9322,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -10818,8 +10807,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -10854,8 +10842,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -10890,8 +10877,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -14781,16 +14767,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -20641,7 +20620,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -20662,7 +20641,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -23409,11 +23388,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -23425,20 +23400,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -23522,7 +23483,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -23548,7 +23509,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -23660,10 +23621,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -25906,10 +25865,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -25945,10 +25903,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -26074,11 +26031,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -26814,7 +26770,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -27708,7 +27664,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -27946,8 +27901,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -28095,7 +28049,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -28116,7 +28070,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -28137,7 +28091,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -28152,7 +28106,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28166,7 +28120,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28180,7 +28134,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -28188,7 +28142,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
+43 -71
View File
@@ -554,13 +554,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -572,13 +569,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$4 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$4;
remainingLanes[index$4] = 0;
eventTimes[index$4] = -1;
expirationTimes[index$4] = -1;
var hiddenUpdatesForLane = root[index$4];
if (null !== hiddenUpdatesForLane)
@@ -2728,7 +2723,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -2913,11 +2908,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root = enqueueUpdate(provider, fiber, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
entangleTransitions(root, provider, lane);
}
null !== root &&
(scheduleUpdateOnFiber(root, provider, lane),
entangleTransitions(root, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -2938,16 +2931,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -2982,8 +2972,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -3275,8 +3264,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -3288,8 +3276,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -3300,8 +3287,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -4528,7 +4514,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = didSuspend),
enqueueConcurrentRenderForLane(current, didSuspend),
scheduleUpdateOnFiber(nextProps, current, didSuspend, -1),
scheduleUpdateOnFiber(nextProps, current, didSuspend),
SelectiveHydrationException)
);
}
@@ -6554,7 +6540,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -6564,7 +6550,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -7959,15 +7945,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -7981,29 +7959,30 @@ function requestUpdateLane(fiber) {
fiber = currentUpdatePriority;
return 0 !== fiber ? fiber : 32;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$6] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$6] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -8019,7 +7998,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -8974,10 +8952,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -9011,9 +8987,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -9055,10 +9030,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -9828,7 +9802,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -9909,8 +9882,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(current, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, current, lane, callback),
(scheduleUpdateOnFiber(element, current, lane),
entangleTransitions(element, current, lane));
return lane;
}
@@ -10038,7 +10010,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "18.3.0-www-classic-390b1cd2",
version: "18.3.0-www-classic-4f277ac7",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1329 = {
@@ -10069,7 +10041,7 @@ var internals$jscomp$inline_1329 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-390b1cd2"
reconcilerVersion: "18.3.0-www-classic-4f277ac7"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1330 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
+43 -71
View File
@@ -438,13 +438,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -456,13 +453,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$4 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$4;
remainingLanes[index$4] = 0;
eventTimes[index$4] = -1;
expirationTimes[index$4] = -1;
var hiddenUpdatesForLane = root[index$4];
if (null !== hiddenUpdatesForLane)
@@ -2534,7 +2529,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -2719,11 +2714,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root = enqueueUpdate(provider, fiber, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
entangleTransitions(root, provider, lane);
}
null !== root &&
(scheduleUpdateOnFiber(root, provider, lane),
entangleTransitions(root, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -2744,16 +2737,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -2788,8 +2778,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -3081,8 +3070,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -3094,8 +3082,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -3106,8 +3093,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -4287,7 +4273,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = didSuspend),
enqueueConcurrentRenderForLane(current, didSuspend),
scheduleUpdateOnFiber(nextProps, current, didSuspend, -1),
scheduleUpdateOnFiber(nextProps, current, didSuspend),
SelectiveHydrationException)
);
}
@@ -6290,7 +6276,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -6300,7 +6286,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -7695,15 +7681,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -7717,29 +7695,30 @@ function requestUpdateLane(fiber) {
fiber = currentUpdatePriority;
return 0 !== fiber ? fiber : 32;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$6] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$6] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -7755,7 +7734,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -8706,10 +8684,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -8743,9 +8719,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -8787,10 +8762,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -9533,7 +9507,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -9574,8 +9547,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(parentComponent, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, parentComponent, lane, callback),
(scheduleUpdateOnFiber(element, parentComponent, lane),
entangleTransitions(element, parentComponent, lane));
return lane;
}
@@ -9703,7 +9675,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "18.3.0-www-modern-8ad04cf7",
version: "18.3.0-www-modern-6d893aea",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1309 = {
@@ -9734,7 +9706,7 @@ var internals$jscomp$inline_1309 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-8ad04cf7"
reconcilerVersion: "18.3.0-www-modern-6d893aea"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1310 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
+35 -85
View File
@@ -2330,7 +2330,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -2348,12 +2348,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -2386,7 +2380,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -2396,7 +2389,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -13343,7 +13335,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -14004,8 +13996,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -14059,8 +14050,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -14143,8 +14133,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -15631,8 +15620,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15667,8 +15655,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15703,8 +15690,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -19952,16 +19938,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -26291,7 +26270,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -26312,7 +26291,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -29265,11 +29244,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -29281,20 +29256,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -29378,7 +29339,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -29404,7 +29365,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -29506,7 +29467,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
}
function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
function scheduleInitialHydrationOnRoot(root, lane) {
// This is a special fork of scheduleUpdateOnFiber that is only used to
// schedule the initial hydration of a root that has just been created. Most
// of the stuff in scheduleUpdateOnFiber can be skipped.
@@ -29518,7 +29479,7 @@ function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
// match what was rendered on the server.
var current = root.current;
current.lanes = lane;
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
ensureRootIsScheduled(root);
}
function isUnsafeClassRenderPhaseUpdate(fiber) {
@@ -29531,10 +29492,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -31872,10 +31831,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -31911,10 +31869,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -32040,11 +31997,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -32780,7 +32736,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -33693,7 +33649,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -33824,7 +33779,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-7c0aabad";
var ReactVersion = "18.3.0-www-classic-e3eacb5a";
function createPortal$1(
children,
@@ -34010,9 +33965,8 @@ function createHydrationContainer(
var update = createUpdate(lane);
update.callback =
callback !== undefined && callback !== null ? callback : null;
var eventTime = requestEventTime();
enqueueUpdate(current, update, lane);
scheduleInitialHydrationOnRoot(root, lane, eventTime);
scheduleInitialHydrationOnRoot(root, lane);
return root;
}
function updateContainer(element, container, parentComponent, callback) {
@@ -34074,8 +34028,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -34116,8 +34069,7 @@ function attemptSynchronousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, SyncLane, eventTime);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}); // If we're still blocked after this, we need to increase
// the priority of any promises resolving within this
@@ -34163,8 +34115,7 @@ function attemptContinuousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -34180,8 +34131,7 @@ function attemptHydrationAtCurrentPriority(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -34337,7 +34287,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34358,7 +34308,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34379,7 +34329,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -34394,7 +34344,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34408,7 +34358,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34422,7 +34372,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34430,7 +34380,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
+35 -85
View File
@@ -1634,7 +1634,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -1652,12 +1652,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -1690,7 +1684,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -1700,7 +1693,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -13275,7 +13267,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -13936,8 +13928,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -13991,8 +13982,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -14075,8 +14065,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -15561,8 +15550,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15597,8 +15585,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15633,8 +15620,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -19828,16 +19814,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -26132,7 +26111,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -26153,7 +26132,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -29106,11 +29085,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -29122,20 +29097,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -29219,7 +29180,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -29245,7 +29206,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -29347,7 +29308,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
}
function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
function scheduleInitialHydrationOnRoot(root, lane) {
// This is a special fork of scheduleUpdateOnFiber that is only used to
// schedule the initial hydration of a root that has just been created. Most
// of the stuff in scheduleUpdateOnFiber can be skipped.
@@ -29359,7 +29320,7 @@ function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
// match what was rendered on the server.
var current = root.current;
current.lanes = lane;
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
ensureRootIsScheduled(root);
}
function isUnsafeClassRenderPhaseUpdate(fiber) {
@@ -29372,10 +29333,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -31708,10 +31667,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -31747,10 +31705,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -31876,11 +31833,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -32616,7 +32572,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -33529,7 +33485,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -33660,7 +33615,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-8ad04cf7";
var ReactVersion = "18.3.0-www-modern-6d893aea";
function createPortal$1(
children,
@@ -33774,9 +33729,8 @@ function createHydrationContainer(
var update = createUpdate(lane);
update.callback =
callback !== undefined && callback !== null ? callback : null;
var eventTime = requestEventTime();
enqueueUpdate(current, update, lane);
scheduleInitialHydrationOnRoot(root, lane, eventTime);
scheduleInitialHydrationOnRoot(root, lane);
return root;
}
function updateContainer(element, container, parentComponent, callback) {
@@ -33838,8 +33792,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -33864,8 +33817,7 @@ function attemptSynchronousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, SyncLane, eventTime);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}); // If we're still blocked after this, we need to increase
// the priority of any promises resolving within this
@@ -33911,8 +33863,7 @@ function attemptContinuousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -33928,8 +33879,7 @@ function attemptHydrationAtCurrentPriority(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -34076,7 +34026,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34097,7 +34047,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34118,7 +34068,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -34133,7 +34083,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34147,7 +34097,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34161,7 +34111,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34169,7 +34119,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
+81 -118
View File
@@ -583,13 +583,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -601,13 +598,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$4 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$4;
remainingLanes[index$4] = 0;
eventTimes[index$4] = -1;
expirationTimes[index$4] = -1;
var hiddenUpdatesForLane = root[index$4];
if (null !== hiddenUpdatesForLane)
@@ -3501,7 +3496,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -3686,11 +3681,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$49 = enqueueUpdate(provider, fiber, lane);
if (null !== root$49) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$49, provider, lane, eventTime);
entangleTransitions(root$49, provider, lane);
}
null !== root$49 &&
(scheduleUpdateOnFiber(root$49, provider, lane),
entangleTransitions(root$49, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -3711,16 +3704,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -3755,8 +3745,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -4078,8 +4067,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -4091,8 +4079,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -4103,8 +4090,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -5429,7 +5415,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -7946,7 +7932,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -7956,7 +7942,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -9640,15 +9626,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -9665,29 +9643,30 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$6] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig$1.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$6] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -9703,7 +9682,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -10745,10 +10723,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -10782,9 +10758,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -10826,10 +10801,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -11810,7 +11784,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -11963,10 +11936,9 @@ function createHydrationContainer(
hydrationCallbacks = createUpdate(tag);
hydrationCallbacks.callback =
void 0 !== callback && null !== callback ? callback : null;
callback = requestEventTime();
enqueueUpdate(containerInfo, hydrationCallbacks, tag);
initialChildren.current.lanes = tag;
markRootUpdated(initialChildren, tag, callback);
markRootUpdated(initialChildren, tag);
ensureRootIsScheduled(initialChildren);
return initialChildren;
}
@@ -11983,8 +11955,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(current, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, current, lane, callback),
(scheduleUpdateOnFiber(element, current, lane),
entangleTransitions(element, current, lane));
return lane;
}
@@ -12016,10 +11987,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -12038,10 +12006,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -12581,14 +12546,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$367;
if (canUseDOM) {
var isSupported$jscomp$inline_1595 = "oninput" in document;
if (!isSupported$jscomp$inline_1595) {
var element$jscomp$inline_1596 = document.createElement("div");
element$jscomp$inline_1596.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1595 =
"function" === typeof element$jscomp$inline_1596.oninput;
var isSupported$jscomp$inline_1594 = "oninput" in document;
if (!isSupported$jscomp$inline_1594) {
var element$jscomp$inline_1595 = document.createElement("div");
element$jscomp$inline_1595.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1594 =
"function" === typeof element$jscomp$inline_1595.oninput;
}
JSCompiler_inline_result$jscomp$367 = isSupported$jscomp$inline_1595;
JSCompiler_inline_result$jscomp$367 = isSupported$jscomp$inline_1594;
} else JSCompiler_inline_result$jscomp$367 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$367 &&
@@ -12900,20 +12865,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1636 = 0;
i$jscomp$inline_1636 < simpleEventPluginEvents.length;
i$jscomp$inline_1636++
var i$jscomp$inline_1635 = 0;
i$jscomp$inline_1635 < simpleEventPluginEvents.length;
i$jscomp$inline_1635++
) {
var eventName$jscomp$inline_1637 =
simpleEventPluginEvents[i$jscomp$inline_1636],
domEventName$jscomp$inline_1638 =
eventName$jscomp$inline_1637.toLowerCase(),
capitalizedEvent$jscomp$inline_1639 =
eventName$jscomp$inline_1637[0].toUpperCase() +
eventName$jscomp$inline_1637.slice(1);
var eventName$jscomp$inline_1636 =
simpleEventPluginEvents[i$jscomp$inline_1635],
domEventName$jscomp$inline_1637 =
eventName$jscomp$inline_1636.toLowerCase(),
capitalizedEvent$jscomp$inline_1638 =
eventName$jscomp$inline_1636[0].toUpperCase() +
eventName$jscomp$inline_1636.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1638,
"on" + capitalizedEvent$jscomp$inline_1639
domEventName$jscomp$inline_1637,
"on" + capitalizedEvent$jscomp$inline_1638
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -15843,10 +15808,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -16366,17 +16329,17 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1843 = {
var devToolsConfig$jscomp$inline_1841 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-classic-e9109a51",
version: "18.3.0-www-classic-ded49a3c",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2203 = {
bundleType: devToolsConfig$jscomp$inline_1843.bundleType,
version: devToolsConfig$jscomp$inline_1843.version,
rendererPackageName: devToolsConfig$jscomp$inline_1843.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1843.rendererConfig,
var internals$jscomp$inline_2201 = {
bundleType: devToolsConfig$jscomp$inline_1841.bundleType,
version: devToolsConfig$jscomp$inline_1841.version,
rendererPackageName: devToolsConfig$jscomp$inline_1841.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1841.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -16392,26 +16355,26 @@ var internals$jscomp$inline_2203 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1843.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1841.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-e9109a51"
reconcilerVersion: "18.3.0-www-classic-ded49a3c"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2204 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_2202 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_2204.isDisabled &&
hook$jscomp$inline_2204.supportsFiber
!hook$jscomp$inline_2202.isDisabled &&
hook$jscomp$inline_2202.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_2204.inject(
internals$jscomp$inline_2203
(rendererID = hook$jscomp$inline_2202.inject(
internals$jscomp$inline_2201
)),
(injectedHook = hook$jscomp$inline_2204);
(injectedHook = hook$jscomp$inline_2202);
} catch (err) {}
}
assign(Internals, {
@@ -16639,4 +16602,4 @@ exports.unstable_renderSubtreeIntoContainer = function (
);
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-classic-e9109a51";
exports.version = "18.3.0-www-classic-ded49a3c";
+81 -118
View File
@@ -310,13 +310,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -328,13 +325,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$3 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$3;
remainingLanes[index$3] = 0;
eventTimes[index$3] = -1;
expirationTimes[index$3] = -1;
var hiddenUpdatesForLane = root[index$3];
if (null !== hiddenUpdatesForLane)
@@ -3389,7 +3384,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -3574,11 +3569,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$49 = enqueueUpdate(provider, fiber, lane);
if (null !== root$49) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$49, provider, lane, eventTime);
entangleTransitions(root$49, provider, lane);
}
null !== root$49 &&
(scheduleUpdateOnFiber(root$49, provider, lane),
entangleTransitions(root$49, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -3599,16 +3592,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -3643,8 +3633,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -3966,8 +3955,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -3979,8 +3967,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -3991,8 +3978,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -5270,7 +5256,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -7777,7 +7763,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -7787,7 +7773,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -9471,15 +9457,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -9496,29 +9474,30 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$5 = 31 - clz32(lane),
transitions = transitionLanesMap[index$5];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$5] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig$1.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$5 = 31 - clz32(lane),
transitions = transitionLanesMap[index$5];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$5] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -9534,7 +9513,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -10572,10 +10550,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -10609,9 +10585,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -10653,10 +10628,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -11610,7 +11584,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -11707,8 +11680,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(parentComponent, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, parentComponent, lane, callback),
(scheduleUpdateOnFiber(element, parentComponent, lane),
entangleTransitions(element, parentComponent, lane));
return lane;
}
@@ -11729,10 +11701,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -11751,10 +11720,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -11985,10 +11951,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -12814,14 +12778,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$364;
if (canUseDOM) {
var isSupported$jscomp$inline_1587 = "oninput" in document;
if (!isSupported$jscomp$inline_1587) {
var element$jscomp$inline_1588 = document.createElement("div");
element$jscomp$inline_1588.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1587 =
"function" === typeof element$jscomp$inline_1588.oninput;
var isSupported$jscomp$inline_1586 = "oninput" in document;
if (!isSupported$jscomp$inline_1586) {
var element$jscomp$inline_1587 = document.createElement("div");
element$jscomp$inline_1587.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1586 =
"function" === typeof element$jscomp$inline_1587.oninput;
}
JSCompiler_inline_result$jscomp$364 = isSupported$jscomp$inline_1587;
JSCompiler_inline_result$jscomp$364 = isSupported$jscomp$inline_1586;
} else JSCompiler_inline_result$jscomp$364 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$364 &&
@@ -13133,20 +13097,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1628 = 0;
i$jscomp$inline_1628 < simpleEventPluginEvents.length;
i$jscomp$inline_1628++
var i$jscomp$inline_1627 = 0;
i$jscomp$inline_1627 < simpleEventPluginEvents.length;
i$jscomp$inline_1627++
) {
var eventName$jscomp$inline_1629 =
simpleEventPluginEvents[i$jscomp$inline_1628],
domEventName$jscomp$inline_1630 =
eventName$jscomp$inline_1629.toLowerCase(),
capitalizedEvent$jscomp$inline_1631 =
eventName$jscomp$inline_1629[0].toUpperCase() +
eventName$jscomp$inline_1629.slice(1);
var eventName$jscomp$inline_1628 =
simpleEventPluginEvents[i$jscomp$inline_1627],
domEventName$jscomp$inline_1629 =
eventName$jscomp$inline_1628.toLowerCase(),
capitalizedEvent$jscomp$inline_1630 =
eventName$jscomp$inline_1628[0].toUpperCase() +
eventName$jscomp$inline_1628.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1630,
"on" + capitalizedEvent$jscomp$inline_1631
domEventName$jscomp$inline_1629,
"on" + capitalizedEvent$jscomp$inline_1630
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -15893,17 +15857,17 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1801 = {
var devToolsConfig$jscomp$inline_1800 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-modern-6c02faf9",
version: "18.3.0-www-modern-b596b6b5",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2166 = {
bundleType: devToolsConfig$jscomp$inline_1801.bundleType,
version: devToolsConfig$jscomp$inline_1801.version,
rendererPackageName: devToolsConfig$jscomp$inline_1801.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1801.rendererConfig,
var internals$jscomp$inline_2165 = {
bundleType: devToolsConfig$jscomp$inline_1800.bundleType,
version: devToolsConfig$jscomp$inline_1800.version,
rendererPackageName: devToolsConfig$jscomp$inline_1800.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1800.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -15920,26 +15884,26 @@ var internals$jscomp$inline_2166 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1801.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1800.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-6c02faf9"
reconcilerVersion: "18.3.0-www-modern-b596b6b5"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2167 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_2166 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_2167.isDisabled &&
hook$jscomp$inline_2167.supportsFiber
!hook$jscomp$inline_2166.isDisabled &&
hook$jscomp$inline_2166.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_2167.inject(
internals$jscomp$inline_2166
(rendererID = hook$jscomp$inline_2166.inject(
internals$jscomp$inline_2165
)),
(injectedHook = hook$jscomp$inline_2167);
(injectedHook = hook$jscomp$inline_2166);
} catch (err) {}
}
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
@@ -16025,10 +15989,9 @@ exports.hydrateRoot = function (container, initialChildren, options) {
isStrictMode = requestUpdateLane(options);
concurrentUpdatesByDefaultOverride = createUpdate(isStrictMode);
concurrentUpdatesByDefaultOverride.callback = null;
identifierPrefix = requestEventTime();
enqueueUpdate(options, concurrentUpdatesByDefaultOverride, isStrictMode);
initialChildren.current.lanes = isStrictMode;
markRootUpdated(initialChildren, isStrictMode, identifierPrefix);
markRootUpdated(initialChildren, isStrictMode);
ensureRootIsScheduled(initialChildren);
container[internalContainerInstanceKey] = initialChildren.current;
Dispatcher.current = ReactDOMClientDispatcher;
@@ -16096,4 +16059,4 @@ exports.unstable_createEventHandle = function (type, options) {
return eventHandle;
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-modern-6c02faf9";
exports.version = "18.3.0-www-modern-b596b6b5";
@@ -697,13 +697,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -715,13 +712,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$5 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$5;
remainingLanes[index$5] = 0;
eventTimes[index$5] = -1;
expirationTimes[index$5] = -1;
var hiddenUpdatesForLane = root[index$5];
if (null !== hiddenUpdatesForLane)
@@ -3645,7 +3640,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -3830,11 +3825,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$52 = enqueueUpdate(provider, fiber, lane);
if (null !== root$52) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$52, provider, lane, eventTime);
entangleTransitions(root$52, provider, lane);
}
null !== root$52 &&
(scheduleUpdateOnFiber(root$52, provider, lane),
entangleTransitions(root$52, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -3855,16 +3848,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
enableSchedulingProfiler && markStateUpdateScheduled(fiber, lane);
}
function dispatchSetState(fiber, queue, action) {
@@ -3900,8 +3890,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
enableSchedulingProfiler && markStateUpdateScheduled(fiber, lane);
@@ -4286,8 +4275,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
enableSchedulingProfiler && markStateUpdateScheduled(inst, lane);
},
@@ -4300,8 +4288,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
enableSchedulingProfiler && markStateUpdateScheduled(inst, lane);
},
@@ -4313,8 +4300,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
enableSchedulingProfiler &&
enableSchedulingProfiler &&
@@ -5667,7 +5653,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -8464,7 +8450,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -8474,7 +8460,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -10232,15 +10218,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now$1()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now$1());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -10257,14 +10235,14 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
isDevToolsPresent && addFiberToLanesMap(root, fiber, lane);
if (
@@ -10273,29 +10251,29 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
root === rootCommittingMutationOrLayoutEffects &&
fiber.mode & 2
)
for (eventTime = fiber; null !== eventTime; ) {
if (12 === eventTime.tag) {
var _current$memoizedProp = eventTime.memoizedProps,
for (var current = fiber; null !== current; ) {
if (12 === current.tag) {
var _current$memoizedProp = current.memoizedProps,
id = _current$memoizedProp.id;
_current$memoizedProp = _current$memoizedProp.onNestedUpdateScheduled;
"function" === typeof _current$memoizedProp &&
_current$memoizedProp(id);
}
eventTime = eventTime.return;
current = current.return;
}
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now$1()),
((current = ReactCurrentBatchConfig$1.transition),
null !== current &&
null != current.name &&
(-1 === current.startTime && (current.startTime = now$1()),
enableTransitionTracing))
) {
id = root.transitionLanes;
_current$memoizedProp = 31 - clz32(lane);
var transitions = id[_current$memoizedProp];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitions.add(current);
id[_current$memoizedProp] = transitions;
}
root === workInProgressRoot &&
@@ -10313,7 +10291,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
function performConcurrentWorkOnRoot(root, didTimeout) {
nestedUpdateScheduled = currentUpdateIsNested = !1;
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -11483,10 +11460,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -11520,9 +11495,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -11565,10 +11539,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -12575,7 +12548,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -12733,10 +12705,9 @@ function createHydrationContainer(
hydrationCallbacks = createUpdate(tag);
hydrationCallbacks.callback =
void 0 !== callback && null !== callback ? callback : null;
callback = requestEventTime();
enqueueUpdate(containerInfo, hydrationCallbacks, tag);
initialChildren.current.lanes = tag;
markRootUpdated(initialChildren, tag, callback);
markRootUpdated(initialChildren, tag);
ensureRootIsScheduled(initialChildren);
return initialChildren;
}
@@ -12758,8 +12729,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(current, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, current, lane, callback),
(scheduleUpdateOnFiber(element, current, lane),
entangleTransitions(element, current, lane));
return lane;
}
@@ -12791,10 +12761,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -12813,10 +12780,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -13356,14 +13320,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$388;
if (canUseDOM) {
var isSupported$jscomp$inline_1674 = "oninput" in document;
if (!isSupported$jscomp$inline_1674) {
var element$jscomp$inline_1675 = document.createElement("div");
element$jscomp$inline_1675.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1674 =
"function" === typeof element$jscomp$inline_1675.oninput;
var isSupported$jscomp$inline_1673 = "oninput" in document;
if (!isSupported$jscomp$inline_1673) {
var element$jscomp$inline_1674 = document.createElement("div");
element$jscomp$inline_1674.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1673 =
"function" === typeof element$jscomp$inline_1674.oninput;
}
JSCompiler_inline_result$jscomp$388 = isSupported$jscomp$inline_1674;
JSCompiler_inline_result$jscomp$388 = isSupported$jscomp$inline_1673;
} else JSCompiler_inline_result$jscomp$388 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$388 &&
@@ -13675,20 +13639,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1715 = 0;
i$jscomp$inline_1715 < simpleEventPluginEvents.length;
i$jscomp$inline_1715++
var i$jscomp$inline_1714 = 0;
i$jscomp$inline_1714 < simpleEventPluginEvents.length;
i$jscomp$inline_1714++
) {
var eventName$jscomp$inline_1716 =
simpleEventPluginEvents[i$jscomp$inline_1715],
domEventName$jscomp$inline_1717 =
eventName$jscomp$inline_1716.toLowerCase(),
capitalizedEvent$jscomp$inline_1718 =
eventName$jscomp$inline_1716[0].toUpperCase() +
eventName$jscomp$inline_1716.slice(1);
var eventName$jscomp$inline_1715 =
simpleEventPluginEvents[i$jscomp$inline_1714],
domEventName$jscomp$inline_1716 =
eventName$jscomp$inline_1715.toLowerCase(),
capitalizedEvent$jscomp$inline_1717 =
eventName$jscomp$inline_1715[0].toUpperCase() +
eventName$jscomp$inline_1715.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1717,
"on" + capitalizedEvent$jscomp$inline_1718
domEventName$jscomp$inline_1716,
"on" + capitalizedEvent$jscomp$inline_1717
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -16618,10 +16582,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -17141,10 +17103,10 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1922 = {
var devToolsConfig$jscomp$inline_1920 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-classic-43e06ed6",
version: "18.3.0-www-classic-c5e22311",
rendererPackageName: "react-dom"
};
(function (internals) {
@@ -17162,10 +17124,10 @@ var devToolsConfig$jscomp$inline_1922 = {
} catch (err) {}
return hook.checkDCE ? !0 : !1;
})({
bundleType: devToolsConfig$jscomp$inline_1922.bundleType,
version: devToolsConfig$jscomp$inline_1922.version,
rendererPackageName: devToolsConfig$jscomp$inline_1922.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1922.rendererConfig,
bundleType: devToolsConfig$jscomp$inline_1920.bundleType,
version: devToolsConfig$jscomp$inline_1920.version,
rendererPackageName: devToolsConfig$jscomp$inline_1920.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1920.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -17181,14 +17143,14 @@ var devToolsConfig$jscomp$inline_1922 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1922.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1920.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-43e06ed6"
reconcilerVersion: "18.3.0-www-classic-c5e22311"
});
assign(Internals, {
ReactBrowserEventEmitter: {
@@ -17415,7 +17377,7 @@ exports.unstable_renderSubtreeIntoContainer = function (
);
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-classic-43e06ed6";
exports.version = "18.3.0-www-classic-c5e22311";
/* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
if (
@@ -424,13 +424,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -442,13 +439,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$4 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$4;
remainingLanes[index$4] = 0;
eventTimes[index$4] = -1;
expirationTimes[index$4] = -1;
var hiddenUpdatesForLane = root[index$4];
if (null !== hiddenUpdatesForLane)
@@ -3533,7 +3528,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -3718,11 +3713,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$52 = enqueueUpdate(provider, fiber, lane);
if (null !== root$52) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$52, provider, lane, eventTime);
entangleTransitions(root$52, provider, lane);
}
null !== root$52 &&
(scheduleUpdateOnFiber(root$52, provider, lane),
entangleTransitions(root$52, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -3743,16 +3736,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
enableSchedulingProfiler && markStateUpdateScheduled(fiber, lane);
}
function dispatchSetState(fiber, queue, action) {
@@ -3788,8 +3778,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
enableSchedulingProfiler && markStateUpdateScheduled(fiber, lane);
@@ -4174,8 +4163,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
enableSchedulingProfiler && markStateUpdateScheduled(inst, lane);
},
@@ -4188,8 +4176,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
enableSchedulingProfiler && markStateUpdateScheduled(inst, lane);
},
@@ -4201,8 +4188,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
enableSchedulingProfiler &&
enableSchedulingProfiler &&
@@ -5502,7 +5488,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -8289,7 +8275,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -8299,7 +8285,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -10057,15 +10043,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now$1()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now$1());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -10082,14 +10060,14 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
isDevToolsPresent && addFiberToLanesMap(root, fiber, lane);
if (
@@ -10098,29 +10076,29 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
root === rootCommittingMutationOrLayoutEffects &&
fiber.mode & 2
)
for (eventTime = fiber; null !== eventTime; ) {
if (12 === eventTime.tag) {
var _current$memoizedProp = eventTime.memoizedProps,
for (var current = fiber; null !== current; ) {
if (12 === current.tag) {
var _current$memoizedProp = current.memoizedProps,
id = _current$memoizedProp.id;
_current$memoizedProp = _current$memoizedProp.onNestedUpdateScheduled;
"function" === typeof _current$memoizedProp &&
_current$memoizedProp(id);
}
eventTime = eventTime.return;
current = current.return;
}
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now$1()),
((current = ReactCurrentBatchConfig$1.transition),
null !== current &&
null != current.name &&
(-1 === current.startTime && (current.startTime = now$1()),
enableTransitionTracing))
) {
id = root.transitionLanes;
_current$memoizedProp = 31 - clz32(lane);
var transitions = id[_current$memoizedProp];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitions.add(current);
id[_current$memoizedProp] = transitions;
}
root === workInProgressRoot &&
@@ -10138,7 +10116,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
function performConcurrentWorkOnRoot(root, didTimeout) {
nestedUpdateScheduled = currentUpdateIsNested = !1;
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -11304,10 +11281,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -11341,9 +11316,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -11386,10 +11360,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -12369,7 +12342,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -12476,8 +12448,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(parentComponent, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, parentComponent, lane, callback),
(scheduleUpdateOnFiber(element, parentComponent, lane),
entangleTransitions(element, parentComponent, lane));
return lane;
}
@@ -12498,10 +12469,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -12520,10 +12488,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -12754,10 +12719,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -13583,14 +13546,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$385;
if (canUseDOM) {
var isSupported$jscomp$inline_1666 = "oninput" in document;
if (!isSupported$jscomp$inline_1666) {
var element$jscomp$inline_1667 = document.createElement("div");
element$jscomp$inline_1667.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1666 =
"function" === typeof element$jscomp$inline_1667.oninput;
var isSupported$jscomp$inline_1665 = "oninput" in document;
if (!isSupported$jscomp$inline_1665) {
var element$jscomp$inline_1666 = document.createElement("div");
element$jscomp$inline_1666.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1665 =
"function" === typeof element$jscomp$inline_1666.oninput;
}
JSCompiler_inline_result$jscomp$385 = isSupported$jscomp$inline_1666;
JSCompiler_inline_result$jscomp$385 = isSupported$jscomp$inline_1665;
} else JSCompiler_inline_result$jscomp$385 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$385 &&
@@ -13902,20 +13865,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1707 = 0;
i$jscomp$inline_1707 < simpleEventPluginEvents.length;
i$jscomp$inline_1707++
var i$jscomp$inline_1706 = 0;
i$jscomp$inline_1706 < simpleEventPluginEvents.length;
i$jscomp$inline_1706++
) {
var eventName$jscomp$inline_1708 =
simpleEventPluginEvents[i$jscomp$inline_1707],
domEventName$jscomp$inline_1709 =
eventName$jscomp$inline_1708.toLowerCase(),
capitalizedEvent$jscomp$inline_1710 =
eventName$jscomp$inline_1708[0].toUpperCase() +
eventName$jscomp$inline_1708.slice(1);
var eventName$jscomp$inline_1707 =
simpleEventPluginEvents[i$jscomp$inline_1706],
domEventName$jscomp$inline_1708 =
eventName$jscomp$inline_1707.toLowerCase(),
capitalizedEvent$jscomp$inline_1709 =
eventName$jscomp$inline_1707[0].toUpperCase() +
eventName$jscomp$inline_1707.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1709,
"on" + capitalizedEvent$jscomp$inline_1710
domEventName$jscomp$inline_1708,
"on" + capitalizedEvent$jscomp$inline_1709
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -16662,10 +16625,10 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1880 = {
var devToolsConfig$jscomp$inline_1879 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-modern-8e733635",
version: "18.3.0-www-modern-f255a7e3",
rendererPackageName: "react-dom"
};
(function (internals) {
@@ -16683,10 +16646,10 @@ var devToolsConfig$jscomp$inline_1880 = {
} catch (err) {}
return hook.checkDCE ? !0 : !1;
})({
bundleType: devToolsConfig$jscomp$inline_1880.bundleType,
version: devToolsConfig$jscomp$inline_1880.version,
rendererPackageName: devToolsConfig$jscomp$inline_1880.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1880.rendererConfig,
bundleType: devToolsConfig$jscomp$inline_1879.bundleType,
version: devToolsConfig$jscomp$inline_1879.version,
rendererPackageName: devToolsConfig$jscomp$inline_1879.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1879.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -16703,14 +16666,14 @@ var devToolsConfig$jscomp$inline_1880 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1880.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1879.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-8e733635"
reconcilerVersion: "18.3.0-www-modern-f255a7e3"
});
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
exports.createPortal = function (children, container) {
@@ -16795,10 +16758,9 @@ exports.hydrateRoot = function (container, initialChildren, options) {
isStrictMode = requestUpdateLane(options);
concurrentUpdatesByDefaultOverride = createUpdate(isStrictMode);
concurrentUpdatesByDefaultOverride.callback = null;
identifierPrefix = requestEventTime();
enqueueUpdate(options, concurrentUpdatesByDefaultOverride, isStrictMode);
initialChildren.current.lanes = isStrictMode;
markRootUpdated(initialChildren, isStrictMode, identifierPrefix);
markRootUpdated(initialChildren, isStrictMode);
ensureRootIsScheduled(initialChildren);
container[internalContainerInstanceKey] = initialChildren.current;
Dispatcher.current = ReactDOMClientDispatcher;
@@ -16866,7 +16828,7 @@ exports.unstable_createEventHandle = function (type, options) {
return eventHandle;
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-modern-8e733635";
exports.version = "18.3.0-www-modern-f255a7e3";
/* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
if (
@@ -2319,7 +2319,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -2337,12 +2337,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -2375,7 +2369,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -2385,7 +2378,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -16583,7 +16575,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -17244,8 +17236,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -17299,8 +17290,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -17383,8 +17373,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -18871,8 +18860,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -18907,8 +18895,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -18943,8 +18930,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -23192,16 +23178,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -29531,7 +29510,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -29552,7 +29531,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -32988,11 +32967,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -33004,20 +32979,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -33101,7 +33062,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -33127,7 +33088,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -33229,7 +33190,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
}
function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
function scheduleInitialHydrationOnRoot(root, lane) {
// This is a special fork of scheduleUpdateOnFiber that is only used to
// schedule the initial hydration of a root that has just been created. Most
// of the stuff in scheduleUpdateOnFiber can be skipped.
@@ -33241,7 +33202,7 @@ function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
// match what was rendered on the server.
var current = root.current;
current.lanes = lane;
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
ensureRootIsScheduled(root);
}
function isUnsafeClassRenderPhaseUpdate(fiber) {
@@ -33254,10 +33215,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -35595,10 +35554,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -35634,10 +35592,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -35763,11 +35720,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -36503,7 +36459,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -37416,7 +37372,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -37547,7 +37502,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-e96410ff";
var ReactVersion = "18.3.0-www-classic-5ca6dfdf";
function createPortal$1(
children,
@@ -37733,9 +37688,8 @@ function createHydrationContainer(
var update = createUpdate(lane);
update.callback =
callback !== undefined && callback !== null ? callback : null;
var eventTime = requestEventTime();
enqueueUpdate(current, update, lane);
scheduleInitialHydrationOnRoot(root, lane, eventTime);
scheduleInitialHydrationOnRoot(root, lane);
return root;
}
function updateContainer(element, container, parentComponent, callback) {
@@ -37797,8 +37751,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -37839,8 +37792,7 @@ function attemptSynchronousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, SyncLane, eventTime);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}); // If we're still blocked after this, we need to increase
// the priority of any promises resolving within this
@@ -37886,8 +37838,7 @@ function attemptContinuousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -37903,8 +37854,7 @@ function attemptHydrationAtCurrentPriority(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -38060,7 +38010,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -38081,7 +38031,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -38102,7 +38052,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -38117,7 +38067,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -38131,7 +38081,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -38145,7 +38095,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -38153,7 +38103,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -1623,7 +1623,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -1641,12 +1641,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -1679,7 +1673,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -1689,7 +1682,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -13411,7 +13403,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -14072,8 +14064,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -14127,8 +14118,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -14211,8 +14201,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -15697,8 +15686,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15733,8 +15721,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -15769,8 +15756,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
@@ -19964,16 +19950,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -26268,7 +26247,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -26289,7 +26268,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -29725,11 +29704,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -29741,20 +29716,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -29838,7 +29799,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -29864,7 +29825,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -29966,7 +29927,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
}
function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
function scheduleInitialHydrationOnRoot(root, lane) {
// This is a special fork of scheduleUpdateOnFiber that is only used to
// schedule the initial hydration of a root that has just been created. Most
// of the stuff in scheduleUpdateOnFiber can be skipped.
@@ -29978,7 +29939,7 @@ function scheduleInitialHydrationOnRoot(root, lane, eventTime) {
// match what was rendered on the server.
var current = root.current;
current.lanes = lane;
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
ensureRootIsScheduled(root);
}
function isUnsafeClassRenderPhaseUpdate(fiber) {
@@ -29991,10 +29952,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -32327,10 +32286,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -32366,10 +32324,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -32495,11 +32452,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -33235,7 +33191,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -34148,7 +34104,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -34279,7 +34234,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-1d5f900e";
var ReactVersion = "18.3.0-www-modern-9f58dd96";
function createPortal$1(
children,
@@ -34393,9 +34348,8 @@ function createHydrationContainer(
var update = createUpdate(lane);
update.callback =
callback !== undefined && callback !== null ? callback : null;
var eventTime = requestEventTime();
enqueueUpdate(current, update, lane);
scheduleInitialHydrationOnRoot(root, lane, eventTime);
scheduleInitialHydrationOnRoot(root, lane);
return root;
}
function updateContainer(element, container, parentComponent, callback) {
@@ -34457,8 +34411,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -34483,8 +34436,7 @@ function attemptSynchronousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, SyncLane, eventTime);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}); // If we're still blocked after this, we need to increase
// the priority of any promises resolving within this
@@ -34530,8 +34482,7 @@ function attemptContinuousHydration(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -34547,8 +34498,7 @@ function attemptHydrationAtCurrentPriority(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
}
markRetryLaneIfNotHydrated(fiber, lane);
@@ -34695,7 +34645,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34716,7 +34666,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -34737,7 +34687,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -34752,7 +34702,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34766,7 +34716,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34780,7 +34730,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -34788,7 +34738,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -583,13 +583,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -601,13 +598,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$4 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$4;
remainingLanes[index$4] = 0;
eventTimes[index$4] = -1;
expirationTimes[index$4] = -1;
var hiddenUpdatesForLane = root[index$4];
if (null !== hiddenUpdatesForLane)
@@ -4452,7 +4447,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -4637,11 +4632,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$115 = enqueueUpdate(provider, fiber, lane);
if (null !== root$115) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$115, provider, lane, eventTime);
entangleTransitions(root$115, provider, lane);
}
null !== root$115 &&
(scheduleUpdateOnFiber(root$115, provider, lane),
entangleTransitions(root$115, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -4662,16 +4655,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -4706,8 +4696,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -5029,8 +5018,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -5042,8 +5030,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -5054,8 +5041,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -6380,7 +6366,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -8897,7 +8883,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -8907,7 +8893,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -10777,15 +10763,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -10802,29 +10780,30 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$6] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig$1.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$6 = 31 - clz32(lane),
transitions = transitionLanesMap[index$6];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$6] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -10840,7 +10819,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -11882,10 +11860,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -11919,9 +11895,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -11963,10 +11938,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -12947,7 +12921,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -13100,10 +13073,9 @@ function createHydrationContainer(
hydrationCallbacks = createUpdate(tag);
hydrationCallbacks.callback =
void 0 !== callback && null !== callback ? callback : null;
callback = requestEventTime();
enqueueUpdate(containerInfo, hydrationCallbacks, tag);
initialChildren.current.lanes = tag;
markRootUpdated(initialChildren, tag, callback);
markRootUpdated(initialChildren, tag);
ensureRootIsScheduled(initialChildren);
return initialChildren;
}
@@ -13120,8 +13092,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(current, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, current, lane, callback),
(scheduleUpdateOnFiber(element, current, lane),
entangleTransitions(element, current, lane));
return lane;
}
@@ -13153,10 +13124,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -13175,10 +13143,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -13718,14 +13683,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$370;
if (canUseDOM) {
var isSupported$jscomp$inline_1645 = "oninput" in document;
if (!isSupported$jscomp$inline_1645) {
var element$jscomp$inline_1646 = document.createElement("div");
element$jscomp$inline_1646.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1645 =
"function" === typeof element$jscomp$inline_1646.oninput;
var isSupported$jscomp$inline_1644 = "oninput" in document;
if (!isSupported$jscomp$inline_1644) {
var element$jscomp$inline_1645 = document.createElement("div");
element$jscomp$inline_1645.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1644 =
"function" === typeof element$jscomp$inline_1645.oninput;
}
JSCompiler_inline_result$jscomp$370 = isSupported$jscomp$inline_1645;
JSCompiler_inline_result$jscomp$370 = isSupported$jscomp$inline_1644;
} else JSCompiler_inline_result$jscomp$370 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$370 &&
@@ -14037,20 +14002,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1686 = 0;
i$jscomp$inline_1686 < simpleEventPluginEvents.length;
i$jscomp$inline_1686++
var i$jscomp$inline_1685 = 0;
i$jscomp$inline_1685 < simpleEventPluginEvents.length;
i$jscomp$inline_1685++
) {
var eventName$jscomp$inline_1687 =
simpleEventPluginEvents[i$jscomp$inline_1686],
domEventName$jscomp$inline_1688 =
eventName$jscomp$inline_1687.toLowerCase(),
capitalizedEvent$jscomp$inline_1689 =
eventName$jscomp$inline_1687[0].toUpperCase() +
eventName$jscomp$inline_1687.slice(1);
var eventName$jscomp$inline_1686 =
simpleEventPluginEvents[i$jscomp$inline_1685],
domEventName$jscomp$inline_1687 =
eventName$jscomp$inline_1686.toLowerCase(),
capitalizedEvent$jscomp$inline_1688 =
eventName$jscomp$inline_1686[0].toUpperCase() +
eventName$jscomp$inline_1686.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1688,
"on" + capitalizedEvent$jscomp$inline_1689
domEventName$jscomp$inline_1687,
"on" + capitalizedEvent$jscomp$inline_1688
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -15063,17 +15028,17 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1800 = {
var devToolsConfig$jscomp$inline_1799 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-classic-ab122236",
version: "18.3.0-www-classic-e55ff31a",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2233 = {
bundleType: devToolsConfig$jscomp$inline_1800.bundleType,
version: devToolsConfig$jscomp$inline_1800.version,
rendererPackageName: devToolsConfig$jscomp$inline_1800.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1800.rendererConfig,
var internals$jscomp$inline_2231 = {
bundleType: devToolsConfig$jscomp$inline_1799.bundleType,
version: devToolsConfig$jscomp$inline_1799.version,
rendererPackageName: devToolsConfig$jscomp$inline_1799.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1799.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -15089,26 +15054,26 @@ var internals$jscomp$inline_2233 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1800.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1799.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-ab122236"
reconcilerVersion: "18.3.0-www-classic-e55ff31a"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2234 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_2232 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_2234.isDisabled &&
hook$jscomp$inline_2234.supportsFiber
!hook$jscomp$inline_2232.isDisabled &&
hook$jscomp$inline_2232.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_2234.inject(
internals$jscomp$inline_2233
(rendererID = hook$jscomp$inline_2232.inject(
internals$jscomp$inline_2231
)),
(injectedHook = hook$jscomp$inline_2234);
(injectedHook = hook$jscomp$inline_2232);
} catch (err) {}
}
var tagToRoleMappings = {
@@ -16388,10 +16353,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -17098,4 +17061,4 @@ exports.unstable_renderSubtreeIntoContainer = function (
);
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-classic-ab122236";
exports.version = "18.3.0-www-classic-e55ff31a";
@@ -310,13 +310,10 @@ function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial);
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane;
536870912 !== updateLane &&
((root.suspendedLanes = 0), (root.pingedLanes = 0));
root = root.eventTimes;
updateLane = 31 - clz32(updateLane);
root[updateLane] = eventTime;
}
function markRootFinished(root, remainingLanes) {
var noLongerPendingLanes = root.pendingLanes & ~remainingLanes;
@@ -328,13 +325,11 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
remainingLanes = root.entanglements;
var eventTimes = root.eventTimes,
expirationTimes = root.expirationTimes;
var expirationTimes = root.expirationTimes;
for (root = root.hiddenUpdates; 0 < noLongerPendingLanes; ) {
var index$3 = 31 - clz32(noLongerPendingLanes),
lane = 1 << index$3;
remainingLanes[index$3] = 0;
eventTimes[index$3] = -1;
expirationTimes[index$3] = -1;
var hiddenUpdatesForLane = root[index$3];
if (null !== hiddenUpdatesForLane)
@@ -3530,7 +3525,7 @@ function checkIfSnapshotChanged(inst) {
}
function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root && scheduleUpdateOnFiber(root, fiber, 2, -1);
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}
function mountState(initialState) {
var hook = mountWorkInProgressHook();
@@ -3715,11 +3710,9 @@ function refreshCache(fiber, seedKey, seedValue) {
var lane = requestUpdateLane(provider);
fiber = createUpdate(lane);
var root$49 = enqueueUpdate(provider, fiber, lane);
if (null !== root$49) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root$49, provider, lane, eventTime);
entangleTransitions(root$49, provider, lane);
}
null !== root$49 &&
(scheduleUpdateOnFiber(root$49, provider, lane),
entangleTransitions(root$49, provider, lane));
provider = createCache();
null !== seedKey &&
void 0 !== seedKey &&
@@ -3740,16 +3733,13 @@ function dispatchReducerAction(fiber, queue, action) {
eagerState: null,
next: null
};
if (isRenderPhaseUpdate(fiber)) enqueueRenderPhaseUpdate(queue, action);
else if (
(enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action)
) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(action, fiber, lane, eventTime);
entangleTransitionUpdate(action, queue, lane);
}
isRenderPhaseUpdate(fiber)
? enqueueRenderPhaseUpdate(queue, action)
: (enqueueUpdate$1(fiber, queue, action, lane),
(action = getRootForUpdatedFiber(fiber)),
null !== action &&
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane)));
}
function dispatchSetState(fiber, queue, action) {
var lane = requestUpdateLane(fiber),
@@ -3784,8 +3774,7 @@ function dispatchSetState(fiber, queue, action) {
enqueueUpdate$1(fiber, queue, update, lane);
action = getRootForUpdatedFiber(fiber);
null !== action &&
((update = requestEventTime()),
scheduleUpdateOnFiber(action, fiber, lane, update),
(scheduleUpdateOnFiber(action, fiber, lane),
entangleTransitionUpdate(action, queue, lane));
}
}
@@ -4107,8 +4096,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueReplaceState: function (inst, payload, callback) {
@@ -4120,8 +4108,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
payload = enqueueUpdate(inst, update, lane);
null !== payload &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(payload, inst, lane, callback),
(scheduleUpdateOnFiber(payload, inst, lane),
entangleTransitions(payload, inst, lane));
},
enqueueForceUpdate: function (inst, callback) {
@@ -4132,8 +4119,7 @@ var classComponentUpdater = {
void 0 !== callback && null !== callback && (update.callback = callback);
callback = enqueueUpdate(inst, update, lane);
null !== callback &&
((update = requestEventTime()),
scheduleUpdateOnFiber(callback, inst, lane, update),
(scheduleUpdateOnFiber(callback, inst, lane),
entangleTransitions(callback, inst, lane));
}
};
@@ -5411,7 +5397,7 @@ function updateDehydratedSuspenseComponent(
throw (
((suspenseState.retryLane = suspenseInstance),
enqueueConcurrentRenderForLane(current, suspenseInstance),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance, -1),
scheduleUpdateOnFiber(nextProps, current, suspenseInstance),
SelectiveHydrationException)
);
}
@@ -7918,7 +7904,7 @@ function detachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility |= 2),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachOffscreenInstance(instance) {
@@ -7928,7 +7914,7 @@ function attachOffscreenInstance(instance) {
var root = enqueueConcurrentRenderForLane(fiber, 2);
null !== root &&
((instance._pendingVisibility &= -3),
scheduleUpdateOnFiber(root, fiber, 2, -1));
scheduleUpdateOnFiber(root, fiber, 2));
}
}
function attachSuspenseRetryListeners(finishedWork, wakeables) {
@@ -9798,15 +9784,7 @@ var hasUncaughtError = !1,
pendingPassiveTransitions = null,
nestedUpdateCount = 0,
rootWithNestedUpdates = null,
currentEventTime = -1,
currentEventTransitionLane = 0;
function requestEventTime() {
return 0 !== (executionContext & 6)
? now()
: -1 !== currentEventTime
? currentEventTime
: (currentEventTime = now());
}
function requestUpdateLane(fiber) {
if (0 === (fiber.mode & 1)) return 2;
if (0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes)
@@ -9823,29 +9801,30 @@ function requestUpdateLane(fiber) {
fiber = void 0 === fiber ? 32 : getEventPriority(fiber.type);
return fiber;
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
if (
(root === workInProgressRoot && 2 === workInProgressSuspendedReason) ||
null !== root.cancelPendingCommit
)
prepareFreshStack(root, 0),
markRootSuspended(root, workInProgressRootRenderLanes);
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (0 === (executionContext & 2) || root !== workInProgressRoot) {
if (
enableTransitionTracing &&
((eventTime = ReactCurrentBatchConfig$1.transition),
null !== eventTime &&
null != eventTime.name &&
(-1 === eventTime.startTime && (eventTime.startTime = now()),
enableTransitionTracing))
) {
var transitionLanesMap = root.transitionLanes,
index$5 = 31 - clz32(lane),
transitions = transitionLanesMap[index$5];
null === transitions && (transitions = new Set());
transitions.add(eventTime);
transitionLanesMap[index$5] = transitions;
if (enableTransitionTracing) {
var transition = ReactCurrentBatchConfig$1.transition;
if (
null !== transition &&
null != transition.name &&
(-1 === transition.startTime && (transition.startTime = now()),
enableTransitionTracing)
) {
var transitionLanesMap = root.transitionLanes,
index$5 = 31 - clz32(lane),
transitions = transitionLanesMap[index$5];
null === transitions && (transitions = new Set());
transitions.add(transition);
transitionLanesMap[index$5] = transitions;
}
}
root === workInProgressRoot &&
(0 === (executionContext & 2) &&
@@ -9861,7 +9840,6 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
}
}
function performConcurrentWorkOnRoot(root, didTimeout) {
currentEventTime = -1;
currentEventTransitionLane = 0;
if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
var originalCallbackNode = root.callbackNode;
@@ -10899,10 +10877,8 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
sourceFiber = createRootErrorUpdate(rootFiber, sourceFiber, 2);
rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
sourceFiber = requestEventTime();
null !== rootFiber &&
(markRootUpdated(rootFiber, 2, sourceFiber),
ensureRootIsScheduled(rootFiber));
(markRootUpdated(rootFiber, 2), ensureRootIsScheduled(rootFiber));
}
function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
if (3 === sourceFiber.tag)
@@ -10936,9 +10912,8 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
sourceFiber,
2
);
sourceFiber = requestEventTime();
null !== nearestMountedAncestor &&
(markRootUpdated(nearestMountedAncestor, 2, sourceFiber),
(markRootUpdated(nearestMountedAncestor, 2),
ensureRootIsScheduled(nearestMountedAncestor));
break;
}
@@ -10980,10 +10955,9 @@ function pingSuspendedRoot(root, wakeable, pingedLanes) {
function retryTimedOutBoundary(boundaryFiber, retryLane) {
0 === retryLane &&
(retryLane = 0 === (boundaryFiber.mode & 1) ? 2 : claimNextRetryLane());
var eventTime = requestEventTime();
boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
null !== boundaryFiber &&
(markRootUpdated(boundaryFiber, retryLane, eventTime),
(markRootUpdated(boundaryFiber, retryLane),
ensureRootIsScheduled(boundaryFiber));
}
function retryDehydratedSuspenseBoundary(boundaryFiber) {
@@ -11937,7 +11911,6 @@ function FiberRootNode(
this.cancelPendingCommit =
null;
this.callbackPriority = 0;
this.eventTimes = createLaneMap(0);
this.expirationTimes = createLaneMap(-1);
this.entangledLanes =
this.errorRecoveryDisabledLanes =
@@ -12034,8 +12007,7 @@ function updateContainer(element, container, parentComponent, callback) {
null !== callback && (container.callback = callback);
element = enqueueUpdate(parentComponent, container, lane);
null !== element &&
((callback = requestEventTime()),
scheduleUpdateOnFiber(element, parentComponent, lane, callback),
(scheduleUpdateOnFiber(element, parentComponent, lane),
entangleTransitions(element, parentComponent, lane));
return lane;
}
@@ -12056,10 +12028,7 @@ function attemptSynchronousHydration(fiber) {
case 13:
flushSync$1(function () {
var root = enqueueConcurrentRenderForLane(fiber, 2);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 2, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 2);
}),
markRetryLaneIfNotHydrated(fiber, 2);
}
@@ -12078,10 +12047,7 @@ function markRetryLaneIfNotHydrated(fiber, retryLane) {
function attemptContinuousHydration(fiber) {
if (13 === fiber.tag) {
var root = enqueueConcurrentRenderForLane(fiber, 134217728);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, 134217728, eventTime);
}
null !== root && scheduleUpdateOnFiber(root, fiber, 134217728);
markRetryLaneIfNotHydrated(fiber, 134217728);
}
}
@@ -12312,10 +12278,8 @@ function attemptExplicitHydrationTarget(queuedTarget) {
if (13 === nearestMounted.tag) {
var lane = requestUpdateLane(nearestMounted),
root = enqueueConcurrentRenderForLane(nearestMounted, lane);
if (null !== root) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, nearestMounted, lane, eventTime);
}
null !== root &&
scheduleUpdateOnFiber(root, nearestMounted, lane);
markRetryLaneIfNotHydrated(nearestMounted, lane);
}
});
@@ -13141,14 +13105,14 @@ var isInputEventSupported = !1;
if (canUseDOM) {
var JSCompiler_inline_result$jscomp$366;
if (canUseDOM) {
var isSupported$jscomp$inline_1616 = "oninput" in document;
if (!isSupported$jscomp$inline_1616) {
var element$jscomp$inline_1617 = document.createElement("div");
element$jscomp$inline_1617.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1616 =
"function" === typeof element$jscomp$inline_1617.oninput;
var isSupported$jscomp$inline_1615 = "oninput" in document;
if (!isSupported$jscomp$inline_1615) {
var element$jscomp$inline_1616 = document.createElement("div");
element$jscomp$inline_1616.setAttribute("oninput", "return;");
isSupported$jscomp$inline_1615 =
"function" === typeof element$jscomp$inline_1616.oninput;
}
JSCompiler_inline_result$jscomp$366 = isSupported$jscomp$inline_1616;
JSCompiler_inline_result$jscomp$366 = isSupported$jscomp$inline_1615;
} else JSCompiler_inline_result$jscomp$366 = !1;
isInputEventSupported =
JSCompiler_inline_result$jscomp$366 &&
@@ -13460,20 +13424,20 @@ function registerSimpleEvent(domEventName, reactName) {
registerTwoPhaseEvent(reactName, [domEventName]);
}
for (
var i$jscomp$inline_1657 = 0;
i$jscomp$inline_1657 < simpleEventPluginEvents.length;
i$jscomp$inline_1657++
var i$jscomp$inline_1656 = 0;
i$jscomp$inline_1656 < simpleEventPluginEvents.length;
i$jscomp$inline_1656++
) {
var eventName$jscomp$inline_1658 =
simpleEventPluginEvents[i$jscomp$inline_1657],
domEventName$jscomp$inline_1659 =
eventName$jscomp$inline_1658.toLowerCase(),
capitalizedEvent$jscomp$inline_1660 =
eventName$jscomp$inline_1658[0].toUpperCase() +
eventName$jscomp$inline_1658.slice(1);
var eventName$jscomp$inline_1657 =
simpleEventPluginEvents[i$jscomp$inline_1656],
domEventName$jscomp$inline_1658 =
eventName$jscomp$inline_1657.toLowerCase(),
capitalizedEvent$jscomp$inline_1659 =
eventName$jscomp$inline_1657[0].toUpperCase() +
eventName$jscomp$inline_1657.slice(1);
registerSimpleEvent(
domEventName$jscomp$inline_1659,
"on" + capitalizedEvent$jscomp$inline_1660
domEventName$jscomp$inline_1658,
"on" + capitalizedEvent$jscomp$inline_1659
);
}
registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -16277,17 +16241,17 @@ Internals.Events = [
restoreStateIfNeeded,
batchedUpdates$1
];
var devToolsConfig$jscomp$inline_1830 = {
var devToolsConfig$jscomp$inline_1829 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-modern-d66c88c7",
version: "18.3.0-www-modern-c910362f",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2200 = {
bundleType: devToolsConfig$jscomp$inline_1830.bundleType,
version: devToolsConfig$jscomp$inline_1830.version,
rendererPackageName: devToolsConfig$jscomp$inline_1830.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1830.rendererConfig,
var internals$jscomp$inline_2199 = {
bundleType: devToolsConfig$jscomp$inline_1829.bundleType,
version: devToolsConfig$jscomp$inline_1829.version,
rendererPackageName: devToolsConfig$jscomp$inline_1829.rendererPackageName,
rendererConfig: devToolsConfig$jscomp$inline_1829.rendererConfig,
overrideHookState: null,
overrideHookStateDeletePath: null,
overrideHookStateRenamePath: null,
@@ -16304,26 +16268,26 @@ var internals$jscomp$inline_2200 = {
return null === fiber ? null : fiber.stateNode;
},
findFiberByHostInstance:
devToolsConfig$jscomp$inline_1830.findFiberByHostInstance ||
devToolsConfig$jscomp$inline_1829.findFiberByHostInstance ||
emptyFindFiberByHostInstance,
findHostInstancesForRefresh: null,
scheduleRefresh: null,
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-d66c88c7"
reconcilerVersion: "18.3.0-www-modern-c910362f"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2201 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
var hook$jscomp$inline_2200 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
if (
!hook$jscomp$inline_2201.isDisabled &&
hook$jscomp$inline_2201.supportsFiber
!hook$jscomp$inline_2200.isDisabled &&
hook$jscomp$inline_2200.supportsFiber
)
try {
(rendererID = hook$jscomp$inline_2201.inject(
internals$jscomp$inline_2200
(rendererID = hook$jscomp$inline_2200.inject(
internals$jscomp$inline_2199
)),
(injectedHook = hook$jscomp$inline_2201);
(injectedHook = hook$jscomp$inline_2200);
} catch (err) {}
}
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
@@ -16542,10 +16506,9 @@ exports.hydrateRoot = function (container, initialChildren, options) {
isStrictMode = requestUpdateLane(options);
concurrentUpdatesByDefaultOverride = createUpdate(isStrictMode);
concurrentUpdatesByDefaultOverride.callback = null;
identifierPrefix = requestEventTime();
enqueueUpdate(options, concurrentUpdatesByDefaultOverride, isStrictMode);
initialChildren.current.lanes = isStrictMode;
markRootUpdated(initialChildren, isStrictMode, identifierPrefix);
markRootUpdated(initialChildren, isStrictMode);
ensureRootIsScheduled(initialChildren);
container[internalContainerInstanceKey] = initialChildren.current;
Dispatcher.current = ReactDOMClientDispatcher;
@@ -16631,4 +16594,4 @@ exports.unstable_createEventHandle = function (type, options) {
return eventHandle;
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-modern-d66c88c7";
exports.version = "18.3.0-www-modern-c910362f";
@@ -1681,7 +1681,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -1699,12 +1699,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -1737,7 +1731,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -1747,7 +1740,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -7643,7 +7635,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -8151,8 +8143,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -8206,8 +8197,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -8288,8 +8278,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -9634,8 +9623,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
},
@@ -9657,8 +9645,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
},
@@ -9680,8 +9667,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
}
@@ -13104,16 +13090,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -18128,7 +18107,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -18149,7 +18128,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -20458,11 +20437,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -20474,20 +20449,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -20571,7 +20532,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -20597,7 +20558,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -20663,10 +20624,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -22687,10 +22646,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -22726,10 +22684,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -22848,11 +22805,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -23504,7 +23460,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -24302,7 +24258,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -24407,7 +24362,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-31ab641e";
var ReactVersion = "18.3.0-www-classic-e35cd90b";
// Might add PROFILE later.
@@ -24515,8 +24470,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -24680,7 +24634,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -24701,7 +24655,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -24722,7 +24676,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -24737,7 +24691,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24751,7 +24705,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24765,7 +24719,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24773,7 +24727,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -1681,7 +1681,7 @@ function createLaneMap(initial) {
return laneMap;
}
function markRootUpdated(root, updateLane, eventTime) {
function markRootUpdated(root, updateLane) {
root.pendingLanes |= updateLane; // If there are any suspended transitions, it's possible this new update
// could unblock them. Clear the suspended lanes so that we can try rendering
// them again.
@@ -1699,12 +1699,6 @@ function markRootUpdated(root, updateLane, eventTime) {
root.suspendedLanes = NoLanes;
root.pingedLanes = NoLanes;
}
var eventTimes = root.eventTimes;
var index = laneToIndex(updateLane); // We can always overwrite an existing timestamp because we prefer the most
// recent event, and we assume time is monotonically increasing.
eventTimes[index] = eventTime;
}
function markRootSuspended$1(root, suspendedLanes) {
root.suspendedLanes |= suspendedLanes;
@@ -1737,7 +1731,6 @@ function markRootFinished(root, remainingLanes) {
root.entangledLanes &= remainingLanes;
root.errorRecoveryDisabledLanes &= remainingLanes;
var entanglements = root.entanglements;
var eventTimes = root.eventTimes;
var expirationTimes = root.expirationTimes;
var hiddenUpdates = root.hiddenUpdates; // Clear the lanes that no longer have pending work
@@ -1747,7 +1740,6 @@ function markRootFinished(root, remainingLanes) {
var index = pickArbitraryLaneIndex(lanes);
var lane = 1 << index;
entanglements[index] = NoLanes;
eventTimes[index] = NoTimestamp;
expirationTimes[index] = NoTimestamp;
var hiddenUpdatesForLane = hiddenUpdates[index];
@@ -7643,7 +7635,7 @@ function forceStoreRerender(fiber) {
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -8151,8 +8143,7 @@ function refreshCache(fiber, seedKey, seedValue) {
var root = enqueueUpdate(provider, refreshUpdate, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, provider, lane, eventTime);
scheduleUpdateOnFiber(root, provider, lane);
entangleTransitions(root, provider, lane);
} // TODO: If a refresh never commits, the new cache created here must be
// released. A simple case is start refreshing a cache boundary, but then
@@ -8206,8 +8197,7 @@ function dispatchReducerAction(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -8288,8 +8278,7 @@ function dispatchSetState(fiber, queue, action) {
var root = enqueueConcurrentHookUpdate(fiber, queue, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitionUpdate(root, queue, lane);
}
}
@@ -9634,8 +9623,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
},
@@ -9657,8 +9645,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
},
@@ -9680,8 +9667,7 @@ var classComponentUpdater = {
var root = enqueueUpdate(fiber, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, fiber, lane, eventTime);
scheduleUpdateOnFiber(root, fiber, lane);
entangleTransitions(root, fiber, lane);
}
}
@@ -13104,16 +13090,9 @@ function updateDehydratedSuspenseComponent(
// Intentionally mutating since this render will get interrupted. This
// is one of the very rare times where we mutate the current tree
// during the render phase.
suspenseState.retryLane = attemptHydrationAtLane; // TODO: Ideally this would inherit the event time of the current render
var eventTime = NoTimestamp;
suspenseState.retryLane = attemptHydrationAtLane;
enqueueConcurrentRenderForLane(current, attemptHydrationAtLane);
scheduleUpdateOnFiber(
root,
current,
attemptHydrationAtLane,
eventTime
); // Throw a special object that signals to the work loop that it should
scheduleUpdateOnFiber(root, current, attemptHydrationAtLane); // Throw a special object that signals to the work loop that it should
// interrupt the current render.
//
// Because we're inside a React-only execution stack, we don't
@@ -18128,7 +18107,7 @@ function detachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility |= OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
function attachOffscreenInstance(instance) {
@@ -18149,7 +18128,7 @@ function attachOffscreenInstance(instance) {
if (root !== null) {
instance._pendingVisibility &= ~OffscreenDetached;
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -20458,11 +20437,7 @@ var isFlushingPassiveEffects = false;
var didScheduleUpdateDuringPassiveEffects = false;
var NESTED_PASSIVE_UPDATE_LIMIT = 50;
var nestedPassiveUpdateCount = 0;
var rootWithPassiveNestedUpdates = null; // If two updates are scheduled within the same event, we should treat their
// event times as simultaneous, even if the actual clock time has advanced
// between the first and second call.
var currentEventTime = NoTimestamp;
var rootWithPassiveNestedUpdates = null;
var currentEventTransitionLane = NoLanes;
var isRunningInsertionEffect = false;
function getWorkInProgressRoot() {
@@ -20474,20 +20449,6 @@ function getWorkInProgressRootRenderLanes() {
function isWorkLoopSuspendedOnData() {
return workInProgressSuspendedReason === SuspendedOnData;
}
function requestEventTime() {
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
// We're inside React, so it's fine to read the actual time.
return now$1();
} // We're not inside React, so we may be in the middle of a browser event.
if (currentEventTime !== NoTimestamp) {
// Use the same start time for all updates until we enter React again.
return currentEventTime;
} // This is the first update since React yielded. Compute a new start time.
currentEventTime = now$1();
return currentEventTime;
}
function requestUpdateLane(fiber) {
// Special cases
var mode = fiber.mode;
@@ -20571,7 +20532,7 @@ function requestRetryLane(fiber) {
return claimNextRetryLane();
}
function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
function scheduleUpdateOnFiber(root, fiber, lane) {
{
if (isRunningInsertionEffect) {
error("useInsertionEffect must not schedule updates.");
@@ -20597,7 +20558,7 @@ function scheduleUpdateOnFiber(root, fiber, lane, eventTime) {
markRootSuspended(root, workInProgressRootRenderLanes);
} // Mark that the root has a pending update.
markRootUpdated(root, lane, eventTime);
markRootUpdated(root, lane);
if (
(executionContext & RenderContext) !== NoLanes &&
@@ -20663,10 +20624,8 @@ function isUnsafeClassRenderPhaseUpdate(fiber) {
function performConcurrentWorkOnRoot(root, didTimeout) {
{
resetNestedUpdateFlag();
} // Since we know we're in a React event, we can clear the current
// event time. The next update will compute a new event time.
}
currentEventTime = NoTimestamp;
currentEventTransitionLane = NoLanes;
if ((executionContext & (RenderContext | CommitContext)) !== NoContext) {
@@ -22687,10 +22646,9 @@ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
var errorInfo = createCapturedValueAtFiber(error, sourceFiber);
var update = createRootErrorUpdate(rootFiber, errorInfo, SyncLane);
var root = enqueueUpdate(rootFiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
}
@@ -22726,10 +22684,9 @@ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error$1) {
var errorInfo = createCapturedValueAtFiber(error$1, sourceFiber);
var update = createClassErrorUpdate(fiber, errorInfo, SyncLane);
var root = enqueueUpdate(fiber, update, SyncLane);
var eventTime = requestEventTime();
if (root !== null) {
markRootUpdated(root, SyncLane, eventTime);
markRootUpdated(root, SyncLane);
ensureRootIsScheduled(root);
}
@@ -22848,11 +22805,10 @@ function retryTimedOutBoundary(boundaryFiber, retryLane) {
retryLane = requestRetryLane(boundaryFiber);
} // TODO: Special case idle priority?
var eventTime = requestEventTime();
var root = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
if (root !== null) {
markRootUpdated(root, retryLane, eventTime);
markRootUpdated(root, retryLane);
ensureRootIsScheduled(root);
}
}
@@ -23504,7 +23460,7 @@ function scheduleFibersWithFamiliesRecursively(
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
@@ -24302,7 +24258,6 @@ function FiberRootNode(
this.next = null;
this.callbackNode = null;
this.callbackPriority = NoLane;
this.eventTimes = createLaneMap(NoLanes);
this.expirationTimes = createLaneMap(NoTimestamp);
this.pendingLanes = NoLanes;
this.suspendedLanes = NoLanes;
@@ -24407,7 +24362,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-d66c88c7";
var ReactVersion = "18.3.0-www-modern-c910362f";
// Might add PROFILE later.
@@ -24515,8 +24470,7 @@ function updateContainer(element, container, parentComponent, callback) {
var root = enqueueUpdate(current$1, update, lane);
if (root !== null) {
var eventTime = requestEventTime();
scheduleUpdateOnFiber(root, current$1, lane, eventTime);
scheduleUpdateOnFiber(root, current$1, lane);
entangleTransitions(root, current$1, lane);
}
@@ -24680,7 +24634,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -24701,7 +24655,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
};
@@ -24722,7 +24676,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
}
}; // Support DevTools props for function components, forwardRef, memo, host components, etc.
@@ -24737,7 +24691,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24751,7 +24705,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24765,7 +24719,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};
@@ -24773,7 +24727,7 @@ var setSuspenseHandler = null;
var root = enqueueConcurrentRenderForLane(fiber, SyncLane);
if (root !== null) {
scheduleUpdateOnFiber(root, fiber, SyncLane, NoTimestamp);
scheduleUpdateOnFiber(root, fiber, SyncLane);
}
};