react-dom 19.0.0-rc-100dfd7dab-20240701 → 19.0.0-rc-3da26163a3-20240704

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.
@@ -5366,6 +5366,9 @@ function getStackByComponentStackNode(componentStack) {
5366
5366
  !0
5367
5367
  );
5368
5368
  info = JSCompiler_temp_const + JSCompiler_inline_result$jscomp$0;
5369
+ break;
5370
+ case 3:
5371
+ info += describeBuiltInComponentFrame(componentStack.type);
5369
5372
  }
5370
5373
  componentStack = componentStack.parent;
5371
5374
  } while (componentStack);
@@ -5470,7 +5473,6 @@ function RequestInstance(
5470
5473
  abortSet,
5471
5474
  null,
5472
5475
  rootFormatContext,
5473
- emptyContextObject,
5474
5476
  null,
5475
5477
  emptyTreeContext,
5476
5478
  null,
@@ -5546,7 +5548,6 @@ function createRenderTask(
5546
5548
  abortSet,
5547
5549
  keyPath,
5548
5550
  formatContext,
5549
- legacyContext,
5550
5551
  context,
5551
5552
  treeContext,
5552
5553
  componentStack,
@@ -5569,7 +5570,6 @@ function createRenderTask(
5569
5570
  abortSet: abortSet,
5570
5571
  keyPath: keyPath,
5571
5572
  formatContext: formatContext,
5572
- legacyContext: legacyContext,
5573
5573
  context: context,
5574
5574
  treeContext: treeContext,
5575
5575
  componentStack: componentStack,
@@ -5590,7 +5590,6 @@ function createReplayTask(
5590
5590
  abortSet,
5591
5591
  keyPath,
5592
5592
  formatContext,
5593
- legacyContext,
5594
5593
  context,
5595
5594
  treeContext,
5596
5595
  componentStack,
@@ -5614,7 +5613,6 @@ function createReplayTask(
5614
5613
  abortSet: abortSet,
5615
5614
  keyPath: keyPath,
5616
5615
  formatContext: formatContext,
5617
- legacyContext: legacyContext,
5618
5616
  context: context,
5619
5617
  treeContext: treeContext,
5620
5618
  componentStack: componentStack,
@@ -5668,8 +5666,37 @@ function createFunctionComponentStack(task, type, owner, stack) {
5668
5666
  stack: stack
5669
5667
  };
5670
5668
  }
5671
- function getThrownInfo(request, node) {
5672
- return node ? { componentStack: getStackByComponentStackNode(node) } : {};
5669
+ function pushServerComponentStack(task, debugInfo) {
5670
+ if (null != debugInfo)
5671
+ for (var i = 0; i < debugInfo.length; i++) {
5672
+ var componentInfo = debugInfo[i];
5673
+ if ("string" === typeof componentInfo.name) {
5674
+ var name = componentInfo.name,
5675
+ env = componentInfo.env;
5676
+ env && (name += " (" + env + ")");
5677
+ task.componentStack = {
5678
+ tag: 3,
5679
+ parent: task.componentStack,
5680
+ type: name,
5681
+ owner: componentInfo.owner,
5682
+ stack: componentInfo.stack
5683
+ };
5684
+ }
5685
+ }
5686
+ }
5687
+ function getThrownInfo(node) {
5688
+ var errorInfo = {};
5689
+ node &&
5690
+ Object.defineProperty(errorInfo, "componentStack", {
5691
+ configurable: !0,
5692
+ enumerable: !0,
5693
+ get: function () {
5694
+ var stack = getStackByComponentStackNode(node);
5695
+ Object.defineProperty(errorInfo, "componentStack", { value: stack });
5696
+ return stack;
5697
+ }
5698
+ });
5699
+ return errorInfo;
5673
5700
  }
5674
5701
  function encodeErrorForBoundary(
5675
5702
  boundary,
@@ -5694,19 +5721,20 @@ function encodeErrorForBoundary(
5694
5721
  boundary.errorComponentStack = thrownInfo.componentStack;
5695
5722
  }
5696
5723
  function logRecoverableError(request, error$1, errorInfo) {
5697
- request = request.onError(error$1, errorInfo);
5698
- if (null != request && "string" !== typeof request)
5724
+ request = request.onError;
5725
+ error$1 = request(error$1, errorInfo);
5726
+ if (null != error$1 && "string" !== typeof error$1)
5699
5727
  error(
5700
5728
  'onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "%s" instead',
5701
- typeof request
5729
+ typeof error$1
5702
5730
  );
5703
- else return request;
5731
+ else return error$1;
5704
5732
  }
5705
5733
  function fatalError(request, error) {
5706
- var onShellError = request.onShellError;
5707
- onShellError(error);
5708
- onShellError = request.onFatalError;
5734
+ var onShellError = request.onShellError,
5735
+ onFatalError = request.onFatalError;
5709
5736
  onShellError(error);
5737
+ onFatalError(error);
5710
5738
  null !== request.destination
5711
5739
  ? ((request.status = 2), closeWithError(request.destination, error))
5712
5740
  : ((request.status = 1), (request.fatalError = error));
@@ -6378,7 +6406,7 @@ function renderElement(request, task, keyPath, type, props, ref, owner, stack) {
6378
6406
  } catch (error$2) {
6379
6407
  contentRootSegment.status = 4;
6380
6408
  newBoundary.status = CLIENT_RENDERED;
6381
- var thrownInfo = getThrownInfo(request, task.componentStack);
6409
+ var thrownInfo = getThrownInfo(task.componentStack);
6382
6410
  var errorDigest = logRecoverableError(request, error$2, thrownInfo);
6383
6411
  encodeErrorForBoundary(
6384
6412
  newBoundary,
@@ -6424,7 +6452,6 @@ function renderElement(request, task, keyPath, type, props, ref, owner, stack) {
6424
6452
  fallbackAbortSet,
6425
6453
  fallbackKeyPath,
6426
6454
  task.formatContext,
6427
- task.legacyContext,
6428
6455
  task.context,
6429
6456
  task.treeContext,
6430
6457
  suspenseComponentStack,
@@ -6627,211 +6654,208 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
6627
6654
  props = node$jscomp$0.props,
6628
6655
  refProp = props.ref;
6629
6656
  var ref = void 0 !== refProp ? refProp : null;
6630
- refProp = node$jscomp$0._owner;
6657
+ var owner = node$jscomp$0._owner;
6658
+ refProp = task.componentStack;
6659
+ pushServerComponentStack(task, node$jscomp$0._debugInfo);
6631
6660
  var name = getComponentNameFromType(type),
6632
6661
  keyOrIndex =
6633
6662
  null == key ? (-1 === childIndex ? 0 : childIndex) : key;
6634
6663
  key = [task.keyPath, name, keyOrIndex];
6635
- if (null !== task.replay)
6636
- a: {
6637
- var replay = task.replay;
6638
- childIndex = replay.nodes;
6639
- for (
6640
- node$jscomp$0 = 0;
6641
- node$jscomp$0 < childIndex.length;
6642
- node$jscomp$0++
6643
- ) {
6644
- var node = childIndex[node$jscomp$0];
6645
- if (keyOrIndex === node[1]) {
6646
- if (4 === node.length) {
6647
- if (null !== name && name !== node[0])
6664
+ if (null !== task.replay) {
6665
+ var replay = task.replay;
6666
+ node$jscomp$0 = replay.nodes;
6667
+ for (
6668
+ childIndex = 0;
6669
+ childIndex < node$jscomp$0.length;
6670
+ childIndex++
6671
+ ) {
6672
+ var node = node$jscomp$0[childIndex];
6673
+ if (keyOrIndex === node[1]) {
6674
+ if (4 === node.length) {
6675
+ if (null !== name && name !== node[0])
6676
+ throw Error(
6677
+ "Expected the resume to render <" +
6678
+ node[0] +
6679
+ "> in this slot but instead it rendered <" +
6680
+ name +
6681
+ ">. The tree doesn't match so React will fallback to client rendering."
6682
+ );
6683
+ var childNodes = node[2];
6684
+ name = node[3];
6685
+ keyOrIndex = task.node;
6686
+ task.replay = {
6687
+ nodes: childNodes,
6688
+ slots: name,
6689
+ pendingTasks: 1
6690
+ };
6691
+ try {
6692
+ renderElement(
6693
+ request,
6694
+ task,
6695
+ key,
6696
+ type,
6697
+ props,
6698
+ ref,
6699
+ owner,
6700
+ null
6701
+ );
6702
+ if (
6703
+ 1 === task.replay.pendingTasks &&
6704
+ 0 < task.replay.nodes.length
6705
+ )
6648
6706
  throw Error(
6649
- "Expected the resume to render <" +
6650
- node[0] +
6651
- "> in this slot but instead it rendered <" +
6652
- name +
6653
- ">. The tree doesn't match so React will fallback to client rendering."
6707
+ "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
6654
6708
  );
6655
- var childNodes = node[2];
6709
+ task.replay.pendingTasks--;
6710
+ } catch (x) {
6711
+ if (
6712
+ "object" === typeof x &&
6713
+ null !== x &&
6714
+ (x === SuspenseException || "function" === typeof x.then)
6715
+ )
6716
+ throw (
6717
+ (task.node === keyOrIndex && (task.replay = replay), x)
6718
+ );
6719
+ task.replay.pendingTasks--;
6720
+ owner = getThrownInfo(task.componentStack);
6721
+ erroredReplay(
6722
+ request,
6723
+ task.blockedBoundary,
6724
+ x,
6725
+ owner,
6726
+ childNodes,
6727
+ name
6728
+ );
6729
+ }
6730
+ task.replay = replay;
6731
+ } else {
6732
+ if (type !== REACT_SUSPENSE_TYPE)
6733
+ throw Error(
6734
+ "Expected the resume to render <Suspense> in this slot but instead it rendered <" +
6735
+ (getComponentNameFromType(type) || "Unknown") +
6736
+ ">. The tree doesn't match so React will fallback to client rendering."
6737
+ );
6738
+ a: {
6739
+ type = void 0;
6740
+ ref = task;
6741
+ var props$jscomp$0 = props;
6742
+ props = node[5];
6743
+ replay = node[2];
6656
6744
  name = node[3];
6657
- node = task.node;
6658
- task.replay = {
6659
- nodes: childNodes,
6745
+ keyOrIndex = null === node[4] ? [] : node[4][2];
6746
+ node = null === node[4] ? null : node[4][3];
6747
+ var previousComponentStack = ref.componentStack;
6748
+ owner = ref.componentStack = createBuiltInComponentStack(
6749
+ ref,
6750
+ "Suspense",
6751
+ owner,
6752
+ null
6753
+ );
6754
+ var prevKeyPath = ref.keyPath,
6755
+ previousReplaySet = ref.replay,
6756
+ parentBoundary = ref.blockedBoundary,
6757
+ parentHoistableState = ref.hoistableState,
6758
+ content = props$jscomp$0.children;
6759
+ props$jscomp$0 = props$jscomp$0.fallback;
6760
+ var fallbackAbortSet = new Set(),
6761
+ resumedBoundary = createSuspenseBoundary(
6762
+ request,
6763
+ fallbackAbortSet
6764
+ );
6765
+ resumedBoundary.parentFlushed = !0;
6766
+ resumedBoundary.rootSegmentID = props;
6767
+ ref.blockedBoundary = resumedBoundary;
6768
+ ref.hoistableState = resumedBoundary.contentState;
6769
+ ref.replay = {
6770
+ nodes: replay,
6660
6771
  slots: name,
6661
6772
  pendingTasks: 1
6662
6773
  };
6663
6774
  try {
6664
- renderElement(
6665
- request,
6666
- task,
6667
- key,
6668
- type,
6669
- props,
6670
- ref,
6671
- refProp,
6672
- null
6673
- );
6775
+ renderNode(request, ref, content, -1);
6674
6776
  if (
6675
- 1 === task.replay.pendingTasks &&
6676
- 0 < task.replay.nodes.length
6777
+ 1 === ref.replay.pendingTasks &&
6778
+ 0 < ref.replay.nodes.length
6677
6779
  )
6678
6780
  throw Error(
6679
6781
  "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
6680
6782
  );
6681
- task.replay.pendingTasks--;
6682
- } catch (x) {
6783
+ ref.replay.pendingTasks--;
6683
6784
  if (
6684
- "object" === typeof x &&
6685
- null !== x &&
6686
- (x === SuspenseException ||
6687
- "function" === typeof x.then)
6688
- )
6689
- throw (task.node === node && (task.replay = replay), x);
6690
- task.replay.pendingTasks--;
6691
- refProp = getThrownInfo(request, task.componentStack);
6692
- erroredReplay(
6693
- request,
6694
- task.blockedBoundary,
6695
- x,
6696
- refProp,
6697
- childNodes,
6698
- name
6699
- );
6700
- }
6701
- task.replay = replay;
6702
- } else {
6703
- if (type !== REACT_SUSPENSE_TYPE)
6704
- throw Error(
6705
- "Expected the resume to render <Suspense> in this slot but instead it rendered <" +
6706
- (getComponentNameFromType(type) || "Unknown") +
6707
- ">. The tree doesn't match so React will fallback to client rendering."
6708
- );
6709
- b: {
6710
- type = void 0;
6711
- ref = key;
6712
- var props$jscomp$0 = props;
6713
- props = node[5];
6714
- key = node[2];
6715
- replay = node[3];
6716
- name = null === node[4] ? [] : node[4][2];
6717
- node = null === node[4] ? null : node[4][3];
6718
- keyOrIndex = task.componentStack;
6719
- refProp = task.componentStack =
6720
- createBuiltInComponentStack(
6721
- task,
6722
- "Suspense",
6723
- refProp,
6724
- null
6725
- );
6726
- var prevKeyPath = task.keyPath,
6727
- previousReplaySet = task.replay,
6728
- parentBoundary = task.blockedBoundary,
6729
- parentHoistableState = task.hoistableState,
6730
- content = props$jscomp$0.children;
6731
- props$jscomp$0 = props$jscomp$0.fallback;
6732
- var fallbackAbortSet = new Set(),
6733
- resumedBoundary = createSuspenseBoundary(
6734
- request,
6735
- fallbackAbortSet
6736
- );
6737
- resumedBoundary.parentFlushed = !0;
6738
- resumedBoundary.rootSegmentID = props;
6739
- task.blockedBoundary = resumedBoundary;
6740
- task.hoistableState = resumedBoundary.contentState;
6741
- task.replay = {
6742
- nodes: key,
6743
- slots: replay,
6744
- pendingTasks: 1
6745
- };
6746
- try {
6747
- renderNode(request, task, content, -1);
6748
- if (
6749
- 1 === task.replay.pendingTasks &&
6750
- 0 < task.replay.nodes.length
6751
- )
6752
- throw Error(
6753
- "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
6754
- );
6755
- task.replay.pendingTasks--;
6756
- if (
6757
- 0 === resumedBoundary.pendingTasks &&
6758
- resumedBoundary.status === PENDING
6759
- ) {
6760
- resumedBoundary.status = COMPLETED;
6761
- request.completedBoundaries.push(resumedBoundary);
6762
- break b;
6763
- }
6764
- } catch (error$3) {
6765
- (resumedBoundary.status = CLIENT_RENDERED),
6766
- (childNodes = getThrownInfo(
6767
- request,
6768
- task.componentStack
6769
- )),
6770
- (type = logRecoverableError(
6771
- request,
6772
- error$3,
6773
- childNodes
6774
- )),
6775
- encodeErrorForBoundary(
6776
- resumedBoundary,
6777
- type,
6778
- error$3,
6779
- childNodes,
6780
- !1
6781
- ),
6782
- task.replay.pendingTasks--,
6783
- request.clientRenderedBoundaries.push(
6784
- resumedBoundary
6785
- );
6786
- } finally {
6787
- (task.blockedBoundary = parentBoundary),
6788
- (task.hoistableState = parentHoistableState),
6789
- (task.replay = previousReplaySet),
6790
- (task.keyPath = prevKeyPath),
6791
- (task.componentStack = keyOrIndex);
6785
+ 0 === resumedBoundary.pendingTasks &&
6786
+ resumedBoundary.status === PENDING
6787
+ ) {
6788
+ resumedBoundary.status = COMPLETED;
6789
+ request.completedBoundaries.push(resumedBoundary);
6790
+ break a;
6792
6791
  }
6793
- childNodes = createReplayTask(
6794
- request,
6795
- null,
6796
- { nodes: name, slots: node, pendingTasks: 0 },
6797
- props$jscomp$0,
6798
- -1,
6799
- parentBoundary,
6800
- resumedBoundary.fallbackState,
6801
- fallbackAbortSet,
6802
- [ref[0], "Suspense Fallback", ref[2]],
6803
- task.formatContext,
6804
- task.legacyContext,
6805
- task.context,
6806
- task.treeContext,
6807
- refProp,
6808
- !0
6809
- );
6810
- request.pingedTasks.push(childNodes);
6792
+ } catch (error$3) {
6793
+ (resumedBoundary.status = CLIENT_RENDERED),
6794
+ (childNodes = getThrownInfo(ref.componentStack)),
6795
+ (type = logRecoverableError(
6796
+ request,
6797
+ error$3,
6798
+ childNodes
6799
+ )),
6800
+ encodeErrorForBoundary(
6801
+ resumedBoundary,
6802
+ type,
6803
+ error$3,
6804
+ childNodes,
6805
+ !1
6806
+ ),
6807
+ ref.replay.pendingTasks--,
6808
+ request.clientRenderedBoundaries.push(resumedBoundary);
6809
+ } finally {
6810
+ (ref.blockedBoundary = parentBoundary),
6811
+ (ref.hoistableState = parentHoistableState),
6812
+ (ref.replay = previousReplaySet),
6813
+ (ref.keyPath = prevKeyPath),
6814
+ (ref.componentStack = previousComponentStack);
6811
6815
  }
6816
+ childNodes = createReplayTask(
6817
+ request,
6818
+ null,
6819
+ { nodes: keyOrIndex, slots: node, pendingTasks: 0 },
6820
+ props$jscomp$0,
6821
+ -1,
6822
+ parentBoundary,
6823
+ resumedBoundary.fallbackState,
6824
+ fallbackAbortSet,
6825
+ [key[0], "Suspense Fallback", key[2]],
6826
+ ref.formatContext,
6827
+ ref.context,
6828
+ ref.treeContext,
6829
+ owner,
6830
+ !0
6831
+ );
6832
+ request.pingedTasks.push(childNodes);
6812
6833
  }
6813
- childIndex.splice(node$jscomp$0, 1);
6814
- break a;
6815
6834
  }
6835
+ node$jscomp$0.splice(childIndex, 1);
6836
+ break;
6816
6837
  }
6817
6838
  }
6818
- else
6819
- renderElement(request, task, key, type, props, ref, refProp, null);
6839
+ } else
6840
+ renderElement(request, task, key, type, props, ref, owner, null);
6841
+ task.componentStack = refProp;
6820
6842
  return;
6821
6843
  case REACT_PORTAL_TYPE:
6822
6844
  throw Error(
6823
6845
  "Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render."
6824
6846
  );
6825
6847
  case REACT_LAZY_TYPE:
6826
- childNodes = task.componentStack;
6827
- task.componentStack = createBuiltInComponentStack(
6828
- task,
6829
- "Lazy",
6830
- null,
6831
- null
6832
- );
6848
+ refProp = task.componentStack;
6849
+ pushServerComponentStack(task, node$jscomp$0._debugInfo);
6850
+ task.componentStack === refProp &&
6851
+ (task.componentStack = createBuiltInComponentStack(
6852
+ task,
6853
+ "Lazy",
6854
+ null,
6855
+ null
6856
+ ));
6833
6857
  node$jscomp$0 = callLazyInitInDEV(node$jscomp$0);
6834
- task.componentStack = childNodes;
6858
+ task.componentStack = refProp;
6835
6859
  renderNodeDestructive(request, task, node$jscomp$0, childIndex);
6836
6860
  return;
6837
6861
  }
@@ -6840,20 +6864,20 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
6840
6864
  return;
6841
6865
  }
6842
6866
  null === node$jscomp$0 || "object" !== typeof node$jscomp$0
6843
- ? (refProp = null)
6844
- : ((childNodes =
6867
+ ? (childNodes = null)
6868
+ : ((refProp =
6845
6869
  (MAYBE_ITERATOR_SYMBOL && node$jscomp$0[MAYBE_ITERATOR_SYMBOL]) ||
6846
6870
  node$jscomp$0["@@iterator"]),
6847
- (refProp = "function" === typeof childNodes ? childNodes : null));
6848
- if (refProp && (childNodes = refProp.call(node$jscomp$0))) {
6849
- if (childNodes === node$jscomp$0) {
6871
+ (childNodes = "function" === typeof refProp ? refProp : null));
6872
+ if (childNodes && (refProp = childNodes.call(node$jscomp$0))) {
6873
+ if (refProp === node$jscomp$0) {
6850
6874
  if (
6851
6875
  -1 !== childIndex ||
6852
6876
  null === task.componentStack ||
6853
6877
  1 !== task.componentStack.tag ||
6854
6878
  "[object GeneratorFunction]" !==
6855
6879
  Object.prototype.toString.call(task.componentStack.type) ||
6856
- "[object Generator]" !== Object.prototype.toString.call(childNodes)
6880
+ "[object Generator]" !== Object.prototype.toString.call(refProp)
6857
6881
  )
6858
6882
  didWarnAboutGenerators ||
6859
6883
  error(
@@ -6861,32 +6885,36 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
6861
6885
  ),
6862
6886
  (didWarnAboutGenerators = !0);
6863
6887
  } else
6864
- node$jscomp$0.entries !== refProp ||
6888
+ node$jscomp$0.entries !== childNodes ||
6865
6889
  didWarnAboutMaps ||
6866
6890
  (error(
6867
6891
  "Using Maps as children is not supported. Use an array of keyed ReactElements instead."
6868
6892
  ),
6869
6893
  (didWarnAboutMaps = !0));
6870
- node$jscomp$0 = childNodes.next();
6894
+ node$jscomp$0 = refProp.next();
6871
6895
  if (!node$jscomp$0.done) {
6872
- refProp = [];
6896
+ childNodes = [];
6873
6897
  do
6874
- refProp.push(node$jscomp$0.value),
6875
- (node$jscomp$0 = childNodes.next());
6898
+ childNodes.push(node$jscomp$0.value),
6899
+ (node$jscomp$0 = refProp.next());
6876
6900
  while (!node$jscomp$0.done);
6877
- renderChildrenArray(request, task, refProp, childIndex);
6901
+ renderChildrenArray(request, task, childNodes, childIndex);
6878
6902
  }
6879
6903
  return;
6880
6904
  }
6881
6905
  if ("function" === typeof node$jscomp$0.then)
6882
6906
  return (
6883
6907
  (task.thenableState = null),
6884
- renderNodeDestructive(
6908
+ (refProp = task.componentStack),
6909
+ pushServerComponentStack(task, node$jscomp$0._debugInfo),
6910
+ (node$jscomp$0 = renderNodeDestructive(
6885
6911
  request,
6886
6912
  task,
6887
6913
  unwrapThenable(node$jscomp$0),
6888
6914
  childIndex
6889
- )
6915
+ )),
6916
+ (task.componentStack = refProp),
6917
+ node$jscomp$0
6890
6918
  );
6891
6919
  if (node$jscomp$0.$$typeof === REACT_CONTEXT_TYPE)
6892
6920
  return renderNodeDestructive(
@@ -6895,40 +6923,40 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
6895
6923
  node$jscomp$0._currentValue,
6896
6924
  childIndex
6897
6925
  );
6898
- childIndex = Object.prototype.toString.call(node$jscomp$0);
6926
+ task = Object.prototype.toString.call(node$jscomp$0);
6899
6927
  throw Error(
6900
6928
  "Objects are not valid as a React child (found: " +
6901
- ("[object Object]" === childIndex
6929
+ ("[object Object]" === task
6902
6930
  ? "object with keys {" + Object.keys(node$jscomp$0).join(", ") + "}"
6903
- : childIndex) +
6931
+ : task) +
6904
6932
  "). If you meant to render a collection of children, use an array instead."
6905
6933
  );
6906
6934
  }
6907
6935
  "string" === typeof node$jscomp$0
6908
- ? ((childIndex = task.blockedSegment),
6909
- null !== childIndex &&
6910
- (childIndex.lastPushedText = pushTextInstance(
6911
- childIndex.chunks,
6936
+ ? ((task = task.blockedSegment),
6937
+ null !== task &&
6938
+ (task.lastPushedText = pushTextInstance(
6939
+ task.chunks,
6912
6940
  node$jscomp$0,
6913
6941
  request.renderState,
6914
- childIndex.lastPushedText
6942
+ task.lastPushedText
6915
6943
  )))
6916
6944
  : "number" === typeof node$jscomp$0 || "bigint" === typeof node$jscomp$0
6917
- ? ((childIndex = task.blockedSegment),
6918
- null !== childIndex &&
6919
- (childIndex.lastPushedText = pushTextInstance(
6920
- childIndex.chunks,
6945
+ ? ((task = task.blockedSegment),
6946
+ null !== task &&
6947
+ (task.lastPushedText = pushTextInstance(
6948
+ task.chunks,
6921
6949
  "" + node$jscomp$0,
6922
6950
  request.renderState,
6923
- childIndex.lastPushedText
6951
+ task.lastPushedText
6924
6952
  )))
6925
6953
  : ("function" === typeof node$jscomp$0 &&
6926
- ((childIndex =
6954
+ ((task =
6927
6955
  node$jscomp$0.displayName || node$jscomp$0.name || "Component"),
6928
6956
  error(
6929
6957
  "Functions are not valid as a React child. This may happen if you return %s instead of <%s /> from render. Or maybe you meant to call this function rather than return it.",
6930
- childIndex,
6931
- childIndex
6958
+ task,
6959
+ task
6932
6960
  )),
6933
6961
  "symbol" === typeof node$jscomp$0 &&
6934
6962
  error(
@@ -6938,7 +6966,9 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
6938
6966
  }
6939
6967
  }
6940
6968
  function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
6941
- var prevKeyPath = task.keyPath;
6969
+ var prevKeyPath = task.keyPath,
6970
+ previousComponentStack = task.componentStack;
6971
+ pushServerComponentStack(task, task.node._debugInfo);
6942
6972
  if (
6943
6973
  -1 !== childIndex &&
6944
6974
  ((task.keyPath = [task.keyPath, "Fragment", childIndex]),
@@ -6969,7 +6999,7 @@ function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
6969
6999
  )
6970
7000
  throw x;
6971
7001
  task.replay.pendingTasks--;
6972
- children = getThrownInfo(request$jscomp$0, task.componentStack);
7002
+ children = getThrownInfo(task.componentStack);
6973
7003
  erroredReplay(
6974
7004
  request$jscomp$0,
6975
7005
  task.blockedBoundary,
@@ -6985,6 +7015,7 @@ function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
6985
7015
  }
6986
7016
  }
6987
7017
  task.keyPath = prevKeyPath;
7018
+ task.componentStack = previousComponentStack;
6988
7019
  return;
6989
7020
  }
6990
7021
  replay = task.treeContext;
@@ -7010,6 +7041,7 @@ function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
7010
7041
  }
7011
7042
  task.treeContext = replay;
7012
7043
  task.keyPath = prevKeyPath;
7044
+ task.componentStack = previousComponentStack;
7013
7045
  return;
7014
7046
  }
7015
7047
  for (j = 0; j < replayNodes; j++) {
@@ -7101,6 +7133,7 @@ function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
7101
7133
  }
7102
7134
  task.treeContext = replay;
7103
7135
  task.keyPath = prevKeyPath;
7136
+ task.componentStack = previousComponentStack;
7104
7137
  }
7105
7138
  function untrackBoundary(request, boundary) {
7106
7139
  request = request.trackedPostpones;
@@ -7113,7 +7146,6 @@ function untrackBoundary(request, boundary) {
7113
7146
  }
7114
7147
  function renderNode(request, task, node, childIndex) {
7115
7148
  var previousFormatContext = task.formatContext,
7116
- previousLegacyContext = task.legacyContext,
7117
7149
  previousContext = task.context,
7118
7150
  previousKeyPath = task.keyPath,
7119
7151
  previousTreeContext = task.treeContext,
@@ -7145,7 +7177,6 @@ function renderNode(request, task, node, childIndex) {
7145
7177
  task.abortSet,
7146
7178
  task.keyPath,
7147
7179
  task.formatContext,
7148
- task.legacyContext,
7149
7180
  task.context,
7150
7181
  task.treeContext,
7151
7182
  null !== task.componentStack ? task.componentStack.parent : null,
@@ -7153,7 +7184,6 @@ function renderNode(request, task, node, childIndex) {
7153
7184
  ).ping;
7154
7185
  node.then(request, request);
7155
7186
  task.formatContext = previousFormatContext;
7156
- task.legacyContext = previousLegacyContext;
7157
7187
  task.context = previousContext;
7158
7188
  task.keyPath = previousKeyPath;
7159
7189
  task.treeContext = previousTreeContext;
@@ -7203,7 +7233,6 @@ function renderNode(request, task, node, childIndex) {
7203
7233
  task.abortSet,
7204
7234
  task.keyPath,
7205
7235
  task.formatContext,
7206
- task.legacyContext,
7207
7236
  task.context,
7208
7237
  task.treeContext,
7209
7238
  null !== task.componentStack ? task.componentStack.parent : null,
@@ -7211,7 +7240,6 @@ function renderNode(request, task, node, childIndex) {
7211
7240
  ).ping;
7212
7241
  node.then(request, request);
7213
7242
  task.formatContext = previousFormatContext;
7214
- task.legacyContext = previousLegacyContext;
7215
7243
  task.context = previousContext;
7216
7244
  task.keyPath = previousKeyPath;
7217
7245
  task.treeContext = previousTreeContext;
@@ -7222,7 +7250,6 @@ function renderNode(request, task, node, childIndex) {
7222
7250
  }
7223
7251
  }
7224
7252
  task.formatContext = previousFormatContext;
7225
- task.legacyContext = previousLegacyContext;
7226
7253
  task.context = previousContext;
7227
7254
  task.keyPath = previousKeyPath;
7228
7255
  task.treeContext = previousTreeContext;
@@ -7352,7 +7379,7 @@ function abortTask(task, request, error) {
7352
7379
  boundary.pendingTasks--,
7353
7380
  boundary.status !== CLIENT_RENDERED &&
7354
7381
  ((boundary.status = CLIENT_RENDERED),
7355
- (task = getThrownInfo(request, task.componentStack)),
7382
+ (task = getThrownInfo(task.componentStack)),
7356
7383
  (segment = logRecoverableError(request, error, task)),
7357
7384
  encodeErrorForBoundary(boundary, segment, error, task, !0),
7358
7385
  untrackBoundary(request, boundary),
@@ -7556,10 +7583,7 @@ function performWork(request$jscomp$1) {
7556
7583
  } else {
7557
7584
  request.replay.pendingTasks--;
7558
7585
  request.abortSet.delete(request);
7559
- var errorInfo = getThrownInfo(
7560
- request$jscomp$0,
7561
- request.componentStack
7562
- );
7586
+ var errorInfo = getThrownInfo(request.componentStack);
7563
7587
  erroredReplay(
7564
7588
  request$jscomp$0,
7565
7589
  request.blockedBoundary,
@@ -7627,7 +7651,6 @@ function performWork(request$jscomp$1) {
7627
7651
  task$jscomp$0.componentStack.parent);
7628
7652
  } else {
7629
7653
  var errorInfo$jscomp$0 = getThrownInfo(
7630
- request,
7631
7654
  task$jscomp$0.componentStack
7632
7655
  );
7633
7656
  task$jscomp$0.abortSet.delete(task$jscomp$0);
@@ -8181,15 +8204,15 @@ function abort(request, reason) {
8181
8204
  logRecoverableError(request, error$8, {}), fatalError(request, error$8);
8182
8205
  }
8183
8206
  }
8184
- var isomorphicReactPackageVersion$jscomp$inline_739 = React.version;
8207
+ var isomorphicReactPackageVersion$jscomp$inline_746 = React.version;
8185
8208
  if (
8186
- "19.0.0-rc-100dfd7dab-20240701" !==
8187
- isomorphicReactPackageVersion$jscomp$inline_739
8209
+ "19.0.0-rc-3da26163a3-20240704" !==
8210
+ isomorphicReactPackageVersion$jscomp$inline_746
8188
8211
  )
8189
8212
  throw Error(
8190
8213
  'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
8191
- (isomorphicReactPackageVersion$jscomp$inline_739 +
8192
- "\n - react-dom: 19.0.0-rc-100dfd7dab-20240701\nLearn more: https://react.dev/warnings/version-mismatch")
8214
+ (isomorphicReactPackageVersion$jscomp$inline_746 +
8215
+ "\n - react-dom: 19.0.0-rc-3da26163a3-20240704\nLearn more: https://react.dev/warnings/version-mismatch")
8193
8216
  );
8194
8217
  exports.renderToReadableStream = function (children, options) {
8195
8218
  return new Promise(function (resolve, reject) {
@@ -8278,4 +8301,4 @@ exports.renderToReadableStream = function (children, options) {
8278
8301
  startWork(request$jscomp$0);
8279
8302
  });
8280
8303
  };
8281
- exports.version = "19.0.0-rc-100dfd7dab-20240701";
8304
+ exports.version = "19.0.0-rc-3da26163a3-20240704";