react-dom 19.2.0-canary-4448b187-20250515 → 19.2.0-canary-c4676e72-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 +456 -173
- package/cjs/react-dom-server-legacy.browser.production.js +376 -123
- package/cjs/react-dom-server-legacy.node.development.js +456 -173
- package/cjs/react-dom-server-legacy.node.production.js +376 -123
- package/cjs/react-dom-server.browser.development.js +455 -172
- package/cjs/react-dom-server.browser.production.js +355 -103
- package/cjs/react-dom-server.bun.development.js +478 -180
- package/cjs/react-dom-server.bun.production.js +375 -108
- package/cjs/react-dom-server.edge.development.js +455 -172
- package/cjs/react-dom-server.edge.production.js +355 -103
- package/cjs/react-dom-server.node.development.js +455 -169
- package/cjs/react-dom-server.node.production.js +355 -103
- 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
@@ -29,8 +29,15 @@ var React = require("react"),
|
|
29
29
|
REACT_LEGACY_HIDDEN_TYPE = Symbol.for("react.legacy_hidden"),
|
30
30
|
REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel"),
|
31
31
|
REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
|
32
|
-
MAYBE_ITERATOR_SYMBOL = Symbol.iterator
|
33
|
-
|
32
|
+
MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
|
33
|
+
function getIteratorFn(maybeIterable) {
|
34
|
+
if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
|
35
|
+
maybeIterable =
|
36
|
+
(MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||
|
37
|
+
maybeIterable["@@iterator"];
|
38
|
+
return "function" === typeof maybeIterable ? maybeIterable : null;
|
39
|
+
}
|
40
|
+
var isArrayImpl = Array.isArray,
|
34
41
|
jsxPropsParents = new WeakMap(),
|
35
42
|
jsxChildrenParents = new WeakMap();
|
36
43
|
function objectName(object) {
|
@@ -1724,7 +1731,8 @@ function getSuspenseViewTransition(parentViewTransition) {
|
|
1724
1731
|
nameIdx: 0
|
1725
1732
|
};
|
1726
1733
|
}
|
1727
|
-
function getSuspenseFallbackFormatContext(parentContext) {
|
1734
|
+
function getSuspenseFallbackFormatContext(resumableState, parentContext) {
|
1735
|
+
parentContext.tagScope & 32 && (resumableState.instructions |= 128);
|
1728
1736
|
return createFormatContext(
|
1729
1737
|
parentContext.insertionMode,
|
1730
1738
|
parentContext.selectedValue,
|
@@ -1732,7 +1740,7 @@ function getSuspenseFallbackFormatContext(parentContext) {
|
|
1732
1740
|
getSuspenseViewTransition(parentContext.viewTransition)
|
1733
1741
|
);
|
1734
1742
|
}
|
1735
|
-
function getSuspenseContentFormatContext(parentContext) {
|
1743
|
+
function getSuspenseContentFormatContext(resumableState, parentContext) {
|
1736
1744
|
return createFormatContext(
|
1737
1745
|
parentContext.insertionMode,
|
1738
1746
|
parentContext.selectedValue,
|
@@ -1746,6 +1754,9 @@ function pushTextInstance(target, text, renderState, textEmbedded) {
|
|
1746
1754
|
target.push(escapeTextForBrowser(text));
|
1747
1755
|
return !0;
|
1748
1756
|
}
|
1757
|
+
function pushSegmentFinale(target, renderState, lastPushedText, textEmbedded) {
|
1758
|
+
lastPushedText && textEmbedded && target.push("\x3c!-- --\x3e");
|
1759
|
+
}
|
1749
1760
|
var styleNameCache = new Map(),
|
1750
1761
|
styleAttributeStart = ' style="',
|
1751
1762
|
styleAssign = ":",
|
@@ -3877,9 +3888,7 @@ var completeSegmentScript1Full =
|
|
3877
3888
|
completeSegmentScript2 = '","',
|
3878
3889
|
completeSegmentScriptEnd = '")\x3c/script>',
|
3879
3890
|
completeBoundaryScriptFunctionOnly =
|
3880
|
-
'$RB=[];$
|
3881
|
-
completeBoundaryScript1Full =
|
3882
|
-
'$RB=[];$RC=function(d,c){function m(){$RT=performance.now();var f=$RB;$RB=[];for(var e=0;e<f.length;e+=2){var a=f[e],l=f[e+1],g=a.parentNode;if(g){var h=a.previousSibling,k=0;do{if(a&&8===a.nodeType){var b=a.data;if("/$"===b||"/&"===b)if(0===k)break;else k--;else"$"!==b&&"$?"!==b&&"$~"!==b&&"$!"!==b&&"&"!==b||k++}b=a.nextSibling;g.removeChild(a);a=b}while(a);for(;l.firstChild;)g.insertBefore(l.firstChild,a);h.data="$";h._reactRetry&&h._reactRetry()}}}if(c=document.getElementById(c))if(c.parentNode.removeChild(c),d=\ndocument.getElementById(d))d.previousSibling.data="$~",$RB.push(d,c),2===$RB.length&&setTimeout(m,("number"!==typeof $RT?0:$RT)+300-performance.now())};$RC("',
|
3891
|
+
'$RB=[];$RV=function(){$RT=performance.now();var d=$RB;$RB=[];for(var a=0;a<d.length;a+=2){var b=d[a],h=d[a+1],e=b.parentNode;if(e){var f=b.previousSibling,g=0;do{if(b&&8===b.nodeType){var c=b.data;if("/$"===c||"/&"===c)if(0===g)break;else g--;else"$"!==c&&"$?"!==c&&"$~"!==c&&"$!"!==c&&"&"!==c||g++}c=b.nextSibling;e.removeChild(b);b=c}while(b);for(;h.firstChild;)e.insertBefore(h.firstChild,b);f.data="$";f._reactRetry&&f._reactRetry()}}};$RC=function(d,a){if(a=document.getElementById(a))if(a.parentNode.removeChild(a),d=document.getElementById(d))d.previousSibling.data="$~",$RB.push(d,a),2===$RB.length&&setTimeout($RV,("number"!==typeof $RT?0:$RT)+300-performance.now())};',
|
3883
3892
|
completeBoundaryScript1Partial = '$RC("',
|
3884
3893
|
completeBoundaryWithStylesScript1FullPartial =
|
3885
3894
|
'$RM=new Map;$RR=function(n,w,p){function u(q){this._p=null;q()}for(var r=new Map,t=document,h,b,e=t.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=e[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&$RM.set(b.getAttribute("href"),b),r.set(b.dataset.precedence,h=b));e=0;b=[];var l,a;for(k=!0;;){if(k){var f=p[e++];if(!f){k=!1;e=0;continue}var c=!1,m=0;var d=f[m++];if(a=$RM.get(d)){var g=a._p;c=!0}else{a=t.createElement("link");a.href=d;a.rel=\n"stylesheet";for(a.dataset.precedence=l=f[m++];g=f[m++];)a.setAttribute(g,f[m++]);g=a._p=new Promise(function(q,x){a.onload=u.bind(a,q);a.onerror=u.bind(a,x)});$RM.set(d,a)}d=a.getAttribute("media");!g||d&&!matchMedia(d).matches||b.push(g);if(c)continue}else{a=v[e++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=r.get(l)||h;c===h&&(h=a);r.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=t.head,c.insertBefore(a,c.firstChild))}if(p=document.getElementById(n))p.previousSibling.data=\n"$~";Promise.all(b).then($RC.bind(null,n,w),$RX.bind(null,n,"CSS failed to load"))};$RR("',
|
@@ -5583,6 +5592,7 @@ var CLIENT_RENDERED = 4,
|
|
5583
5592
|
PENDING = 0,
|
5584
5593
|
COMPLETED = 1,
|
5585
5594
|
FLUSHED = 2,
|
5595
|
+
ABORTED = 3,
|
5586
5596
|
POSTPONED = 5,
|
5587
5597
|
CLOSED = 14;
|
5588
5598
|
function defaultErrorHandler(error) {
|
@@ -5712,6 +5722,7 @@ function createRequest(
|
|
5712
5722
|
null,
|
5713
5723
|
emptyTreeContext,
|
5714
5724
|
null,
|
5725
|
+
null,
|
5715
5726
|
emptyContextObject,
|
5716
5727
|
null
|
5717
5728
|
);
|
@@ -5734,15 +5745,17 @@ function pingTask(request, task) {
|
|
5734
5745
|
}
|
5735
5746
|
function createSuspenseBoundary(
|
5736
5747
|
request,
|
5748
|
+
row,
|
5737
5749
|
fallbackAbortableTasks,
|
5738
5750
|
contentPreamble,
|
5739
5751
|
fallbackPreamble
|
5740
5752
|
) {
|
5741
|
-
|
5753
|
+
fallbackAbortableTasks = {
|
5742
5754
|
status: PENDING,
|
5743
5755
|
rootSegmentID: -1,
|
5744
5756
|
parentFlushed: !1,
|
5745
5757
|
pendingTasks: 0,
|
5758
|
+
row: row,
|
5746
5759
|
completedSegments: [],
|
5747
5760
|
byteSize: 0,
|
5748
5761
|
fallbackAbortableTasks: fallbackAbortableTasks,
|
@@ -5757,6 +5770,14 @@ function createSuspenseBoundary(
|
|
5757
5770
|
errorStack: null,
|
5758
5771
|
errorComponentStack: null
|
5759
5772
|
};
|
5773
|
+
null !== row &&
|
5774
|
+
(row.pendingTasks++,
|
5775
|
+
(row = row.boundaries),
|
5776
|
+
null !== row &&
|
5777
|
+
(request.allPendingTasks++,
|
5778
|
+
fallbackAbortableTasks.pendingTasks++,
|
5779
|
+
row.push(fallbackAbortableTasks)));
|
5780
|
+
return fallbackAbortableTasks;
|
5760
5781
|
}
|
5761
5782
|
function createRenderTask(
|
5762
5783
|
request,
|
@@ -5772,6 +5793,7 @@ function createRenderTask(
|
|
5772
5793
|
formatContext,
|
5773
5794
|
context,
|
5774
5795
|
treeContext,
|
5796
|
+
row,
|
5775
5797
|
componentStack,
|
5776
5798
|
legacyContext,
|
5777
5799
|
debugTask
|
@@ -5780,6 +5802,7 @@ function createRenderTask(
|
|
5780
5802
|
null === blockedBoundary
|
5781
5803
|
? request.pendingRootTasks++
|
5782
5804
|
: blockedBoundary.pendingTasks++;
|
5805
|
+
null !== row && row.pendingTasks++;
|
5783
5806
|
var task = {
|
5784
5807
|
replay: null,
|
5785
5808
|
node: node,
|
@@ -5796,6 +5819,7 @@ function createRenderTask(
|
|
5796
5819
|
formatContext: formatContext,
|
5797
5820
|
context: context,
|
5798
5821
|
treeContext: treeContext,
|
5822
|
+
row: row,
|
5799
5823
|
componentStack: componentStack,
|
5800
5824
|
thenableState: thenableState
|
5801
5825
|
};
|
@@ -5816,6 +5840,7 @@ function createReplayTask(
|
|
5816
5840
|
formatContext,
|
5817
5841
|
context,
|
5818
5842
|
treeContext,
|
5843
|
+
row,
|
5819
5844
|
componentStack,
|
5820
5845
|
legacyContext,
|
5821
5846
|
debugTask
|
@@ -5824,6 +5849,7 @@ function createReplayTask(
|
|
5824
5849
|
null === blockedBoundary
|
5825
5850
|
? request.pendingRootTasks++
|
5826
5851
|
: blockedBoundary.pendingTasks++;
|
5852
|
+
null !== row && row.pendingTasks++;
|
5827
5853
|
replay.pendingTasks++;
|
5828
5854
|
var task = {
|
5829
5855
|
replay: replay,
|
@@ -5841,6 +5867,7 @@ function createReplayTask(
|
|
5841
5867
|
formatContext: formatContext,
|
5842
5868
|
context: context,
|
5843
5869
|
treeContext: treeContext,
|
5870
|
+
row: row,
|
5844
5871
|
componentStack: componentStack,
|
5845
5872
|
thenableState: thenableState
|
5846
5873
|
};
|
@@ -6024,6 +6051,140 @@ function fatalError(request, error, errorInfo, debugTask) {
|
|
6024
6051
|
? ((request.status = CLOSED), closeWithError(request.destination, error))
|
6025
6052
|
: ((request.status = 13), (request.fatalError = error));
|
6026
6053
|
}
|
6054
|
+
function finishSuspenseListRow(request, row) {
|
6055
|
+
for (row = row.next; null !== row; ) {
|
6056
|
+
var unblockedBoundaries = row.boundaries;
|
6057
|
+
if (null !== unblockedBoundaries) {
|
6058
|
+
row.boundaries = null;
|
6059
|
+
for (var i = 0; i < unblockedBoundaries.length; i++)
|
6060
|
+
finishedTask(request, unblockedBoundaries[i], null, null);
|
6061
|
+
}
|
6062
|
+
row.pendingTasks--;
|
6063
|
+
if (0 < row.pendingTasks) break;
|
6064
|
+
row = row.next;
|
6065
|
+
}
|
6066
|
+
}
|
6067
|
+
function createSuspenseListRow(previousRow) {
|
6068
|
+
var newRow = { pendingTasks: 1, boundaries: null, next: null };
|
6069
|
+
null !== previousRow &&
|
6070
|
+
0 < previousRow.pendingTasks &&
|
6071
|
+
(newRow.pendingTasks++,
|
6072
|
+
(newRow.boundaries = []),
|
6073
|
+
(previousRow.next = newRow));
|
6074
|
+
return newRow;
|
6075
|
+
}
|
6076
|
+
function renderSuspenseListRows(request, task, keyPath, rows, revealOrder) {
|
6077
|
+
keyPath = task.keyPath;
|
6078
|
+
var previousComponentStack = task.componentStack;
|
6079
|
+
var previousDebugTask = task.debugTask;
|
6080
|
+
pushServerComponentStack(task, task.node.props.children._debugInfo);
|
6081
|
+
var prevTreeContext = task.treeContext,
|
6082
|
+
prevRow = task.row,
|
6083
|
+
totalChildren = rows.length,
|
6084
|
+
previousSuspenseListRow = null;
|
6085
|
+
if (null !== task.replay) {
|
6086
|
+
var resumeSlots = task.replay.slots;
|
6087
|
+
if (null !== resumeSlots && "object" === typeof resumeSlots)
|
6088
|
+
for (var n = 0; n < totalChildren; n++) {
|
6089
|
+
var i = "backwards" !== revealOrder ? n : totalChildren - 1 - n,
|
6090
|
+
node = rows[i];
|
6091
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
6092
|
+
previousSuspenseListRow
|
6093
|
+
);
|
6094
|
+
task.treeContext = pushTreeContext(prevTreeContext, totalChildren, i);
|
6095
|
+
var resumeSegmentID = resumeSlots[i];
|
6096
|
+
"number" === typeof resumeSegmentID
|
6097
|
+
? (resumeNode(request, task, resumeSegmentID, node, i),
|
6098
|
+
delete resumeSlots[i])
|
6099
|
+
: renderNode(request, task, node, i);
|
6100
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
6101
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
6102
|
+
}
|
6103
|
+
else
|
6104
|
+
for (resumeSlots = 0; resumeSlots < totalChildren; resumeSlots++)
|
6105
|
+
(n =
|
6106
|
+
"backwards" !== revealOrder
|
6107
|
+
? resumeSlots
|
6108
|
+
: totalChildren - 1 - resumeSlots),
|
6109
|
+
(i = rows[n]),
|
6110
|
+
warnForMissingKey(request, task, i),
|
6111
|
+
(task.row = previousSuspenseListRow =
|
6112
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
6113
|
+
(task.treeContext = pushTreeContext(
|
6114
|
+
prevTreeContext,
|
6115
|
+
totalChildren,
|
6116
|
+
n
|
6117
|
+
)),
|
6118
|
+
renderNode(request, task, i, n),
|
6119
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
6120
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
6121
|
+
} else if ("backwards" !== revealOrder)
|
6122
|
+
for (revealOrder = 0; revealOrder < totalChildren; revealOrder++)
|
6123
|
+
(resumeSlots = rows[revealOrder]),
|
6124
|
+
warnForMissingKey(request, task, resumeSlots),
|
6125
|
+
(task.row = previousSuspenseListRow =
|
6126
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
6127
|
+
(task.treeContext = pushTreeContext(
|
6128
|
+
prevTreeContext,
|
6129
|
+
totalChildren,
|
6130
|
+
revealOrder
|
6131
|
+
)),
|
6132
|
+
renderNode(request, task, resumeSlots, revealOrder),
|
6133
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
6134
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
6135
|
+
else {
|
6136
|
+
revealOrder = task.blockedSegment;
|
6137
|
+
resumeSlots = revealOrder.children.length;
|
6138
|
+
n = revealOrder.chunks.length;
|
6139
|
+
for (i = totalChildren - 1; 0 <= i; i--) {
|
6140
|
+
node = rows[i];
|
6141
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
6142
|
+
previousSuspenseListRow
|
6143
|
+
);
|
6144
|
+
task.treeContext = pushTreeContext(prevTreeContext, totalChildren, i);
|
6145
|
+
resumeSegmentID = createPendingSegment(
|
6146
|
+
request,
|
6147
|
+
n,
|
6148
|
+
null,
|
6149
|
+
task.formatContext,
|
6150
|
+
0 === i ? revealOrder.lastPushedText : !0,
|
6151
|
+
!0
|
6152
|
+
);
|
6153
|
+
revealOrder.children.splice(resumeSlots, 0, resumeSegmentID);
|
6154
|
+
task.blockedSegment = resumeSegmentID;
|
6155
|
+
warnForMissingKey(request, task, node);
|
6156
|
+
try {
|
6157
|
+
renderNode(request, task, node, i),
|
6158
|
+
pushSegmentFinale(
|
6159
|
+
resumeSegmentID.chunks,
|
6160
|
+
request.renderState,
|
6161
|
+
resumeSegmentID.lastPushedText,
|
6162
|
+
resumeSegmentID.textEmbedded
|
6163
|
+
),
|
6164
|
+
(resumeSegmentID.status = COMPLETED),
|
6165
|
+
finishedSegment(request, task.blockedBoundary, resumeSegmentID),
|
6166
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
6167
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
6168
|
+
} catch (thrownValue) {
|
6169
|
+
throw (
|
6170
|
+
((resumeSegmentID.status = 12 === request.status ? ABORTED : 4),
|
6171
|
+
thrownValue)
|
6172
|
+
);
|
6173
|
+
}
|
6174
|
+
}
|
6175
|
+
task.blockedSegment = revealOrder;
|
6176
|
+
revealOrder.lastPushedText = !1;
|
6177
|
+
}
|
6178
|
+
null !== prevRow &&
|
6179
|
+
null !== previousSuspenseListRow &&
|
6180
|
+
0 < previousSuspenseListRow.pendingTasks &&
|
6181
|
+
(prevRow.pendingTasks++, (previousSuspenseListRow.next = prevRow));
|
6182
|
+
task.treeContext = prevTreeContext;
|
6183
|
+
task.row = prevRow;
|
6184
|
+
task.keyPath = keyPath;
|
6185
|
+
task.componentStack = previousComponentStack;
|
6186
|
+
task.debugTask = previousDebugTask;
|
6187
|
+
}
|
6027
6188
|
function renderWithHooks(request, task, keyPath, Component, props, secondArg) {
|
6028
6189
|
var prevThenableState = task.thenableState;
|
6029
6190
|
task.thenableState = null;
|
@@ -6558,6 +6719,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6558
6719
|
task.formatContext,
|
6559
6720
|
task.context,
|
6560
6721
|
task.treeContext,
|
6722
|
+
task.row,
|
6561
6723
|
task.componentStack,
|
6562
6724
|
emptyContextObject,
|
6563
6725
|
task.debugTask
|
@@ -6641,10 +6803,53 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6641
6803
|
}
|
6642
6804
|
return;
|
6643
6805
|
case REACT_SUSPENSE_LIST_TYPE:
|
6644
|
-
|
6645
|
-
|
6646
|
-
|
6647
|
-
|
6806
|
+
a: {
|
6807
|
+
var children$jscomp$0 = props.children,
|
6808
|
+
revealOrder = props.revealOrder;
|
6809
|
+
if ("forwards" === revealOrder || "backwards" === revealOrder) {
|
6810
|
+
if (isArrayImpl(children$jscomp$0)) {
|
6811
|
+
renderSuspenseListRows(
|
6812
|
+
request,
|
6813
|
+
task,
|
6814
|
+
keyPath,
|
6815
|
+
children$jscomp$0,
|
6816
|
+
revealOrder
|
6817
|
+
);
|
6818
|
+
break a;
|
6819
|
+
}
|
6820
|
+
var iteratorFn = getIteratorFn(children$jscomp$0);
|
6821
|
+
if (iteratorFn) {
|
6822
|
+
var iterator = iteratorFn.call(children$jscomp$0);
|
6823
|
+
if (iterator) {
|
6824
|
+
validateIterable(
|
6825
|
+
task,
|
6826
|
+
children$jscomp$0,
|
6827
|
+
-1,
|
6828
|
+
iterator,
|
6829
|
+
iteratorFn
|
6830
|
+
);
|
6831
|
+
var step = iterator.next();
|
6832
|
+
if (!step.done) {
|
6833
|
+
var rows = [];
|
6834
|
+
do rows.push(step.value), (step = iterator.next());
|
6835
|
+
while (!step.done);
|
6836
|
+
renderSuspenseListRows(
|
6837
|
+
request,
|
6838
|
+
task,
|
6839
|
+
keyPath,
|
6840
|
+
children$jscomp$0,
|
6841
|
+
revealOrder
|
6842
|
+
);
|
6843
|
+
}
|
6844
|
+
break a;
|
6845
|
+
}
|
6846
|
+
}
|
6847
|
+
}
|
6848
|
+
var prevKeyPath$jscomp$3 = task.keyPath;
|
6849
|
+
task.keyPath = keyPath;
|
6850
|
+
renderNodeDestructive(request, task, children$jscomp$0, -1);
|
6851
|
+
task.keyPath = prevKeyPath$jscomp$3;
|
6852
|
+
}
|
6648
6853
|
return;
|
6649
6854
|
case REACT_VIEW_TRANSITION_TYPE:
|
6650
6855
|
case REACT_SCOPE_TYPE:
|
@@ -6652,18 +6857,26 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6652
6857
|
case REACT_SUSPENSE_TYPE:
|
6653
6858
|
a: if (null !== task.replay) {
|
6654
6859
|
var _prevKeyPath = task.keyPath,
|
6655
|
-
_prevContext = task.formatContext
|
6860
|
+
_prevContext = task.formatContext,
|
6861
|
+
_prevRow = task.row;
|
6656
6862
|
task.keyPath = keyPath;
|
6657
|
-
task.formatContext = getSuspenseContentFormatContext(
|
6863
|
+
task.formatContext = getSuspenseContentFormatContext(
|
6864
|
+
request.resumableState,
|
6865
|
+
_prevContext
|
6866
|
+
);
|
6867
|
+
task.row = null;
|
6658
6868
|
var _content = props.children;
|
6659
6869
|
try {
|
6660
6870
|
renderNode(request, task, _content, -1);
|
6661
6871
|
} finally {
|
6662
|
-
(task.keyPath = _prevKeyPath),
|
6872
|
+
(task.keyPath = _prevKeyPath),
|
6873
|
+
(task.formatContext = _prevContext),
|
6874
|
+
(task.row = _prevRow);
|
6663
6875
|
}
|
6664
6876
|
} else {
|
6665
|
-
var prevKeyPath$jscomp$
|
6877
|
+
var prevKeyPath$jscomp$4 = task.keyPath,
|
6666
6878
|
prevContext$jscomp$0 = task.formatContext,
|
6879
|
+
prevRow = task.row,
|
6667
6880
|
parentBoundary = task.blockedBoundary,
|
6668
6881
|
parentPreamble = task.blockedPreamble,
|
6669
6882
|
parentHoistableState = task.hoistableState,
|
@@ -6675,11 +6888,18 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6675
6888
|
task.formatContext.insertionMode < HTML_MODE
|
6676
6889
|
? createSuspenseBoundary(
|
6677
6890
|
request,
|
6891
|
+
task.row,
|
6678
6892
|
fallbackAbortSet,
|
6679
6893
|
createPreambleState(),
|
6680
6894
|
createPreambleState()
|
6681
6895
|
)
|
6682
|
-
: createSuspenseBoundary(
|
6896
|
+
: createSuspenseBoundary(
|
6897
|
+
request,
|
6898
|
+
task.row,
|
6899
|
+
fallbackAbortSet,
|
6900
|
+
null,
|
6901
|
+
null
|
6902
|
+
);
|
6683
6903
|
null !== request.trackedPostpones &&
|
6684
6904
|
(newBoundary.trackedContentKeyPath = keyPath);
|
6685
6905
|
var boundarySegment = createPendingSegment(
|
@@ -6717,25 +6937,30 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6717
6937
|
task.blockedSegment = boundarySegment;
|
6718
6938
|
task.blockedPreamble = newBoundary.fallbackPreamble;
|
6719
6939
|
task.keyPath = fallbackKeyPath;
|
6720
|
-
task.formatContext =
|
6721
|
-
|
6940
|
+
task.formatContext = getSuspenseFallbackFormatContext(
|
6941
|
+
request.resumableState,
|
6942
|
+
prevContext$jscomp$0
|
6943
|
+
);
|
6722
6944
|
boundarySegment.status = 6;
|
6723
6945
|
try {
|
6724
6946
|
renderNode(request, task, fallback, -1),
|
6725
|
-
|
6726
|
-
boundarySegment.
|
6727
|
-
|
6947
|
+
pushSegmentFinale(
|
6948
|
+
boundarySegment.chunks,
|
6949
|
+
request.renderState,
|
6950
|
+
boundarySegment.lastPushedText,
|
6951
|
+
boundarySegment.textEmbedded
|
6952
|
+
),
|
6728
6953
|
(boundarySegment.status = COMPLETED),
|
6729
6954
|
finishedSegment(request, parentBoundary, boundarySegment);
|
6730
6955
|
} catch (thrownValue) {
|
6731
6956
|
throw (
|
6732
|
-
((boundarySegment.status = 12 === request.status ?
|
6957
|
+
((boundarySegment.status = 12 === request.status ? ABORTED : 4),
|
6733
6958
|
thrownValue)
|
6734
6959
|
);
|
6735
6960
|
} finally {
|
6736
6961
|
(task.blockedSegment = parentSegment),
|
6737
6962
|
(task.blockedPreamble = parentPreamble),
|
6738
|
-
(task.keyPath = prevKeyPath$jscomp$
|
6963
|
+
(task.keyPath = prevKeyPath$jscomp$4),
|
6739
6964
|
(task.formatContext = prevContext$jscomp$0);
|
6740
6965
|
}
|
6741
6966
|
var suspendedPrimaryTask = createRenderTask(
|
@@ -6749,9 +6974,13 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6749
6974
|
newBoundary.contentState,
|
6750
6975
|
task.abortSet,
|
6751
6976
|
keyPath,
|
6752
|
-
getSuspenseContentFormatContext(
|
6977
|
+
getSuspenseContentFormatContext(
|
6978
|
+
request.resumableState,
|
6979
|
+
task.formatContext
|
6980
|
+
),
|
6753
6981
|
task.context,
|
6754
6982
|
task.treeContext,
|
6983
|
+
null,
|
6755
6984
|
task.componentStack,
|
6756
6985
|
emptyContextObject,
|
6757
6986
|
task.debugTask
|
@@ -6764,15 +6993,21 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6764
6993
|
task.hoistableState = newBoundary.contentState;
|
6765
6994
|
task.blockedSegment = contentRootSegment;
|
6766
6995
|
task.keyPath = keyPath;
|
6767
|
-
task.formatContext =
|
6768
|
-
|
6996
|
+
task.formatContext = getSuspenseContentFormatContext(
|
6997
|
+
request.resumableState,
|
6998
|
+
prevContext$jscomp$0
|
6999
|
+
);
|
7000
|
+
task.row = null;
|
6769
7001
|
contentRootSegment.status = 6;
|
6770
7002
|
try {
|
6771
7003
|
if (
|
6772
7004
|
(renderNode(request, task, content, -1),
|
6773
|
-
|
6774
|
-
contentRootSegment.
|
6775
|
-
|
7005
|
+
pushSegmentFinale(
|
7006
|
+
contentRootSegment.chunks,
|
7007
|
+
request.renderState,
|
7008
|
+
contentRootSegment.lastPushedText,
|
7009
|
+
contentRootSegment.textEmbedded
|
7010
|
+
),
|
6776
7011
|
(contentRootSegment.status = COMPLETED),
|
6777
7012
|
finishedSegment(request, newBoundary, contentRootSegment),
|
6778
7013
|
queueCompletedSegment(newBoundary, contentRootSegment),
|
@@ -6781,6 +7016,9 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6781
7016
|
((newBoundary.status = COMPLETED),
|
6782
7017
|
!(500 < newBoundary.byteSize)))
|
6783
7018
|
) {
|
7019
|
+
null !== prevRow &&
|
7020
|
+
0 === --prevRow.pendingTasks &&
|
7021
|
+
finishSuspenseListRow(request, prevRow);
|
6784
7022
|
0 === request.pendingRootTasks &&
|
6785
7023
|
task.blockedPreamble &&
|
6786
7024
|
preparePreamble(request);
|
@@ -6789,7 +7027,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6789
7027
|
} catch (thrownValue$2) {
|
6790
7028
|
newBoundary.status = CLIENT_RENDERED;
|
6791
7029
|
if (12 === request.status) {
|
6792
|
-
contentRootSegment.status =
|
7030
|
+
contentRootSegment.status = ABORTED;
|
6793
7031
|
var error = request.fatalError;
|
6794
7032
|
} else (contentRootSegment.status = 4), (error = thrownValue$2);
|
6795
7033
|
var thrownInfo = getThrownInfo(task.componentStack);
|
@@ -6812,8 +7050,9 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6812
7050
|
(task.blockedPreamble = parentPreamble),
|
6813
7051
|
(task.hoistableState = parentHoistableState),
|
6814
7052
|
(task.blockedSegment = parentSegment),
|
6815
|
-
(task.keyPath = prevKeyPath$jscomp$
|
6816
|
-
(task.formatContext = prevContext$jscomp$0)
|
7053
|
+
(task.keyPath = prevKeyPath$jscomp$4),
|
7054
|
+
(task.formatContext = prevContext$jscomp$0),
|
7055
|
+
(task.row = prevRow);
|
6817
7056
|
}
|
6818
7057
|
var suspendedFallbackTask = createRenderTask(
|
6819
7058
|
request,
|
@@ -6826,9 +7065,13 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6826
7065
|
newBoundary.fallbackState,
|
6827
7066
|
fallbackAbortSet,
|
6828
7067
|
[keyPath[0], "Suspense Fallback", keyPath[2]],
|
6829
|
-
getSuspenseFallbackFormatContext(
|
7068
|
+
getSuspenseFallbackFormatContext(
|
7069
|
+
request.resumableState,
|
7070
|
+
task.formatContext
|
7071
|
+
),
|
6830
7072
|
task.context,
|
6831
7073
|
task.treeContext,
|
7074
|
+
task.row,
|
6832
7075
|
task.componentStack,
|
6833
7076
|
emptyContextObject,
|
6834
7077
|
task.debugTask
|
@@ -6847,7 +7090,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6847
7090
|
for (var key in props)
|
6848
7091
|
"ref" !== key && (propsWithoutRef[key] = props[key]);
|
6849
7092
|
} else propsWithoutRef = props;
|
6850
|
-
var children$jscomp$
|
7093
|
+
var children$jscomp$1 = renderWithHooks(
|
6851
7094
|
request,
|
6852
7095
|
task,
|
6853
7096
|
keyPath,
|
@@ -6859,7 +7102,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6859
7102
|
request,
|
6860
7103
|
task,
|
6861
7104
|
keyPath,
|
6862
|
-
children$jscomp$
|
7105
|
+
children$jscomp$1,
|
6863
7106
|
0 !== localIdCounter,
|
6864
7107
|
actionStateCounter,
|
6865
7108
|
actionStateMatchingIndex
|
@@ -6871,9 +7114,9 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6871
7114
|
case REACT_PROVIDER_TYPE:
|
6872
7115
|
case REACT_CONTEXT_TYPE:
|
6873
7116
|
var value$jscomp$0 = props.value,
|
6874
|
-
children$jscomp$
|
7117
|
+
children$jscomp$2 = props.children;
|
6875
7118
|
var prevSnapshot = task.context;
|
6876
|
-
var prevKeyPath$jscomp$
|
7119
|
+
var prevKeyPath$jscomp$5 = task.keyPath;
|
6877
7120
|
var prevValue = type._currentValue;
|
6878
7121
|
type._currentValue = value$jscomp$0;
|
6879
7122
|
void 0 !== type._currentRenderer &&
|
@@ -6894,7 +7137,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6894
7137
|
currentActiveSnapshot = newNode;
|
6895
7138
|
task.context = newNode;
|
6896
7139
|
task.keyPath = keyPath;
|
6897
|
-
renderNodeDestructive(request, task, children$jscomp$
|
7140
|
+
renderNodeDestructive(request, task, children$jscomp$2, -1);
|
6898
7141
|
var prevSnapshot$jscomp$0 = currentActiveSnapshot;
|
6899
7142
|
if (null === prevSnapshot$jscomp$0)
|
6900
7143
|
throw Error(
|
@@ -6916,7 +7159,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6916
7159
|
var JSCompiler_inline_result$jscomp$0 = (currentActiveSnapshot =
|
6917
7160
|
prevSnapshot$jscomp$0.parent);
|
6918
7161
|
task.context = JSCompiler_inline_result$jscomp$0;
|
6919
|
-
task.keyPath = prevKeyPath$jscomp$
|
7162
|
+
task.keyPath = prevKeyPath$jscomp$5;
|
6920
7163
|
prevSnapshot !== task.context &&
|
6921
7164
|
console.error(
|
6922
7165
|
"Popping the context provider did not return back to the original snapshot. This is a bug in React."
|
@@ -6930,10 +7173,10 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
6930
7173
|
"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."
|
6931
7174
|
);
|
6932
7175
|
var newChildren = render(context$jscomp$0._currentValue),
|
6933
|
-
prevKeyPath$jscomp$
|
7176
|
+
prevKeyPath$jscomp$6 = task.keyPath;
|
6934
7177
|
task.keyPath = keyPath;
|
6935
7178
|
renderNodeDestructive(request, task, newChildren, -1);
|
6936
|
-
task.keyPath = prevKeyPath$jscomp$
|
7179
|
+
task.keyPath = prevKeyPath$jscomp$6;
|
6937
7180
|
return;
|
6938
7181
|
case REACT_LAZY_TYPE:
|
6939
7182
|
var Component = callLazyInitInDEV(type);
|
@@ -7062,6 +7305,7 @@ function replayElement(
|
|
7062
7305
|
node = null === node[4] ? null : node[4][3];
|
7063
7306
|
var prevKeyPath = task.keyPath,
|
7064
7307
|
prevContext = task.formatContext,
|
7308
|
+
prevRow = task.row,
|
7065
7309
|
previousReplaySet = task.replay,
|
7066
7310
|
parentBoundary = task.blockedBoundary,
|
7067
7311
|
parentHoistableState = task.hoistableState,
|
@@ -7072,17 +7316,28 @@ function replayElement(
|
|
7072
7316
|
task.formatContext.insertionMode < HTML_MODE
|
7073
7317
|
? createSuspenseBoundary(
|
7074
7318
|
request,
|
7319
|
+
task.row,
|
7075
7320
|
fallbackAbortSet,
|
7076
7321
|
createPreambleState(),
|
7077
7322
|
createPreambleState()
|
7078
7323
|
)
|
7079
|
-
: createSuspenseBoundary(
|
7324
|
+
: createSuspenseBoundary(
|
7325
|
+
request,
|
7326
|
+
task.row,
|
7327
|
+
fallbackAbortSet,
|
7328
|
+
null,
|
7329
|
+
null
|
7330
|
+
);
|
7080
7331
|
props.parentFlushed = !0;
|
7081
7332
|
props.rootSegmentID = name;
|
7082
7333
|
task.blockedBoundary = props;
|
7083
7334
|
task.hoistableState = props.contentState;
|
7084
7335
|
task.keyPath = keyPath;
|
7085
|
-
task.formatContext = getSuspenseContentFormatContext(
|
7336
|
+
task.formatContext = getSuspenseContentFormatContext(
|
7337
|
+
request.resumableState,
|
7338
|
+
prevContext
|
7339
|
+
);
|
7340
|
+
task.row = null;
|
7086
7341
|
task.replay = { nodes: type, slots: ref, pendingTasks: 1 };
|
7087
7342
|
try {
|
7088
7343
|
renderNode(request, task, content, -1);
|
@@ -7113,7 +7368,8 @@ function replayElement(
|
|
7113
7368
|
(task.hoistableState = parentHoistableState),
|
7114
7369
|
(task.replay = previousReplaySet),
|
7115
7370
|
(task.keyPath = prevKeyPath),
|
7116
|
-
(task.formatContext = prevContext)
|
7371
|
+
(task.formatContext = prevContext),
|
7372
|
+
(task.row = prevRow);
|
7117
7373
|
}
|
7118
7374
|
props = createReplayTask(
|
7119
7375
|
request,
|
@@ -7125,9 +7381,13 @@ function replayElement(
|
|
7125
7381
|
props.fallbackState,
|
7126
7382
|
fallbackAbortSet,
|
7127
7383
|
[keyPath[0], "Suspense Fallback", keyPath[2]],
|
7128
|
-
getSuspenseFallbackFormatContext(
|
7384
|
+
getSuspenseFallbackFormatContext(
|
7385
|
+
request.resumableState,
|
7386
|
+
task.formatContext
|
7387
|
+
),
|
7129
7388
|
task.context,
|
7130
7389
|
task.treeContext,
|
7390
|
+
task.row,
|
7131
7391
|
task.componentStack,
|
7132
7392
|
emptyContextObject,
|
7133
7393
|
task.debugTask
|
@@ -7141,6 +7401,29 @@ function replayElement(
|
|
7141
7401
|
}
|
7142
7402
|
}
|
7143
7403
|
}
|
7404
|
+
function validateIterable(task, iterable, childIndex, iterator, iteratorFn) {
|
7405
|
+
if (iterator === iterable) {
|
7406
|
+
if (
|
7407
|
+
-1 !== childIndex ||
|
7408
|
+
null === task.componentStack ||
|
7409
|
+
"function" !== typeof task.componentStack.type ||
|
7410
|
+
"[object GeneratorFunction]" !==
|
7411
|
+
Object.prototype.toString.call(task.componentStack.type) ||
|
7412
|
+
"[object Generator]" !== Object.prototype.toString.call(iterator)
|
7413
|
+
)
|
7414
|
+
didWarnAboutGenerators ||
|
7415
|
+
console.error(
|
7416
|
+
"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."
|
7417
|
+
),
|
7418
|
+
(didWarnAboutGenerators = !0);
|
7419
|
+
} else
|
7420
|
+
iterable.entries !== iteratorFn ||
|
7421
|
+
didWarnAboutMaps ||
|
7422
|
+
(console.error(
|
7423
|
+
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
7424
|
+
),
|
7425
|
+
(didWarnAboutMaps = !0));
|
7426
|
+
}
|
7144
7427
|
function renderNodeDestructive(request, task, node, childIndex) {
|
7145
7428
|
null !== task.replay && "number" === typeof task.replay.slots
|
7146
7429
|
? resumeNode(request, task, task.replay.slots, node, childIndex)
|
@@ -7217,52 +7500,27 @@ function retryNode(request, task) {
|
|
7217
7500
|
"Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render."
|
7218
7501
|
);
|
7219
7502
|
case REACT_LAZY_TYPE:
|
7220
|
-
|
7503
|
+
type = callLazyInitInDEV(node);
|
7221
7504
|
if (12 === request.status) throw null;
|
7222
|
-
renderNodeDestructive(request, task,
|
7505
|
+
renderNodeDestructive(request, task, type, childIndex);
|
7223
7506
|
return;
|
7224
7507
|
}
|
7225
7508
|
if (isArrayImpl(node)) {
|
7226
7509
|
renderChildrenArray(request, task, node, childIndex);
|
7227
7510
|
return;
|
7228
7511
|
}
|
7229
|
-
|
7230
|
-
|
7231
|
-
|
7232
|
-
|
7233
|
-
|
7234
|
-
|
7235
|
-
|
7236
|
-
|
7237
|
-
|
7238
|
-
|
7239
|
-
|
7240
|
-
"function" !== typeof task.componentStack.type ||
|
7241
|
-
"[object GeneratorFunction]" !==
|
7242
|
-
Object.prototype.toString.call(task.componentStack.type) ||
|
7243
|
-
"[object Generator]" !== Object.prototype.toString.call(type)
|
7244
|
-
)
|
7245
|
-
didWarnAboutGenerators ||
|
7246
|
-
console.error(
|
7247
|
-
"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."
|
7248
|
-
),
|
7249
|
-
(didWarnAboutGenerators = !0);
|
7250
|
-
} else
|
7251
|
-
node.entries !== key ||
|
7252
|
-
didWarnAboutMaps ||
|
7253
|
-
(console.error(
|
7254
|
-
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
7255
|
-
),
|
7256
|
-
(didWarnAboutMaps = !0));
|
7257
|
-
node = type.next();
|
7258
|
-
if (!node.done) {
|
7259
|
-
key = [];
|
7260
|
-
do key.push(node.value), (node = type.next());
|
7261
|
-
while (!node.done);
|
7262
|
-
renderChildrenArray(request, task, key, childIndex);
|
7512
|
+
if ((key = getIteratorFn(node)))
|
7513
|
+
if ((type = key.call(node))) {
|
7514
|
+
validateIterable(task, node, childIndex, type, key);
|
7515
|
+
node = type.next();
|
7516
|
+
if (!node.done) {
|
7517
|
+
key = [];
|
7518
|
+
do key.push(node.value), (node = type.next());
|
7519
|
+
while (!node.done);
|
7520
|
+
renderChildrenArray(request, task, key, childIndex);
|
7521
|
+
}
|
7522
|
+
return;
|
7263
7523
|
}
|
7264
|
-
return;
|
7265
|
-
}
|
7266
7524
|
if ("function" === typeof node.then)
|
7267
7525
|
return (
|
7268
7526
|
(task.thenableState = null),
|
@@ -7316,6 +7574,67 @@ function retryNode(request, task) {
|
|
7316
7574
|
));
|
7317
7575
|
}
|
7318
7576
|
}
|
7577
|
+
function warnForMissingKey(request, task, child) {
|
7578
|
+
if (
|
7579
|
+
null !== child &&
|
7580
|
+
"object" === typeof child &&
|
7581
|
+
(child.$$typeof === REACT_ELEMENT_TYPE ||
|
7582
|
+
child.$$typeof === REACT_PORTAL_TYPE) &&
|
7583
|
+
child._store &&
|
7584
|
+
((!child._store.validated && null == child.key) ||
|
7585
|
+
2 === child._store.validated)
|
7586
|
+
) {
|
7587
|
+
if ("object" !== typeof child._store)
|
7588
|
+
throw Error(
|
7589
|
+
"React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue."
|
7590
|
+
);
|
7591
|
+
child._store.validated = 1;
|
7592
|
+
var didWarnForKey = request.didWarnForKey;
|
7593
|
+
null == didWarnForKey &&
|
7594
|
+
(didWarnForKey = request.didWarnForKey = new WeakSet());
|
7595
|
+
request = task.componentStack;
|
7596
|
+
if (null !== request && !didWarnForKey.has(request)) {
|
7597
|
+
didWarnForKey.add(request);
|
7598
|
+
var componentName = getComponentNameFromType(child.type);
|
7599
|
+
didWarnForKey = child._owner;
|
7600
|
+
var parentOwner = request.owner;
|
7601
|
+
request = "";
|
7602
|
+
if (parentOwner && "undefined" !== typeof parentOwner.type) {
|
7603
|
+
var name = getComponentNameFromType(parentOwner.type);
|
7604
|
+
name && (request = "\n\nCheck the render method of `" + name + "`.");
|
7605
|
+
}
|
7606
|
+
request ||
|
7607
|
+
(componentName &&
|
7608
|
+
(request =
|
7609
|
+
"\n\nCheck the top-level render call using <" +
|
7610
|
+
componentName +
|
7611
|
+
">."));
|
7612
|
+
componentName = "";
|
7613
|
+
null != didWarnForKey &&
|
7614
|
+
parentOwner !== didWarnForKey &&
|
7615
|
+
((parentOwner = null),
|
7616
|
+
"undefined" !== typeof didWarnForKey.type
|
7617
|
+
? (parentOwner = getComponentNameFromType(didWarnForKey.type))
|
7618
|
+
: "string" === typeof didWarnForKey.name &&
|
7619
|
+
(parentOwner = didWarnForKey.name),
|
7620
|
+
parentOwner &&
|
7621
|
+
(componentName = " It was passed a child from " + parentOwner + "."));
|
7622
|
+
didWarnForKey = task.componentStack;
|
7623
|
+
task.componentStack = {
|
7624
|
+
parent: task.componentStack,
|
7625
|
+
type: child.type,
|
7626
|
+
owner: child._owner,
|
7627
|
+
stack: child._debugStack
|
7628
|
+
};
|
7629
|
+
console.error(
|
7630
|
+
'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
|
7631
|
+
request,
|
7632
|
+
componentName
|
7633
|
+
);
|
7634
|
+
task.componentStack = didWarnForKey;
|
7635
|
+
}
|
7636
|
+
}
|
7637
|
+
}
|
7319
7638
|
function renderChildrenArray(request, task, children, childIndex) {
|
7320
7639
|
var prevKeyPath = task.keyPath,
|
7321
7640
|
previousComponentStack = task.componentStack;
|
@@ -7402,75 +7721,11 @@ function renderChildrenArray(request, task, children, childIndex) {
|
|
7402
7721
|
task.debugTask = previousDebugTask;
|
7403
7722
|
return;
|
7404
7723
|
}
|
7405
|
-
for (j = 0; j < replayNodes; j++)
|
7406
|
-
childIndex = children[j]
|
7407
|
-
|
7408
|
-
|
7409
|
-
|
7410
|
-
if (
|
7411
|
-
null !== error &&
|
7412
|
-
"object" === typeof error &&
|
7413
|
-
(error.$$typeof === REACT_ELEMENT_TYPE ||
|
7414
|
-
error.$$typeof === REACT_PORTAL_TYPE) &&
|
7415
|
-
error._store &&
|
7416
|
-
((!error._store.validated && null == error.key) ||
|
7417
|
-
2 === error._store.validated)
|
7418
|
-
) {
|
7419
|
-
if ("object" !== typeof error._store)
|
7420
|
-
throw Error(
|
7421
|
-
"React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue."
|
7422
|
-
);
|
7423
|
-
error._store.validated = 1;
|
7424
|
-
thrownInfo = resumeSlots.didWarnForKey;
|
7425
|
-
null == thrownInfo &&
|
7426
|
-
(thrownInfo = resumeSlots.didWarnForKey = new WeakSet());
|
7427
|
-
resumeSlots = node.componentStack;
|
7428
|
-
if (null !== resumeSlots && !thrownInfo.has(resumeSlots)) {
|
7429
|
-
thrownInfo.add(resumeSlots);
|
7430
|
-
var componentName = getComponentNameFromType(error.type);
|
7431
|
-
thrownInfo = error._owner;
|
7432
|
-
var parentOwner = resumeSlots.owner;
|
7433
|
-
resumeSlots = "";
|
7434
|
-
if (parentOwner && "undefined" !== typeof parentOwner.type) {
|
7435
|
-
var name = getComponentNameFromType(parentOwner.type);
|
7436
|
-
name &&
|
7437
|
-
(resumeSlots = "\n\nCheck the render method of `" + name + "`.");
|
7438
|
-
}
|
7439
|
-
resumeSlots ||
|
7440
|
-
(componentName &&
|
7441
|
-
(resumeSlots =
|
7442
|
-
"\n\nCheck the top-level render call using <" +
|
7443
|
-
componentName +
|
7444
|
-
">."));
|
7445
|
-
componentName = "";
|
7446
|
-
null != thrownInfo &&
|
7447
|
-
parentOwner !== thrownInfo &&
|
7448
|
-
((parentOwner = null),
|
7449
|
-
"undefined" !== typeof thrownInfo.type
|
7450
|
-
? (parentOwner = getComponentNameFromType(thrownInfo.type))
|
7451
|
-
: "string" === typeof thrownInfo.name &&
|
7452
|
-
(parentOwner = thrownInfo.name),
|
7453
|
-
parentOwner &&
|
7454
|
-
(componentName =
|
7455
|
-
" It was passed a child from " + parentOwner + "."));
|
7456
|
-
thrownInfo = node.componentStack;
|
7457
|
-
node.componentStack = {
|
7458
|
-
parent: node.componentStack,
|
7459
|
-
type: error.type,
|
7460
|
-
owner: error._owner,
|
7461
|
-
stack: error._debugStack
|
7462
|
-
};
|
7463
|
-
console.error(
|
7464
|
-
'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
|
7465
|
-
resumeSlots,
|
7466
|
-
componentName
|
7467
|
-
);
|
7468
|
-
node.componentStack = thrownInfo;
|
7469
|
-
}
|
7470
|
-
}
|
7471
|
-
task.treeContext = pushTreeContext(replay, replayNodes, j);
|
7472
|
-
renderNode(request, task, childIndex, j);
|
7473
|
-
}
|
7724
|
+
for (j = 0; j < replayNodes; j++)
|
7725
|
+
(childIndex = children[j]),
|
7726
|
+
warnForMissingKey(request, task, childIndex),
|
7727
|
+
(task.treeContext = pushTreeContext(replay, replayNodes, j)),
|
7728
|
+
renderNode(request, task, childIndex, j);
|
7474
7729
|
task.treeContext = replay;
|
7475
7730
|
task.keyPath = prevKeyPath;
|
7476
7731
|
task.componentStack = previousComponentStack;
|
@@ -7499,6 +7754,7 @@ function spawnNewSuspendedReplayTask(request, task, thenableState) {
|
|
7499
7754
|
task.formatContext,
|
7500
7755
|
task.context,
|
7501
7756
|
task.treeContext,
|
7757
|
+
task.row,
|
7502
7758
|
task.componentStack,
|
7503
7759
|
emptyContextObject,
|
7504
7760
|
task.debugTask
|
@@ -7530,6 +7786,7 @@ function spawnNewSuspendedRenderTask(request, task, thenableState) {
|
|
7530
7786
|
task.formatContext,
|
7531
7787
|
task.context,
|
7532
7788
|
task.treeContext,
|
7789
|
+
task.row,
|
7533
7790
|
task.componentStack,
|
7534
7791
|
emptyContextObject,
|
7535
7792
|
task.debugTask
|
@@ -7636,9 +7893,11 @@ function renderNode(request, task, node, childIndex) {
|
|
7636
7893
|
throw node;
|
7637
7894
|
}
|
7638
7895
|
function abortTaskSoft(task) {
|
7639
|
-
var boundary = task.blockedBoundary
|
7640
|
-
|
7641
|
-
null !==
|
7896
|
+
var boundary = task.blockedBoundary,
|
7897
|
+
segment = task.blockedSegment;
|
7898
|
+
null !== segment &&
|
7899
|
+
((segment.status = ABORTED),
|
7900
|
+
finishedTask(this, boundary, task.row, segment));
|
7642
7901
|
}
|
7643
7902
|
function abortRemainingReplayNodes(
|
7644
7903
|
request$jscomp$0,
|
@@ -7672,6 +7931,7 @@ function abortRemainingReplayNodes(
|
|
7672
7931
|
wasAborted = aborted,
|
7673
7932
|
resumedBoundary = createSuspenseBoundary(
|
7674
7933
|
request,
|
7934
|
+
null,
|
7675
7935
|
new Set(),
|
7676
7936
|
null,
|
7677
7937
|
null
|
@@ -7715,8 +7975,12 @@ function abortTask(task, request, error) {
|
|
7715
7975
|
segment = task.blockedSegment;
|
7716
7976
|
if (null !== segment) {
|
7717
7977
|
if (6 === segment.status) return;
|
7718
|
-
segment.status =
|
7978
|
+
segment.status = ABORTED;
|
7719
7979
|
}
|
7980
|
+
segment = task.row;
|
7981
|
+
null !== segment &&
|
7982
|
+
0 === --segment.pendingTasks &&
|
7983
|
+
finishSuspenseListRow(request, segment);
|
7720
7984
|
segment = getThrownInfo(task.componentStack);
|
7721
7985
|
if (null === boundary) {
|
7722
7986
|
if (13 !== request.status && request.status !== CLOSED) {
|
@@ -7864,7 +8128,11 @@ function finishedSegment(request, boundary, segment) {
|
|
7864
8128
|
: (boundary.byteSize += segmentByteSize);
|
7865
8129
|
}
|
7866
8130
|
}
|
7867
|
-
function finishedTask(request, boundary, segment) {
|
8131
|
+
function finishedTask(request, boundary, row, segment) {
|
8132
|
+
null !== row &&
|
8133
|
+
0 === --row.pendingTasks &&
|
8134
|
+
finishSuspenseListRow(request, row);
|
8135
|
+
request.allPendingTasks--;
|
7868
8136
|
if (null === boundary) {
|
7869
8137
|
if (null !== segment && segment.parentFlushed) {
|
7870
8138
|
if (null !== request.completedRootSegment)
|
@@ -7892,7 +8160,11 @@ function finishedTask(request, boundary, segment) {
|
|
7892
8160
|
abortTaskSoft,
|
7893
8161
|
request
|
7894
8162
|
),
|
7895
|
-
boundary.fallbackAbortableTasks.clear()
|
8163
|
+
boundary.fallbackAbortableTasks.clear(),
|
8164
|
+
(row = boundary.row),
|
8165
|
+
null !== row &&
|
8166
|
+
0 === --row.pendingTasks &&
|
8167
|
+
finishSuspenseListRow(request, row)),
|
7896
8168
|
0 === request.pendingRootTasks &&
|
7897
8169
|
null === request.trackedPostpones &&
|
7898
8170
|
null !== boundary.contentPreamble &&
|
@@ -7904,7 +8176,6 @@ function finishedTask(request, boundary, segment) {
|
|
7904
8176
|
1 === boundary.completedSegments.length &&
|
7905
8177
|
boundary.parentFlushed &&
|
7906
8178
|
request.partialBoundaries.push(boundary)));
|
7907
|
-
request.allPendingTasks--;
|
7908
8179
|
0 === request.allPendingTasks && completeAll(request);
|
7909
8180
|
}
|
7910
8181
|
function performWork(request$jscomp$2) {
|
@@ -7954,7 +8225,12 @@ function performWork(request$jscomp$2) {
|
|
7954
8225
|
);
|
7955
8226
|
request.replay.pendingTasks--;
|
7956
8227
|
request.abortSet.delete(request);
|
7957
|
-
finishedTask(
|
8228
|
+
finishedTask(
|
8229
|
+
request$jscomp$0,
|
8230
|
+
request.blockedBoundary,
|
8231
|
+
request.row,
|
8232
|
+
null
|
8233
|
+
);
|
7958
8234
|
} catch (thrownValue) {
|
7959
8235
|
resetHooksState();
|
7960
8236
|
var x =
|
@@ -8024,9 +8300,12 @@ function performWork(request$jscomp$2) {
|
|
8024
8300
|
chunkLength = request$jscomp$1.chunks.length;
|
8025
8301
|
try {
|
8026
8302
|
retryNode(request, errorDigest),
|
8027
|
-
|
8028
|
-
request$jscomp$1.
|
8029
|
-
request
|
8303
|
+
pushSegmentFinale(
|
8304
|
+
request$jscomp$1.chunks,
|
8305
|
+
request.renderState,
|
8306
|
+
request$jscomp$1.lastPushedText,
|
8307
|
+
request$jscomp$1.textEmbedded
|
8308
|
+
),
|
8030
8309
|
errorDigest.abortSet.delete(errorDigest),
|
8031
8310
|
(request$jscomp$1.status = COMPLETED),
|
8032
8311
|
finishedSegment(
|
@@ -8037,6 +8316,7 @@ function performWork(request$jscomp$2) {
|
|
8037
8316
|
finishedTask(
|
8038
8317
|
request,
|
8039
8318
|
errorDigest.blockedBoundary,
|
8319
|
+
errorDigest.row,
|
8040
8320
|
request$jscomp$1
|
8041
8321
|
);
|
8042
8322
|
} catch (thrownValue) {
|
@@ -8065,7 +8345,12 @@ function performWork(request$jscomp$2) {
|
|
8065
8345
|
errorDigest.abortSet.delete(errorDigest);
|
8066
8346
|
request$jscomp$1.status = 4;
|
8067
8347
|
var boundary$jscomp$0 = errorDigest.blockedBoundary,
|
8348
|
+
row = errorDigest.row,
|
8068
8349
|
debugTask = errorDigest.debugTask;
|
8350
|
+
null !== row &&
|
8351
|
+
0 === --row.pendingTasks &&
|
8352
|
+
finishSuspenseListRow(request, row);
|
8353
|
+
request.allPendingTasks--;
|
8069
8354
|
prevTaskInDEV = logRecoverableError(
|
8070
8355
|
request,
|
8071
8356
|
x$jscomp$0,
|
@@ -8091,7 +8376,6 @@ function performWork(request$jscomp$2) {
|
|
8091
8376
|
null === request.trackedPostpones &&
|
8092
8377
|
null !== boundary$jscomp$0.contentPreamble &&
|
8093
8378
|
preparePreamble(request)));
|
8094
|
-
request.allPendingTasks--;
|
8095
8379
|
0 === request.allPendingTasks && completeAll(request);
|
8096
8380
|
}
|
8097
8381
|
} finally {
|
@@ -8240,15 +8524,19 @@ function flushSegment(request, destination, segment, hoistableState) {
|
|
8240
8524
|
return flushSubtree(request, destination, segment, hoistableState);
|
8241
8525
|
boundary.parentFlushed = !0;
|
8242
8526
|
if (boundary.status === CLIENT_RENDERED) {
|
8243
|
-
var
|
8244
|
-
|
8527
|
+
var row = boundary.row;
|
8528
|
+
null !== row &&
|
8529
|
+
0 === --row.pendingTasks &&
|
8530
|
+
finishSuspenseListRow(request, row);
|
8531
|
+
row = boundary.errorDigest;
|
8532
|
+
var errorMessage = boundary.errorMessage,
|
8245
8533
|
errorStack = boundary.errorStack;
|
8246
8534
|
boundary = boundary.errorComponentStack;
|
8247
8535
|
destination.write(startClientRenderedSuspenseBoundary);
|
8248
8536
|
writeChunk(destination, clientRenderedSuspenseBoundaryError1);
|
8249
|
-
|
8537
|
+
row &&
|
8250
8538
|
(writeChunk(destination, clientRenderedSuspenseBoundaryError1A),
|
8251
|
-
writeChunk(destination, escapeTextForBrowser(
|
8539
|
+
writeChunk(destination, escapeTextForBrowser(row)),
|
8252
8540
|
writeChunk(
|
8253
8541
|
destination,
|
8254
8542
|
clientRenderedSuspenseBoundaryErrorAttrInterstitial
|
@@ -8312,6 +8600,11 @@ function flushSegment(request, destination, segment, hoistableState) {
|
|
8312
8600
|
((segment = boundary.contentState),
|
8313
8601
|
segment.styles.forEach(hoistStyleQueueDependency, hoistableState),
|
8314
8602
|
segment.stylesheets.forEach(hoistStylesheetDependency, hoistableState));
|
8603
|
+
segment = boundary.row;
|
8604
|
+
null !== segment &&
|
8605
|
+
500 < boundary.byteSize &&
|
8606
|
+
0 === --segment.pendingTasks &&
|
8607
|
+
finishSuspenseListRow(request, segment);
|
8315
8608
|
destination.write(startCompletedSuspenseBoundary);
|
8316
8609
|
segment = boundary.completedSegments;
|
8317
8610
|
if (1 !== segment.length)
|
@@ -8346,6 +8639,11 @@ function flushCompletedBoundary(request, destination, boundary) {
|
|
8346
8639
|
completedSegments[i]
|
8347
8640
|
);
|
8348
8641
|
completedSegments.length = 0;
|
8642
|
+
completedSegments = boundary.row;
|
8643
|
+
null !== completedSegments &&
|
8644
|
+
500 < boundary.byteSize &&
|
8645
|
+
0 === --completedSegments.pendingTasks &&
|
8646
|
+
finishSuspenseListRow(request, completedSegments);
|
8349
8647
|
writeHoistablesForBoundary(
|
8350
8648
|
destination,
|
8351
8649
|
boundary.contentState,
|
@@ -8373,11 +8671,11 @@ function flushCompletedBoundary(request, destination, boundary) {
|
|
8373
8671
|
? ((completedSegments.instructions |= SentStyleInsertionFunction),
|
8374
8672
|
writeChunk(destination, completeBoundaryWithStylesScript1FullPartial))
|
8375
8673
|
: writeChunk(destination, completeBoundaryWithStylesScript1Partial))
|
8376
|
-
: (completedSegments.instructions & SentCompleteBoundaryFunction) ===
|
8377
|
-
NothingSent
|
8378
|
-
|
8379
|
-
writeChunk(destination,
|
8380
|
-
|
8674
|
+
: ((completedSegments.instructions & SentCompleteBoundaryFunction) ===
|
8675
|
+
NothingSent &&
|
8676
|
+
((completedSegments.instructions |= SentCompleteBoundaryFunction),
|
8677
|
+
writeChunk(destination, completeBoundaryScriptFunctionOnly)),
|
8678
|
+
writeChunk(destination, completeBoundaryScript1Partial));
|
8381
8679
|
completedSegments = i.toString(16);
|
8382
8680
|
writeChunk(destination, request.boundaryPrefix);
|
8383
8681
|
writeChunk(destination, completedSegments);
|
@@ -8771,15 +9069,15 @@ function abort(request, reason) {
|
|
8771
9069
|
fatalError(request, error$4, reason, null);
|
8772
9070
|
}
|
8773
9071
|
}
|
8774
|
-
var isomorphicReactPackageVersion$jscomp$
|
9072
|
+
var isomorphicReactPackageVersion$jscomp$inline_752 = React.version;
|
8775
9073
|
if (
|
8776
|
-
"19.2.0-canary-
|
8777
|
-
isomorphicReactPackageVersion$jscomp$
|
9074
|
+
"19.2.0-canary-c4676e72-20250520" !==
|
9075
|
+
isomorphicReactPackageVersion$jscomp$inline_752
|
8778
9076
|
)
|
8779
9077
|
throw Error(
|
8780
9078
|
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
|
8781
|
-
(isomorphicReactPackageVersion$jscomp$
|
8782
|
-
"\n - react-dom: 19.2.0-canary-
|
9079
|
+
(isomorphicReactPackageVersion$jscomp$inline_752 +
|
9080
|
+
"\n - react-dom: 19.2.0-canary-c4676e72-20250520\nLearn more: https://react.dev/warnings/version-mismatch")
|
8783
9081
|
);
|
8784
9082
|
exports.renderToReadableStream = function (children, options) {
|
8785
9083
|
return new Promise(function (resolve, reject) {
|
@@ -8872,4 +9170,4 @@ exports.renderToReadableStream = function (children, options) {
|
|
8872
9170
|
startWork(request$jscomp$0);
|
8873
9171
|
});
|
8874
9172
|
};
|
8875
|
-
exports.version = "19.2.0-canary-
|
9173
|
+
exports.version = "19.2.0-canary-c4676e72-20250520";
|