react 19.3.0-canary-4fdf7cf2-20251003 → 19.3.0-canary-a4eb2dfa-20251006

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.
@@ -31,6 +31,8 @@
31
31
  return "SuspenseList";
32
32
  case REACT_ACTIVITY_TYPE:
33
33
  return "Activity";
34
+ case REACT_VIEW_TRANSITION_TYPE:
35
+ return "ViewTransition";
34
36
  }
35
37
  if ("object" === typeof type)
36
38
  switch (
@@ -297,6 +299,7 @@
297
299
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
298
300
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
299
301
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
302
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
300
303
  REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
301
304
  ReactSharedInternals =
302
305
  React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
@@ -31,6 +31,8 @@
31
31
  return "SuspenseList";
32
32
  case REACT_ACTIVITY_TYPE:
33
33
  return "Activity";
34
+ case REACT_VIEW_TRANSITION_TYPE:
35
+ return "ViewTransition";
34
36
  }
35
37
  if ("object" === typeof type)
36
38
  switch (
@@ -297,6 +299,7 @@
297
299
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
298
300
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
299
301
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
302
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
300
303
  REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
301
304
  ReactSharedInternalsServer =
302
305
  React.__SERVER_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
@@ -31,6 +31,8 @@
31
31
  return "SuspenseList";
32
32
  case REACT_ACTIVITY_TYPE:
33
33
  return "Activity";
34
+ case REACT_VIEW_TRANSITION_TYPE:
35
+ return "ViewTransition";
34
36
  }
35
37
  if ("object" === typeof type)
36
38
  switch (
@@ -297,6 +299,7 @@
297
299
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
298
300
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
299
301
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
302
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
300
303
  REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
301
304
  ReactSharedInternals =
302
305
  React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
@@ -31,6 +31,8 @@
31
31
  return "SuspenseList";
32
32
  case REACT_ACTIVITY_TYPE:
33
33
  return "Activity";
34
+ case REACT_VIEW_TRANSITION_TYPE:
35
+ return "ViewTransition";
34
36
  }
35
37
  if ("object" === typeof type)
36
38
  switch (
@@ -297,6 +299,7 @@
297
299
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
298
300
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
299
301
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
302
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
300
303
  REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
301
304
  ReactSharedInternalsServer =
302
305
  React.__SERVER_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
@@ -105,6 +105,8 @@
105
105
  return "SuspenseList";
106
106
  case REACT_ACTIVITY_TYPE:
107
107
  return "Activity";
108
+ case REACT_VIEW_TRANSITION_TYPE:
109
+ return "ViewTransition";
108
110
  }
109
111
  if ("object" === typeof type)
