react-dom 19.2.0-canary-462d08f9-20250517 → 19.2.0-canary-23884812-20250520
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.
- package/cjs/react-dom-client.development.js +73 -56
- package/cjs/react-dom-client.production.js +33 -32
- package/cjs/react-dom-profiling.development.js +73 -56
- package/cjs/react-dom-profiling.profiling.js +33 -32
- package/cjs/react-dom-server-legacy.browser.development.js +593 -251
- package/cjs/react-dom-server-legacy.browser.production.js +469 -182
- package/cjs/react-dom-server-legacy.node.development.js +593 -251
- package/cjs/react-dom-server-legacy.node.production.js +469 -182
- package/cjs/react-dom-server.browser.development.js +579 -220
- package/cjs/react-dom-server.browser.production.js +441 -133
- package/cjs/react-dom-server.bun.development.js +587 -224
- package/cjs/react-dom-server.bun.production.js +465 -142
- package/cjs/react-dom-server.edge.development.js +579 -220
- package/cjs/react-dom-server.edge.production.js +441 -133
- package/cjs/react-dom-server.node.development.js +579 -217
- package/cjs/react-dom-server.node.production.js +441 -133
- package/cjs/react-dom.development.js +1 -1
- package/cjs/react-dom.production.js +1 -1
- package/cjs/react-dom.react-server.development.js +1 -1
- package/cjs/react-dom.react-server.production.js +1 -1
- package/package.json +3 -3
@@ -41,6 +41,14 @@
|
|
41
41
|
function scriptReplacer(match, prefix, s, suffix) {
|
42
42
|
return "" + prefix + ("s" === s ? "\\u0073" : "\\u0053") + suffix;
|
43
43
|
}
|
44
|
+
function getIteratorFn(maybeIterable) {
|
45
|
+
if (null === maybeIterable || "object" !== typeof maybeIterable)
|
46
|
+
return null;
|
47
|
+
maybeIterable =
|
48
|
+
(MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||
|
49
|
+
maybeIterable["@@iterator"];
|
50
|
+
return "function" === typeof maybeIterable ? maybeIterable : null;
|
51
|
+
}
|
44
52
|
function objectName(object) {
|
45
53
|
return Object.prototype.toString
|
46
54
|
.call(object)
|
@@ -758,9 +766,6 @@
|
|
758
766
|
moduleScriptResources: {}
|
759
767
|
};
|
760
768
|
}
|
761
|
-
function createPreambleState() {
|
762
|
-
return { htmlChunks: null, headChunks: null, bodyChunks: null };
|
763
|
-
}
|
764
769
|
function createFormatContext(
|
765
770
|
insertionMode,
|
766
771
|
selectedValue,
|
@@ -3349,6 +3354,10 @@
|
|
3349
3354
|
function hoistStylesheetDependency(stylesheet) {
|
3350
3355
|
this.stylesheets.add(stylesheet);
|
3351
3356
|
}
|
3357
|
+
function hoistHoistables(parentState, childState) {
|
3358
|
+
childState.styles.forEach(hoistStyleQueueDependency, parentState);
|
3359
|
+
childState.stylesheets.forEach(hoistStylesheetDependency, parentState);
|
3360
|
+
}
|
3352
3361
|
function createRenderState(resumableState, generateStaticMarkup) {
|
3353
3362
|
var idPrefix = resumableState.idPrefix,
|
3354
3363
|
bootstrapChunks = [],
|
@@ -3368,7 +3377,7 @@
|
|
3368
3377
|
segmentPrefix: idPrefix + "S:",
|
3369
3378
|
boundaryPrefix: idPrefix + "B:",
|
3370
3379
|
startInlineScript: "<script",
|
3371
|
-
preamble:
|
3380
|
+
preamble: { htmlChunks: null, headChunks: null, bodyChunks: null },
|
3372
3381
|
externalRuntimeScript: null,
|
3373
3382
|
bootstrapChunks: bootstrapChunks,
|
3374
3383
|
importMapChunks: [],
|
@@ -4427,6 +4436,7 @@
|
|
4427
4436
|
null,
|
4428
4437
|
emptyTreeContext,
|
4429
4438
|
null,
|
4439
|
+
null,
|
4430
4440
|
emptyContextObject,
|
4431
4441
|
null
|
4432
4442
|
);
|
@@ -4442,15 +4452,17 @@
|
|
4442
4452
|
}
|
4443
4453
|
function createSuspenseBoundary(
|
4444
4454
|
request,
|
4455
|
+
row,
|
4445
4456
|
fallbackAbortableTasks,
|
4446
4457
|
contentPreamble,
|
4447
4458
|
fallbackPreamble
|
4448
4459
|
) {
|
4449
|
-
|
4460
|
+
fallbackAbortableTasks = {
|
4450
4461
|
status: PENDING,
|
4451
4462
|
rootSegmentID: -1,
|
4452
4463
|
parentFlushed: !1,
|
4453
4464
|
pendingTasks: 0,
|
4465
|
+
row: row,
|
4454
4466
|
completedSegments: [],
|
4455
4467
|
byteSize: 0,
|
4456
4468
|
fallbackAbortableTasks: fallbackAbortableTasks,
|
@@ -4465,6 +4477,17 @@
|
|
4465
4477
|
errorStack: null,
|
4466
4478
|
errorComponentStack: null
|
4467
4479
|
};
|
4480
|
+
null !== row &&
|
4481
|
+
(row.pendingTasks++,
|
4482
|
+
(contentPreamble = row.boundaries),
|
4483
|
+
null !== contentPreamble &&
|
4484
|
+
(request.allPendingTasks++,
|
4485
|
+
fallbackAbortableTasks.pendingTasks++,
|
4486
|
+
contentPreamble.push(fallbackAbortableTasks)),
|
4487
|
+
(request = row.inheritedHoistables),
|
4488
|
+
null !== request &&
|
4489
|
+
hoistHoistables(fallbackAbortableTasks.contentState, request));
|
4490
|
+
return fallbackAbortableTasks;
|
4468
4491
|
}
|
4469
4492
|
function createRenderTask(
|
4470
4493
|
request,
|
@@ -4480,6 +4503,7 @@
|
|
4480
4503
|
formatContext,
|
4481
4504
|
context,
|
4482
4505
|
treeContext,
|
4506
|
+
row,
|
4483
4507
|
componentStack,
|
4484
4508
|
legacyContext,
|
4485
4509
|
debugTask
|
@@ -4488,6 +4512,7 @@
|
|
4488
4512
|
null === blockedBoundary
|
4489
4513
|
? request.pendingRootTasks++
|
4490
4514
|
: blockedBoundary.pendingTasks++;
|
4515
|
+
null !== row && row.pendingTasks++;
|
4491
4516
|
var task = {
|
4492
4517
|
replay: null,
|
4493
4518
|
node: node,
|
@@ -4504,6 +4529,7 @@
|
|
4504
4529
|
formatContext: formatContext,
|
4505
4530
|
context: context,
|
4506
4531
|
treeContext: treeContext,
|
4532
|
+
row: row,
|
4507
4533
|
componentStack: componentStack,
|
4508
4534
|
thenableState: thenableState
|
4509
4535
|
};
|
@@ -4524,6 +4550,7 @@
|
|
4524
4550
|
formatContext,
|
4525
4551
|
context,
|
4526
4552
|
treeContext,
|
4553
|
+
row,
|
4527
4554
|
componentStack,
|
4528
4555
|
legacyContext,
|
4529
4556
|
debugTask
|
@@ -4532,6 +4559,7 @@
|
|
4532
4559
|
null === blockedBoundary
|
4533
4560
|
? request.pendingRootTasks++
|
4534
4561
|
: blockedBoundary.pendingTasks++;
|
4562
|
+
null !== row && row.pendingTasks++;
|
4535
4563
|
replay.pendingTasks++;
|
4536
4564
|
var task = {
|
4537
4565
|
replay: replay,
|
@@ -4549,6 +4577,7 @@
|
|
4549
4577
|
formatContext: formatContext,
|
4550
4578
|
context: context,
|
4551
4579
|
treeContext: treeContext,
|
4580
|
+
row: row,
|
4552
4581
|
componentStack: componentStack,
|
4553
4582
|
thenableState: thenableState
|
4554
4583
|
};
|
@@ -4734,6 +4763,186 @@
|
|
4734
4763
|
? ((request.status = CLOSED), request.destination.destroy(error))
|
4735
4764
|
: ((request.status = 13), (request.fatalError = error));
|
4736
4765
|
}
|
4766
|
+
function finishSuspenseListRow(request, row) {
|
4767
|
+
unblockSuspenseListRow(request, row.next, row.hoistables);
|
4768
|
+
}
|
4769
|
+
function unblockSuspenseListRow(
|
4770
|
+
request,
|
4771
|
+
unblockedRow,
|
4772
|
+
inheritedHoistables
|
4773
|
+
) {
|
4774
|
+
for (; null !== unblockedRow; ) {
|
4775
|
+
null !== inheritedHoistables &&
|
4776
|
+
(hoistHoistables(unblockedRow.hoistables, inheritedHoistables),
|
4777
|
+
(unblockedRow.inheritedHoistables = inheritedHoistables));
|
4778
|
+
var unblockedBoundaries = unblockedRow.boundaries;
|
4779
|
+
if (null !== unblockedBoundaries) {
|
4780
|
+
unblockedRow.boundaries = null;
|
4781
|
+
for (var i = 0; i < unblockedBoundaries.length; i++) {
|
4782
|
+
var unblockedBoundary = unblockedBoundaries[i];
|
4783
|
+
null !== inheritedHoistables &&
|
4784
|
+
hoistHoistables(
|
4785
|
+
unblockedBoundary.contentState,
|
4786
|
+
inheritedHoistables
|
4787
|
+
);
|
4788
|
+
finishedTask(request, unblockedBoundary, null, null);
|
4789
|
+
}
|
4790
|
+
}
|
4791
|
+
unblockedRow.pendingTasks--;
|
4792
|
+
if (0 < unblockedRow.pendingTasks) break;
|
4793
|
+
inheritedHoistables = unblockedRow.hoistables;
|
4794
|
+
unblockedRow = unblockedRow.next;
|
4795
|
+
}
|
4796
|
+
}
|
4797
|
+
function tryToResolveTogetherRow(request, togetherRow) {
|
4798
|
+
var boundaries = togetherRow.boundaries;
|
4799
|
+
if (
|
4800
|
+
null !== boundaries &&
|
4801
|
+
togetherRow.pendingTasks === boundaries.length
|
4802
|
+
) {
|
4803
|
+
for (
|
4804
|
+
var allCompleteAndInlinable = !0, i = 0;
|
4805
|
+
i < boundaries.length;
|
4806
|
+
i++
|
4807
|
+
) {
|
4808
|
+
var rowBoundary = boundaries[i];
|
4809
|
+
if (
|
4810
|
+
1 !== rowBoundary.pendingTasks ||
|
4811
|
+
rowBoundary.parentFlushed ||
|
4812
|
+
500 < rowBoundary.byteSize
|
4813
|
+
) {
|
4814
|
+
allCompleteAndInlinable = !1;
|
4815
|
+
break;
|
4816
|
+
}
|
4817
|
+
}
|
4818
|
+
allCompleteAndInlinable &&
|
4819
|
+
unblockSuspenseListRow(request, togetherRow, togetherRow.hoistables);
|
4820
|
+
}
|
4821
|
+
}
|
4822
|
+
function createSuspenseListRow(previousRow) {
|
4823
|
+
var newRow = {
|
4824
|
+
pendingTasks: 1,
|
4825
|
+
boundaries: null,
|
4826
|
+
hoistables: createHoistableState(),
|
4827
|
+
inheritedHoistables: null,
|
4828
|
+
together: !1,
|
4829
|
+
next: null
|
4830
|
+
};
|
4831
|
+
null !== previousRow &&
|
4832
|
+
0 < previousRow.pendingTasks &&
|
4833
|
+
(newRow.pendingTasks++,
|
4834
|
+
(newRow.boundaries = []),
|
4835
|
+
(previousRow.next = newRow));
|
4836
|
+
return newRow;
|
4837
|
+
}
|
4838
|
+
function renderSuspenseListRows(request, task, keyPath, rows, revealOrder) {
|
4839
|
+
var prevKeyPath = task.keyPath,
|
4840
|
+
prevTreeContext = task.treeContext,
|
4841
|
+
prevRow = task.row,
|
4842
|
+
previousComponentStack = task.componentStack;
|
4843
|
+
var previousDebugTask = task.debugTask;
|
4844
|
+
pushServerComponentStack(task, task.node.props.children._debugInfo);
|
4845
|
+
task.keyPath = keyPath;
|
4846
|
+
keyPath = rows.length;
|
4847
|
+
var previousSuspenseListRow = null;
|
4848
|
+
if (null !== task.replay) {
|
4849
|
+
var resumeSlots = task.replay.slots;
|
4850
|
+
if (null !== resumeSlots && "object" === typeof resumeSlots)
|
4851
|
+
for (var n = 0; n < keyPath; n++) {
|
4852
|
+
var i = "backwards" !== revealOrder ? n : keyPath - 1 - n,
|
4853
|
+
node = rows[i];
|
4854
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
4855
|
+
previousSuspenseListRow
|
4856
|
+
);
|
4857
|
+
task.treeContext = pushTreeContext(prevTreeContext, keyPath, i);
|
4858
|
+
var resumeSegmentID = resumeSlots[i];
|
4859
|
+
"number" === typeof resumeSegmentID
|
4860
|
+
? (resumeNode(request, task, resumeSegmentID, node, i),
|
4861
|
+
delete resumeSlots[i])
|
4862
|
+
: renderNode(request, task, node, i);
|
4863
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
4864
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
4865
|
+
}
|
4866
|
+
else
|
4867
|
+
for (resumeSlots = 0; resumeSlots < keyPath; resumeSlots++)
|
4868
|
+
(n =
|
4869
|
+
"backwards" !== revealOrder
|
4870
|
+
? resumeSlots
|
4871
|
+
: keyPath - 1 - resumeSlots),
|
4872
|
+
(i = rows[n]),
|
4873
|
+
warnForMissingKey(request, task, i),
|
4874
|
+
(task.row = previousSuspenseListRow =
|
4875
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
4876
|
+
(task.treeContext = pushTreeContext(prevTreeContext, keyPath, n)),
|
4877
|
+
renderNode(request, task, i, n),
|
4878
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
4879
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
4880
|
+
} else if ("backwards" !== revealOrder)
|
4881
|
+
for (revealOrder = 0; revealOrder < keyPath; revealOrder++)
|
4882
|
+
(resumeSlots = rows[revealOrder]),
|
4883
|
+
warnForMissingKey(request, task, resumeSlots),
|
4884
|
+
(task.row = previousSuspenseListRow =
|
4885
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
4886
|
+
(task.treeContext = pushTreeContext(
|
4887
|
+
prevTreeContext,
|
4888
|
+
keyPath,
|
4889
|
+
revealOrder
|
4890
|
+
)),
|
4891
|
+
renderNode(request, task, resumeSlots, revealOrder),
|
4892
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
4893
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
4894
|
+
else {
|
4895
|
+
revealOrder = task.blockedSegment;
|
4896
|
+
resumeSlots = revealOrder.children.length;
|
4897
|
+
n = revealOrder.chunks.length;
|
4898
|
+
for (i = keyPath - 1; 0 <= i; i--) {
|
4899
|
+
node = rows[i];
|
4900
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
4901
|
+
previousSuspenseListRow
|
4902
|
+
);
|
4903
|
+
task.treeContext = pushTreeContext(prevTreeContext, keyPath, i);
|
4904
|
+
resumeSegmentID = createPendingSegment(
|
4905
|
+
request,
|
4906
|
+
n,
|
4907
|
+
null,
|
4908
|
+
task.formatContext,
|
4909
|
+
0 === i ? revealOrder.lastPushedText : !0,
|
4910
|
+
!0
|
4911
|
+
);
|
4912
|
+
revealOrder.children.splice(resumeSlots, 0, resumeSegmentID);
|
4913
|
+
task.blockedSegment = resumeSegmentID;
|
4914
|
+
warnForMissingKey(request, task, node);
|
4915
|
+
try {
|
4916
|
+
renderNode(request, task, node, i),
|
4917
|
+
pushSegmentFinale(
|
4918
|
+
resumeSegmentID.chunks,
|
4919
|
+
request.renderState,
|
4920
|
+
resumeSegmentID.lastPushedText,
|
4921
|
+
resumeSegmentID.textEmbedded
|
4922
|
+
),
|
4923
|
+
(resumeSegmentID.status = COMPLETED),
|
4924
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
4925
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
4926
|
+
} catch (thrownValue) {
|
4927
|
+
throw (
|
4928
|
+
((resumeSegmentID.status = 12 === request.status ? ABORTED : 4),
|
4929
|
+
thrownValue)
|
4930
|
+
);
|
4931
|
+
}
|
4932
|
+
}
|
4933
|
+
task.blockedSegment = revealOrder;
|
4934
|
+
revealOrder.lastPushedText = !1;
|
4935
|
+
}
|
4936
|
+
null !== prevRow &&
|
4937
|
+
null !== previousSuspenseListRow &&
|
4938
|
+
0 < previousSuspenseListRow.pendingTasks &&
|
4939
|
+
(prevRow.pendingTasks++, (previousSuspenseListRow.next = prevRow));
|
4940
|
+
task.treeContext = prevTreeContext;
|
4941
|
+
task.row = prevRow;
|
4942
|
+
task.keyPath = prevKeyPath;
|
4943
|
+
task.componentStack = previousComponentStack;
|
4944
|
+
task.debugTask = previousDebugTask;
|
4945
|
+
}
|
4737
4946
|
function renderWithHooks(
|
4738
4947
|
request,
|
4739
4948
|
task,
|
@@ -5275,7 +5484,7 @@
|
|
5275
5484
|
);
|
5276
5485
|
segment.lastPushedText = !1;
|
5277
5486
|
var _prevContext2 = task.formatContext,
|
5278
|
-
|
5487
|
+
_prevKeyPath3 = task.keyPath;
|
5279
5488
|
task.keyPath = keyPath;
|
5280
5489
|
if (
|
5281
5490
|
(task.formatContext = getChildFormatContext(
|
@@ -5307,6 +5516,7 @@
|
|
5307
5516
|
task.formatContext,
|
5308
5517
|
task.context,
|
5309
5518
|
task.treeContext,
|
5519
|
+
task.row,
|
5310
5520
|
task.componentStack,
|
5311
5521
|
emptyContextObject,
|
5312
5522
|
task.debugTask
|
@@ -5315,7 +5525,7 @@
|
|
5315
5525
|
request.pingedTasks.push(preambleTask);
|
5316
5526
|
} else renderNode(request, task, _children, -1);
|
5317
5527
|
task.formatContext = _prevContext2;
|
5318
|
-
task.keyPath =
|
5528
|
+
task.keyPath = _prevKeyPath3;
|
5319
5529
|
a: {
|
5320
5530
|
var target = segment.chunks,
|
5321
5531
|
resumableState = request.resumableState;
|
@@ -5382,20 +5592,80 @@
|
|
5382
5592
|
request.renderState.generateStaticMarkup ||
|
5383
5593
|
segment$jscomp$0.chunks.push("\x3c!--&--\x3e");
|
5384
5594
|
segment$jscomp$0.lastPushedText = !1;
|
5385
|
-
var
|
5595
|
+
var _prevKeyPath4 = task.keyPath;
|
5386
5596
|
task.keyPath = keyPath;
|
5387
5597
|
renderNode(request, task, props.children, -1);
|
5388
|
-
task.keyPath =
|
5598
|
+
task.keyPath = _prevKeyPath4;
|
5389
5599
|
request.renderState.generateStaticMarkup ||
|
5390
5600
|
segment$jscomp$0.chunks.push("\x3c!--/&--\x3e");
|
5391
5601
|
segment$jscomp$0.lastPushedText = !1;
|
5392
5602
|
}
|
5393
5603
|
return;
|
5394
5604
|
case REACT_SUSPENSE_LIST_TYPE:
|
5395
|
-
|
5396
|
-
|
5397
|
-
|
5398
|
-
|
5605
|
+
a: {
|
5606
|
+
var children$jscomp$0 = props.children,
|
5607
|
+
revealOrder = props.revealOrder;
|
5608
|
+
if ("forwards" === revealOrder || "backwards" === revealOrder) {
|
5609
|
+
if (isArrayImpl(children$jscomp$0)) {
|
5610
|
+
renderSuspenseListRows(
|
5611
|
+
request,
|
5612
|
+
task,
|
5613
|
+
keyPath,
|
5614
|
+
children$jscomp$0,
|
5615
|
+
revealOrder
|
5616
|
+
);
|
5617
|
+
break a;
|
5618
|
+
}
|
5619
|
+
var iteratorFn = getIteratorFn(children$jscomp$0);
|
5620
|
+
if (iteratorFn) {
|
5621
|
+
var iterator = iteratorFn.call(children$jscomp$0);
|
5622
|
+
if (iterator) {
|
5623
|
+
validateIterable(
|
5624
|
+
task,
|
5625
|
+
children$jscomp$0,
|
5626
|
+
-1,
|
5627
|
+
iterator,
|
5628
|
+
iteratorFn
|
5629
|
+
);
|
5630
|
+
var step = iterator.next();
|
5631
|
+
if (!step.done) {
|
5632
|
+
var rows = [];
|
5633
|
+
do rows.push(step.value), (step = iterator.next());
|
5634
|
+
while (!step.done);
|
5635
|
+
renderSuspenseListRows(
|
5636
|
+
request,
|
5637
|
+
task,
|
5638
|
+
keyPath,
|
5639
|
+
children$jscomp$0,
|
5640
|
+
revealOrder
|
5641
|
+
);
|
5642
|
+
}
|
5643
|
+
break a;
|
5644
|
+
}
|
5645
|
+
}
|
5646
|
+
}
|
5647
|
+
if ("together" === revealOrder) {
|
5648
|
+
var _prevKeyPath2 = task.keyPath,
|
5649
|
+
prevRow = task.row,
|
5650
|
+
newRow = (task.row = createSuspenseListRow(null));
|
5651
|
+
newRow.boundaries = [];
|
5652
|
+
newRow.together = !0;
|
5653
|
+
task.keyPath = keyPath;
|
5654
|
+
renderNodeDestructive(request, task, children$jscomp$0, -1);
|
5655
|
+
0 === --newRow.pendingTasks &&
|
5656
|
+
finishSuspenseListRow(request, newRow);
|
5657
|
+
task.keyPath = _prevKeyPath2;
|
5658
|
+
task.row = prevRow;
|
5659
|
+
null !== prevRow &&
|
5660
|
+
0 < newRow.pendingTasks &&
|
5661
|
+
(prevRow.pendingTasks++, (newRow.next = prevRow));
|
5662
|
+
} else {
|
5663
|
+
var prevKeyPath$jscomp$3 = task.keyPath;
|
5664
|
+
task.keyPath = keyPath;
|
5665
|
+
renderNodeDestructive(request, task, children$jscomp$0, -1);
|
5666
|
+
task.keyPath = prevKeyPath$jscomp$3;
|
5667
|
+
}
|
5668
|
+
}
|
5399
5669
|
return;
|
5400
5670
|
case REACT_VIEW_TRANSITION_TYPE:
|
5401
5671
|
case REACT_SCOPE_TYPE:
|
@@ -5405,22 +5675,26 @@
|
|
5405
5675
|
case REACT_SUSPENSE_TYPE:
|
5406
5676
|
a: if (null !== task.replay) {
|
5407
5677
|
var _prevKeyPath = task.keyPath,
|
5408
|
-
_prevContext = task.formatContext
|
5678
|
+
_prevContext = task.formatContext,
|
5679
|
+
_prevRow = task.row;
|
5409
5680
|
task.keyPath = keyPath;
|
5410
5681
|
task.formatContext = getSuspenseContentFormatContext(
|
5411
5682
|
request.resumableState,
|
5412
5683
|
_prevContext
|
5413
5684
|
);
|
5685
|
+
task.row = null;
|
5414
5686
|
var _content = props.children;
|
5415
5687
|
try {
|
5416
5688
|
renderNode(request, task, _content, -1);
|
5417
5689
|
} finally {
|
5418
5690
|
(task.keyPath = _prevKeyPath),
|
5419
|
-
(task.formatContext = _prevContext)
|
5691
|
+
(task.formatContext = _prevContext),
|
5692
|
+
(task.row = _prevRow);
|
5420
5693
|
}
|
5421
5694
|
} else {
|
5422
|
-
var prevKeyPath$jscomp$
|
5695
|
+
var prevKeyPath$jscomp$4 = task.keyPath,
|
5423
5696
|
prevContext$jscomp$0 = task.formatContext,
|
5697
|
+
prevRow$jscomp$0 = task.row,
|
5424
5698
|
parentBoundary = task.blockedBoundary,
|
5425
5699
|
parentPreamble = task.blockedPreamble,
|
5426
5700
|
parentHoistableState = task.hoistableState,
|
@@ -5428,20 +5702,13 @@
|
|
5428
5702
|
fallback = props.fallback,
|
5429
5703
|
content = props.children,
|
5430
5704
|
fallbackAbortSet = new Set();
|
5431
|
-
var newBoundary =
|
5432
|
-
|
5433
|
-
|
5434
|
-
|
5435
|
-
|
5436
|
-
|
5437
|
-
|
5438
|
-
)
|
5439
|
-
: createSuspenseBoundary(
|
5440
|
-
request,
|
5441
|
-
fallbackAbortSet,
|
5442
|
-
null,
|
5443
|
-
null
|
5444
|
-
);
|
5705
|
+
var newBoundary = createSuspenseBoundary(
|
5706
|
+
request,
|
5707
|
+
task.row,
|
5708
|
+
fallbackAbortSet,
|
5709
|
+
null,
|
5710
|
+
null
|
5711
|
+
);
|
5445
5712
|
null !== request.trackedPostpones &&
|
5446
5713
|
(newBoundary.trackedContentKeyPath = keyPath);
|
5447
5714
|
var boundarySegment = createPendingSegment(
|
@@ -5499,13 +5766,14 @@
|
|
5499
5766
|
(boundarySegment.status = COMPLETED);
|
5500
5767
|
} catch (thrownValue) {
|
5501
5768
|
throw (
|
5502
|
-
((boundarySegment.status =
|
5769
|
+
((boundarySegment.status =
|
5770
|
+
12 === request.status ? ABORTED : 4),
|
5503
5771
|
thrownValue)
|
5504
5772
|
);
|
5505
5773
|
} finally {
|
5506
5774
|
(task.blockedSegment = parentSegment),
|
5507
5775
|
(task.blockedPreamble = parentPreamble),
|
5508
|
-
(task.keyPath = prevKeyPath$jscomp$
|
5776
|
+
(task.keyPath = prevKeyPath$jscomp$4),
|
5509
5777
|
(task.formatContext = prevContext$jscomp$0);
|
5510
5778
|
}
|
5511
5779
|
var suspendedPrimaryTask = createRenderTask(
|
@@ -5525,6 +5793,7 @@
|
|
5525
5793
|
),
|
5526
5794
|
task.context,
|
5527
5795
|
task.treeContext,
|
5796
|
+
null,
|
5528
5797
|
task.componentStack,
|
5529
5798
|
emptyContextObject,
|
5530
5799
|
task.debugTask
|
@@ -5541,6 +5810,7 @@
|
|
5541
5810
|
request.resumableState,
|
5542
5811
|
prevContext$jscomp$0
|
5543
5812
|
);
|
5813
|
+
task.row = null;
|
5544
5814
|
contentRootSegment.status = 6;
|
5545
5815
|
try {
|
5546
5816
|
if (
|
@@ -5554,19 +5824,28 @@
|
|
5554
5824
|
(contentRootSegment.status = COMPLETED),
|
5555
5825
|
queueCompletedSegment(newBoundary, contentRootSegment),
|
5556
5826
|
0 === newBoundary.pendingTasks &&
|
5557
|
-
newBoundary.status === PENDING
|
5558
|
-
((newBoundary.status = COMPLETED),
|
5559
|
-
!(500 < newBoundary.byteSize)))
|
5827
|
+
newBoundary.status === PENDING)
|
5560
5828
|
) {
|
5561
|
-
|
5562
|
-
|
5563
|
-
|
5564
|
-
|
5565
|
-
|
5829
|
+
if (
|
5830
|
+
((newBoundary.status = COMPLETED),
|
5831
|
+
!(500 < newBoundary.byteSize))
|
5832
|
+
) {
|
5833
|
+
null !== prevRow$jscomp$0 &&
|
5834
|
+
0 === --prevRow$jscomp$0.pendingTasks &&
|
5835
|
+
finishSuspenseListRow(request, prevRow$jscomp$0);
|
5836
|
+
0 === request.pendingRootTasks &&
|
5837
|
+
task.blockedPreamble &&
|
5838
|
+
preparePreamble(request);
|
5839
|
+
break a;
|
5840
|
+
}
|
5841
|
+
} else
|
5842
|
+
null !== prevRow$jscomp$0 &&
|
5843
|
+
prevRow$jscomp$0.together &&
|
5844
|
+
tryToResolveTogetherRow(request, prevRow$jscomp$0);
|
5566
5845
|
} catch (thrownValue$2) {
|
5567
5846
|
newBoundary.status = CLIENT_RENDERED;
|
5568
5847
|
if (12 === request.status) {
|
5569
|
-
contentRootSegment.status =
|
5848
|
+
contentRootSegment.status = ABORTED;
|
5570
5849
|
var error = request.fatalError;
|
5571
5850
|
} else
|
5572
5851
|
(contentRootSegment.status = 4), (error = thrownValue$2);
|
@@ -5590,8 +5869,9 @@
|
|
5590
5869
|
(task.blockedPreamble = parentPreamble),
|
5591
5870
|
(task.hoistableState = parentHoistableState),
|
5592
5871
|
(task.blockedSegment = parentSegment),
|
5593
|
-
(task.keyPath = prevKeyPath$jscomp$
|
5594
|
-
(task.formatContext = prevContext$jscomp$0)
|
5872
|
+
(task.keyPath = prevKeyPath$jscomp$4),
|
5873
|
+
(task.formatContext = prevContext$jscomp$0),
|
5874
|
+
(task.row = prevRow$jscomp$0);
|
5595
5875
|
}
|
5596
5876
|
var suspendedFallbackTask = createRenderTask(
|
5597
5877
|
request,
|
@@ -5610,6 +5890,7 @@
|
|
5610
5890
|
),
|
5611
5891
|
task.context,
|
5612
5892
|
task.treeContext,
|
5893
|
+
task.row,
|
5613
5894
|
task.componentStack,
|
5614
5895
|
emptyContextObject,
|
5615
5896
|
task.debugTask
|
@@ -5628,7 +5909,7 @@
|
|
5628
5909
|
for (var key in props)
|
5629
5910
|
"ref" !== key && (propsWithoutRef[key] = props[key]);
|
5630
5911
|
} else propsWithoutRef = props;
|
5631
|
-
var children$jscomp$
|
5912
|
+
var children$jscomp$1 = renderWithHooks(
|
5632
5913
|
request,
|
5633
5914
|
task,
|
5634
5915
|
keyPath,
|
@@ -5640,7 +5921,7 @@
|
|
5640
5921
|
request,
|
5641
5922
|
task,
|
5642
5923
|
keyPath,
|
5643
|
-
children$jscomp$
|
5924
|
+
children$jscomp$1,
|
5644
5925
|
0 !== localIdCounter,
|
5645
5926
|
actionStateCounter,
|
5646
5927
|
actionStateMatchingIndex
|
@@ -5652,9 +5933,9 @@
|
|
5652
5933
|
case REACT_PROVIDER_TYPE:
|
5653
5934
|
case REACT_CONTEXT_TYPE:
|
5654
5935
|
var value$jscomp$0 = props.value,
|
5655
|
-
children$jscomp$
|
5936
|
+
children$jscomp$2 = props.children;
|
5656
5937
|
var prevSnapshot = task.context;
|
5657
|
-
var prevKeyPath$jscomp$
|
5938
|
+
var prevKeyPath$jscomp$5 = task.keyPath;
|
5658
5939
|
var prevValue = type._currentValue2;
|
5659
5940
|
type._currentValue2 = value$jscomp$0;
|
5660
5941
|
void 0 !== type._currentRenderer2 &&
|
@@ -5675,7 +5956,7 @@
|
|
5675
5956
|
currentActiveSnapshot = newNode;
|
5676
5957
|
task.context = newNode;
|
5677
5958
|
task.keyPath = keyPath;
|
5678
|
-
renderNodeDestructive(request, task, children$jscomp$
|
5959
|
+
renderNodeDestructive(request, task, children$jscomp$2, -1);
|
5679
5960
|
var prevSnapshot$jscomp$0 = currentActiveSnapshot;
|
5680
5961
|
if (null === prevSnapshot$jscomp$0)
|
5681
5962
|
throw Error(
|
@@ -5697,7 +5978,7 @@
|
|
5697
5978
|
var JSCompiler_inline_result$jscomp$0 = (currentActiveSnapshot =
|
5698
5979
|
prevSnapshot$jscomp$0.parent);
|
5699
5980
|
task.context = JSCompiler_inline_result$jscomp$0;
|
5700
|
-
task.keyPath = prevKeyPath$jscomp$
|
5981
|
+
task.keyPath = prevKeyPath$jscomp$5;
|
5701
5982
|
prevSnapshot !== task.context &&
|
5702
5983
|
console.error(
|
5703
5984
|
"Popping the context provider did not return back to the original snapshot. This is a bug in React."
|
@@ -5711,10 +5992,10 @@
|
|
5711
5992
|
"A context consumer was rendered with multiple children, or a child that isn't a function. A context consumer expects a single child that is a function. If you did pass a function, make sure there is no trailing or leading whitespace around it."
|
5712
5993
|
);
|
5713
5994
|
var newChildren = render(context$jscomp$0._currentValue2),
|
5714
|
-
prevKeyPath$jscomp$
|
5995
|
+
prevKeyPath$jscomp$6 = task.keyPath;
|
5715
5996
|
task.keyPath = keyPath;
|
5716
5997
|
renderNodeDestructive(request, task, newChildren, -1);
|
5717
|
-
task.keyPath = prevKeyPath$jscomp$
|
5998
|
+
task.keyPath = prevKeyPath$jscomp$6;
|
5718
5999
|
return;
|
5719
6000
|
case REACT_LAZY_TYPE:
|
5720
6001
|
var Component = callLazyInitInDEV(type);
|
@@ -5845,26 +6126,20 @@
|
|
5845
6126
|
node = null === node[4] ? null : node[4][3];
|
5846
6127
|
var prevKeyPath = task.keyPath,
|
5847
6128
|
prevContext = task.formatContext,
|
6129
|
+
prevRow = task.row,
|
5848
6130
|
previousReplaySet = task.replay,
|
5849
6131
|
parentBoundary = task.blockedBoundary,
|
5850
6132
|
parentHoistableState = task.hoistableState,
|
5851
6133
|
content = props.children,
|
5852
6134
|
fallback = props.fallback,
|
5853
6135
|
fallbackAbortSet = new Set();
|
5854
|
-
props =
|
5855
|
-
|
5856
|
-
|
5857
|
-
|
5858
|
-
|
5859
|
-
|
5860
|
-
|
5861
|
-
)
|
5862
|
-
: createSuspenseBoundary(
|
5863
|
-
request,
|
5864
|
-
fallbackAbortSet,
|
5865
|
-
null,
|
5866
|
-
null
|
5867
|
-
);
|
6136
|
+
props = createSuspenseBoundary(
|
6137
|
+
request,
|
6138
|
+
task.row,
|
6139
|
+
fallbackAbortSet,
|
6140
|
+
null,
|
6141
|
+
null
|
6142
|
+
);
|
5868
6143
|
props.parentFlushed = !0;
|
5869
6144
|
props.rootSegmentID = name;
|
5870
6145
|
task.blockedBoundary = props;
|
@@ -5874,6 +6149,7 @@
|
|
5874
6149
|
request.resumableState,
|
5875
6150
|
prevContext
|
5876
6151
|
);
|
6152
|
+
task.row = null;
|
5877
6153
|
task.replay = { nodes: type, slots: ref, pendingTasks: 1 };
|
5878
6154
|
try {
|
5879
6155
|
renderNode(request, task, content, -1);
|
@@ -5907,7 +6183,8 @@
|
|
5907
6183
|
(task.hoistableState = parentHoistableState),
|
5908
6184
|
(task.replay = previousReplaySet),
|
5909
6185
|
(task.keyPath = prevKeyPath),
|
5910
|
-
(task.formatContext = prevContext)
|
6186
|
+
(task.formatContext = prevContext),
|
6187
|
+
(task.row = prevRow);
|
5911
6188
|
}
|
5912
6189
|
props = createReplayTask(
|
5913
6190
|
request,
|
@@ -5925,6 +6202,7 @@
|
|
5925
6202
|
),
|
5926
6203
|
task.context,
|
5927
6204
|
task.treeContext,
|
6205
|
+
task.row,
|
5928
6206
|
task.componentStack,
|
5929
6207
|
emptyContextObject,
|
5930
6208
|
task.debugTask
|
@@ -5938,6 +6216,35 @@
|
|
5938
6216
|
}
|
5939
6217
|
}
|
5940
6218
|
}
|
6219
|
+
function validateIterable(
|
6220
|
+
task,
|
6221
|
+
iterable,
|
6222
|
+
childIndex,
|
6223
|
+
iterator,
|
6224
|
+
iteratorFn
|
6225
|
+
) {
|
6226
|
+
if (iterator === iterable) {
|
6227
|
+
if (
|
6228
|
+
-1 !== childIndex ||
|
6229
|
+
null === task.componentStack ||
|
6230
|
+
"function" !== typeof task.componentStack.type ||
|
6231
|
+
"[object GeneratorFunction]" !==
|
6232
|
+
Object.prototype.toString.call(task.componentStack.type) ||
|
6233
|
+
"[object Generator]" !== Object.prototype.toString.call(iterator)
|
6234
|
+
)
|
6235
|
+
didWarnAboutGenerators ||
|
6236
|
+
console.error(
|
6237
|
+
"Using Iterators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. You can also use an Iterable that can iterate multiple times over the same items."
|
6238
|
+
),
|
6239
|
+
(didWarnAboutGenerators = !0);
|
6240
|
+
} else
|
6241
|
+
iterable.entries !== iteratorFn ||
|
6242
|
+
didWarnAboutMaps ||
|
6243
|
+
(console.error(
|
6244
|
+
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
6245
|
+
),
|
6246
|
+
(didWarnAboutMaps = !0));
|
6247
|
+
}
|
5941
6248
|
function renderNodeDestructive(request, task, node, childIndex) {
|
5942
6249
|
null !== task.replay && "number" === typeof task.replay.slots
|
5943
6250
|
? resumeNode(request, task, task.replay.slots, node, childIndex)
|
@@ -6014,52 +6321,27 @@
|
|
6014
6321
|
"Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render."
|
6015
6322
|
);
|
6016
6323
|
case REACT_LAZY_TYPE:
|
6017
|
-
|
6324
|
+
type = callLazyInitInDEV(node);
|
6018
6325
|
if (12 === request.status) throw null;
|
6019
|
-
renderNodeDestructive(request, task,
|
6326
|
+
renderNodeDestructive(request, task, type, childIndex);
|
6020
6327
|
return;
|
6021
6328
|
}
|
6022
6329
|
if (isArrayImpl(node)) {
|
6023
6330
|
renderChildrenArray(request, task, node, childIndex);
|
6024
6331
|
return;
|
6025
6332
|
}
|
6026
|
-
|
6027
|
-
|
6028
|
-
|
6029
|
-
|
6030
|
-
|
6031
|
-
|
6032
|
-
|
6033
|
-
|
6034
|
-
|
6035
|
-
|
6036
|
-
|
6037
|
-
"function" !== typeof task.componentStack.type ||
|
6038
|
-
"[object GeneratorFunction]" !==
|
6039
|
-
Object.prototype.toString.call(task.componentStack.type) ||
|
6040
|
-
"[object Generator]" !== Object.prototype.toString.call(type)
|
6041
|
-
)
|
6042
|
-
didWarnAboutGenerators ||
|
6043
|
-
console.error(
|
6044
|
-
"Using Iterators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. You can also use an Iterable that can iterate multiple times over the same items."
|
6045
|
-
),
|
6046
|
-
(didWarnAboutGenerators = !0);
|
6047
|
-
} else
|
6048
|
-
node.entries !== key ||
|
6049
|
-
didWarnAboutMaps ||
|
6050
|
-
(console.error(
|
6051
|
-
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
6052
|
-
),
|
6053
|
-
(didWarnAboutMaps = !0));
|
6054
|
-
node = type.next();
|
6055
|
-
if (!node.done) {
|
6056
|
-
key = [];
|
6057
|
-
do key.push(node.value), (node = type.next());
|
6058
|
-
while (!node.done);
|
6059
|
-
renderChildrenArray(request, task, key, childIndex);
|
6333
|
+
if ((key = getIteratorFn(node)))
|
6334
|
+
if ((type = key.call(node))) {
|
6335
|
+
validateIterable(task, node, childIndex, type, key);
|
6336
|
+
node = type.next();
|
6337
|
+
if (!node.done) {
|
6338
|
+
key = [];
|
6339
|
+
do key.push(node.value), (node = type.next());
|
6340
|
+
while (!node.done);
|
6341
|
+
renderChildrenArray(request, task, key, childIndex);
|
6342
|
+
}
|
6343
|
+
return;
|
6060
6344
|
}
|
6061
|
-
return;
|
6062
|
-
}
|
6063
6345
|
if ("function" === typeof node.then)
|
6064
6346
|
return (
|
6065
6347
|
(task.thenableState = null),
|
@@ -6118,6 +6400,69 @@
|
|
6118
6400
|
));
|
6119
6401
|
}
|
6120
6402
|
}
|
6403
|
+
function warnForMissingKey(request, task, child) {
|
6404
|
+
if (
|
6405
|
+
null !== child &&
|
6406
|
+
"object" === typeof child &&
|
6407
|
+
(child.$$typeof === REACT_ELEMENT_TYPE ||
|
6408
|
+
child.$$typeof === REACT_PORTAL_TYPE) &&
|
6409
|
+
child._store &&
|
6410
|
+
((!child._store.validated && null == child.key) ||
|
6411
|
+
2 === child._store.validated)
|
6412
|
+
) {
|
6413
|
+
if ("object" !== typeof child._store)
|
6414
|
+
throw Error(
|
6415
|
+
"React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue."
|
6416
|
+
);
|
6417
|
+
child._store.validated = 1;
|
6418
|
+
var didWarnForKey = request.didWarnForKey;
|
6419
|
+
null == didWarnForKey &&
|
6420
|
+
(didWarnForKey = request.didWarnForKey = new WeakSet());
|
6421
|
+
request = task.componentStack;
|
6422
|
+
if (null !== request && !didWarnForKey.has(request)) {
|
6423
|
+
didWarnForKey.add(request);
|
6424
|
+
var componentName = getComponentNameFromType(child.type);
|
6425
|
+
didWarnForKey = child._owner;
|
6426
|
+
var parentOwner = request.owner;
|
6427
|
+
request = "";
|
6428
|
+
if (parentOwner && "undefined" !== typeof parentOwner.type) {
|
6429
|
+
var name = getComponentNameFromType(parentOwner.type);
|
6430
|
+
name &&
|
6431
|
+
(request = "\n\nCheck the render method of `" + name + "`.");
|
6432
|
+
}
|
6433
|
+
request ||
|
6434
|
+
(componentName &&
|
6435
|
+
(request =
|
6436
|
+
"\n\nCheck the top-level render call using <" +
|
6437
|
+
componentName +
|
6438
|
+
">."));
|
6439
|
+
componentName = "";
|
6440
|
+
null != didWarnForKey &&
|
6441
|
+
parentOwner !== didWarnForKey &&
|
6442
|
+
((parentOwner = null),
|
6443
|
+
"undefined" !== typeof didWarnForKey.type
|
6444
|
+
? (parentOwner = getComponentNameFromType(didWarnForKey.type))
|
6445
|
+
: "string" === typeof didWarnForKey.name &&
|
6446
|
+
(parentOwner = didWarnForKey.name),
|
6447
|
+
parentOwner &&
|
6448
|
+
(componentName =
|
6449
|
+
" It was passed a child from " + parentOwner + "."));
|
6450
|
+
didWarnForKey = task.componentStack;
|
6451
|
+
task.componentStack = {
|
6452
|
+
parent: task.componentStack,
|
6453
|
+
type: child.type,
|
6454
|
+
owner: child._owner,
|
6455
|
+
stack: child._debugStack
|
6456
|
+
};
|
6457
|
+
console.error(
|
6458
|
+
'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
|
6459
|
+
request,
|
6460
|
+
componentName
|
6461
|
+
);
|
6462
|
+
task.componentStack = didWarnForKey;
|
6463
|
+
}
|
6464
|
+
}
|
6465
|
+
}
|
6121
6466
|
function renderChildrenArray(request, task, children, childIndex) {
|
6122
6467
|
var prevKeyPath = task.keyPath,
|
6123
6468
|
previousComponentStack = task.componentStack;
|
@@ -6211,76 +6556,11 @@
|
|
6211
6556
|
task.debugTask = previousDebugTask;
|
6212
6557
|
return;
|
6213
6558
|
}
|
6214
|
-
for (j = 0; j < replayNodes; j++)
|
6215
|
-
childIndex = children[j]
|
6216
|
-
|
6217
|
-
|
6218
|
-
|
6219
|
-
if (
|
6220
|
-
null !== error &&
|
6221
|
-
"object" === typeof error &&
|
6222
|
-
(error.$$typeof === REACT_ELEMENT_TYPE ||
|
6223
|
-
error.$$typeof === REACT_PORTAL_TYPE) &&
|
6224
|
-
error._store &&
|
6225
|
-
((!error._store.validated && null == error.key) ||
|
6226
|
-
2 === error._store.validated)
|
6227
|
-
) {
|
6228
|
-
if ("object" !== typeof error._store)
|
6229
|
-
throw Error(
|
6230
|
-
"React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue."
|
6231
|
-
);
|
6232
|
-
error._store.validated = 1;
|
6233
|
-
thrownInfo = resumeSlots.didWarnForKey;
|
6234
|
-
null == thrownInfo &&
|
6235
|
-
(thrownInfo = resumeSlots.didWarnForKey = new WeakSet());
|
6236
|
-
resumeSlots = node.componentStack;
|
6237
|
-
if (null !== resumeSlots && !thrownInfo.has(resumeSlots)) {
|
6238
|
-
thrownInfo.add(resumeSlots);
|
6239
|
-
var componentName = getComponentNameFromType(error.type);
|
6240
|
-
thrownInfo = error._owner;
|
6241
|
-
var parentOwner = resumeSlots.owner;
|
6242
|
-
resumeSlots = "";
|
6243
|
-
if (parentOwner && "undefined" !== typeof parentOwner.type) {
|
6244
|
-
var name = getComponentNameFromType(parentOwner.type);
|
6245
|
-
name &&
|
6246
|
-
(resumeSlots =
|
6247
|
-
"\n\nCheck the render method of `" + name + "`.");
|
6248
|
-
}
|
6249
|
-
resumeSlots ||
|
6250
|
-
(componentName &&
|
6251
|
-
(resumeSlots =
|
6252
|
-
"\n\nCheck the top-level render call using <" +
|
6253
|
-
componentName +
|
6254
|
-
">."));
|
6255
|
-
componentName = "";
|
6256
|
-
null != thrownInfo &&
|
6257
|
-
parentOwner !== thrownInfo &&
|
6258
|
-
((parentOwner = null),
|
6259
|
-
"undefined" !== typeof thrownInfo.type
|
6260
|
-
? (parentOwner = getComponentNameFromType(thrownInfo.type))
|
6261
|
-
: "string" === typeof thrownInfo.name &&
|
6262
|
-
(parentOwner = thrownInfo.name),
|
6263
|
-
parentOwner &&
|
6264
|
-
(componentName =
|
6265
|
-
" It was passed a child from " + parentOwner + "."));
|
6266
|
-
thrownInfo = node.componentStack;
|
6267
|
-
node.componentStack = {
|
6268
|
-
parent: node.componentStack,
|
6269
|
-
type: error.type,
|
6270
|
-
owner: error._owner,
|
6271
|
-
stack: error._debugStack
|
6272
|
-
};
|
6273
|
-
console.error(
|
6274
|
-
'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
|
6275
|
-
resumeSlots,
|
6276
|
-
componentName
|
6277
|
-
);
|
6278
|
-
node.componentStack = thrownInfo;
|
6279
|
-
}
|
6280
|
-
}
|
6281
|
-
task.treeContext = pushTreeContext(replay, replayNodes, j);
|
6282
|
-
renderNode(request, task, childIndex, j);
|
6283
|
-
}
|
6559
|
+
for (j = 0; j < replayNodes; j++)
|
6560
|
+
(childIndex = children[j]),
|
6561
|
+
warnForMissingKey(request, task, childIndex),
|
6562
|
+
(task.treeContext = pushTreeContext(replay, replayNodes, j)),
|
6563
|
+
renderNode(request, task, childIndex, j);
|
6284
6564
|
task.treeContext = replay;
|
6285
6565
|
task.keyPath = prevKeyPath;
|
6286
6566
|
task.componentStack = previousComponentStack;
|
@@ -6309,6 +6589,7 @@
|
|
6309
6589
|
task.formatContext,
|
6310
6590
|
task.context,
|
6311
6591
|
task.treeContext,
|
6592
|
+
task.row,
|
6312
6593
|
task.componentStack,
|
6313
6594
|
emptyContextObject,
|
6314
6595
|
task.debugTask
|
@@ -6340,6 +6621,7 @@
|
|
6340
6621
|
task.formatContext,
|
6341
6622
|
task.context,
|
6342
6623
|
task.treeContext,
|
6624
|
+
task.row,
|
6343
6625
|
task.componentStack,
|
6344
6626
|
emptyContextObject,
|
6345
6627
|
task.debugTask
|
@@ -6454,9 +6736,11 @@
|
|
6454
6736
|
throw node;
|
6455
6737
|
}
|
6456
6738
|
function abortTaskSoft(task) {
|
6457
|
-
var boundary = task.blockedBoundary
|
6458
|
-
|
6459
|
-
null !==
|
6739
|
+
var boundary = task.blockedBoundary,
|
6740
|
+
segment = task.blockedSegment;
|
6741
|
+
null !== segment &&
|
6742
|
+
((segment.status = ABORTED),
|
6743
|
+
finishedTask(this, boundary, task.row, segment));
|
6460
6744
|
}
|
6461
6745
|
function abortRemainingReplayNodes(
|
6462
6746
|
request$jscomp$0,
|
@@ -6490,6 +6774,7 @@
|
|
6490
6774
|
wasAborted = aborted,
|
6491
6775
|
resumedBoundary = createSuspenseBoundary(
|
6492
6776
|
request,
|
6777
|
+
null,
|
6493
6778
|
new Set(),
|
6494
6779
|
null,
|
6495
6780
|
null
|
@@ -6534,7 +6819,7 @@
|
|
6534
6819
|
segment = task.blockedSegment;
|
6535
6820
|
if (null !== segment) {
|
6536
6821
|
if (6 === segment.status) return;
|
6537
|
-
segment.status =
|
6822
|
+
segment.status = ABORTED;
|
6538
6823
|
}
|
6539
6824
|
segment = getThrownInfo(task.componentStack);
|
6540
6825
|
if (null === boundary) {
|
@@ -6546,36 +6831,49 @@
|
|
6546
6831
|
return;
|
6547
6832
|
}
|
6548
6833
|
boundary.pendingTasks--;
|
6549
|
-
0 === boundary.pendingTasks &&
|
6550
|
-
|
6551
|
-
|
6834
|
+
if (0 === boundary.pendingTasks && 0 < boundary.nodes.length) {
|
6835
|
+
var errorDigest = logRecoverableError(
|
6836
|
+
request,
|
6837
|
+
error,
|
6838
|
+
segment,
|
6839
|
+
null
|
6840
|
+
);
|
6552
6841
|
abortRemainingReplayNodes(
|
6553
6842
|
request,
|
6554
6843
|
null,
|
6555
6844
|
boundary.nodes,
|
6556
6845
|
boundary.slots,
|
6557
6846
|
error,
|
6558
|
-
|
6847
|
+
errorDigest,
|
6559
6848
|
segment,
|
6560
6849
|
!0
|
6561
|
-
)
|
6850
|
+
);
|
6851
|
+
}
|
6562
6852
|
request.pendingRootTasks--;
|
6563
6853
|
0 === request.pendingRootTasks && completeShell(request);
|
6564
6854
|
}
|
6565
6855
|
} else
|
6566
|
-
boundary.
|
6567
|
-
boundary.status
|
6568
|
-
|
6569
|
-
|
6570
|
-
|
6571
|
-
|
6572
|
-
|
6573
|
-
boundary
|
6574
|
-
|
6856
|
+
boundary.status !== CLIENT_RENDERED &&
|
6857
|
+
((boundary.status = CLIENT_RENDERED),
|
6858
|
+
(errorDigest = logRecoverableError(request, error, segment, null)),
|
6859
|
+
(boundary.status = CLIENT_RENDERED),
|
6860
|
+
encodeErrorForBoundary(boundary, errorDigest, error, segment, !0),
|
6861
|
+
untrackBoundary(request, boundary),
|
6862
|
+
boundary.parentFlushed &&
|
6863
|
+
request.clientRenderedBoundaries.push(boundary)),
|
6864
|
+
boundary.pendingTasks--,
|
6865
|
+
(segment = boundary.row),
|
6866
|
+
null !== segment &&
|
6867
|
+
0 === --segment.pendingTasks &&
|
6868
|
+
finishSuspenseListRow(request, segment),
|
6575
6869
|
boundary.fallbackAbortableTasks.forEach(function (fallbackTask) {
|
6576
6870
|
return abortTask(fallbackTask, request, error);
|
6577
6871
|
}),
|
6578
6872
|
boundary.fallbackAbortableTasks.clear();
|
6873
|
+
task = task.row;
|
6874
|
+
null !== task &&
|
6875
|
+
0 === --task.pendingTasks &&
|
6876
|
+
finishSuspenseListRow(request, task);
|
6579
6877
|
request.allPendingTasks--;
|
6580
6878
|
0 === request.allPendingTasks && completeAll(request);
|
6581
6879
|
}
|
@@ -6677,7 +6975,11 @@
|
|
6677
6975
|
queueCompletedSegment(boundary, childSegment);
|
6678
6976
|
} else boundary.completedSegments.push(segment);
|
6679
6977
|
}
|
6680
|
-
function finishedTask(request, boundary, segment) {
|
6978
|
+
function finishedTask(request, boundary, row, segment) {
|
6979
|
+
null !== row &&
|
6980
|
+
(0 === --row.pendingTasks
|
6981
|
+
? finishSuspenseListRow(request, row)
|
6982
|
+
: row.together && tryToResolveTogetherRow(request, row));
|
6681
6983
|
request.allPendingTasks--;
|
6682
6984
|
if (null === boundary) {
|
6683
6985
|
if (null !== segment && segment.parentFlushed) {
|
@@ -6701,23 +7003,33 @@
|
|
6701
7003
|
boundary.parentFlushed &&
|
6702
7004
|
request.completedBoundaries.push(boundary),
|
6703
7005
|
boundary.status === COMPLETED &&
|
6704
|
-
(
|
7006
|
+
((row = boundary.row),
|
7007
|
+
null !== row &&
|
7008
|
+
hoistHoistables(row.hoistables, boundary.contentState),
|
7009
|
+
500 < boundary.byteSize ||
|
6705
7010
|
(boundary.fallbackAbortableTasks.forEach(
|
6706
7011
|
abortTaskSoft,
|
6707
7012
|
request
|
6708
7013
|
),
|
6709
|
-
boundary.fallbackAbortableTasks.clear()
|
7014
|
+
boundary.fallbackAbortableTasks.clear(),
|
7015
|
+
null !== row &&
|
7016
|
+
0 === --row.pendingTasks &&
|
7017
|
+
finishSuspenseListRow(request, row)),
|
6710
7018
|
0 === request.pendingRootTasks &&
|
6711
7019
|
null === request.trackedPostpones &&
|
6712
7020
|
null !== boundary.contentPreamble &&
|
6713
7021
|
preparePreamble(request)))
|
6714
|
-
: null !== segment &&
|
6715
|
-
|
6716
|
-
|
6717
|
-
|
6718
|
-
|
6719
|
-
|
6720
|
-
|
7022
|
+
: (null !== segment &&
|
7023
|
+
segment.parentFlushed &&
|
7024
|
+
segment.status === COMPLETED &&
|
7025
|
+
(queueCompletedSegment(boundary, segment),
|
7026
|
+
1 === boundary.completedSegments.length &&
|
7027
|
+
boundary.parentFlushed &&
|
7028
|
+
request.partialBoundaries.push(boundary)),
|
7029
|
+
(boundary = boundary.row),
|
7030
|
+
null !== boundary &&
|
7031
|
+
boundary.together &&
|
7032
|
+
tryToResolveTogetherRow(request, boundary)));
|
6721
7033
|
0 === request.allPendingTasks && completeAll(request);
|
6722
7034
|
}
|
6723
7035
|
function performWork(request$jscomp$2) {
|
@@ -6770,7 +7082,12 @@
|
|
6770
7082
|
);
|
6771
7083
|
request.replay.pendingTasks--;
|
6772
7084
|
request.abortSet.delete(request);
|
6773
|
-
finishedTask(
|
7085
|
+
finishedTask(
|
7086
|
+
request$jscomp$0,
|
7087
|
+
request.blockedBoundary,
|
7088
|
+
request.row,
|
7089
|
+
null
|
7090
|
+
);
|
6774
7091
|
} catch (thrownValue) {
|
6775
7092
|
resetHooksState();
|
6776
7093
|
var x =
|
@@ -6851,6 +7168,7 @@
|
|
6851
7168
|
finishedTask(
|
6852
7169
|
request,
|
6853
7170
|
errorDigest.blockedBoundary,
|
7171
|
+
errorDigest.row,
|
6854
7172
|
request$jscomp$1
|
6855
7173
|
);
|
6856
7174
|
} catch (thrownValue) {
|
@@ -6879,40 +7197,49 @@
|
|
6879
7197
|
errorDigest.abortSet.delete(errorDigest);
|
6880
7198
|
request$jscomp$1.status = 4;
|
6881
7199
|
var boundary$jscomp$0 = errorDigest.blockedBoundary,
|
7200
|
+
row = errorDigest.row,
|
6882
7201
|
debugTask = errorDigest.debugTask;
|
7202
|
+
null !== row &&
|
7203
|
+
0 === --row.pendingTasks &&
|
7204
|
+
finishSuspenseListRow(request, row);
|
7205
|
+
request.allPendingTasks--;
|
6883
7206
|
prevTaskInDEV = logRecoverableError(
|
6884
7207
|
request,
|
6885
7208
|
x$jscomp$0,
|
6886
7209
|
errorInfo$jscomp$1,
|
6887
7210
|
debugTask
|
6888
7211
|
);
|
6889
|
-
null === boundary$jscomp$0
|
6890
|
-
|
6891
|
-
|
6892
|
-
|
6893
|
-
|
6894
|
-
|
6895
|
-
|
6896
|
-
|
6897
|
-
|
6898
|
-
|
6899
|
-
|
6900
|
-
|
6901
|
-
|
6902
|
-
|
6903
|
-
|
6904
|
-
|
6905
|
-
|
6906
|
-
|
6907
|
-
|
6908
|
-
|
6909
|
-
|
6910
|
-
|
6911
|
-
|
6912
|
-
|
6913
|
-
|
6914
|
-
|
6915
|
-
|
7212
|
+
if (null === boundary$jscomp$0)
|
7213
|
+
fatalError(
|
7214
|
+
request,
|
7215
|
+
x$jscomp$0,
|
7216
|
+
errorInfo$jscomp$1,
|
7217
|
+
debugTask
|
7218
|
+
);
|
7219
|
+
else if (
|
7220
|
+
(boundary$jscomp$0.pendingTasks--,
|
7221
|
+
boundary$jscomp$0.status !== CLIENT_RENDERED)
|
7222
|
+
) {
|
7223
|
+
boundary$jscomp$0.status = CLIENT_RENDERED;
|
7224
|
+
encodeErrorForBoundary(
|
7225
|
+
boundary$jscomp$0,
|
7226
|
+
prevTaskInDEV,
|
7227
|
+
x$jscomp$0,
|
7228
|
+
errorInfo$jscomp$1,
|
7229
|
+
!1
|
7230
|
+
);
|
7231
|
+
untrackBoundary(request, boundary$jscomp$0);
|
7232
|
+
var boundaryRow = boundary$jscomp$0.row;
|
7233
|
+
null !== boundaryRow &&
|
7234
|
+
0 === --boundaryRow.pendingTasks &&
|
7235
|
+
finishSuspenseListRow(request, boundaryRow);
|
7236
|
+
boundary$jscomp$0.parentFlushed &&
|
7237
|
+
request.clientRenderedBoundaries.push(boundary$jscomp$0);
|
7238
|
+
0 === request.pendingRootTasks &&
|
7239
|
+
null === request.trackedPostpones &&
|
7240
|
+
null !== boundary$jscomp$0.contentPreamble &&
|
7241
|
+
preparePreamble(request);
|
7242
|
+
}
|
6916
7243
|
0 === request.allPendingTasks && completeAll(request);
|
6917
7244
|
}
|
6918
7245
|
} finally {
|
@@ -7063,10 +7390,14 @@
|
|
7063
7390
|
return flushSubtree(request, destination, segment, hoistableState);
|
7064
7391
|
boundary.parentFlushed = !0;
|
7065
7392
|
if (boundary.status === CLIENT_RENDERED) {
|
7393
|
+
var row = boundary.row;
|
7394
|
+
null !== row &&
|
7395
|
+
0 === --row.pendingTasks &&
|
7396
|
+
finishSuspenseListRow(request, row);
|
7066
7397
|
if (!request.renderState.generateStaticMarkup) {
|
7067
7398
|
var errorDigest = boundary.errorDigest,
|
7068
|
-
errorMessage = boundary.errorMessage
|
7069
|
-
|
7399
|
+
errorMessage = boundary.errorMessage;
|
7400
|
+
row = boundary.errorStack;
|
7070
7401
|
boundary = boundary.errorComponentStack;
|
7071
7402
|
destination.push(startClientRenderedSuspenseBoundary);
|
7072
7403
|
destination.push(clientRenderedSuspenseBoundaryError1);
|
@@ -7084,17 +7415,17 @@
|
|
7084
7415
|
destination.push(
|
7085
7416
|
clientRenderedSuspenseBoundaryErrorAttrInterstitial
|
7086
7417
|
));
|
7087
|
-
|
7418
|
+
row &&
|
7088
7419
|
(destination.push(clientRenderedSuspenseBoundaryError1C),
|
7089
|
-
(
|
7090
|
-
destination.push(
|
7420
|
+
(row = escapeTextForBrowser(row)),
|
7421
|
+
destination.push(row),
|
7091
7422
|
destination.push(
|
7092
7423
|
clientRenderedSuspenseBoundaryErrorAttrInterstitial
|
7093
7424
|
));
|
7094
7425
|
boundary &&
|
7095
7426
|
(destination.push(clientRenderedSuspenseBoundaryError1D),
|
7096
|
-
(
|
7097
|
-
destination.push(
|
7427
|
+
(row = escapeTextForBrowser(boundary)),
|
7428
|
+
destination.push(row),
|
7098
7429
|
destination.push(
|
7099
7430
|
clientRenderedSuspenseBoundaryErrorAttrInterstitial
|
7100
7431
|
));
|
@@ -7118,15 +7449,7 @@
|
|
7118
7449
|
boundary.rootSegmentID
|
7119
7450
|
),
|
7120
7451
|
hoistableState &&
|
7121
|
-
(
|
7122
|
-
errorStack.styles.forEach(
|
7123
|
-
hoistStyleQueueDependency,
|
7124
|
-
hoistableState
|
7125
|
-
),
|
7126
|
-
errorStack.stylesheets.forEach(
|
7127
|
-
hoistStylesheetDependency,
|
7128
|
-
hoistableState
|
7129
|
-
)),
|
7452
|
+
hoistHoistables(hoistableState, boundary.fallbackState),
|
7130
7453
|
flushSubtree(request, destination, segment, hoistableState),
|
7131
7454
|
destination.push(endSuspenseBoundary)
|
7132
7455
|
);
|
@@ -7146,10 +7469,12 @@
|
|
7146
7469
|
destination.push(endSuspenseBoundary)
|
7147
7470
|
);
|
7148
7471
|
flushedByteSize += boundary.byteSize;
|
7149
|
-
hoistableState &&
|
7150
|
-
|
7151
|
-
|
7152
|
-
|
7472
|
+
hoistableState && hoistHoistables(hoistableState, boundary.contentState);
|
7473
|
+
segment = boundary.row;
|
7474
|
+
null !== segment &&
|
7475
|
+
500 < boundary.byteSize &&
|
7476
|
+
0 === --segment.pendingTasks &&
|
7477
|
+
finishSuspenseListRow(request, segment);
|
7153
7478
|
request.renderState.generateStaticMarkup ||
|
7154
7479
|
destination.push(startCompletedSuspenseBoundary);
|
7155
7480
|
segment = boundary.completedSegments;
|
@@ -7192,6 +7517,11 @@
|
|
7192
7517
|
completedSegments[i]
|
7193
7518
|
);
|
7194
7519
|
completedSegments.length = 0;
|
7520
|
+
completedSegments = boundary.row;
|
7521
|
+
null !== completedSegments &&
|
7522
|
+
500 < boundary.byteSize &&
|
7523
|
+
0 === --completedSegments.pendingTasks &&
|
7524
|
+
finishSuspenseListRow(request, completedSegments);
|
7195
7525
|
writeHoistablesForBoundary(
|
7196
7526
|
destination,
|
7197
7527
|
boundary.contentState,
|
@@ -7559,6 +7889,17 @@
|
|
7559
7889
|
break a;
|
7560
7890
|
}
|
7561
7891
|
completedSegments.splice(0, JSCompiler_inline_result);
|
7892
|
+
var row = boundary$jscomp$0.row;
|
7893
|
+
null !== row &&
|
7894
|
+
row.together &&
|
7895
|
+
1 === boundary$jscomp$0.pendingTasks &&
|
7896
|
+
(1 === row.pendingTasks
|
7897
|
+
? unblockSuspenseListRow(
|
7898
|
+
clientRenderedBoundaries,
|
7899
|
+
row,
|
7900
|
+
row.hoistables
|
7901
|
+
)
|
7902
|
+
: row.pendingTasks--);
|
7562
7903
|
JSCompiler_inline_result$jscomp$0 = writeHoistablesForBoundary(
|
7563
7904
|
boundary,
|
7564
7905
|
boundary$jscomp$0.contentState,
|
@@ -9150,6 +9491,7 @@
|
|
9150
9491
|
PENDING = 0,
|
9151
9492
|
COMPLETED = 1,
|
9152
9493
|
FLUSHED = 2,
|
9494
|
+
ABORTED = 3,
|
9153
9495
|
POSTPONED = 5,
|
9154
9496
|
CLOSED = 14,
|
9155
9497
|
currentRequest = null,
|
@@ -9177,5 +9519,5 @@
|
|
9177
9519
|
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
|
9178
9520
|
);
|
9179
9521
|
};
|
9180
|
-
exports.version = "19.2.0-canary-
|
9522
|
+
exports.version = "19.2.0-canary-23884812-20250520";
|
9181
9523
|
})();
|