react-dom 19.1.0-canary-7130d0c6-20241212 → 19.1.0-canary-e06c72fc-20241215

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -51,7 +51,6 @@ var REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element"),
51
51
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
52
52
  REACT_LAZY_TYPE = Symbol.for("react.lazy");
53
53
  Symbol.for("react.scope");
54
- Symbol.for("react.debug_trace_mode");
55
54
  var REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen");
56
55
  Symbol.for("react.legacy_hidden");
57
56
  Symbol.for("react.tracing_marker");
@@ -284,13 +283,11 @@ function describeFiber(fiber) {
284
283
  return describeBuiltInComponentFrame("SuspenseList");
285
284
  case 0:
286
285
  case 15:
287
- return (fiber = describeNativeComponentFrame(fiber.type, !1)), fiber;
286
+ return describeNativeComponentFrame(fiber.type, !1);
288
287
  case 11:
289
- return (
290
- (fiber = describeNativeComponentFrame(fiber.type.render, !1)), fiber
291
- );
288
+ return describeNativeComponentFrame(fiber.type.render, !1);
292
289
  case 1:
293
- return (fiber = describeNativeComponentFrame(fiber.type, !0)), fiber;
290
+ return describeNativeComponentFrame(fiber.type, !0);
294
291
  default:
295
292
  return "";
296
293
  }
@@ -772,6 +769,46 @@ function markRootEntangled(root, entangledLanes) {
772
769
  rootEntangledLanes &= ~lane;
773
770
  }
774
771
  }
772
+ function getBumpedLaneForHydrationByLane(lane) {
773
+ switch (lane) {
774
+ case 2:
775
+ lane = 1;
776
+ break;
777
+ case 8:
778
+ lane = 4;
779
+ break;
780
+ case 32:
781
+ lane = 16;
782
+ break;
783
+ case 128:
784
+ case 256:
785
+ case 512:
786
+ case 1024:
787
+ case 2048:
788
+ case 4096:
789
+ case 8192:
790
+ case 16384:
791
+ case 32768:
792
+ case 65536:
793
+ case 131072:
794
+ case 262144:
795
+ case 524288:
796
+ case 1048576:
797
+ case 2097152:
798
+ case 4194304:
799
+ case 8388608:
800
+ case 16777216:
801
+ case 33554432:
802
+ lane = 64;
803
+ break;
804
+ case 268435456:
805
+ lane = 134217728;
806
+ break;
807
+ default:
808
+ lane = 0;
809
+ }
810
+ return lane;
811
+ }
775
812
  function lanesToEventPriority(lanes) {
776
813
  lanes &= -lanes;
777
814
  return 2 < lanes
@@ -888,12 +925,7 @@ function registerDirectEvent(registrationName, dependencies) {
888
925
  )
889
926
  allNativeEvents.add(dependencies[registrationName]);
890
927
  }
891
- var canUseDOM = !(
892
- "undefined" === typeof window ||
893
- "undefined" === typeof window.document ||
894
- "undefined" === typeof window.document.createElement
895
- ),
896
- VALID_ATTRIBUTE_NAME_REGEX = RegExp(
928
+ var VALID_ATTRIBUTE_NAME_REGEX = RegExp(
897
929
  "^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"
898
930
  ),
899
931
  illegalAttributeNameCache = {},
@@ -1502,7 +1534,12 @@ function getListener(inst, registrationName) {
1502
1534
  );
1503
1535
  return stateNode;
1504
1536
  }
1505
- var passiveBrowserEventsSupported = !1;
1537
+ var canUseDOM = !(
1538
+ "undefined" === typeof window ||
1539
+ "undefined" === typeof window.document ||
1540
+ "undefined" === typeof window.document.createElement
1541
+ ),
1542
+ passiveBrowserEventsSupported = !1;
1506
1543
  if (canUseDOM)