110
112
  switch (
@@ -523,6 +525,60 @@
523
525
  function releaseAsyncTransition() {
524
526
  ReactSharedInternals.asyncTransitions--;
525
527
  }
528
+ function startTransition(scope) {
529
+ var prevTransition = ReactSharedInternals.T,
530
+ currentTransition = {};
531
+ currentTransition.types =
532
+ null !== prevTransition ? prevTransition.types : null;
533
+ currentTransition._updatedFibers = new Set();
534
+ ReactSharedInternals.T = currentTransition;
535
+ try {
536
+ var returnValue = scope(),
537
+ onStartTransitionFinish = ReactSharedInternals.S;
538
+ null !== onStartTransitionFinish &&
539
+ onStartTransitionFinish(currentTransition, returnValue);
540
+ "object" === typeof returnValue &&
541
+ null !== returnValue &&
542
+ "function" === typeof returnValue.then &&
543
+ (ReactSharedInternals.asyncTransitions++,
544
+ returnValue.then(releaseAsyncTransition, releaseAsyncTransition),
545
+ returnValue.then(noop, reportGlobalError));
546
+ } catch (error) {
547
+ reportGlobalError(error);
548
+ } finally {
549
+ null === prevTransition &&
550
+ currentTransition._updatedFibers &&
551
+ ((scope = currentTransition._updatedFibers.size),
552
+ currentTransition._updatedFibers.clear(),
553
+ 10 < scope &&
554
+ console.warn(
555
+ "Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table."
556
+ )),
557
+ null !== prevTransition &&
558
+ null !== currentTransition.types &&
559
+ (null !== prevTransition.types &&
560
+ prevTransition.types !== currentTransition.types &&
561
+ console.error(
562
+ "We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."
563
+ ),
564
+ (prevTransition.types = currentTransition.types)),
565
+ (ReactSharedInternals.T = prevTransition);
566
+ }
567
+ }
568
+ function addTransitionType(type) {
569
+ var transition = ReactSharedInternals.T;
570
+ if (null !== transition) {
571
+ var transitionTypes = transition.types;
572
+ null === transitionTypes
573
+ ? (transition.types = [type])
574
+ : -1 === transitionTypes.indexOf(type) && transitionTypes.push(type);
575
+ } else
576
+ 0 === ReactSharedInternals.asyncTransitions &&
577
+ console.error(
578
+ "addTransitionType can only be called inside a `startTransition()` callback. It must be associated with a specific Transition."
579
+ ),
580
+ startTransition(addTransitionType.bind(null, type));
581
+ }
526
582
  function enqueueTask(task) {
527
583
  if (null === enqueueTaskImpl)
528
584
  try {
@@ -623,6 +679,7 @@
623
679
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
624
680
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
625
681
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
682
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
626
683
  MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
627
684
  didWarnStateUpdateForUnmountedComponent = {},
628
685
  ReactNoopUpdateQueue = {
@@ -800,6 +857,7 @@
800
857
  exports.PureComponent = PureComponent;
801
858
  exports.StrictMode = REACT_STRICT_MODE_TYPE;
802
859
  exports.Suspense = REACT_SUSPENSE_TYPE;
860
+ exports.ViewTransition = REACT_VIEW_TRANSITION_TYPE;
803
861
  exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
804
862
  ReactSharedInternals;
805
863
  exports.__COMPILER_RUNTIME = deprecatedAPIs;
@@ -914,6 +972,7 @@
914
972
  }
915
973
  };
916
974
  };
975
+ exports.addTransitionType = addTransitionType;
917
976
  exports.cache = function (fn) {
918
977
  return function () {
919
978
  return fn.apply(null, arguments);
@@ -1149,44 +1208,7 @@
1149
1208
  });
1150
1209
  return compare;
1151
1210
  };
1152
- exports.startTransition = function (scope) {
1153
- var prevTransition = ReactSharedInternals.T,
1154
- currentTransition = {};
1155
- currentTransition._updatedFibers = new Set();
1156
- ReactSharedInternals.T = currentTransition;
1157
- try {
1158
- var returnValue = scope(),
1159
- onStartTransitionFinish = ReactSharedInternals.S;
1160
- null !== onStartTransitionFinish &&
1161
- onStartTransitionFinish(currentTransition, returnValue);
1162
- "object" === typeof returnValue &&
1163
- null !== returnValue &&
1164
- "function" === typeof returnValue.then &&
1165
- (ReactSharedInternals.asyncTransitions++,
1166
- returnValue.then(releaseAsyncTransition, releaseAsyncTransition),
1167
- returnValue.then(noop, reportGlobalError));
1168
- } catch (error) {
1169
- reportGlobalError(error);
1170
- } finally {
1171
- null === prevTransition &&
1172
- currentTransition._updatedFibers &&
1173
- ((scope = currentTransition._updatedFibers.size),
1174
- currentTransition._updatedFibers.clear(),
1175
- 10 < scope &&
1176
- console.warn(
1177
- "Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table."
1178
- )),
1179
- null !== prevTransition &&
1180
- null !== currentTransition.types &&
1181
- (null !== prevTransition.types &&
1182
- prevTransition.types !== currentTransition.types &&
1183
- console.error(
1184
- "We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."
1185
- ),
1186
- (prevTransition.types = currentTransition.types)),
1187
- (ReactSharedInternals.T = prevTransition);
1188
- }
1189
- };
1211
+ exports.startTransition = startTransition;
1190
1212
  exports.unstable_useCacheRefresh = function () {
1191
1213
  return resolveDispatcher().useCacheRefresh();
1192
1214
  };
@@ -1276,7 +1298,7 @@
1276
1298
  exports.useTransition = function () {
1277
1299
  return resolveDispatcher().useTransition();
1278
1300
  };
1279
- exports.version = "19.3.0-canary-4fdf7cf2-20251003";
1301
+ exports.version = "19.3.0-canary-a4eb2dfa-20251006";
1280
1302
  "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
1281
1303
  "function" ===
1282
1304
  typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -21,6 +21,7 @@ var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
21
21
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
22
22
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
23
23
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
24
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
24
25
  MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
25
26
  function getIteratorFn(maybeIterable) {
26
27
  if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
@@ -281,67 +282,100 @@ function lazyInitializer(payload) {
281
282
  throw payload._result;
282
283
  }
283
284
  var reportGlobalError =
284
- "function" === typeof reportError
285
- ? reportError
286
- : function (error) {
287
- if (
288
- "object" === typeof window &&
289
- "function" === typeof window.ErrorEvent
290
- ) {
291
- var event = new window.ErrorEvent("error", {
292
- bubbles: !0,
293
- cancelable: !0,
294
- message:
295
- "object" === typeof error &&
296
- null !== error &&
297
- "string" === typeof error.message
298
- ? String(error.message)
299
- : String(error),
300
- error: error
301
- });
302
- if (!window.dispatchEvent(event)) return;
303
- } else if (
304
- "object" === typeof process &&
305
- "function" === typeof process.emit
306
- ) {
307
- process.emit("uncaughtException", error);
308
- return;
309
- }
310
- console.error(error);
311
- },
312
- Children = {
313
- map: mapChildren,
314
- forEach: function (children, forEachFunc, forEachContext) {
315
- mapChildren(
316
- children,
317
- function () {
318
- forEachFunc.apply(this, arguments);
319
- },
320
- forEachContext
321
- );
322
- },
323
- count: function (children) {
324
- var n = 0;
325
- mapChildren(children, function () {
326
- n++;
327
- });
328
- return n;
329
- },
330
- toArray: function (children) {
331
- return (
332
- mapChildren(children, function (child) {
333
- return child;
334
- }) || []
285
+ "function" === typeof reportError
286
+ ? reportError
287
+ : function (error) {
288
+ if (
289
+ "object" === typeof window &&
290
+ "function" === typeof window.ErrorEvent
291
+ ) {
292
+ var event = new window.ErrorEvent("error", {
293
+ bubbles: !0,
294
+ cancelable: !0,
295
+ message:
296
+ "object" === typeof error &&
297
+ null !== error &&
298
+ "string" === typeof error.message
299
+ ? String(error.message)
300
+ : String(error),
301
+ error: error
302
+ });
303
+ if (!window.dispatchEvent(event)) return;
304
+ } else if (
305
+ "object" === typeof process &&
306
+ "function" === typeof process.emit
307
+ ) {
308
+ process.emit("uncaughtException", error);
309
+ return;
310
+ }
311
+ console.error(error);
312
+ };
313
+ function startTransition(scope) {
314
+ var prevTransition = ReactSharedInternals.T,
315
+ currentTransition = {};
316
+ currentTransition.types =
317
+ null !== prevTransition ? prevTransition.types : null;
318
+ ReactSharedInternals.T = currentTransition;
319
+ try {
320
+ var returnValue = scope(),
321
+ onStartTransitionFinish = ReactSharedInternals.S;
322
+ null !== onStartTransitionFinish &&
323
+ onStartTransitionFinish(currentTransition, returnValue);
324
+ "object" === typeof returnValue &&
325
+ null !== returnValue &&
326
+ "function" === typeof returnValue.then &&
327
+ returnValue.then(noop, reportGlobalError);
328
+ } catch (error) {
329
+ reportGlobalError(error);
330
+ } finally {
331
+ null !== prevTransition &&
332
+ null !== currentTransition.types &&
333
+ (prevTransition.types = currentTransition.types),
334
+ (ReactSharedInternals.T = prevTransition);
335
+ }
336
+ }
337
+ function addTransitionType(type) {
338
+ var transition = ReactSharedInternals.T;
339
+ if (null !== transition) {
340
+ var transitionTypes = transition.types;
341
+ null === transitionTypes
342
+ ? (transition.types = [type])
343
+ : -1 === transitionTypes.indexOf(type) && transitionTypes.push(type);
344
+ } else startTransition(addTransitionType.bind(null, type));
345
+ }
346
+ var Children = {
347
+ map: mapChildren,
348
+ forEach: function (children, forEachFunc, forEachContext) {
349
+ mapChildren(
350
+ children,
351
+ function () {
352
+ forEachFunc.apply(this, arguments);
353
+ },
354
+ forEachContext
355
+ );
356
+ },
357
+ count: function (children) {
358
+ var n = 0;
359
+ mapChildren(children, function () {
360
+ n++;
361
+ });
362
+ return n;
363
+ },
364
+ toArray: function (children) {
365
+ return (
366
+ mapChildren(children, function (child) {
367
+ return child;
368
+ }) || []
369
+ );
370
+ },
371
+ only: function (children) {
372
+ if (!isValidElement(children))
373
+ throw Error(
374
+ "React.Children.only expected to receive a single React element child."
335
375
  );
336
- },
337
- only: function (children) {
338
- if (!isValidElement(children))
339
- throw Error(
340
- "React.Children.only expected to receive a single React element child."
341
- );
342
- return children;
343
- }
344
- };
376
+ return children;
377
+ }
378
+ };
345
379
  exports.Activity = REACT_ACTIVITY_TYPE;
346
380
  exports.Children = Children;
347
381
  exports.Component = Component;
@@ -350,6 +384,7 @@ exports.Profiler = REACT_PROFILER_TYPE;
350
384
  exports.PureComponent = PureComponent;
351
385
  exports.StrictMode = REACT_STRICT_MODE_TYPE;
352
386
  exports.Suspense = REACT_SUSPENSE_TYPE;
387
+ exports.ViewTransition = REACT_VIEW_TRANSITION_TYPE;
353
388
  exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
354
389
  ReactSharedInternals;
355
390
  exports.__COMPILER_RUNTIME = {
@@ -358,6 +393,7 @@ exports.__COMPILER_RUNTIME = {
358
393
  return ReactSharedInternals.H.useMemoCache(size);
359
394
  }
360
395
  };
396
+ exports.addTransitionType = addTransitionType;
361
397
  exports.cache = function (fn) {
362
398
  return function () {
363
399
  return fn.apply(null, arguments);
@@ -451,28 +487,7 @@ exports.memo = function (type, compare) {
451
487
  compare: void 0 === compare ? null : compare
452
488
  };
453
489
  };
454
- exports.startTransition = function (scope) {
455
- var prevTransition = ReactSharedInternals.T,
456
- currentTransition = {};
457
- ReactSharedInternals.T = currentTransition;
458
- try {
459
- var returnValue = scope(),
460
- onStartTransitionFinish = ReactSharedInternals.S;
461
- null !== onStartTransitionFinish &&
462
- onStartTransitionFinish(currentTransition, returnValue);
463
- "object" === typeof returnValue &&
464
- null !== returnValue &&
465
- "function" === typeof returnValue.then &&
466
- returnValue.then(noop, reportGlobalError);
467
- } catch (error) {
468
- reportGlobalError(error);
469
- } finally {
470
- null !== prevTransition &&
471
- null !== currentTransition.types &&
472
- (prevTransition.types = currentTransition.types),
473
- (ReactSharedInternals.T = prevTransition);
474
- }
475
- };
490
+ exports.startTransition = startTransition;
476
491
  exports.unstable_useCacheRefresh = function () {
477
492
  return ReactSharedInternals.H.useCacheRefresh();
478
493
  };
@@ -539,4 +554,4 @@ exports.useSyncExternalStore = function (
539
554
  exports.useTransition = function () {
540
555
  return ReactSharedInternals.H.useTransition();
541
556
  };
542
- exports.version = "19.3.0-canary-4fdf7cf2-20251003";
557
+ exports.version = "19.3.0-canary-a4eb2dfa-20251006";
@@ -67,6 +67,8 @@
67
67
  return "SuspenseList";
68
68
  case REACT_ACTIVITY_TYPE:
69
69
  return "Activity";
70
+ case REACT_VIEW_TRANSITION_TYPE:
71
+ return "ViewTransition";
70
72
  }
71
73
  if ("object" === typeof type)
72
74
  switch (
@@ -508,6 +510,7 @@
508
510
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
509
511
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
510
512
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
513
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
511
514
  MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
512
515
  REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"),
513
516
  hasOwnProperty = Object.prototype.hasOwnProperty,
@@ -572,6 +575,7 @@
572
575
  exports.Profiler = REACT_PROFILER_TYPE;
573
576
  exports.StrictMode = REACT_STRICT_MODE_TYPE;
574
577
  exports.Suspense = REACT_SUSPENSE_TYPE;
578
+ exports.ViewTransition = REACT_VIEW_TRANSITION_TYPE;
575
579
  exports.__SERVER_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
576
580
  ReactSharedInternals;
577
581
  exports.cache = function (fn) {
@@ -846,5 +850,5 @@
846
850
  exports.useMemo = function (create, deps) {
847
851
  return resolveDispatcher().useMemo(create, deps);
848
852
  };
849
- exports.version = "19.3.0-canary-4fdf7cf2-20251003";
853
+ exports.version = "19.3.0-canary-a4eb2dfa-20251006";
850
854
  })();
@@ -37,6 +37,7 @@ var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
37
37
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
38
38
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
39
39
  REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
40
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
40
41
  MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
41
42
  function getIteratorFn(maybeIterable) {
42
43
  if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
@@ -294,6 +295,7 @@ exports.Fragment = REACT_FRAGMENT_TYPE;
294
295
  exports.Profiler = REACT_PROFILER_TYPE;
295
296
  exports.StrictMode = REACT_STRICT_MODE_TYPE;
296
297
  exports.Suspense = REACT_SUSPENSE_TYPE;
298
+ exports.ViewTransition = REACT_VIEW_TRANSITION_TYPE;
297
299
  exports.__SERVER_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
298
300
  ReactSharedInternals;
299
301
  exports.cache = function (fn) {
@@ -423,4 +425,4 @@ exports.useId = function () {
423
425
  exports.useMemo = function (create, deps) {
424
426
  return ReactSharedInternals.H.useMemo(create, deps);
425
427
  };
426
- exports.version = "19.3.0-canary-4fdf7cf2-20251003";
428
+ exports.version = "19.3.0-canary-a4eb2dfa-20251006";
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "keywords": [
5
5
  "react"
6
6
  ],
7
- "version": "19.3.0-canary-4fdf7cf2-20251003",
7
+ "version": "19.3.0-canary-a4eb2dfa-20251006",
8
8
  "homepage": "https://react.dev/",
9
9
  "bugs": "https://github.com/facebook/react/issues",
10
10
  "license": "MIT",