1507
1544
  try {
1508
1545
  var options = {};
@@ -1989,19 +2026,19 @@ function getTargetInstForChangeEvent(domEventName, targetInst) {
1989
2026
  }
1990
2027
  var isInputEventSupported = !1;
1991
2028
  if (canUseDOM) {
1992
- var JSCompiler_inline_result$jscomp$282;
2029
+ var JSCompiler_inline_result$jscomp$279;
1993
2030
  if (canUseDOM) {
1994
- var isSupported$jscomp$inline_418 = "oninput" in document;
1995
- if (!isSupported$jscomp$inline_418) {
1996
- var element$jscomp$inline_419 = document.createElement("div");
1997
- element$jscomp$inline_419.setAttribute("oninput", "return;");
1998
- isSupported$jscomp$inline_418 =
1999
- "function" === typeof element$jscomp$inline_419.oninput;
2031
+ var isSupported$jscomp$inline_409 = "oninput" in document;
2032
+ if (!isSupported$jscomp$inline_409) {
2033
+ var element$jscomp$inline_410 = document.createElement("div");
2034
+ element$jscomp$inline_410.setAttribute("oninput", "return;");
2035
+ isSupported$jscomp$inline_409 =
2036
+ "function" === typeof element$jscomp$inline_410.oninput;
2000
2037
  }
2001
- JSCompiler_inline_result$jscomp$282 = isSupported$jscomp$inline_418;
2002
- } else JSCompiler_inline_result$jscomp$282 = !1;
2038
+ JSCompiler_inline_result$jscomp$279 = isSupported$jscomp$inline_409;
2039
+ } else JSCompiler_inline_result$jscomp$279 = !1;
2003
2040
  isInputEventSupported =
2004
- JSCompiler_inline_result$jscomp$282 &&
2041
+ JSCompiler_inline_result$jscomp$279 &&
2005
2042
  (!document.documentMode || 9 < document.documentMode);
2006
2043
  }
2007
2044
  function stopWatchingForValueChange() {
@@ -3054,10 +3091,9 @@ function updateWorkInProgressHook() {
3054
3091
  }
3055
3092
  return workInProgressHook;
3056
3093
  }
3057
- var createFunctionComponentUpdateQueue;
3058
- createFunctionComponentUpdateQueue = function () {
3094
+ function createFunctionComponentUpdateQueue() {
3059
3095
  return { lastEffect: null, events: null, stores: null, memoCache: null };
3060
- };
3096
+ }
3061
3097
  function useThenable(thenable) {
3062
3098
  var index = thenableIndexCounter$1;
3063
3099
  thenableIndexCounter$1 += 1;
@@ -3985,321 +4021,326 @@ function entangleTransitionUpdate(root, queue, lane) {
3985
4021
  }
3986
4022
  }
3987
4023
  var ContextOnlyDispatcher = {
3988
- readContext: readContext,
3989
- use: use,
3990
- useCallback: throwInvalidHookError,
3991
- useContext: throwInvalidHookError,
3992
- useEffect: throwInvalidHookError,
3993
- useImperativeHandle: throwInvalidHookError,
3994
- useLayoutEffect: throwInvalidHookError,
3995
- useInsertionEffect: throwInvalidHookError,
3996
- useMemo: throwInvalidHookError,
3997
- useReducer: throwInvalidHookError,
3998
- useRef: throwInvalidHookError,
3999
- useState: throwInvalidHookError,
4000
- useDebugValue: throwInvalidHookError,
4001
- useDeferredValue: throwInvalidHookError,
4002
- useTransition: throwInvalidHookError,
4003
- useSyncExternalStore: throwInvalidHookError,
4004
- useId: throwInvalidHookError
4005
- };
4006
- ContextOnlyDispatcher.useCacheRefresh = throwInvalidHookError;
4007
- ContextOnlyDispatcher.useMemoCache = throwInvalidHookError;
4008
- ContextOnlyDispatcher.useHostTransitionStatus = throwInvalidHookError;
4009
- ContextOnlyDispatcher.useFormState = throwInvalidHookError;
4010
- ContextOnlyDispatcher.useActionState = throwInvalidHookError;
4011
- ContextOnlyDispatcher.useOptimistic = throwInvalidHookError;
4012
- var HooksDispatcherOnMount = {
4013
- readContext: readContext,
4014
- use: use,
4015
- useCallback: function (callback, deps) {
4016
- mountWorkInProgressHook().memoizedState = [
4017
- callback,
4018
- void 0 === deps ? null : deps
4019
- ];
4020
- return callback;
4021
- },
4022
- useContext: readContext,
4023
- useEffect: mountEffect,
4024
- useImperativeHandle: function (ref, create, deps) {
4025
- deps = null !== deps && void 0 !== deps ? deps.concat([ref]) : null;
4026
- mountEffectImpl(
4027
- 4194308,
4028
- 4,
4029
- imperativeHandleEffect.bind(null, create, ref),
4030
- deps
4031
- );
4032
- },
4033
- useLayoutEffect: function (create, deps) {
4034
- return mountEffectImpl(4194308, 4, create, deps);
4035
- },
4036
- useInsertionEffect: function (create, deps) {
4037
- mountEffectImpl(4, 2, create, deps);
4038
- },
4039
- useMemo: function (nextCreate, deps) {
4040
- var hook = mountWorkInProgressHook();
4041
- deps = void 0 === deps ? null : deps;
4042
- var nextValue = nextCreate();
4043
- if (shouldDoubleInvokeUserFnsInHooksDEV) {
4044
- setIsStrictModeForDevtools(!0);
4045
- try {
4046
- nextCreate();
4047
- } finally {
4048
- setIsStrictModeForDevtools(!1);
4049
- }
4050
- }
4051
- hook.memoizedState = [nextValue, deps];
4052
- return nextValue;
4024
+ readContext: readContext,
4025
+ use: use,
4026
+ useCallback: throwInvalidHookError,
4027
+ useContext: throwInvalidHookError,
4028
+ useEffect: throwInvalidHookError,
4029
+ useImperativeHandle: throwInvalidHookError,
4030
+ useLayoutEffect: throwInvalidHookError,
4031
+ useInsertionEffect: throwInvalidHookError,
4032
+ useMemo: throwInvalidHookError,
4033
+ useReducer: throwInvalidHookError,
4034
+ useRef: throwInvalidHookError,
4035
+ useState: throwInvalidHookError,
4036
+ useDebugValue: throwInvalidHookError,
4037
+ useDeferredValue: throwInvalidHookError,
4038
+ useTransition: throwInvalidHookError,
4039
+ useSyncExternalStore: throwInvalidHookError,
4040
+ useId: throwInvalidHookError,
4041
+ useHostTransitionStatus: throwInvalidHookError,
4042
+ useFormState: throwInvalidHookError,
4043
+ useActionState: throwInvalidHookError,
4044
+ useOptimistic: throwInvalidHookError,
4045
+ useMemoCache: throwInvalidHookError,
4046
+ useCacheRefresh: throwInvalidHookError
4053
4047
  },
4054
- useReducer: function (reducer, initialArg, init) {
4055
- var hook = mountWorkInProgressHook();
4056
- if (void 0 !== init) {
4057
- var initialState = init(initialArg);
4048
+ HooksDispatcherOnMount = {
4049
+ readContext: readContext,
4050
+ use: use,
4051
+ useCallback: function (callback, deps) {
4052
+ mountWorkInProgressHook().memoizedState = [
4053
+ callback,
4054
+ void 0 === deps ? null : deps
4055
+ ];
4056
+ return callback;
4057
+ },
4058
+ useContext: readContext,
4059
+ useEffect: mountEffect,
4060
+ useImperativeHandle: function (ref, create, deps) {
4061
+ deps = null !== deps && void 0 !== deps ? deps.concat([ref]) : null;
4062
+ mountEffectImpl(
4063
+ 4194308,
4064
+ 4,
4065
+ imperativeHandleEffect.bind(null, create, ref),
4066
+ deps
4067
+ );
4068
+ },
4069
+ useLayoutEffect: function (create, deps) {
4070
+ return mountEffectImpl(4194308, 4, create, deps);
4071
+ },
4072
+ useInsertionEffect: function (create, deps) {
4073
+ mountEffectImpl(4, 2, create, deps);
4074
+ },
4075
+ useMemo: function (nextCreate, deps) {
4076
+ var hook = mountWorkInProgressHook();
4077
+ deps = void 0 === deps ? null : deps;
4078
+ var nextValue = nextCreate();
4058
4079
  if (shouldDoubleInvokeUserFnsInHooksDEV) {
4059
4080
  setIsStrictModeForDevtools(!0);
4060
4081
  try {
4061
- init(initialArg);
4082
+ nextCreate();
4062
4083
  } finally {
4063
4084
  setIsStrictModeForDevtools(!1);
4064
4085
  }
4065
4086
  }
4066
- } else initialState = initialArg;
4067
- hook.memoizedState = hook.baseState = initialState;
4068
- reducer = {
4069
- pending: null,
4070
- lanes: 0,
4071
- dispatch: null,
4072
- lastRenderedReducer: reducer,
4073
- lastRenderedState: initialState
4074
- };
4075
- hook.queue = reducer;
4076
- reducer = reducer.dispatch = dispatchReducerAction.bind(
4077
- null,
4078
- currentlyRenderingFiber$1,
4079
- reducer
4080
- );
4081
- return [hook.memoizedState, reducer];
4082
- },
4083
- useRef: function (initialValue) {
4084
- var hook = mountWorkInProgressHook();
4085
- initialValue = { current: initialValue };
4086
- return (hook.memoizedState = initialValue);
4087
- },
4088
- useState: function (initialState) {
4089
- initialState = mountStateImpl(initialState);
4090
- var queue = initialState.queue,
4091
- dispatch = dispatchSetState.bind(null, currentlyRenderingFiber$1, queue);
4092
- queue.dispatch = dispatch;
4093
- return [initialState.memoizedState, dispatch];
4094
- },
4095
- useDebugValue: mountDebugValue,
4096
- useDeferredValue: function (value, initialValue) {
4097
- var hook = mountWorkInProgressHook();
4098
- return mountDeferredValueImpl(hook, value, initialValue);
4099
- },
4100
- useTransition: function () {
4101
- var stateHook = mountStateImpl(!1);
4102
- stateHook = startTransition.bind(
4103
- null,
4104
- currentlyRenderingFiber$1,
4105
- stateHook.queue,
4106
- !0,
4107
- !1
4108
- );
4109
- mountWorkInProgressHook().memoizedState = stateHook;
4110
- return [!1, stateHook];
4111
- },
4112
- useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
4113
- var fiber = currentlyRenderingFiber$1,
4114
- hook = mountWorkInProgressHook();
4115
- if (isHydrating) {
4116
- if (void 0 === getServerSnapshot)
4117
- throw Error(formatProdErrorMessage(407));
4118
- getServerSnapshot = getServerSnapshot();
4119
- } else {
4120
- getServerSnapshot = getSnapshot();
4121
- if (null === workInProgressRoot) throw Error(formatProdErrorMessage(349));
4122
- 0 !== (workInProgressRootRenderLanes & 60) ||
4123
- pushStoreConsistencyCheck(fiber, getSnapshot, getServerSnapshot);
4124
- }
4125
- hook.memoizedState = getServerSnapshot;
4126
- var inst = { value: getServerSnapshot, getSnapshot: getSnapshot };
4127
- hook.queue = inst;
4128
- mountEffect(subscribeToStore.bind(null, fiber, inst, subscribe), [
4129
- subscribe
4130
- ]);
4131
- fiber.flags |= 2048;
4132
- pushSimpleEffect(
4133
- 9,
4134
- createEffectInstance(),
4135
- updateStoreInstance.bind(
4087
+ hook.memoizedState = [nextValue, deps];
4088
+ return nextValue;
4089
+ },
4090
+ useReducer: function (reducer, initialArg, init) {
4091
+ var hook = mountWorkInProgressHook();
4092
+ if (void 0 !== init) {
4093
+ var initialState = init(initialArg);
4094
+ if (shouldDoubleInvokeUserFnsInHooksDEV) {
4095
+ setIsStrictModeForDevtools(!0);
4096
+ try {
4097
+ init(initialArg);
4098
+ } finally {
4099
+ setIsStrictModeForDevtools(!1);
4100
+ }
4101
+ }
4102
+ } else initialState = initialArg;
4103
+ hook.memoizedState = hook.baseState = initialState;
4104
+ reducer = {
4105
+ pending: null,
4106
+ lanes: 0,
4107
+ dispatch: null,
4108
+ lastRenderedReducer: reducer,
4109
+ lastRenderedState: initialState
4110
+ };
4111
+ hook.queue = reducer;
4112
+ reducer = reducer.dispatch = dispatchReducerAction.bind(
4136
4113
  null,
4137
- fiber,
4138
- inst,
4139
- getServerSnapshot,
4140
- getSnapshot
4141
- ),
4142
- null
4143
- );
4144
- return getServerSnapshot;
4145
- },
4146
- useId: function () {
4147
- var hook = mountWorkInProgressHook(),
4148
- identifierPrefix = workInProgressRoot.identifierPrefix;
4149
- if (isHydrating) {
4150
- var JSCompiler_inline_result = treeContextOverflow;
4151
- var idWithLeadingBit = treeContextId;
4152
- JSCompiler_inline_result =
4153
- (
4154
- idWithLeadingBit & ~(1 << (32 - clz32(idWithLeadingBit) - 1))
4155
- ).toString(32) + JSCompiler_inline_result;
4156
- identifierPrefix =
4157
- ":" + identifierPrefix + "R" + JSCompiler_inline_result;
4158
- JSCompiler_inline_result = localIdCounter++;
4159
- 0 < JSCompiler_inline_result &&
4160
- (identifierPrefix += "H" + JSCompiler_inline_result.toString(32));
4161
- identifierPrefix += ":";
4162
- } else
4163
- (JSCompiler_inline_result = globalClientIdCounter++),
4164
- (identifierPrefix =
4165
- ":" +
4166
- identifierPrefix +
4167
- "r" +
4168
- JSCompiler_inline_result.toString(32) +
4169
- ":");
4170
- return (hook.memoizedState = identifierPrefix);
4171
- },
4172
- useCacheRefresh: function () {
4173
- return (mountWorkInProgressHook().memoizedState = refreshCache.bind(
4174
- null,
4175
- currentlyRenderingFiber$1
4176
- ));
4177
- }
4178
- };
4179
- HooksDispatcherOnMount.useMemoCache = useMemoCache;
4180
- HooksDispatcherOnMount.useHostTransitionStatus = useHostTransitionStatus;
4181
- HooksDispatcherOnMount.useFormState = mountActionState;
4182
- HooksDispatcherOnMount.useActionState = mountActionState;
4183
- HooksDispatcherOnMount.useOptimistic = function (passthrough) {
4184
- var hook = mountWorkInProgressHook();
4185
- hook.memoizedState = hook.baseState = passthrough;
4186
- var queue = {
4187
- pending: null,
4188
- lanes: 0,
4189
- dispatch: null,
4190
- lastRenderedReducer: null,
4191
- lastRenderedState: null
4192
- };
4193
- hook.queue = queue;
4194
- hook = dispatchOptimisticSetState.bind(
4195
- null,
4196
- currentlyRenderingFiber$1,
4197
- !0,
4198
- queue
4199
- );
4200
- queue.dispatch = hook;
4201
- return [passthrough, hook];
4202
- };
4203
- var HooksDispatcherOnUpdate = {
4204
- readContext: readContext,
4205
- use: use,
4206
- useCallback: updateCallback,
4207
- useContext: readContext,
4208
- useEffect: updateEffect,
4209
- useImperativeHandle: updateImperativeHandle,
4210
- useInsertionEffect: updateInsertionEffect,
4211
- useLayoutEffect: updateLayoutEffect,
4212
- useMemo: updateMemo,
4213
- useReducer: updateReducer,
4214
- useRef: updateRef,
4215
- useState: function () {
4216
- return updateReducer(basicStateReducer);
4217
- },
4218
- useDebugValue: mountDebugValue,
4219
- useDeferredValue: function (value, initialValue) {
4220
- var hook = updateWorkInProgressHook();
4221
- return updateDeferredValueImpl(
4222
- hook,
4223
- currentHook.memoizedState,
4224
- value,
4225
- initialValue
4226
- );
4227
- },
4228
- useTransition: function () {
4229
- var booleanOrThenable = updateReducer(basicStateReducer)[0],
4230
- start = updateWorkInProgressHook().memoizedState;
4231
- return [
4232
- "boolean" === typeof booleanOrThenable
4233
- ? booleanOrThenable
4234
- : useThenable(booleanOrThenable),
4235
- start
4236
- ];
4237
- },
4238
- useSyncExternalStore: updateSyncExternalStore,
4239
- useId: updateId
4240
- };
4241
- HooksDispatcherOnUpdate.useCacheRefresh = updateRefresh;
4242
- HooksDispatcherOnUpdate.useMemoCache = useMemoCache;
4243
- HooksDispatcherOnUpdate.useHostTransitionStatus = useHostTransitionStatus;
4244
- HooksDispatcherOnUpdate.useFormState = updateActionState;
4245
- HooksDispatcherOnUpdate.useActionState = updateActionState;
4246
- HooksDispatcherOnUpdate.useOptimistic = function (passthrough, reducer) {
4247
- var hook = updateWorkInProgressHook();
4248
- return updateOptimisticImpl(hook, currentHook, passthrough, reducer);
4249
- };
4250
- var HooksDispatcherOnRerender = {
4251
- readContext: readContext,
4252
- use: use,
4253
- useCallback: updateCallback,
4254
- useContext: readContext,
4255
- useEffect: updateEffect,
4256
- useImperativeHandle: updateImperativeHandle,
4257
- useInsertionEffect: updateInsertionEffect,
4258
- useLayoutEffect: updateLayoutEffect,
4259
- useMemo: updateMemo,
4260
- useReducer: rerenderReducer,
4261
- useRef: updateRef,
4262
- useState: function () {
4263
- return rerenderReducer(basicStateReducer);
4264
- },
4265
- useDebugValue: mountDebugValue,
4266
- useDeferredValue: function (value, initialValue) {
4267
- var hook = updateWorkInProgressHook();
4268
- return null === currentHook
4269
- ? mountDeferredValueImpl(hook, value, initialValue)
4270
- : updateDeferredValueImpl(
4271
- hook,
4272
- currentHook.memoizedState,
4273
- value,
4274
- initialValue
4114
+ currentlyRenderingFiber$1,
4115
+ reducer
4116
+ );
4117
+ return [hook.memoizedState, reducer];
4118
+ },
4119
+ useRef: function (initialValue) {
4120
+ var hook = mountWorkInProgressHook();
4121
+ initialValue = { current: initialValue };
4122
+ return (hook.memoizedState = initialValue);
4123
+ },
4124
+ useState: function (initialState) {
4125
+ initialState = mountStateImpl(initialState);
4126
+ var queue = initialState.queue,
4127
+ dispatch = dispatchSetState.bind(
4128
+ null,
4129
+ currentlyRenderingFiber$1,
4130
+ queue
4275
4131
  );
4132
+ queue.dispatch = dispatch;
4133
+ return [initialState.memoizedState, dispatch];
4134
+ },
4135
+ useDebugValue: mountDebugValue,
4136
+ useDeferredValue: function (value, initialValue) {
4137
+ var hook = mountWorkInProgressHook();
4138
+ return mountDeferredValueImpl(hook, value, initialValue);
4139
+ },
4140
+ useTransition: function () {
4141
+ var stateHook = mountStateImpl(!1);
4142
+ stateHook = startTransition.bind(
4143
+ null,
4144
+ currentlyRenderingFiber$1,
4145
+ stateHook.queue,
4146
+ !0,
4147
+ !1
4148
+ );
4149
+ mountWorkInProgressHook().memoizedState = stateHook;
4150
+ return [!1, stateHook];
4151
+ },
4152
+ useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
4153
+ var fiber = currentlyRenderingFiber$1,
4154
+ hook = mountWorkInProgressHook();
4155
+ if (isHydrating) {
4156
+ if (void 0 === getServerSnapshot)
4157
+ throw Error(formatProdErrorMessage(407));
4158
+ getServerSnapshot = getServerSnapshot();
4159
+ } else {
4160
+ getServerSnapshot = getSnapshot();
4161
+ if (null === workInProgressRoot)
4162
+ throw Error(formatProdErrorMessage(349));
4163
+ 0 !== (workInProgressRootRenderLanes & 60) ||
4164
+ pushStoreConsistencyCheck(fiber, getSnapshot, getServerSnapshot);
4165
+ }
4166
+ hook.memoizedState = getServerSnapshot;
4167
+ var inst = { value: getServerSnapshot, getSnapshot: getSnapshot };
4168
+ hook.queue = inst;
4169
+ mountEffect(subscribeToStore.bind(null, fiber, inst, subscribe), [
4170
+ subscribe
4171
+ ]);
4172
+ fiber.flags |= 2048;
4173
+ pushSimpleEffect(
4174
+ 9,
4175
+ createEffectInstance(),
4176
+ updateStoreInstance.bind(
4177
+ null,
4178
+ fiber,
4179
+ inst,
4180
+ getServerSnapshot,
4181
+ getSnapshot
4182
+ ),
4183
+ null
4184
+ );
4185
+ return getServerSnapshot;
4186
+ },
4187
+ useId: function () {
4188
+ var hook = mountWorkInProgressHook(),
4189
+ identifierPrefix = workInProgressRoot.identifierPrefix;
4190
+ if (isHydrating) {
4191
+ var JSCompiler_inline_result = treeContextOverflow;
4192
+ var idWithLeadingBit = treeContextId;
4193
+ JSCompiler_inline_result =
4194
+ (
4195
+ idWithLeadingBit & ~(1 << (32 - clz32(idWithLeadingBit) - 1))
4196
+ ).toString(32) + JSCompiler_inline_result;
4197
+ identifierPrefix =
4198
+ ":" + identifierPrefix + "R" + JSCompiler_inline_result;
4199
+ JSCompiler_inline_result = localIdCounter++;
4200
+ 0 < JSCompiler_inline_result &&
4201
+ (identifierPrefix += "H" + JSCompiler_inline_result.toString(32));
4202
+ identifierPrefix += ":";
4203
+ } else
4204
+ (JSCompiler_inline_result = globalClientIdCounter++),
4205
+ (identifierPrefix =
4206
+ ":" +
4207
+ identifierPrefix +
4208
+ "r" +
4209
+ JSCompiler_inline_result.toString(32) +
4210
+ ":");
4211
+ return (hook.memoizedState = identifierPrefix);
4212
+ },
4213
+ useHostTransitionStatus: useHostTransitionStatus,
4214
+ useFormState: mountActionState,
4215
+ useActionState: mountActionState,
4216
+ useOptimistic: function (passthrough) {
4217
+ var hook = mountWorkInProgressHook();
4218
+ hook.memoizedState = hook.baseState = passthrough;
4219
+ var queue = {
4220
+ pending: null,
4221
+ lanes: 0,
4222
+ dispatch: null,
4223
+ lastRenderedReducer: null,
4224
+ lastRenderedState: null
4225
+ };
4226
+ hook.queue = queue;
4227
+ hook = dispatchOptimisticSetState.bind(
4228
+ null,
4229
+ currentlyRenderingFiber$1,
4230
+ !0,
4231
+ queue
4232
+ );
4233
+ queue.dispatch = hook;
4234
+ return [passthrough, hook];
4235
+ },
4236
+ useMemoCache: useMemoCache,
4237
+ useCacheRefresh: function () {
4238
+ return (mountWorkInProgressHook().memoizedState = refreshCache.bind(
4239
+ null,
4240
+ currentlyRenderingFiber$1
4241
+ ));
4242
+ }
4276
4243
  },
4277
- useTransition: function () {
4278
- var booleanOrThenable = rerenderReducer(basicStateReducer)[0],
4279
- start = updateWorkInProgressHook().memoizedState;
4280
- return [
4281
- "boolean" === typeof booleanOrThenable
4282
- ? booleanOrThenable
4283
- : useThenable(booleanOrThenable),
4284
- start
4285
- ];
4244
+ HooksDispatcherOnUpdate = {
4245
+ readContext: readContext,
4246
+ use: use,
4247
+ useCallback: updateCallback,
4248
+ useContext: readContext,
4249
+ useEffect: updateEffect,
4250
+ useImperativeHandle: updateImperativeHandle,
4251
+ useInsertionEffect: updateInsertionEffect,
4252
+ useLayoutEffect: updateLayoutEffect,
4253
+ useMemo: updateMemo,
4254
+ useReducer: updateReducer,
4255
+ useRef: updateRef,
4256
+ useState: function () {
4257
+ return updateReducer(basicStateReducer);
4258
+ },
4259
+ useDebugValue: mountDebugValue,
4260
+ useDeferredValue: function (value, initialValue) {
4261
+ var hook = updateWorkInProgressHook();
4262
+ return updateDeferredValueImpl(
4263
+ hook,
4264
+ currentHook.memoizedState,
4265
+ value,
4266
+ initialValue
4267
+ );
4268
+ },
4269
+ useTransition: function () {
4270
+ var booleanOrThenable = updateReducer(basicStateReducer)[0],
4271
+ start = updateWorkInProgressHook().memoizedState;
4272
+ return [
4273
+ "boolean" === typeof booleanOrThenable
4274
+ ? booleanOrThenable
4275
+ : useThenable(booleanOrThenable),
4276
+ start
4277
+ ];
4278
+ },
4279
+ useSyncExternalStore: updateSyncExternalStore,
4280
+ useId: updateId,
4281
+ useHostTransitionStatus: useHostTransitionStatus,
4282
+ useFormState: updateActionState,
4283
+ useActionState: updateActionState,
4284
+ useOptimistic: function (passthrough, reducer) {
4285
+ var hook = updateWorkInProgressHook();
4286
+ return updateOptimisticImpl(hook, currentHook, passthrough, reducer);
4287
+ },
4288
+ useMemoCache: useMemoCache,
4289
+ useCacheRefresh: updateRefresh
4286
4290
  },
4287
- useSyncExternalStore: updateSyncExternalStore,
4288
- useId: updateId
4289
- };
4290
- HooksDispatcherOnRerender.useCacheRefresh = updateRefresh;
4291
- HooksDispatcherOnRerender.useMemoCache = useMemoCache;
4292
- HooksDispatcherOnRerender.useHostTransitionStatus = useHostTransitionStatus;
4293
- HooksDispatcherOnRerender.useFormState = rerenderActionState;
4294
- HooksDispatcherOnRerender.useActionState = rerenderActionState;
4295
- HooksDispatcherOnRerender.useOptimistic = function (passthrough, reducer) {
4296
- var hook = updateWorkInProgressHook();
4297
- if (null !== currentHook)
4298
- return updateOptimisticImpl(hook, currentHook, passthrough, reducer);
4299
- hook.baseState = passthrough;
4300
- return [passthrough, hook.queue.dispatch];
4301
- };
4302
- var thenableState = null,
4291
+ HooksDispatcherOnRerender = {
4292
+ readContext: readContext,
4293
+ use: use,
4294
+ useCallback: updateCallback,
4295
+ useContext: readContext,
4296
+ useEffect: updateEffect,
4297
+ useImperativeHandle: updateImperativeHandle,
4298
+ useInsertionEffect: updateInsertionEffect,
4299
+ useLayoutEffect: updateLayoutEffect,
4300
+ useMemo: updateMemo,
4301
+ useReducer: rerenderReducer,
4302
+ useRef: updateRef,
4303
+ useState: function () {
4304
+ return rerenderReducer(basicStateReducer);
4305
+ },
4306
+ useDebugValue: mountDebugValue,
4307
+ useDeferredValue: function (value, initialValue) {
4308
+ var hook = updateWorkInProgressHook();
4309
+ return null === currentHook
4310
+ ? mountDeferredValueImpl(hook, value, initialValue)
4311
+ : updateDeferredValueImpl(
4312
+ hook,
4313
+ currentHook.memoizedState,
4314
+ value,
4315
+ initialValue
4316
+ );
4317
+ },
4318
+ useTransition: function () {
4319
+ var booleanOrThenable = rerenderReducer(basicStateReducer)[0],
4320
+ start = updateWorkInProgressHook().memoizedState;
4321
+ return [
4322
+ "boolean" === typeof booleanOrThenable
4323
+ ? booleanOrThenable
4324
+ : useThenable(booleanOrThenable),
4325
+ start
4326
+ ];
4327
+ },
4328
+ useSyncExternalStore: updateSyncExternalStore,
4329
+ useId: updateId,
4330
+ useHostTransitionStatus: useHostTransitionStatus,
4331
+ useFormState: rerenderActionState,
4332
+ useActionState: rerenderActionState,
4333
+ useOptimistic: function (passthrough, reducer) {
4334
+ var hook = updateWorkInProgressHook();
4335
+ if (null !== currentHook)
4336
+ return updateOptimisticImpl(hook, currentHook, passthrough, reducer);
4337
+ hook.baseState = passthrough;
4338
+ return [passthrough, hook.queue.dispatch];
4339
+ },
4340
+ useMemoCache: useMemoCache,
4341
+ useCacheRefresh: updateRefresh
4342
+ },
4343
+ thenableState = null,
4303
4344
  thenableIndexCounter = 0;
4304
4345
  function unwrapThenable(thenable) {
4305
4346
  var index = thenableIndexCounter;
@@ -6068,7 +6109,7 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
6068
6109
  )
6069
6110
  return (
6070
6111
  isSuspenseInstanceFallback(nextInstance)
6071
- ? (workInProgress.lanes = 16)
6112
+ ? (workInProgress.lanes = 32)
6072
6113
  : (workInProgress.lanes = 536870912),
6073
6114
  null
6074
6115
  );
@@ -6185,59 +6226,25 @@ function updateSuspenseComponent(current, workInProgress, renderLanes) {
6185
6226
  didReceiveUpdate || JSCompiler_temp)
6186
6227
  ) {
6187
6228
  JSCompiler_temp = workInProgressRoot;
6188
- if (null !== JSCompiler_temp) {
6189
- nextProps = renderLanes & -renderLanes;
6190
- if (0 !== (nextProps & 42)) nextProps = 1;
6191
- else
6192
- switch (nextProps) {
6193
- case 2:
6194
- nextProps = 1;
6195
- break;
6196
- case 8:
6197
- nextProps = 4;
6198
- break;
6199
- case 32:
6200
- nextProps = 16;
6201
- break;
6202
- case 128:
6203
- case 256:
6204
- case 512:
6205
- case 1024:
6206
- case 2048:
6207
- case 4096:
6208
- case 8192:
6209
- case 16384:
6210
- case 32768:
6211
- case 65536:
6212
- case 131072:
6213
- case 262144:
6214
- case 524288:
6215
- case 1048576:
6216
- case 2097152:
6217
- case 4194304:
6218
- case 8388608:
6219
- case 16777216:
6220
- case 33554432:
6221
- nextProps = 64;
6222
- break;
6223
- case 268435456:
6224
- nextProps = 134217728;
6225
- break;
6226
- default:
6227
- nextProps = 0;
6228
- }
6229
- nextProps =
6229
+ if (
6230
+ null !== JSCompiler_temp &&
6231
+ ((nextProps = renderLanes & -renderLanes),
6232
+ (nextProps =
6233
+ 0 !== (nextProps & 42)
6234
+ ? 1
6235
+ : getBumpedLaneForHydrationByLane(nextProps)),
6236
+ (nextProps =
6230
6237
  0 !== (nextProps & (JSCompiler_temp.suspendedLanes | renderLanes))
6231
6238
  ? 0
6232
- : nextProps;
6233
- if (0 !== nextProps && nextProps !== JSCompiler_temp$jscomp$0.retryLane)
6234
- throw (
6235
- ((JSCompiler_temp$jscomp$0.retryLane = nextProps),
6236
- enqueueConcurrentRenderForLane(current, nextProps),
6237
- scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
6238
- SelectiveHydrationException)
6239
- );
6240
- }
6239
+ : nextProps),
6240
+ 0 !== nextProps && nextProps !== JSCompiler_temp$jscomp$0.retryLane)
6241
+ )
6242
+ throw (
6243
+ ((JSCompiler_temp$jscomp$0.retryLane = nextProps),
6244
+ enqueueConcurrentRenderForLane(current, nextProps),
6245
+ scheduleUpdateOnFiber(JSCompiler_temp, current, nextProps),
6246
+ SelectiveHydrationException)
6247
+ );
6241
6248
  "$?" === nextInstance.data || renderDidSuspendDelayIfPossible();
6242
6249
  workInProgress = retrySuspenseComponentWithoutHydrating(
6243
6250
  current,
@@ -11627,20 +11634,20 @@ function extractEvents$1(
11627
11634
  }
11628
11635
  }
11629
11636
  for (
11630
- var i$jscomp$inline_1436 = 0;
11631
- i$jscomp$inline_1436 < simpleEventPluginEvents.length;
11632
- i$jscomp$inline_1436++
11637
+ var i$jscomp$inline_1427 = 0;
11638
+ i$jscomp$inline_1427 < simpleEventPluginEvents.length;
11639
+ i$jscomp$inline_1427++
11633
11640
  ) {
11634
- var eventName$jscomp$inline_1437 =
11635
- simpleEventPluginEvents[i$jscomp$inline_1436],
11636
- domEventName$jscomp$inline_1438 =
11637
- eventName$jscomp$inline_1437.toLowerCase(),
11638
- capitalizedEvent$jscomp$inline_1439 =
11639
- eventName$jscomp$inline_1437[0].toUpperCase() +
11640
- eventName$jscomp$inline_1437.slice(1);
11641
+ var eventName$jscomp$inline_1428 =
11642
+ simpleEventPluginEvents[i$jscomp$inline_1427],
11643
+ domEventName$jscomp$inline_1429 =
11644
+ eventName$jscomp$inline_1428.toLowerCase(),
11645
+ capitalizedEvent$jscomp$inline_1430 =
11646
+ eventName$jscomp$inline_1428[0].toUpperCase() +
11647
+ eventName$jscomp$inline_1428.slice(1);
11641
11648
  registerSimpleEvent(
11642
- domEventName$jscomp$inline_1438,
11643
- "on" + capitalizedEvent$jscomp$inline_1439
11649
+ domEventName$jscomp$inline_1429,
11650
+ "on" + capitalizedEvent$jscomp$inline_1430
11644
11651
  );
11645
11652
  }
11646
11653
  registerSimpleEvent(ANIMATION_END, "onAnimationEnd");
@@ -14897,8 +14904,9 @@ function attemptExplicitHydrationTarget(queuedTarget) {
14897
14904
  queuedTarget.blockedOn = targetInst;
14898
14905
  runWithPriority(queuedTarget.priority, function () {
14899
14906
  if (13 === nearestMounted.tag) {
14900
- var lane = requestUpdateLane(),
14901
- root = enqueueConcurrentRenderForLane(nearestMounted, lane);
14907
+ var lane = requestUpdateLane();
14908
+ lane = getBumpedLaneForHydrationByLane(lane);
14909
+ var root = enqueueConcurrentRenderForLane(nearestMounted, lane);
14902
14910
  null !== root &&
14903
14911
  scheduleUpdateOnFiber(root, nearestMounted, lane);
14904
14912
  markRetryLaneIfNotHydrated(nearestMounted, lane);
@@ -15100,16 +15108,16 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) {
15100
15108
  0 === i && attemptExplicitHydrationTarget(target);
15101
15109
  }
15102
15110
  };
15103
- var isomorphicReactPackageVersion$jscomp$inline_1683 = React.version;
15111
+ var isomorphicReactPackageVersion$jscomp$inline_1674 = React.version;
15104
15112
  if (
15105
- "19.1.0-canary-7130d0c6-20241212" !==
15106
- isomorphicReactPackageVersion$jscomp$inline_1683
15113
+ "19.1.0-canary-e06c72fc-20241215" !==
15114
+ isomorphicReactPackageVersion$jscomp$inline_1674
15107
15115
  )
15108
15116
  throw Error(
15109
15117
  formatProdErrorMessage(
15110
15118
  527,
15111
- isomorphicReactPackageVersion$jscomp$inline_1683,
15112
- "19.1.0-canary-7130d0c6-20241212"
15119
+ isomorphicReactPackageVersion$jscomp$inline_1674,
15120
+ "19.1.0-canary-e06c72fc-20241215"
15113
15121
  )
15114
15122
  );
15115
15123
  ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
@@ -15129,24 +15137,24 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
15129
15137
  null === componentOrElement ? null : componentOrElement.stateNode;
15130
15138
  return componentOrElement;
15131
15139
  };
15132
- var internals$jscomp$inline_2159 = {
15140
+ var internals$jscomp$inline_2150 = {
15133
15141
  bundleType: 0,
15134
- version: "19.1.0-canary-7130d0c6-20241212",
15142
+ version: "19.1.0-canary-e06c72fc-20241215",
15135
15143
  rendererPackageName: "react-dom",
15136
15144
  currentDispatcherRef: ReactSharedInternals,
15137
- reconcilerVersion: "19.1.0-canary-7130d0c6-20241212"
15145
+ reconcilerVersion: "19.1.0-canary-e06c72fc-20241215"
15138
15146
  };
15139
15147
  if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
15140
- var hook$jscomp$inline_2160 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
15148
+ var hook$jscomp$inline_2151 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
15141
15149
  if (
15142
- !hook$jscomp$inline_2160.isDisabled &&
15143
- hook$jscomp$inline_2160.supportsFiber
15150
+ !hook$jscomp$inline_2151.isDisabled &&
15151
+ hook$jscomp$inline_2151.supportsFiber
15144
15152
  )
15145
15153
  try {
15146
- (rendererID = hook$jscomp$inline_2160.inject(
15147
- internals$jscomp$inline_2159
15154
+ (rendererID = hook$jscomp$inline_2151.inject(
15155
+ internals$jscomp$inline_2150
15148
15156
  )),
15149
- (injectedHook = hook$jscomp$inline_2160);
15157
+ (injectedHook = hook$jscomp$inline_2151);
15150
15158
  } catch (err) {}
15151
15159
  }
15152
15160
  exports.createRoot = function (container, options) {
@@ -15228,14 +15236,16 @@ exports.hydrateRoot = function (container, initialChildren, options) {
15228
15236
  initialChildren.context = getContextForSubtree(null);
15229
15237
  options = initialChildren.current;
15230
15238
  isStrictMode = requestUpdateLane();
15239
+ isStrictMode = getBumpedLaneForHydrationByLane(isStrictMode);
15231
15240
  identifierPrefix = createUpdate(isStrictMode);
15232
15241
  identifierPrefix.callback = null;
15233
15242
  enqueueUpdate(options, identifierPrefix, isStrictMode);
15234
- initialChildren.current.lanes = isStrictMode;
15235
- markRootUpdated$1(initialChildren, isStrictMode);
15243
+ options = isStrictMode;
15244
+ initialChildren.current.lanes = options;
15245
+ markRootUpdated$1(initialChildren, options);
15236
15246
  ensureRootIsScheduled(initialChildren);
15237
15247
  container[internalContainerInstanceKey] = initialChildren.current;
15238
15248
  listenToAllSupportedEvents(container);
15239
15249
  return new ReactDOMHydrationRoot(initialChildren);
15240
15250
  };
15241
- exports.version = "19.1.0-canary-7130d0c6-20241212";
15251
+ exports.version = "19.1.0-canary-e06c72fc-20241215";