react-dom 19.1.0 → 19.2.4
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 +8914 -5783
- package/cjs/react-dom-client.production.js +4167 -3511
- package/cjs/react-dom-profiling.development.js +8921 -5795
- package/cjs/react-dom-profiling.profiling.js +5894 -4044
- package/cjs/react-dom-server-legacy.browser.development.js +1508 -666
- package/cjs/react-dom-server-legacy.browser.production.js +1228 -517
- package/cjs/react-dom-server-legacy.node.development.js +1508 -666
- package/cjs/react-dom-server-legacy.node.production.js +1237 -517
- package/cjs/react-dom-server.browser.development.js +1997 -820
- package/cjs/react-dom-server.browser.production.js +1626 -600
- package/cjs/react-dom-server.bun.development.js +1586 -720
- package/cjs/react-dom-server.bun.production.js +1355 -577
- package/cjs/react-dom-server.edge.development.js +1997 -820
- package/cjs/react-dom-server.edge.production.js +1638 -603
- package/cjs/react-dom-server.node.development.js +2240 -755
- package/cjs/react-dom-server.node.production.js +1928 -593
- 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
- package/server.browser.js +1 -3
- package/server.bun.js +1 -3
- package/server.edge.js +1 -3
- package/server.node.js +3 -3
- package/static.node.js +2 -0
|
@@ -20,7 +20,6 @@ var util = require("util"),
|
|
|
20
20
|
REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"),
|
|
21
21
|
REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"),
|
|
22
22
|
REACT_PROFILER_TYPE = Symbol.for("react.profiler"),
|
|
23
|
-
REACT_PROVIDER_TYPE = Symbol.for("react.provider"),
|
|
24
23
|
REACT_CONSUMER_TYPE = Symbol.for("react.consumer"),
|
|
25
24
|
REACT_CONTEXT_TYPE = Symbol.for("react.context"),
|
|
26
25
|
REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"),
|
|
@@ -33,8 +32,15 @@ var util = require("util"),
|
|
|
33
32
|
REACT_LEGACY_HIDDEN_TYPE = Symbol.for("react.legacy_hidden"),
|
|
34
33
|
REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel"),
|
|
35
34
|
REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
|
|
36
|
-
MAYBE_ITERATOR_SYMBOL = Symbol.iterator
|
|
37
|
-
|
|
35
|
+
MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
|
|
36
|
+
function getIteratorFn(maybeIterable) {
|
|
37
|
+
if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
|
|
38
|
+
maybeIterable =
|
|
39
|
+
(MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||
|
|
40
|
+
maybeIterable["@@iterator"];
|
|
41
|
+
return "function" === typeof maybeIterable ? maybeIterable : null;
|
|
42
|
+
}
|
|
43
|
+
var isArrayImpl = Array.isArray,
|
|
38
44
|
scheduleMicrotask = queueMicrotask;
|
|
39
45
|
function flushBuffered(destination) {
|
|
40
46
|
"function" === typeof destination.flush && destination.flush();
|
|
@@ -123,6 +129,11 @@ var textEncoder = new util.TextEncoder();
|
|
|
123
129
|
function stringToPrecomputedChunk(content) {
|
|
124
130
|
return textEncoder.encode(content);
|
|
125
131
|
}
|
|
132
|
+
function byteLengthOfChunk(chunk) {
|
|
133
|
+
return "string" === typeof chunk
|
|
134
|
+
? Buffer.byteLength(chunk, "utf8")
|
|
135
|
+
: chunk.byteLength;
|
|
136
|
+
}
|
|
126
137
|
var assign = Object.assign,
|
|
127
138
|
hasOwnProperty = Object.prototype.hasOwnProperty,
|
|
128
139
|
VALID_ATTRIBUTE_NAME_REGEX = RegExp(
|
|
@@ -297,16 +308,18 @@ ReactDOMSharedInternals.d = {
|
|
|
297
308
|
S: preinitStyle,
|
|
298
309
|
M: preinitModuleScript
|
|
299
310
|
};
|
|
300
|
-
var PRELOAD_NO_CREDS = []
|
|
311
|
+
var PRELOAD_NO_CREDS = [],
|
|
312
|
+
currentlyFlushingRenderState = null;
|
|
301
313
|
stringToPrecomputedChunk('"></template>');
|
|
302
|
-
var startInlineScript = stringToPrecomputedChunk("<script
|
|
314
|
+
var startInlineScript = stringToPrecomputedChunk("<script"),
|
|
303
315
|
endInlineScript = stringToPrecomputedChunk("\x3c/script>"),
|
|
304
316
|
startScriptSrc = stringToPrecomputedChunk('<script src="'),
|
|
305
317
|
startModuleSrc = stringToPrecomputedChunk('<script type="module" src="'),
|
|
306
|
-
scriptNonce = stringToPrecomputedChunk('
|
|
307
|
-
scriptIntegirty = stringToPrecomputedChunk('
|
|
308
|
-
scriptCrossOrigin = stringToPrecomputedChunk('
|
|
309
|
-
endAsyncScript = stringToPrecomputedChunk('
|
|
318
|
+
scriptNonce = stringToPrecomputedChunk(' nonce="'),
|
|
319
|
+
scriptIntegirty = stringToPrecomputedChunk(' integrity="'),
|
|
320
|
+
scriptCrossOrigin = stringToPrecomputedChunk(' crossorigin="'),
|
|
321
|
+
endAsyncScript = stringToPrecomputedChunk(' async="">\x3c/script>'),
|
|
322
|
+
startInlineStyle = stringToPrecomputedChunk("<style"),
|
|
310
323
|
scriptRegex = /(<\/|<)(s)(cript)/gi;
|
|
311
324
|
function scriptReplacer(match, prefix, s, suffix) {
|
|
312
325
|
return "" + prefix + ("s" === s ? "\\u0073" : "\\u0053") + suffix;
|
|
@@ -323,23 +336,36 @@ function createRenderState(
|
|
|
323
336
|
onHeaders,
|
|
324
337
|
maxHeadersLength
|
|
325
338
|
) {
|
|
339
|
+
externalRuntimeConfig =
|
|
340
|
+
"string" === typeof nonce ? nonce : nonce && nonce.script;
|
|
326
341
|
var inlineScriptWithNonce =
|
|
327
|
-
void 0 ===
|
|
342
|
+
void 0 === externalRuntimeConfig
|
|
328
343
|
? startInlineScript
|
|
329
344
|
: stringToPrecomputedChunk(
|
|
330
|
-
'<script nonce="' +
|
|
345
|
+
'<script nonce="' +
|
|
346
|
+
escapeTextForBrowser(externalRuntimeConfig) +
|
|
347
|
+
'"'
|
|
348
|
+
),
|
|
349
|
+
nonceStyle = "string" === typeof nonce ? void 0 : nonce && nonce.style,
|
|
350
|
+
inlineStyleWithNonce =
|
|
351
|
+
void 0 === nonceStyle
|
|
352
|
+
? startInlineStyle
|
|
353
|
+
: stringToPrecomputedChunk(
|
|
354
|
+
'<style nonce="' + escapeTextForBrowser(nonceStyle) + '"'
|
|
331
355
|
),
|
|
332
|
-
idPrefix = resumableState.idPrefix
|
|
333
|
-
|
|
334
|
-
|
|
356
|
+
idPrefix = resumableState.idPrefix,
|
|
357
|
+
bootstrapChunks = [],
|
|
358
|
+
bootstrapScriptContent = resumableState.bootstrapScriptContent,
|
|
335
359
|
bootstrapScripts = resumableState.bootstrapScripts,
|
|
336
360
|
bootstrapModules = resumableState.bootstrapModules;
|
|
337
361
|
void 0 !== bootstrapScriptContent &&
|
|
338
|
-
|
|
339
|
-
|
|
362
|
+
(bootstrapChunks.push(inlineScriptWithNonce),
|
|
363
|
+
pushCompletedShellIdAttribute(bootstrapChunks, resumableState),
|
|
364
|
+
bootstrapChunks.push(
|
|
365
|
+
endOfStartTag,
|
|
340
366
|
("" + bootstrapScriptContent).replace(scriptRegex, scriptReplacer),
|
|
341
367
|
endInlineScript
|
|
342
|
-
);
|
|
368
|
+
));
|
|
343
369
|
bootstrapScriptContent = [];
|
|
344
370
|
void 0 !== importMap &&
|
|
345
371
|
(bootstrapScriptContent.push(importMapScriptStart),
|
|
@@ -361,9 +387,10 @@ function createRenderState(
|
|
|
361
387
|
segmentPrefix: stringToPrecomputedChunk(idPrefix + "S:"),
|
|
362
388
|
boundaryPrefix: stringToPrecomputedChunk(idPrefix + "B:"),
|
|
363
389
|
startInlineScript: inlineScriptWithNonce,
|
|
390
|
+
startInlineStyle: inlineStyleWithNonce,
|
|
364
391
|
preamble: createPreambleState(),
|
|
365
392
|
externalRuntimeScript: null,
|
|
366
|
-
bootstrapChunks:
|
|
393
|
+
bootstrapChunks: bootstrapChunks,
|
|
367
394
|
importMapChunks: bootstrapScriptContent,
|
|
368
395
|
onHeaders: onHeaders,
|
|
369
396
|
headers: importMap,
|
|
@@ -390,109 +417,119 @@ function createRenderState(
|
|
|
390
417
|
scripts: new Map(),
|
|
391
418
|
moduleScripts: new Map()
|
|
392
419
|
},
|
|
393
|
-
nonce:
|
|
420
|
+
nonce: { script: externalRuntimeConfig, style: nonceStyle },
|
|
394
421
|
hoistableState: null,
|
|
395
422
|
stylesToHoist: !1
|
|
396
423
|
};
|
|
397
424
|
if (void 0 !== bootstrapScripts)
|
|
398
|
-
for (importMap = 0; importMap < bootstrapScripts.length; importMap++)
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
externalRuntimeConfig
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
425
|
+
for (importMap = 0; importMap < bootstrapScripts.length; importMap++)
|
|
426
|
+
(idPrefix = bootstrapScripts[importMap]),
|
|
427
|
+
(nonceStyle = inlineScriptWithNonce = void 0),
|
|
428
|
+
(inlineStyleWithNonce = {
|
|
429
|
+
rel: "preload",
|
|
430
|
+
as: "script",
|
|
431
|
+
fetchPriority: "low",
|
|
432
|
+
nonce: nonce
|
|
433
|
+
}),
|
|
434
|
+
"string" === typeof idPrefix
|
|
435
|
+
? (inlineStyleWithNonce.href = maxHeadersLength = idPrefix)
|
|
436
|
+
: ((inlineStyleWithNonce.href = maxHeadersLength = idPrefix.src),
|
|
437
|
+
(inlineStyleWithNonce.integrity = nonceStyle =
|
|
438
|
+
"string" === typeof idPrefix.integrity
|
|
439
|
+
? idPrefix.integrity
|
|
440
|
+
: void 0),
|
|
441
|
+
(inlineStyleWithNonce.crossOrigin = inlineScriptWithNonce =
|
|
442
|
+
"string" === typeof idPrefix || null == idPrefix.crossOrigin
|
|
443
|
+
? void 0
|
|
444
|
+
: "use-credentials" === idPrefix.crossOrigin
|
|
445
|
+
? "use-credentials"
|
|
446
|
+
: "")),
|
|
447
|
+
(idPrefix = resumableState),
|
|
448
|
+
(bootstrapScriptContent = maxHeadersLength),
|
|
449
|
+
(idPrefix.scriptResources[bootstrapScriptContent] = null),
|
|
450
|
+
(idPrefix.moduleScriptResources[bootstrapScriptContent] = null),
|
|
451
|
+
(idPrefix = []),
|
|
452
|
+
pushLinkImpl(idPrefix, inlineStyleWithNonce),
|
|
453
|
+
onHeaders.bootstrapScripts.add(idPrefix),
|
|
454
|
+
bootstrapChunks.push(
|
|
455
|
+
startScriptSrc,
|
|
456
|
+
escapeTextForBrowser(maxHeadersLength),
|
|
457
|
+
attributeEnd
|
|
458
|
+
),
|
|
459
|
+
externalRuntimeConfig &&
|
|
460
|
+
bootstrapChunks.push(
|
|
461
|
+
scriptNonce,
|
|
462
|
+
escapeTextForBrowser(externalRuntimeConfig),
|
|
463
|
+
attributeEnd
|
|
464
|
+
),
|
|
465
|
+
"string" === typeof nonceStyle &&
|
|
466
|
+
bootstrapChunks.push(
|
|
467
|
+
scriptIntegirty,
|
|
468
|
+
escapeTextForBrowser(nonceStyle),
|
|
469
|
+
attributeEnd
|
|
470
|
+
),
|
|
471
|
+
"string" === typeof inlineScriptWithNonce &&
|
|
472
|
+
bootstrapChunks.push(
|
|
473
|
+
scriptCrossOrigin,
|
|
474
|
+
escapeTextForBrowser(inlineScriptWithNonce),
|
|
475
|
+
attributeEnd
|
|
476
|
+
),
|
|
477
|
+
pushCompletedShellIdAttribute(bootstrapChunks, resumableState),
|
|
478
|
+
bootstrapChunks.push(endAsyncScript);
|
|
445
479
|
if (void 0 !== bootstrapModules)
|
|
446
|
-
for (
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
)
|
|
451
|
-
(bootstrapScriptContent = bootstrapModules[bootstrapScripts]),
|
|
452
|
-
(inlineScriptWithNonce = maxHeadersLength = void 0),
|
|
453
|
-
(idPrefix = {
|
|
480
|
+
for (nonce = 0; nonce < bootstrapModules.length; nonce++)
|
|
481
|
+
(nonceStyle = bootstrapModules[nonce]),
|
|
482
|
+
(maxHeadersLength = importMap = void 0),
|
|
483
|
+
(inlineScriptWithNonce = {
|
|
454
484
|
rel: "modulepreload",
|
|
455
485
|
fetchPriority: "low",
|
|
456
|
-
nonce:
|
|
486
|
+
nonce: externalRuntimeConfig
|
|
457
487
|
}),
|
|
458
|
-
"string" === typeof
|
|
459
|
-
? (
|
|
460
|
-
: ((
|
|
461
|
-
(
|
|
462
|
-
"string" === typeof
|
|
463
|
-
?
|
|
488
|
+
"string" === typeof nonceStyle
|
|
489
|
+
? (inlineScriptWithNonce.href = bootstrapScripts = nonceStyle)
|
|
490
|
+
: ((inlineScriptWithNonce.href = bootstrapScripts = nonceStyle.src),
|
|
491
|
+
(inlineScriptWithNonce.integrity = maxHeadersLength =
|
|
492
|
+
"string" === typeof nonceStyle.integrity
|
|
493
|
+
? nonceStyle.integrity
|
|
464
494
|
: void 0),
|
|
465
|
-
(
|
|
466
|
-
"string" === typeof
|
|
467
|
-
null == bootstrapScriptContent.crossOrigin
|
|
495
|
+
(inlineScriptWithNonce.crossOrigin = importMap =
|
|
496
|
+
"string" === typeof nonceStyle || null == nonceStyle.crossOrigin
|
|
468
497
|
? void 0
|
|
469
|
-
: "use-credentials" ===
|
|
498
|
+
: "use-credentials" === nonceStyle.crossOrigin
|
|
470
499
|
? "use-credentials"
|
|
471
500
|
: "")),
|
|
472
|
-
(
|
|
473
|
-
(
|
|
474
|
-
(
|
|
475
|
-
(
|
|
476
|
-
(
|
|
477
|
-
pushLinkImpl(
|
|
478
|
-
onHeaders.bootstrapScripts.add(
|
|
479
|
-
|
|
501
|
+
(nonceStyle = resumableState),
|
|
502
|
+
(inlineStyleWithNonce = bootstrapScripts),
|
|
503
|
+
(nonceStyle.scriptResources[inlineStyleWithNonce] = null),
|
|
504
|
+
(nonceStyle.moduleScriptResources[inlineStyleWithNonce] = null),
|
|
505
|
+
(nonceStyle = []),
|
|
506
|
+
pushLinkImpl(nonceStyle, inlineScriptWithNonce),
|
|
507
|
+
onHeaders.bootstrapScripts.add(nonceStyle),
|
|
508
|
+
bootstrapChunks.push(
|
|
480
509
|
startModuleSrc,
|
|
481
|
-
escapeTextForBrowser(
|
|
510
|
+
escapeTextForBrowser(bootstrapScripts),
|
|
511
|
+
attributeEnd
|
|
482
512
|
),
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
escapeTextForBrowser(inlineScriptWithNonce)
|
|
513
|
+
externalRuntimeConfig &&
|
|
514
|
+
bootstrapChunks.push(
|
|
515
|
+
scriptNonce,
|
|
516
|
+
escapeTextForBrowser(externalRuntimeConfig),
|
|
517
|
+
attributeEnd
|
|
489
518
|
),
|
|
490
519
|
"string" === typeof maxHeadersLength &&
|
|
491
|
-
|
|
520
|
+
bootstrapChunks.push(
|
|
521
|
+
scriptIntegirty,
|
|
522
|
+
escapeTextForBrowser(maxHeadersLength),
|
|
523
|
+
attributeEnd
|
|
524
|
+
),
|
|
525
|
+
"string" === typeof importMap &&
|
|
526
|
+
bootstrapChunks.push(
|
|
492
527
|
scriptCrossOrigin,
|
|
493
|
-
escapeTextForBrowser(
|
|
528
|
+
escapeTextForBrowser(importMap),
|
|
529
|
+
attributeEnd
|
|
494
530
|
),
|
|
495
|
-
|
|
531
|
+
pushCompletedShellIdAttribute(bootstrapChunks, resumableState),
|
|
532
|
+
bootstrapChunks.push(endAsyncScript);
|
|
496
533
|
return onHeaders;
|
|
497
534
|
}
|
|
498
535
|
function createResumableState(
|
|
@@ -523,18 +560,19 @@ function createResumableState(
|
|
|
523
560
|
};
|
|
524
561
|
}
|
|
525
562
|
function createPreambleState() {
|
|
526
|
-
return {
|
|
527
|
-
htmlChunks: null,
|
|
528
|
-
headChunks: null,
|
|
529
|
-
bodyChunks: null,
|
|
530
|
-
contribution: 0
|
|
531
|
-
};
|
|
563
|
+
return { htmlChunks: null, headChunks: null, bodyChunks: null };
|
|
532
564
|
}
|
|
533
|
-
function createFormatContext(
|
|
565
|
+
function createFormatContext(
|
|
566
|
+
insertionMode,
|
|
567
|
+
selectedValue,
|
|
568
|
+
tagScope,
|
|
569
|
+
viewTransition
|
|
570
|
+
) {
|
|
534
571
|
return {
|
|
535
572
|
insertionMode: insertionMode,
|
|
536
573
|
selectedValue: selectedValue,
|
|
537
|
-
tagScope: tagScope
|
|
574
|
+
tagScope: tagScope,
|
|
575
|
+
viewTransition: viewTransition
|
|
538
576
|
};
|
|
539
577
|
}
|
|
540
578
|
function createRootFormatContext(namespaceURI) {
|
|
@@ -545,48 +583,93 @@ function createRootFormatContext(namespaceURI) {
|
|
|
545
583
|
? 5
|
|
546
584
|
: 0,
|
|
547
585
|
null,
|
|
548
|
-
0
|
|
586
|
+
0,
|
|
587
|
+
null
|
|
549
588
|
);
|
|
550
589
|
}
|
|
551
590
|
function getChildFormatContext(parentContext, type, props) {
|
|
591
|
+
var subtreeScope = parentContext.tagScope & -25;
|
|
552
592
|
switch (type) {
|
|
553
593
|
case "noscript":
|
|
554
|
-
return createFormatContext(2, null,
|
|
594
|
+
return createFormatContext(2, null, subtreeScope | 1, null);
|
|
555
595
|
case "select":
|
|
556
596
|
return createFormatContext(
|
|
557
597
|
2,
|
|
558
598
|
null != props.value ? props.value : props.defaultValue,
|
|
559
|
-
|
|
599
|
+
subtreeScope,
|
|
600
|
+
null
|
|
560
601
|
);
|
|
561
602
|
case "svg":
|
|
562
|
-
return createFormatContext(4, null,
|
|
603
|
+
return createFormatContext(4, null, subtreeScope, null);
|
|
563
604
|
case "picture":
|
|
564
|
-
return createFormatContext(2, null,
|
|
605
|
+
return createFormatContext(2, null, subtreeScope | 2, null);
|
|
565
606
|
case "math":
|
|
566
|
-
return createFormatContext(5, null,
|
|
607
|
+
return createFormatContext(5, null, subtreeScope, null);
|
|
567
608
|
case "foreignObject":
|
|
568
|
-
return createFormatContext(2, null,
|
|
609
|
+
return createFormatContext(2, null, subtreeScope, null);
|
|
569
610
|
case "table":
|
|
570
|
-
return createFormatContext(6, null,
|
|
611
|
+
return createFormatContext(6, null, subtreeScope, null);
|
|
571
612
|
case "thead":
|
|
572
613
|
case "tbody":
|
|
573
614
|
case "tfoot":
|
|
574
|
-
return createFormatContext(7, null,
|
|
615
|
+
return createFormatContext(7, null, subtreeScope, null);
|
|
575
616
|
case "colgroup":
|
|
576
|
-
return createFormatContext(9, null,
|
|
617
|
+
return createFormatContext(9, null, subtreeScope, null);
|
|
577
618
|
case "tr":
|
|
578
|
-
return createFormatContext(8, null,
|
|
619
|
+
return createFormatContext(8, null, subtreeScope, null);
|
|
579
620
|
case "head":
|
|
580
621
|
if (2 > parentContext.insertionMode)
|
|
581
|
-
return createFormatContext(3, null,
|
|
622
|
+
return createFormatContext(3, null, subtreeScope, null);
|
|
582
623
|
break;
|
|
583
624
|
case "html":
|
|
584
625
|
if (0 === parentContext.insertionMode)
|
|
585
|
-
return createFormatContext(1, null,
|
|
626
|
+
return createFormatContext(1, null, subtreeScope, null);
|
|
586
627
|
}
|
|
587
628
|
return 6 <= parentContext.insertionMode || 2 > parentContext.insertionMode
|
|
588
|
-
? createFormatContext(2, null,
|
|
589
|
-
: parentContext
|
|
629
|
+
? createFormatContext(2, null, subtreeScope, null)
|
|
630
|
+
: parentContext.tagScope !== subtreeScope
|
|
631
|
+
? createFormatContext(
|
|
632
|
+
parentContext.insertionMode,
|
|
633
|
+
parentContext.selectedValue,
|
|
634
|
+
subtreeScope,
|
|
635
|
+
null
|
|
636
|
+
)
|
|
637
|
+
: parentContext;
|
|
638
|
+
}
|
|
639
|
+
function getSuspenseViewTransition(parentViewTransition) {
|
|
640
|
+
return null === parentViewTransition
|
|
641
|
+
? null
|
|
642
|
+
: {
|
|
643
|
+
update: parentViewTransition.update,
|
|
644
|
+
enter: "none",
|
|
645
|
+
exit: "none",
|
|
646
|
+
share: parentViewTransition.update,
|
|
647
|
+
name: parentViewTransition.autoName,
|
|
648
|
+
autoName: parentViewTransition.autoName,
|
|
649
|
+
nameIdx: 0
|
|
650
|
+
};
|
|
651
|
+
}
|
|
652
|
+
function getSuspenseFallbackFormatContext(resumableState, parentContext) {
|
|
653
|
+
parentContext.tagScope & 32 && (resumableState.instructions |= 128);
|
|
654
|
+
return createFormatContext(
|
|
655
|
+
parentContext.insertionMode,
|
|
656
|
+
parentContext.selectedValue,
|
|
657
|
+
parentContext.tagScope | 12,
|
|
658
|
+
getSuspenseViewTransition(parentContext.viewTransition)
|
|
659
|
+
);
|
|
660
|
+
}
|
|
661
|
+
function getSuspenseContentFormatContext(resumableState, parentContext) {
|
|
662
|
+
resumableState = getSuspenseViewTransition(parentContext.viewTransition);
|
|
663
|
+
var subtreeScope = parentContext.tagScope | 16;
|
|
664
|
+
null !== resumableState &&
|
|
665
|
+
"none" !== resumableState.share &&
|
|
666
|
+
(subtreeScope |= 64);
|
|
667
|
+
return createFormatContext(
|
|
668
|
+
parentContext.insertionMode,
|
|
669
|
+
parentContext.selectedValue,
|
|
670
|
+
subtreeScope,
|
|
671
|
+
resumableState
|
|
672
|
+
);
|
|
590
673
|
}
|
|
591
674
|
var textSeparator = stringToPrecomputedChunk("\x3c!-- --\x3e");
|
|
592
675
|
function pushTextInstance(target, text, renderState, textEmbedded) {
|
|
@@ -981,13 +1064,25 @@ var selectedMarkerAttribute = stringToPrecomputedChunk(' selected=""'),
|
|
|
981
1064
|
'addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error(\'React form unexpectedly submitted.\')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});'
|
|
982
1065
|
);
|
|
983
1066
|
function injectFormReplayingRuntime(resumableState, renderState) {
|
|
984
|
-
0 === (resumableState.instructions & 16)
|
|
985
|
-
|
|
986
|
-
renderState.
|
|
987
|
-
renderState.
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
1067
|
+
if (0 === (resumableState.instructions & 16)) {
|
|
1068
|
+
resumableState.instructions |= 16;
|
|
1069
|
+
var preamble = renderState.preamble,
|
|
1070
|
+
bootstrapChunks = renderState.bootstrapChunks;
|
|
1071
|
+
(preamble.htmlChunks || preamble.headChunks) && 0 === bootstrapChunks.length
|
|
1072
|
+
? (bootstrapChunks.push(renderState.startInlineScript),
|
|
1073
|
+
pushCompletedShellIdAttribute(bootstrapChunks, resumableState),
|
|
1074
|
+
bootstrapChunks.push(
|
|
1075
|
+
endOfStartTag,
|
|
1076
|
+
formReplayingRuntimeScript,
|
|
1077
|
+
endInlineScript
|
|
1078
|
+
))
|
|
1079
|
+
: bootstrapChunks.unshift(
|
|
1080
|
+
renderState.startInlineScript,
|
|
1081
|
+
endOfStartTag,
|
|
1082
|
+
formReplayingRuntimeScript,
|
|
1083
|
+
endInlineScript
|
|
1084
|
+
);
|
|
1085
|
+
}
|
|
991
1086
|
}
|
|
992
1087
|
var formStateMarkerIsMatching = stringToPrecomputedChunk("\x3c!--F!--\x3e"),
|
|
993
1088
|
formStateMarkerIsNotMatching = stringToPrecomputedChunk("\x3c!--F--\x3e");
|
|
@@ -1069,6 +1164,10 @@ function pushTitleImpl(target, props) {
|
|
|
1069
1164
|
target.push(endChunkForTag("title"));
|
|
1070
1165
|
return null;
|
|
1071
1166
|
}
|
|
1167
|
+
var headPreambleContributionChunk =
|
|
1168
|
+
stringToPrecomputedChunk("\x3c!--head--\x3e"),
|
|
1169
|
+
bodyPreambleContributionChunk = stringToPrecomputedChunk("\x3c!--body--\x3e"),
|
|
1170
|
+
htmlPreambleContributionChunk = stringToPrecomputedChunk("\x3c!--html--\x3e");
|
|
1072
1171
|
function pushScriptImpl(target, props) {
|
|
1073
1172
|
target.push(startChunkForTag("script"));
|
|
1074
1173
|
var children = null,
|
|
@@ -1166,8 +1265,7 @@ function pushStartInstance(
|
|
|
1166
1265
|
preambleState,
|
|
1167
1266
|
hoistableState,
|
|
1168
1267
|
formatContext,
|
|
1169
|
-
textEmbedded
|
|
1170
|
-
isFallback
|
|
1268
|
+
textEmbedded
|
|
1171
1269
|
) {
|
|
1172
1270
|
switch (type) {
|
|
1173
1271
|
case "div":
|
|
@@ -1642,9 +1740,11 @@ function pushStartInstance(
|
|
|
1642
1740
|
} else JSCompiler_inline_result$jscomp$2 = children$jscomp$5;
|
|
1643
1741
|
return JSCompiler_inline_result$jscomp$2;
|
|
1644
1742
|
case "title":
|
|
1743
|
+
var noscriptTagInScope = formatContext.tagScope & 1,
|
|
1744
|
+
isFallback = formatContext.tagScope & 4;
|
|
1645
1745
|
if (
|
|
1646
1746
|
4 === formatContext.insertionMode ||
|
|
1647
|
-
|
|
1747
|
+
noscriptTagInScope ||
|
|
1648
1748
|
null != props.itemProp
|
|
1649
1749
|
)
|
|
1650
1750
|
var JSCompiler_inline_result$jscomp$3 = pushTitleImpl(
|
|
@@ -1658,12 +1758,14 @@ function pushStartInstance(
|
|
|
1658
1758
|
(JSCompiler_inline_result$jscomp$3 = void 0));
|
|
1659
1759
|
return JSCompiler_inline_result$jscomp$3;
|
|
1660
1760
|
case "link":
|
|
1661
|
-
var
|
|
1761
|
+
var noscriptTagInScope$jscomp$0 = formatContext.tagScope & 1,
|
|
1762
|
+
isFallback$jscomp$0 = formatContext.tagScope & 4,
|
|
1763
|
+
rel = props.rel,
|
|
1662
1764
|
href = props.href,
|
|
1663
1765
|
precedence = props.precedence;
|
|
1664
1766
|
if (
|
|
1665
1767
|
4 === formatContext.insertionMode ||
|
|
1666
|
-
|
|
1768
|
+
noscriptTagInScope$jscomp$0 ||
|
|
1667
1769
|
null != props.itemProp ||
|
|
1668
1770
|
"string" !== typeof rel ||
|
|
1669
1771
|
"string" !== typeof href ||
|
|
@@ -1730,12 +1832,13 @@ function pushStartInstance(
|
|
|
1730
1832
|
props
|
|
1731
1833
|
))
|
|
1732
1834
|
: (textEmbedded && target$jscomp$0.push(textSeparator),
|
|
1733
|
-
(JSCompiler_inline_result$jscomp$4 = isFallback
|
|
1835
|
+
(JSCompiler_inline_result$jscomp$4 = isFallback$jscomp$0
|
|
1734
1836
|
? null
|
|
1735
1837
|
: pushLinkImpl(renderState.hoistableChunks, props)));
|
|
1736
1838
|
return JSCompiler_inline_result$jscomp$4;
|
|
1737
1839
|
case "script":
|
|
1738
|
-
var
|
|
1840
|
+
var noscriptTagInScope$jscomp$1 = formatContext.tagScope & 1,
|
|
1841
|
+
asyncProp = props.async;
|
|
1739
1842
|
if (
|
|
1740
1843
|
"string" !== typeof props.src ||
|
|
1741
1844
|
!props.src ||
|
|
@@ -1745,7 +1848,7 @@ function pushStartInstance(
|
|
|
1745
1848
|
props.onLoad ||
|
|
1746
1849
|
props.onError ||
|
|
1747
1850
|
4 === formatContext.insertionMode ||
|
|
1748
|
-
|
|
1851
|
+
noscriptTagInScope$jscomp$1 ||
|
|
1749
1852
|
null != props.itemProp
|
|
1750
1853
|
)
|
|
1751
1854
|
var JSCompiler_inline_result$jscomp$5 = pushScriptImpl(
|
|
@@ -1782,11 +1885,13 @@ function pushStartInstance(
|
|
|
1782
1885
|
}
|
|
1783
1886
|
return JSCompiler_inline_result$jscomp$5;
|
|
1784
1887
|
case "style":
|
|
1785
|
-
var
|
|
1786
|
-
|
|
1888
|
+
var noscriptTagInScope$jscomp$2 = formatContext.tagScope & 1,
|
|
1889
|
+
precedence$jscomp$0 = props.precedence,
|
|
1890
|
+
href$jscomp$0 = props.href,
|
|
1891
|
+
nonce = props.nonce;
|
|
1787
1892
|
if (
|
|
1788
1893
|
4 === formatContext.insertionMode ||
|
|
1789
|
-
|
|
1894
|
+
noscriptTagInScope$jscomp$2 ||
|
|
1790
1895
|
null != props.itemProp ||
|
|
1791
1896
|
"string" !== typeof precedence$jscomp$0 ||
|
|
1792
1897
|
"string" !== typeof href$jscomp$0 ||
|
|
@@ -1838,46 +1943,47 @@ function pushStartInstance(
|
|
|
1838
1943
|
: void 0)
|
|
1839
1944
|
) {
|
|
1840
1945
|
resumableState.styleResources[href$jscomp$0] = null;
|
|
1841
|
-
styleQueue$jscomp$0
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1946
|
+
styleQueue$jscomp$0 ||
|
|
1947
|
+
((styleQueue$jscomp$0 = {
|
|
1948
|
+
precedence: escapeTextForBrowser(precedence$jscomp$0),
|
|
1949
|
+
rules: [],
|
|
1950
|
+
hrefs: [],
|
|
1951
|
+
sheets: new Map()
|
|
1952
|
+
}),
|
|
1953
|
+
renderState.styles.set(precedence$jscomp$0, styleQueue$jscomp$0));
|
|
1954
|
+
var nonceStyle = renderState.nonce.style;
|
|
1955
|
+
if (!nonceStyle || nonceStyle === nonce) {
|
|
1956
|
+
styleQueue$jscomp$0.hrefs.push(escapeTextForBrowser(href$jscomp$0));
|
|
1957
|
+
var target = styleQueue$jscomp$0.rules,
|
|
1958
|
+
children$jscomp$7 = null,
|
|
1959
|
+
innerHTML$jscomp$6 = null,
|
|
1960
|
+
propKey$jscomp$9;
|
|
1961
|
+
for (propKey$jscomp$9 in props)
|
|
1962
|
+
if (hasOwnProperty.call(props, propKey$jscomp$9)) {
|
|
1963
|
+
var propValue$jscomp$9 = props[propKey$jscomp$9];
|
|
1964
|
+
if (null != propValue$jscomp$9)
|
|
1965
|
+
switch (propKey$jscomp$9) {
|
|
1966
|
+
case "children":
|
|
1967
|
+
children$jscomp$7 = propValue$jscomp$9;
|
|
1968
|
+
break;
|
|
1969
|
+
case "dangerouslySetInnerHTML":
|
|
1970
|
+
innerHTML$jscomp$6 = propValue$jscomp$9;
|
|
1971
|
+
}
|
|
1972
|
+
}
|
|
1973
|
+
var child$jscomp$0 = Array.isArray(children$jscomp$7)
|
|
1974
|
+
? 2 > children$jscomp$7.length
|
|
1975
|
+
? children$jscomp$7[0]
|
|
1976
|
+
: null
|
|
1977
|
+
: children$jscomp$7;
|
|
1978
|
+
"function" !== typeof child$jscomp$0 &&
|
|
1979
|
+
"symbol" !== typeof child$jscomp$0 &&
|
|
1980
|
+
null !== child$jscomp$0 &&
|
|
1981
|
+
void 0 !== child$jscomp$0 &&
|
|
1982
|
+
target.push(
|
|
1983
|
+
("" + child$jscomp$0).replace(styleRegex, styleReplacer)
|
|
1984
|
+
);
|
|
1985
|
+
pushInnerHTML(target, innerHTML$jscomp$6, children$jscomp$7);
|
|
1986
|
+
}
|
|
1881
1987
|
}
|
|
1882
1988
|
styleQueue$jscomp$0 &&
|
|
1883
1989
|
hoistableState &&
|
|
@@ -1887,9 +1993,11 @@ function pushStartInstance(
|
|
|
1887
1993
|
}
|
|
1888
1994
|
return JSCompiler_inline_result$jscomp$6;
|
|
1889
1995
|
case "meta":
|
|
1996
|
+
var noscriptTagInScope$jscomp$3 = formatContext.tagScope & 1,
|
|
1997
|
+
isFallback$jscomp$1 = formatContext.tagScope & 4;
|
|
1890
1998
|
if (
|
|
1891
1999
|
4 === formatContext.insertionMode ||
|
|
1892
|
-
|
|
2000
|
+
noscriptTagInScope$jscomp$3 ||
|
|
1893
2001
|
null != props.itemProp
|
|
1894
2002
|
)
|
|
1895
2003
|
var JSCompiler_inline_result$jscomp$7 = pushSelfClosing(
|
|
@@ -1899,7 +2007,7 @@ function pushStartInstance(
|
|
|
1899
2007
|
);
|
|
1900
2008
|
else
|
|
1901
2009
|
textEmbedded && target$jscomp$0.push(textSeparator),
|
|
1902
|
-
(JSCompiler_inline_result$jscomp$7 = isFallback
|
|
2010
|
+
(JSCompiler_inline_result$jscomp$7 = isFallback$jscomp$1
|
|
1903
2011
|
? null
|
|
1904
2012
|
: "string" === typeof props.charSet
|
|
1905
2013
|
? pushSelfClosing(renderState.charsetChunks, props, "meta")
|
|
@@ -1957,17 +2065,18 @@ function pushStartInstance(
|
|
|
1957
2065
|
target$jscomp$0.push(leadingNewline);
|
|
1958
2066
|
return children$jscomp$8;
|
|
1959
2067
|
case "img":
|
|
1960
|
-
var
|
|
2068
|
+
var pictureOrNoScriptTagInScope = formatContext.tagScope & 3,
|
|
2069
|
+
src = props.src,
|
|
1961
2070
|
srcSet = props.srcSet;
|
|
1962
2071
|
if (
|
|
1963
2072
|
!(
|
|
1964
2073
|
"lazy" === props.loading ||
|
|
1965
2074
|
(!src && !srcSet) ||
|
|
1966
2075
|
("string" !== typeof src && null != src) ||
|
|
1967
|
-
("string" !== typeof srcSet && null != srcSet)
|
|
2076
|
+
("string" !== typeof srcSet && null != srcSet) ||
|
|
2077
|
+
"low" === props.fetchPriority ||
|
|
2078
|
+
pictureOrNoScriptTagInScope
|
|
1968
2079
|
) &&
|
|
1969
|
-
"low" !== props.fetchPriority &&
|
|
1970
|
-
!1 === !!(formatContext.tagScope & 3) &&
|
|
1971
2080
|
("string" !== typeof src ||
|
|
1972
2081
|
":" !== src[4] ||
|
|
1973
2082
|
("d" !== src[0] && "D" !== src[0]) ||
|
|
@@ -1981,6 +2090,9 @@ function pushStartInstance(
|
|
|
1981
2090
|
("t" !== srcSet[2] && "T" !== srcSet[2]) ||
|
|
1982
2091
|
("a" !== srcSet[3] && "A" !== srcSet[3]))
|
|
1983
2092
|
) {
|
|
2093
|
+
null !== hoistableState &&
|
|
2094
|
+
formatContext.tagScope & 64 &&
|
|
2095
|
+
(hoistableState.suspenseyImages = !0);
|
|
1984
2096
|
var sizes = "string" === typeof props.sizes ? props.sizes : void 0,
|
|
1985
2097
|
key$jscomp$0 = srcSet ? srcSet + "\n" + (sizes || "") : src,
|
|
1986
2098
|
promotablePreloads = renderState.preloads.images,
|
|
@@ -2071,6 +2183,8 @@ function pushStartInstance(
|
|
|
2071
2183
|
var preamble = preambleState || renderState.preamble;
|
|
2072
2184
|
if (preamble.headChunks)
|
|
2073
2185
|
throw Error("The `<head>` tag may only be rendered once.");
|
|
2186
|
+
null !== preambleState &&
|
|
2187
|
+
target$jscomp$0.push(headPreambleContributionChunk);
|
|
2074
2188
|
preamble.headChunks = [];
|
|
2075
2189
|
var JSCompiler_inline_result$jscomp$9 = pushStartSingletonElement(
|
|
2076
2190
|
preamble.headChunks,
|
|
@@ -2089,6 +2203,8 @@ function pushStartInstance(
|
|
|
2089
2203
|
var preamble$jscomp$0 = preambleState || renderState.preamble;
|
|
2090
2204
|
if (preamble$jscomp$0.bodyChunks)
|
|
2091
2205
|
throw Error("The `<body>` tag may only be rendered once.");
|
|
2206
|
+
null !== preambleState &&
|
|
2207
|
+
target$jscomp$0.push(bodyPreambleContributionChunk);
|
|
2092
2208
|
preamble$jscomp$0.bodyChunks = [];
|
|
2093
2209
|
var JSCompiler_inline_result$jscomp$10 = pushStartSingletonElement(
|
|
2094
2210
|
preamble$jscomp$0.bodyChunks,
|
|
@@ -2107,6 +2223,8 @@ function pushStartInstance(
|
|
|
2107
2223
|
var preamble$jscomp$1 = preambleState || renderState.preamble;
|
|
2108
2224
|
if (preamble$jscomp$1.htmlChunks)
|
|
2109
2225
|
throw Error("The `<html>` tag may only be rendered once.");
|
|
2226
|
+
null !== preambleState &&
|
|
2227
|
+
target$jscomp$0.push(htmlPreambleContributionChunk);
|
|
2110
2228
|
preamble$jscomp$1.htmlChunks = [doctypeChunk];
|
|
2111
2229
|
var JSCompiler_inline_result$jscomp$11 = pushStartSingletonElement(
|
|
2112
2230
|
preamble$jscomp$1.htmlChunks,
|
|
@@ -2186,16 +2304,13 @@ function hoistPreambleState(renderState, preambleState) {
|
|
|
2186
2304
|
renderState = renderState.preamble;
|
|
2187
2305
|
null === renderState.htmlChunks &&
|
|
2188
2306
|
preambleState.htmlChunks &&
|
|
2189
|
-
(
|
|
2190
|
-
(preambleState.contribution |= 1));
|
|
2307
|
+
(renderState.htmlChunks = preambleState.htmlChunks);
|
|
2191
2308
|
null === renderState.headChunks &&
|
|
2192
2309
|
preambleState.headChunks &&
|
|
2193
|
-
(
|
|
2194
|
-
(preambleState.contribution |= 4));
|
|
2310
|
+
(renderState.headChunks = preambleState.headChunks);
|
|
2195
2311
|
null === renderState.bodyChunks &&
|
|
2196
2312
|
preambleState.bodyChunks &&
|
|
2197
|
-
(
|
|
2198
|
-
(preambleState.contribution |= 2));
|
|
2313
|
+
(renderState.bodyChunks = preambleState.bodyChunks);
|
|
2199
2314
|
}
|
|
2200
2315
|
function writeBootstrap(destination, renderState) {
|
|
2201
2316
|
renderState = renderState.bootstrapChunks;
|
|
@@ -2207,8 +2322,13 @@ function writeBootstrap(destination, renderState) {
|
|
|
2207
2322
|
writeChunkAndReturn(destination, i))
|
|
2208
2323
|
: !0;
|
|
2209
2324
|
}
|
|
2210
|
-
var
|
|
2325
|
+
var shellTimeRuntimeScript = stringToPrecomputedChunk(
|
|
2326
|
+
"requestAnimationFrame(function(){$RT=performance.now()});"
|
|
2327
|
+
),
|
|
2328
|
+
placeholder1 = stringToPrecomputedChunk('<template id="'),
|
|
2211
2329
|
placeholder2 = stringToPrecomputedChunk('"></template>'),
|
|
2330
|
+
startActivityBoundary = stringToPrecomputedChunk("\x3c!--&--\x3e"),
|
|
2331
|
+
endActivityBoundary = stringToPrecomputedChunk("\x3c!--/&--\x3e"),
|
|
2212
2332
|
startCompletedSuspenseBoundary = stringToPrecomputedChunk("\x3c!--$--\x3e"),
|
|
2213
2333
|
startPendingSuspenseBoundary1 = stringToPrecomputedChunk(
|
|
2214
2334
|
'\x3c!--$?--\x3e<template id="'
|
|
@@ -2237,16 +2357,6 @@ function writeStartPendingSuspenseBoundary(destination, renderState, id) {
|
|
|
2237
2357
|
writeChunk(destination, id.toString(16));
|
|
2238
2358
|
return writeChunkAndReturn(destination, startPendingSuspenseBoundary2);
|
|
2239
2359
|
}
|
|
2240
|
-
var boundaryPreambleContributionChunkStart =
|
|
2241
|
-
stringToPrecomputedChunk("\x3c!--"),
|
|
2242
|
-
boundaryPreambleContributionChunkEnd = stringToPrecomputedChunk("--\x3e");
|
|
2243
|
-
function writePreambleContribution(destination, preambleState) {
|
|
2244
|
-
preambleState = preambleState.contribution;
|
|
2245
|
-
0 !== preambleState &&
|
|
2246
|
-
(writeChunk(destination, boundaryPreambleContributionChunkStart),
|
|
2247
|
-
writeChunk(destination, "" + preambleState),
|
|
2248
|
-
writeChunk(destination, boundaryPreambleContributionChunkEnd));
|
|
2249
|
-
}
|
|
2250
2360
|
var startSegmentHTML = stringToPrecomputedChunk('<div hidden id="'),
|
|
2251
2361
|
startSegmentHTML2 = stringToPrecomputedChunk('">'),
|
|
2252
2362
|
endSegmentHTML = stringToPrecomputedChunk("</div>"),
|
|
@@ -2363,15 +2473,12 @@ var completeSegmentScript1Full = stringToPrecomputedChunk(
|
|
|
2363
2473
|
completeSegmentScriptEnd = stringToPrecomputedChunk('")\x3c/script>');
|
|
2364
2474
|
stringToPrecomputedChunk('<template data-rsi="" data-sid="');
|
|
2365
2475
|
stringToPrecomputedChunk('" data-pid="');
|
|
2366
|
-
var
|
|
2367
|
-
'$
|
|
2476
|
+
var completeBoundaryScriptFunctionOnly = stringToPrecomputedChunk(
|
|
2477
|
+
'$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};\n$RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};'
|
|
2368
2478
|
),
|
|
2369
2479
|
completeBoundaryScript1Partial = stringToPrecomputedChunk('$RC("'),
|
|
2370
|
-
completeBoundaryWithStylesScript1FullBoth = stringToPrecomputedChunk(
|
|
2371
|
-
'$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RM=new Map;\n$RR=function(t,u,y){function v(n){this._p=null;n()}for(var w=$RC,p=$RM,q=new Map,r=document,g,b,h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),x=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?x.push(b):("LINK"===b.tagName&&p.set(b.getAttribute("href"),b),q.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var e=y[b++];if(!e){k=!1;b=0;continue}var c=!1,m=0;var d=e[m++];if(a=p.get(d)){var f=a._p;c=!0}else{a=r.createElement("link");a.href=\nd;a.rel="stylesheet";for(a.dataset.precedence=l=e[m++];f=e[m++];)a.setAttribute(f,e[m++]);f=a._p=new Promise(function(n,z){a.onload=v.bind(a,n);a.onerror=v.bind(a,z)});p.set(d,a)}d=a.getAttribute("media");!f||d&&!matchMedia(d).matches||h.push(f);if(c)continue}else{a=x[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=q.get(l)||g;c===g&&(g=a);q.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=r.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(w.bind(null,\nt,u,""),w.bind(null,t,u,"Resource failed to load"))};$RR("'
|
|
2372
|
-
),
|
|
2373
2480
|
completeBoundaryWithStylesScript1FullPartial = stringToPrecomputedChunk(
|
|
2374
|
-
'$RM=new Map
|
|
2481
|
+
'$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("'
|
|
2375
2482
|
),
|
|
2376
2483
|
completeBoundaryWithStylesScript1Partial = stringToPrecomputedChunk('$RR("'),
|
|
2377
2484
|
completeBoundaryScript2 = stringToPrecomputedChunk('","'),
|
|
@@ -2382,7 +2489,10 @@ stringToPrecomputedChunk('<template data-rci="" data-bid="');
|
|
|
2382
2489
|
stringToPrecomputedChunk('<template data-rri="" data-bid="');
|
|
2383
2490
|
stringToPrecomputedChunk('" data-sid="');
|
|
2384
2491
|
stringToPrecomputedChunk('" data-sty="');
|
|
2385
|
-
var
|
|
2492
|
+
var clientRenderScriptFunctionOnly = stringToPrecomputedChunk(
|
|
2493
|
+
'$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};'
|
|
2494
|
+
),
|
|
2495
|
+
clientRenderScript1Full = stringToPrecomputedChunk(
|
|
2386
2496
|
'$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'
|
|
2387
2497
|
),
|
|
2388
2498
|
clientRenderScript1Partial = stringToPrecomputedChunk('$RX("'),
|
|
@@ -2439,7 +2549,7 @@ function escapeJSObjectForInstructionScripts(input) {
|
|
|
2439
2549
|
);
|
|
2440
2550
|
}
|
|
2441
2551
|
var lateStyleTagResourceOpen1 = stringToPrecomputedChunk(
|
|
2442
|
-
'
|
|
2552
|
+
' media="not all" data-precedence="'
|
|
2443
2553
|
),
|
|
2444
2554
|
lateStyleTagResourceOpen2 = stringToPrecomputedChunk('" data-href="'),
|
|
2445
2555
|
lateStyleTagResourceOpen3 = stringToPrecomputedChunk('">'),
|
|
@@ -2451,6 +2561,7 @@ function flushStyleTagsLateForBoundary(styleQueue) {
|
|
|
2451
2561
|
hrefs = styleQueue.hrefs,
|
|
2452
2562
|
i = 0;
|
|
2453
2563
|
if (hrefs.length) {
|
|
2564
|
+
writeChunk(this, currentlyFlushingRenderState.startInlineStyle);
|
|
2454
2565
|
writeChunk(this, lateStyleTagResourceOpen1);
|
|
2455
2566
|
writeChunk(this, styleQueue.precedence);
|
|
2456
2567
|
for (writeChunk(this, lateStyleTagResourceOpen2); i < hrefs.length - 1; i++)
|
|
@@ -2475,7 +2586,9 @@ function hasStylesToHoist(stylesheet) {
|
|
|
2475
2586
|
function writeHoistablesForBoundary(destination, hoistableState, renderState) {
|
|
2476
2587
|
currentlyRenderingBoundaryHasStylesToHoist = !1;
|
|
2477
2588
|
destinationHasCapacity = !0;
|
|
2589
|
+
currentlyFlushingRenderState = renderState;
|
|
2478
2590
|
hoistableState.styles.forEach(flushStyleTagsLateForBoundary, destination);
|
|
2591
|
+
currentlyFlushingRenderState = null;
|
|
2479
2592
|
hoistableState.stylesheets.forEach(hasStylesToHoist);
|
|
2480
2593
|
currentlyRenderingBoundaryHasStylesToHoist &&
|
|
2481
2594
|
(renderState.stylesToHoist = !0);
|
|
@@ -2493,9 +2606,7 @@ function flushStyleInPreamble(stylesheet) {
|
|
|
2493
2606
|
stylesheetFlushingQueue.length = 0;
|
|
2494
2607
|
stylesheet.state = 2;
|
|
2495
2608
|
}
|
|
2496
|
-
var styleTagResourceOpen1 = stringToPrecomputedChunk(
|
|
2497
|
-
'<style data-precedence="'
|
|
2498
|
-
),
|
|
2609
|
+
var styleTagResourceOpen1 = stringToPrecomputedChunk(' data-precedence="'),
|
|
2499
2610
|
styleTagResourceOpen2 = stringToPrecomputedChunk('" data-href="'),
|
|
2500
2611
|
spaceSeparator = stringToPrecomputedChunk(" "),
|
|
2501
2612
|
styleTagResourceOpen3 = stringToPrecomputedChunk('">'),
|
|
@@ -2507,6 +2618,7 @@ function flushStylesInPreamble(styleQueue) {
|
|
|
2507
2618
|
var rules = styleQueue.rules,
|
|
2508
2619
|
hrefs = styleQueue.hrefs;
|
|
2509
2620
|
if (!hasStylesheets || hrefs.length) {
|
|
2621
|
+
writeChunk(this, currentlyFlushingRenderState.startInlineStyle);
|
|
2510
2622
|
writeChunk(this, styleTagResourceOpen1);
|
|
2511
2623
|
writeChunk(this, styleQueue.precedence);
|
|
2512
2624
|
styleQueue = 0;
|
|
@@ -2555,6 +2667,18 @@ function preloadLateStyles(styleQueue) {
|
|
|
2555
2667
|
styleQueue.sheets.forEach(preloadLateStyle, this);
|
|
2556
2668
|
styleQueue.sheets.clear();
|
|
2557
2669
|
}
|
|
2670
|
+
stringToPrecomputedChunk('<link rel="expect" href="#');
|
|
2671
|
+
stringToPrecomputedChunk('" blocking="render"/>');
|
|
2672
|
+
var completedShellIdAttributeStart = stringToPrecomputedChunk(' id="');
|
|
2673
|
+
function pushCompletedShellIdAttribute(target, resumableState) {
|
|
2674
|
+
0 === (resumableState.instructions & 32) &&
|
|
2675
|
+
((resumableState.instructions |= 32),
|
|
2676
|
+
target.push(
|
|
2677
|
+
completedShellIdAttributeStart,
|
|
2678
|
+
escapeTextForBrowser("_" + resumableState.idPrefix + "R_"),
|
|
2679
|
+
attributeEnd
|
|
2680
|
+
));
|
|
2681
|
+
}
|
|
2558
2682
|
var arrayFirstOpenBracket = stringToPrecomputedChunk("["),
|
|
2559
2683
|
arraySubsequentOpenBracket = stringToPrecomputedChunk(",["),
|
|
2560
2684
|
arrayInterstitial = stringToPrecomputedChunk(","),
|
|
@@ -2661,7 +2785,7 @@ function writeStyleResourceAttributeInJS(destination, name, value) {
|
|
|
2661
2785
|
writeChunk(destination, escapeJSObjectForInstructionScripts(name));
|
|
2662
2786
|
}
|
|
2663
2787
|
function createHoistableState() {
|
|
2664
|
-
return { styles: new Set(), stylesheets: new Set() };
|
|
2788
|
+
return { styles: new Set(), stylesheets: new Set(), suspenseyImages: !1 };
|
|
2665
2789
|
}
|
|
2666
2790
|
function prefetchDNS(href) {
|
|
2667
2791
|
var request = resolveRequest();
|
|
@@ -3066,6 +3190,14 @@ function hoistStyleQueueDependency(styleQueue) {
|
|
|
3066
3190
|
function hoistStylesheetDependency(stylesheet) {
|
|
3067
3191
|
this.stylesheets.add(stylesheet);
|
|
3068
3192
|
}
|
|
3193
|
+
function hoistHoistables(parentState, childState) {
|
|
3194
|
+
childState.styles.forEach(hoistStyleQueueDependency, parentState);
|
|
3195
|
+
childState.stylesheets.forEach(hoistStylesheetDependency, parentState);
|
|
3196
|
+
childState.suspenseyImages && (parentState.suspenseyImages = !0);
|
|
3197
|
+
}
|
|
3198
|
+
function hasSuspenseyContent(hoistableState) {
|
|
3199
|
+
return 0 < hoistableState.stylesheets.size || hoistableState.suspenseyImages;
|
|
3200
|
+
}
|
|
3069
3201
|
var bind = Function.prototype.bind,
|
|
3070
3202
|
requestStorage = new async_hooks.AsyncLocalStorage(),
|
|
3071
3203
|
REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference");
|
|
@@ -3095,7 +3227,7 @@ function getComponentNameFromType(type) {
|
|
|
3095
3227
|
case REACT_PORTAL_TYPE:
|
|
3096
3228
|
return "Portal";
|
|
3097
3229
|
case REACT_CONTEXT_TYPE:
|
|
3098
|
-
return
|
|
3230
|
+
return type.displayName || "Context";
|
|
3099
3231
|
case REACT_CONSUMER_TYPE:
|
|
3100
3232
|
return (type._context.displayName || "Context") + ".Consumer";
|
|
3101
3233
|
case REACT_FORWARD_REF_TYPE:
|
|
@@ -3237,15 +3369,15 @@ function clz32Fallback(x) {
|
|
|
3237
3369
|
x >>>= 0;
|
|
3238
3370
|
return 0 === x ? 32 : (31 - ((log(x) / LN2) | 0)) | 0;
|
|
3239
3371
|
}
|
|
3372
|
+
function noop() {}
|
|
3240
3373
|
var SuspenseException = Error(
|
|
3241
3374
|
"Suspense Exception: This is not a real error! It's an implementation detail of `use` to interrupt the current render. You must either rethrow it immediately, or move the `use` call outside of the `try/catch` block. Capturing without rethrowing will lead to unexpected behavior.\n\nTo handle async errors, wrap your component in an error boundary, or call the promise's `.catch` method and pass the result to `use`."
|
|
3242
3375
|
);
|
|
3243
|
-
function noop$2() {}
|
|
3244
3376
|
function trackUsedThenable(thenableState, thenable, index) {
|
|
3245
3377
|
index = thenableState[index];
|
|
3246
3378
|
void 0 === index
|
|
3247
3379
|
? thenableState.push(thenable)
|
|
3248
|
-
: index !== thenable && (thenable.then(noop
|
|
3380
|
+
: index !== thenable && (thenable.then(noop, noop), (thenable = index));
|
|
3249
3381
|
switch (thenable.status) {
|
|
3250
3382
|
case "fulfilled":
|
|
3251
3383
|
return thenable.value;
|
|
@@ -3253,7 +3385,7 @@ function trackUsedThenable(thenableState, thenable, index) {
|
|
|
3253
3385
|
throw thenable.reason;
|
|
3254
3386
|
default:
|
|
3255
3387
|
"string" === typeof thenable.status
|
|
3256
|
-
? thenable.then(noop
|
|
3388
|
+
? thenable.then(noop, noop)
|
|
3257
3389
|
: ((thenableState = thenable),
|
|
3258
3390
|
(thenableState.status = "pending"),
|
|
3259
3391
|
thenableState.then(
|
|
@@ -3433,6 +3565,11 @@ function dispatchAction(componentIdentity, queue, action) {
|
|
|
3433
3565
|
queue.next = componentIdentity;
|
|
3434
3566
|
}
|
|
3435
3567
|
}
|
|
3568
|
+
function throwOnUseEffectEventCall() {
|
|
3569
|
+
throw Error(
|
|
3570
|
+
"A function wrapped in useEffectEvent can't be called during rendering."
|
|
3571
|
+
);
|
|
3572
|
+
}
|
|
3436
3573
|
function unsupportedStartTransition() {
|
|
3437
3574
|
throw Error("startTransition cannot be called during server rendering.");
|
|
3438
3575
|
}
|
|
@@ -3507,7 +3644,6 @@ function unwrapThenable(thenable) {
|
|
|
3507
3644
|
function unsupportedRefresh() {
|
|
3508
3645
|
throw Error("Cache cannot be refreshed during server rendering.");
|
|
3509
3646
|
}
|
|
3510
|
-
function noop$1() {}
|
|
3511
3647
|
var HooksDispatcher = {
|
|
3512
3648
|
readContext: function (context) {
|
|
3513
3649
|
return context._currentValue;
|
|
@@ -3537,16 +3673,16 @@ var HooksDispatcher = {
|
|
|
3537
3673
|
useState: function (initialState) {
|
|
3538
3674
|
return useReducer(basicStateReducer, initialState);
|
|
3539
3675
|
},
|
|
3540
|
-
useInsertionEffect: noop
|
|
3541
|
-
useLayoutEffect: noop
|
|
3676
|
+
useInsertionEffect: noop,
|
|
3677
|
+
useLayoutEffect: noop,
|
|
3542
3678
|
useCallback: function (callback, deps) {
|
|
3543
3679
|
return useMemo(function () {
|
|
3544
3680
|
return callback;
|
|
3545
3681
|
}, deps);
|
|
3546
3682
|
},
|
|
3547
|
-
useImperativeHandle: noop
|
|
3548
|
-
useEffect: noop
|
|
3549
|
-
useDebugValue: noop
|
|
3683
|
+
useImperativeHandle: noop,
|
|
3684
|
+
useEffect: noop,
|
|
3685
|
+
useDebugValue: noop,
|
|
3550
3686
|
useDeferredValue: function (value, initialValue) {
|
|
3551
3687
|
resolveCurrentlyRenderingComponent();
|
|
3552
3688
|
return void 0 !== initialValue ? initialValue : value;
|
|
@@ -3571,9 +3707,9 @@ var HooksDispatcher = {
|
|
|
3571
3707
|
);
|
|
3572
3708
|
overflow = localIdCounter++;
|
|
3573
3709
|
JSCompiler_inline_result =
|
|
3574
|
-
"
|
|
3710
|
+
"_" + resumableState.idPrefix + "R_" + JSCompiler_inline_result;
|
|
3575
3711
|
0 < overflow && (JSCompiler_inline_result += "H" + overflow.toString(32));
|
|
3576
|
-
return JSCompiler_inline_result + "
|
|
3712
|
+
return JSCompiler_inline_result + "_";
|
|
3577
3713
|
},
|
|
3578
3714
|
useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
|
|
3579
3715
|
if (void 0 === getServerSnapshot)
|
|
@@ -3599,12 +3735,18 @@ var HooksDispatcher = {
|
|
|
3599
3735
|
},
|
|
3600
3736
|
useCacheRefresh: function () {
|
|
3601
3737
|
return unsupportedRefresh;
|
|
3738
|
+
},
|
|
3739
|
+
useEffectEvent: function () {
|
|
3740
|
+
return throwOnUseEffectEventCall;
|
|
3602
3741
|
}
|
|
3603
3742
|
},
|
|
3604
3743
|
currentResumableState = null,
|
|
3605
3744
|
DefaultAsyncDispatcher = {
|
|
3606
3745
|
getCacheForType: function () {
|
|
3607
3746
|
throw Error("Not implemented.");
|
|
3747
|
+
},
|
|
3748
|
+
cacheSignal: function () {
|
|
3749
|
+
throw Error("Not implemented.");
|
|
3608
3750
|
}
|
|
3609
3751
|
};
|
|
3610
3752
|
function prepareStackTrace(error, structuredStackTrace) {
|
|
@@ -3787,13 +3929,37 @@ function describeComponentStackByType(type) {
|
|
|
3787
3929
|
}
|
|
3788
3930
|
return describeComponentStackByType(type);
|
|
3789
3931
|
}
|
|
3790
|
-
if ("string" === typeof type.name)
|
|
3791
|
-
|
|
3792
|
-
|
|
3793
|
-
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3932
|
+
if ("string" === typeof type.name) {
|
|
3933
|
+
a: {
|
|
3934
|
+
payload = type.name;
|
|
3935
|
+
lazyComponent = type.env;
|
|
3936
|
+
var location = type.debugLocation;
|
|
3937
|
+
if (
|
|
3938
|
+
null != location &&
|
|
3939
|
+
((type = Error.prepareStackTrace),
|
|
3940
|
+
(Error.prepareStackTrace = prepareStackTrace),
|
|
3941
|
+
(location = location.stack),
|
|
3942
|
+
(Error.prepareStackTrace = type),
|
|
3943
|
+
location.startsWith("Error: react-stack-top-frame\n") &&
|
|
3944
|
+
(location = location.slice(29)),
|
|
3945
|
+
(type = location.indexOf("\n")),
|
|
3946
|
+
-1 !== type && (location = location.slice(type + 1)),
|
|
3947
|
+
(type = location.indexOf("react_stack_bottom_frame")),
|
|
3948
|
+
-1 !== type && (type = location.lastIndexOf("\n", type)),
|
|
3949
|
+
(type = -1 !== type ? (location = location.slice(0, type)) : ""),
|
|
3950
|
+
(location = type.lastIndexOf("\n")),
|
|
3951
|
+
(type = -1 === location ? type : type.slice(location + 1)),
|
|
3952
|
+
-1 !== type.indexOf(payload))
|
|
3953
|
+
) {
|
|
3954
|
+
payload = "\n" + type;
|
|
3955
|
+
break a;
|
|
3956
|
+
}
|
|
3957
|
+
payload = describeBuiltInComponentFrame(
|
|
3958
|
+
payload + (lazyComponent ? " [" + lazyComponent + "]" : "")
|
|
3959
|
+
);
|
|
3960
|
+
}
|
|
3961
|
+
return payload;
|
|
3962
|
+
}
|
|
3797
3963
|
}
|
|
3798
3964
|
switch (type) {
|
|
3799
3965
|
case REACT_SUSPENSE_LIST_TYPE:
|
|
@@ -3803,6 +3969,12 @@ function describeComponentStackByType(type) {
|
|
|
3803
3969
|
}
|
|
3804
3970
|
return "";
|
|
3805
3971
|
}
|
|
3972
|
+
function isEligibleForOutlining(request, boundary) {
|
|
3973
|
+
return (
|
|
3974
|
+
(500 < boundary.byteSize || hasSuspenseyContent(boundary.contentState)) &&
|
|
3975
|
+
null === boundary.contentPreamble
|
|
3976
|
+
);
|
|
3977
|
+
}
|
|
3806
3978
|
function defaultErrorHandler(error) {
|
|
3807
3979
|
if (
|
|
3808
3980
|
"object" === typeof error &&
|
|
@@ -3823,7 +3995,7 @@ function defaultErrorHandler(error) {
|
|
|
3823
3995
|
: error.splice(
|
|
3824
3996
|
0,
|
|
3825
3997
|
0,
|
|
3826
|
-
"\u001b[0m\u001b[7m%c%s\u001b[0m%c
|
|
3998
|
+
"\u001b[0m\u001b[7m%c%s\u001b[0m%c",
|
|
3827
3999
|
"background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px",
|
|
3828
4000
|
" " + JSCompiler_inline_result + " ",
|
|
3829
4001
|
""
|
|
@@ -3834,7 +4006,6 @@ function defaultErrorHandler(error) {
|
|
|
3834
4006
|
} else console.error(error);
|
|
3835
4007
|
return null;
|
|
3836
4008
|
}
|
|
3837
|
-
function noop() {}
|
|
3838
4009
|
function RequestInstance(
|
|
3839
4010
|
resumableState,
|
|
3840
4011
|
renderState,
|
|
@@ -3860,6 +4031,7 @@ function RequestInstance(
|
|
|
3860
4031
|
this.fatalError = null;
|
|
3861
4032
|
this.pendingRootTasks = this.allPendingTasks = this.nextSegmentId = 0;
|
|
3862
4033
|
this.completedPreambleSegments = this.completedRootSegment = null;
|
|
4034
|
+
this.byteSize = 0;
|
|
3863
4035
|
this.abortableTasks = abortSet;
|
|
3864
4036
|
this.pingedTasks = [];
|
|
3865
4037
|
this.clientRenderedBoundaries = [];
|
|
@@ -3925,7 +4097,7 @@ function createRequest(
|
|
|
3925
4097
|
null,
|
|
3926
4098
|
emptyTreeContext,
|
|
3927
4099
|
null,
|
|
3928
|
-
|
|
4100
|
+
null
|
|
3929
4101
|
);
|
|
3930
4102
|
pushComponentStack(children);
|
|
3931
4103
|
resumableState.pingedTasks.push(children);
|
|
@@ -3965,6 +4137,116 @@ function createPrerenderRequest(
|
|
|
3965
4137
|
};
|
|
3966
4138
|
return children;
|
|
3967
4139
|
}
|
|
4140
|
+
function resumeRequest(
|
|
4141
|
+
children,
|
|
4142
|
+
postponedState,
|
|
4143
|
+
renderState,
|
|
4144
|
+
onError,
|
|
4145
|
+
onAllReady,
|
|
4146
|
+
onShellReady,
|
|
4147
|
+
onShellError,
|
|
4148
|
+
onFatalError,
|
|
4149
|
+
onPostpone
|
|
4150
|
+
) {
|
|
4151
|
+
renderState = new RequestInstance(
|
|
4152
|
+
postponedState.resumableState,
|
|
4153
|
+
renderState,
|
|
4154
|
+
postponedState.rootFormatContext,
|
|
4155
|
+
postponedState.progressiveChunkSize,
|
|
4156
|
+
onError,
|
|
4157
|
+
onAllReady,
|
|
4158
|
+
onShellReady,
|
|
4159
|
+
onShellError,
|
|
4160
|
+
onFatalError,
|
|
4161
|
+
onPostpone,
|
|
4162
|
+
null
|
|
4163
|
+
);
|
|
4164
|
+
renderState.nextSegmentId = postponedState.nextSegmentId;
|
|
4165
|
+
if ("number" === typeof postponedState.replaySlots)
|
|
4166
|
+
return (
|
|
4167
|
+
(onError = createPendingSegment(
|
|
4168
|
+
renderState,
|
|
4169
|
+
0,
|
|
4170
|
+
null,
|
|
4171
|
+
postponedState.rootFormatContext,
|
|
4172
|
+
!1,
|
|
4173
|
+
!1
|
|
4174
|
+
)),
|
|
4175
|
+
(onError.parentFlushed = !0),
|
|
4176
|
+
(children = createRenderTask(
|
|
4177
|
+
renderState,
|
|
4178
|
+
null,
|
|
4179
|
+
children,
|
|
4180
|
+
-1,
|
|
4181
|
+
null,
|
|
4182
|
+
onError,
|
|
4183
|
+
null,
|
|
4184
|
+
null,
|
|
4185
|
+
renderState.abortableTasks,
|
|
4186
|
+
null,
|
|
4187
|
+
postponedState.rootFormatContext,
|
|
4188
|
+
null,
|
|
4189
|
+
emptyTreeContext,
|
|
4190
|
+
null,
|
|
4191
|
+
null
|
|
4192
|
+
)),
|
|
4193
|
+
pushComponentStack(children),
|
|
4194
|
+
renderState.pingedTasks.push(children),
|
|
4195
|
+
renderState
|
|
4196
|
+
);
|
|
4197
|
+
children = createReplayTask(
|
|
4198
|
+
renderState,
|
|
4199
|
+
null,
|
|
4200
|
+
{
|
|
4201
|
+
nodes: postponedState.replayNodes,
|
|
4202
|
+
slots: postponedState.replaySlots,
|
|
4203
|
+
pendingTasks: 0
|
|
4204
|
+
},
|
|
4205
|
+
children,
|
|
4206
|
+
-1,
|
|
4207
|
+
null,
|
|
4208
|
+
null,
|
|
4209
|
+
renderState.abortableTasks,
|
|
4210
|
+
null,
|
|
4211
|
+
postponedState.rootFormatContext,
|
|
4212
|
+
null,
|
|
4213
|
+
emptyTreeContext,
|
|
4214
|
+
null,
|
|
4215
|
+
null
|
|
4216
|
+
);
|
|
4217
|
+
pushComponentStack(children);
|
|
4218
|
+
renderState.pingedTasks.push(children);
|
|
4219
|
+
return renderState;
|
|
4220
|
+
}
|
|
4221
|
+
function resumeAndPrerenderRequest(
|
|
4222
|
+
children,
|
|
4223
|
+
postponedState,
|
|
4224
|
+
renderState,
|
|
4225
|
+
onError,
|
|
4226
|
+
onAllReady,
|
|
4227
|
+
onShellReady,
|
|
4228
|
+
onShellError,
|
|
4229
|
+
onFatalError,
|
|
4230
|
+
onPostpone
|
|
4231
|
+
) {
|
|
4232
|
+
children = resumeRequest(
|
|
4233
|
+
children,
|
|
4234
|
+
postponedState,
|
|
4235
|
+
renderState,
|
|
4236
|
+
onError,
|
|
4237
|
+
onAllReady,
|
|
4238
|
+
onShellReady,
|
|
4239
|
+
onShellError,
|
|
4240
|
+
onFatalError,
|
|
4241
|
+
onPostpone
|
|
4242
|
+
);
|
|
4243
|
+
children.trackedPostpones = {
|
|
4244
|
+
workingMap: new Map(),
|
|
4245
|
+
rootNodes: [],
|
|
4246
|
+
rootSlots: null
|
|
4247
|
+
};
|
|
4248
|
+
return children;
|
|
4249
|
+
}
|
|
3968
4250
|
var currentRequest = null;
|
|
3969
4251
|
function resolveRequest() {
|
|
3970
4252
|
if (currentRequest) return currentRequest;
|
|
@@ -3985,15 +4267,17 @@ function pingTask(request, task) {
|
|
|
3985
4267
|
}
|
|
3986
4268
|
function createSuspenseBoundary(
|
|
3987
4269
|
request,
|
|
4270
|
+
row,
|
|
3988
4271
|
fallbackAbortableTasks,
|
|
3989
4272
|
contentPreamble,
|
|
3990
4273
|
fallbackPreamble
|
|
3991
4274
|
) {
|
|
3992
|
-
|
|
4275
|
+
fallbackAbortableTasks = {
|
|
3993
4276
|
status: 0,
|
|
3994
4277
|
rootSegmentID: -1,
|
|
3995
4278
|
parentFlushed: !1,
|
|
3996
4279
|
pendingTasks: 0,
|
|
4280
|
+
row: row,
|
|
3997
4281
|
completedSegments: [],
|
|
3998
4282
|
byteSize: 0,
|
|
3999
4283
|
fallbackAbortableTasks: fallbackAbortableTasks,
|
|
@@ -4005,6 +4289,17 @@ function createSuspenseBoundary(
|
|
|
4005
4289
|
trackedContentKeyPath: null,
|
|
4006
4290
|
trackedFallbackNode: null
|
|
4007
4291
|
};
|
|
4292
|
+
null !== row &&
|
|
4293
|
+
(row.pendingTasks++,
|
|
4294
|
+
(contentPreamble = row.boundaries),
|
|
4295
|
+
null !== contentPreamble &&
|
|
4296
|
+
(request.allPendingTasks++,
|
|
4297
|
+
fallbackAbortableTasks.pendingTasks++,
|
|
4298
|
+
contentPreamble.push(fallbackAbortableTasks)),
|
|
4299
|
+
(request = row.inheritedHoistables),
|
|
4300
|
+
null !== request &&
|
|
4301
|
+
hoistHoistables(fallbackAbortableTasks.contentState, request));
|
|
4302
|
+
return fallbackAbortableTasks;
|
|
4008
4303
|
}
|
|
4009
4304
|
function createRenderTask(
|
|
4010
4305
|
request,
|
|
@@ -4020,13 +4315,14 @@ function createRenderTask(
|
|
|
4020
4315
|
formatContext,
|
|
4021
4316
|
context,
|
|
4022
4317
|
treeContext,
|
|
4023
|
-
|
|
4024
|
-
|
|
4318
|
+
row,
|
|
4319
|
+
componentStack
|
|
4025
4320
|
) {
|
|
4026
4321
|
request.allPendingTasks++;
|
|
4027
4322
|
null === blockedBoundary
|
|
4028
4323
|
? request.pendingRootTasks++
|
|
4029
4324
|
: blockedBoundary.pendingTasks++;
|
|
4325
|
+
null !== row && row.pendingTasks++;
|
|
4030
4326
|
var task = {
|
|
4031
4327
|
replay: null,
|
|
4032
4328
|
node: node,
|
|
@@ -4043,9 +4339,9 @@ function createRenderTask(
|
|
|
4043
4339
|
formatContext: formatContext,
|
|
4044
4340
|
context: context,
|
|
4045
4341
|
treeContext: treeContext,
|
|
4342
|
+
row: row,
|
|
4046
4343
|
componentStack: componentStack,
|
|
4047
|
-
thenableState: thenableState
|
|
4048
|
-
isFallback: isFallback
|
|
4344
|
+
thenableState: thenableState
|
|
4049
4345
|
};
|
|
4050
4346
|
abortSet.add(task);
|
|
4051
4347
|
return task;
|
|
@@ -4063,13 +4359,14 @@ function createReplayTask(
|
|
|
4063
4359
|
formatContext,
|
|
4064
4360
|
context,
|
|
4065
4361
|
treeContext,
|
|
4066
|
-
|
|
4067
|
-
|
|
4362
|
+
row,
|
|
4363
|
+
componentStack
|
|
4068
4364
|
) {
|
|
4069
4365
|
request.allPendingTasks++;
|
|
4070
4366
|
null === blockedBoundary
|
|
4071
4367
|
? request.pendingRootTasks++
|
|
4072
4368
|
: blockedBoundary.pendingTasks++;
|
|
4369
|
+
null !== row && row.pendingTasks++;
|
|
4073
4370
|
replay.pendingTasks++;
|
|
4074
4371
|
var task = {
|
|
4075
4372
|
replay: replay,
|
|
@@ -4087,9 +4384,9 @@ function createReplayTask(
|
|
|
4087
4384
|
formatContext: formatContext,
|
|
4088
4385
|
context: context,
|
|
4089
4386
|
treeContext: treeContext,
|
|
4387
|
+
row: row,
|
|
4090
4388
|
componentStack: componentStack,
|
|
4091
|
-
thenableState: thenableState
|
|
4092
|
-
isFallback: isFallback
|
|
4389
|
+
thenableState: thenableState
|
|
4093
4390
|
};
|
|
4094
4391
|
abortSet.add(task);
|
|
4095
4392
|
return task;
|
|
@@ -4124,6 +4421,13 @@ function pushComponentStack(task) {
|
|
|
4124
4421
|
task.componentStack = { parent: task.componentStack, type: node.type };
|
|
4125
4422
|
}
|
|
4126
4423
|
}
|
|
4424
|
+
function replaceSuspenseComponentStackWithSuspenseFallbackStack(
|
|
4425
|
+
componentStack
|
|
4426
|
+
) {
|
|
4427
|
+
return null === componentStack
|
|
4428
|
+
? null
|
|
4429
|
+
: { parent: componentStack.parent, type: "Suspense Fallback" };
|
|
4430
|
+
}
|
|
4127
4431
|
function getThrownInfo(node$jscomp$0) {
|
|
4128
4432
|
var errorInfo = {};
|
|
4129
4433
|
node$jscomp$0 &&
|
|
@@ -4165,6 +4469,170 @@ function fatalError(request, error) {
|
|
|
4165
4469
|
? ((request.status = 14), request.destination.destroy(error))
|
|
4166
4470
|
: ((request.status = 13), (request.fatalError = error));
|
|
4167
4471
|
}
|
|
4472
|
+
function finishSuspenseListRow(request, row) {
|
|
4473
|
+
unblockSuspenseListRow(request, row.next, row.hoistables);
|
|
4474
|
+
}
|
|
4475
|
+
function unblockSuspenseListRow(request, unblockedRow, inheritedHoistables) {
|
|
4476
|
+
for (; null !== unblockedRow; ) {
|
|
4477
|
+
null !== inheritedHoistables &&
|
|
4478
|
+
(hoistHoistables(unblockedRow.hoistables, inheritedHoistables),
|
|
4479
|
+
(unblockedRow.inheritedHoistables = inheritedHoistables));
|
|
4480
|
+
var unblockedBoundaries = unblockedRow.boundaries;
|
|
4481
|
+
if (null !== unblockedBoundaries) {
|
|
4482
|
+
unblockedRow.boundaries = null;
|
|
4483
|
+
for (var i = 0; i < unblockedBoundaries.length; i++) {
|
|
4484
|
+
var unblockedBoundary = unblockedBoundaries[i];
|
|
4485
|
+
null !== inheritedHoistables &&
|
|
4486
|
+
hoistHoistables(unblockedBoundary.contentState, inheritedHoistables);
|
|
4487
|
+
finishedTask(request, unblockedBoundary, null, null);
|
|
4488
|
+
}
|
|
4489
|
+
}
|
|
4490
|
+
unblockedRow.pendingTasks--;
|
|
4491
|
+
if (0 < unblockedRow.pendingTasks) break;
|
|
4492
|
+
inheritedHoistables = unblockedRow.hoistables;
|
|
4493
|
+
unblockedRow = unblockedRow.next;
|
|
4494
|
+
}
|
|
4495
|
+
}
|
|
4496
|
+
function tryToResolveTogetherRow(request, togetherRow) {
|
|
4497
|
+
var boundaries = togetherRow.boundaries;
|
|
4498
|
+
if (null !== boundaries && togetherRow.pendingTasks === boundaries.length) {
|
|
4499
|
+
for (var allCompleteAndInlinable = !0, i = 0; i < boundaries.length; i++) {
|
|
4500
|
+
var rowBoundary = boundaries[i];
|
|
4501
|
+
if (
|
|
4502
|
+
1 !== rowBoundary.pendingTasks ||
|
|
4503
|
+
rowBoundary.parentFlushed ||
|
|
4504
|
+
isEligibleForOutlining(request, rowBoundary)
|
|
4505
|
+
) {
|
|
4506
|
+
allCompleteAndInlinable = !1;
|
|
4507
|
+
break;
|
|
4508
|
+
}
|
|
4509
|
+
}
|
|
4510
|
+
allCompleteAndInlinable &&
|
|
4511
|
+
unblockSuspenseListRow(request, togetherRow, togetherRow.hoistables);
|
|
4512
|
+
}
|
|
4513
|
+
}
|
|
4514
|
+
function createSuspenseListRow(previousRow) {
|
|
4515
|
+
var newRow = {
|
|
4516
|
+
pendingTasks: 1,
|
|
4517
|
+
boundaries: null,
|
|
4518
|
+
hoistables: createHoistableState(),
|
|
4519
|
+
inheritedHoistables: null,
|
|
4520
|
+
together: !1,
|
|
4521
|
+
next: null
|
|
4522
|
+
};
|
|
4523
|
+
null !== previousRow &&
|
|
4524
|
+
0 < previousRow.pendingTasks &&
|
|
4525
|
+
(newRow.pendingTasks++,
|
|
4526
|
+
(newRow.boundaries = []),
|
|
4527
|
+
(previousRow.next = newRow));
|
|
4528
|
+
return newRow;
|
|
4529
|
+
}
|
|
4530
|
+
function renderSuspenseListRows(request, task, keyPath, rows, revealOrder) {
|
|
4531
|
+
var prevKeyPath = task.keyPath,
|
|
4532
|
+
prevTreeContext = task.treeContext,
|
|
4533
|
+
prevRow = task.row;
|
|
4534
|
+
task.keyPath = keyPath;
|
|
4535
|
+
keyPath = rows.length;
|
|
4536
|
+
var previousSuspenseListRow = null;
|
|
4537
|
+
if (null !== task.replay) {
|
|
4538
|
+
var resumeSlots = task.replay.slots;
|
|
4539
|
+
if (null !== resumeSlots && "object" === typeof resumeSlots)
|
|
4540
|
+
for (var n = 0; n < keyPath; n++) {
|
|
4541
|
+
var i =
|
|
4542
|
+
"backwards" !== revealOrder &&
|
|
4543
|
+
"unstable_legacy-backwards" !== revealOrder
|
|
4544
|
+
? n
|
|
4545
|
+
: keyPath - 1 - n,
|
|
4546
|
+
node = rows[i];
|
|
4547
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
|
4548
|
+
previousSuspenseListRow
|
|
4549
|
+
);
|
|
4550
|
+
task.treeContext = pushTreeContext(prevTreeContext, keyPath, i);
|
|
4551
|
+
var resumeSegmentID = resumeSlots[i];
|
|
4552
|
+
"number" === typeof resumeSegmentID
|
|
4553
|
+
? (resumeNode(request, task, resumeSegmentID, node, i),
|
|
4554
|
+
delete resumeSlots[i])
|
|
4555
|
+
: renderNode(request, task, node, i);
|
|
4556
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
|
4557
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
|
4558
|
+
}
|
|
4559
|
+
else
|
|
4560
|
+
for (resumeSlots = 0; resumeSlots < keyPath; resumeSlots++)
|
|
4561
|
+
(n =
|
|
4562
|
+
"backwards" !== revealOrder &&
|
|
4563
|
+
"unstable_legacy-backwards" !== revealOrder
|
|
4564
|
+
? resumeSlots
|
|
4565
|
+
: keyPath - 1 - resumeSlots),
|
|
4566
|
+
(i = rows[n]),
|
|
4567
|
+
(task.row = previousSuspenseListRow =
|
|
4568
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
|
4569
|
+
(task.treeContext = pushTreeContext(prevTreeContext, keyPath, n)),
|
|
4570
|
+
renderNode(request, task, i, n),
|
|
4571
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
|
4572
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
|
4573
|
+
} else if (
|
|
4574
|
+
"backwards" !== revealOrder &&
|
|
4575
|
+
"unstable_legacy-backwards" !== revealOrder
|
|
4576
|
+
)
|
|
4577
|
+
for (revealOrder = 0; revealOrder < keyPath; revealOrder++)
|
|
4578
|
+
(resumeSlots = rows[revealOrder]),
|
|
4579
|
+
(task.row = previousSuspenseListRow =
|
|
4580
|
+
createSuspenseListRow(previousSuspenseListRow)),
|
|
4581
|
+
(task.treeContext = pushTreeContext(
|
|
4582
|
+
prevTreeContext,
|
|
4583
|
+
keyPath,
|
|
4584
|
+
revealOrder
|
|
4585
|
+
)),
|
|
4586
|
+
renderNode(request, task, resumeSlots, revealOrder),
|
|
4587
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
|
4588
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
|
4589
|
+
else {
|
|
4590
|
+
revealOrder = task.blockedSegment;
|
|
4591
|
+
resumeSlots = revealOrder.children.length;
|
|
4592
|
+
n = revealOrder.chunks.length;
|
|
4593
|
+
for (i = keyPath - 1; 0 <= i; i--) {
|
|
4594
|
+
node = rows[i];
|
|
4595
|
+
task.row = previousSuspenseListRow = createSuspenseListRow(
|
|
4596
|
+
previousSuspenseListRow
|
|
4597
|
+
);
|
|
4598
|
+
task.treeContext = pushTreeContext(prevTreeContext, keyPath, i);
|
|
4599
|
+
resumeSegmentID = createPendingSegment(
|
|
4600
|
+
request,
|
|
4601
|
+
n,
|
|
4602
|
+
null,
|
|
4603
|
+
task.formatContext,
|
|
4604
|
+
0 === i ? revealOrder.lastPushedText : !0,
|
|
4605
|
+
!0
|
|
4606
|
+
);
|
|
4607
|
+
revealOrder.children.splice(resumeSlots, 0, resumeSegmentID);
|
|
4608
|
+
task.blockedSegment = resumeSegmentID;
|
|
4609
|
+
try {
|
|
4610
|
+
renderNode(request, task, node, i),
|
|
4611
|
+
resumeSegmentID.lastPushedText &&
|
|
4612
|
+
resumeSegmentID.textEmbedded &&
|
|
4613
|
+
resumeSegmentID.chunks.push(textSeparator),
|
|
4614
|
+
(resumeSegmentID.status = 1),
|
|
4615
|
+
finishedSegment(request, task.blockedBoundary, resumeSegmentID),
|
|
4616
|
+
0 === --previousSuspenseListRow.pendingTasks &&
|
|
4617
|
+
finishSuspenseListRow(request, previousSuspenseListRow);
|
|
4618
|
+
} catch (thrownValue) {
|
|
4619
|
+
throw (
|
|
4620
|
+
((resumeSegmentID.status = 12 === request.status ? 3 : 4),
|
|
4621
|
+
thrownValue)
|
|
4622
|
+
);
|
|
4623
|
+
}
|
|
4624
|
+
}
|
|
4625
|
+
task.blockedSegment = revealOrder;
|
|
4626
|
+
revealOrder.lastPushedText = !1;
|
|
4627
|
+
}
|
|
4628
|
+
null !== prevRow &&
|
|
4629
|
+
null !== previousSuspenseListRow &&
|
|
4630
|
+
0 < previousSuspenseListRow.pendingTasks &&
|
|
4631
|
+
(prevRow.pendingTasks++, (previousSuspenseListRow.next = prevRow));
|
|
4632
|
+
task.treeContext = prevTreeContext;
|
|
4633
|
+
task.row = prevRow;
|
|
4634
|
+
task.keyPath = prevKeyPath;
|
|
4635
|
+
}
|
|
4168
4636
|
function renderWithHooks(request, task, keyPath, Component, props, secondArg) {
|
|
4169
4637
|
var prevThenableState = task.thenableState;
|
|
4170
4638
|
task.thenableState = null;
|
|
@@ -4232,9 +4700,9 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4232
4700
|
var defaultProps = type.defaultProps;
|
|
4233
4701
|
if (defaultProps) {
|
|
4234
4702
|
newProps === props && (newProps = assign({}, newProps, props));
|
|
4235
|
-
for (var propName$
|
|
4236
|
-
void 0 === newProps[propName$
|
|
4237
|
-
(newProps[propName$
|
|
4703
|
+
for (var propName$44 in defaultProps)
|
|
4704
|
+
void 0 === newProps[propName$44] &&
|
|
4705
|
+
(newProps[propName$44] = defaultProps[propName$44]);
|
|
4238
4706
|
}
|
|
4239
4707
|
props = newProps;
|
|
4240
4708
|
newProps = emptyContextObject;
|
|
@@ -4294,16 +4762,16 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4294
4762
|
defaultProps = ref ? type[0] : newProps.state;
|
|
4295
4763
|
initialState = !0;
|
|
4296
4764
|
for (ref = ref ? 1 : 0; ref < type.length; ref++)
|
|
4297
|
-
(propName$
|
|
4298
|
-
(propName$
|
|
4299
|
-
"function" === typeof propName$
|
|
4300
|
-
? propName$
|
|
4301
|
-
: propName$
|
|
4302
|
-
null != propName$
|
|
4765
|
+
(propName$44 = type[ref]),
|
|
4766
|
+
(propName$44 =
|
|
4767
|
+
"function" === typeof propName$44
|
|
4768
|
+
? propName$44.call(newProps, defaultProps, props, void 0)
|
|
4769
|
+
: propName$44),
|
|
4770
|
+
null != propName$44 &&
|
|
4303
4771
|
(initialState
|
|
4304
4772
|
? ((initialState = !1),
|
|
4305
|
-
(defaultProps = assign({}, defaultProps, propName$
|
|
4306
|
-
: assign(defaultProps, propName$
|
|
4773
|
+
(defaultProps = assign({}, defaultProps, propName$44)))
|
|
4774
|
+
: assign(defaultProps, propName$44));
|
|
4307
4775
|
newProps.state = defaultProps;
|
|
4308
4776
|
}
|
|
4309
4777
|
else defaultProps.queue = null;
|
|
@@ -4337,7 +4805,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4337
4805
|
(task.formatContext = defaultProps),
|
|
4338
4806
|
(task.keyPath = initialState);
|
|
4339
4807
|
else {
|
|
4340
|
-
|
|
4808
|
+
initialState = pushStartInstance(
|
|
4341
4809
|
newProps.chunks,
|
|
4342
4810
|
type,
|
|
4343
4811
|
props,
|
|
@@ -4346,47 +4814,41 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4346
4814
|
task.blockedPreamble,
|
|
4347
4815
|
task.hoistableState,
|
|
4348
4816
|
task.formatContext,
|
|
4349
|
-
newProps.lastPushedText
|
|
4350
|
-
task.isFallback
|
|
4817
|
+
newProps.lastPushedText
|
|
4351
4818
|
);
|
|
4352
4819
|
newProps.lastPushedText = !1;
|
|
4353
4820
|
defaultProps = task.formatContext;
|
|
4354
|
-
|
|
4821
|
+
ref = task.keyPath;
|
|
4355
4822
|
task.keyPath = keyPath;
|
|
4356
|
-
|
|
4357
|
-
|
|
4358
|
-
.
|
|
4359
|
-
|
|
4360
|
-
|
|
4361
|
-
|
|
4362
|
-
|
|
4363
|
-
|
|
4364
|
-
|
|
4365
|
-
|
|
4366
|
-
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
task
|
|
4374
|
-
keyPath
|
|
4375
|
-
|
|
4376
|
-
|
|
4377
|
-
|
|
4378
|
-
task.keyPath
|
|
4379
|
-
|
|
4380
|
-
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
-
task.isFallback
|
|
4384
|
-
)),
|
|
4385
|
-
pushComponentStack(keyPath),
|
|
4386
|
-
request.pingedTasks.push(keyPath))
|
|
4387
|
-
: renderNode(request, task, ref, -1);
|
|
4823
|
+
if (
|
|
4824
|
+
3 ===
|
|
4825
|
+
(task.formatContext = getChildFormatContext(defaultProps, type, props))
|
|
4826
|
+
.insertionMode
|
|
4827
|
+
) {
|
|
4828
|
+
keyPath = createPendingSegment(
|
|
4829
|
+
request,
|
|
4830
|
+
0,
|
|
4831
|
+
null,
|
|
4832
|
+
task.formatContext,
|
|
4833
|
+
!1,
|
|
4834
|
+
!1
|
|
4835
|
+
);
|
|
4836
|
+
newProps.preambleChildren.push(keyPath);
|
|
4837
|
+
task.blockedSegment = keyPath;
|
|
4838
|
+
try {
|
|
4839
|
+
(keyPath.status = 6),
|
|
4840
|
+
renderNode(request, task, initialState, -1),
|
|
4841
|
+
keyPath.lastPushedText &&
|
|
4842
|
+
keyPath.textEmbedded &&
|
|
4843
|
+
keyPath.chunks.push(textSeparator),
|
|
4844
|
+
(keyPath.status = 1),
|
|
4845
|
+
finishedSegment(request, task.blockedBoundary, keyPath);
|
|
4846
|
+
} finally {
|
|
4847
|
+
task.blockedSegment = newProps;
|
|
4848
|
+
}
|
|
4849
|
+
} else renderNode(request, task, initialState, -1);
|
|
4388
4850
|
task.formatContext = defaultProps;
|
|
4389
|
-
task.keyPath =
|
|
4851
|
+
task.keyPath = ref;
|
|
4390
4852
|
a: {
|
|
4391
4853
|
task = newProps.chunks;
|
|
4392
4854
|
request = request.resumableState;
|
|
@@ -4441,17 +4903,67 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4441
4903
|
task.keyPath = type;
|
|
4442
4904
|
return;
|
|
4443
4905
|
case REACT_ACTIVITY_TYPE:
|
|
4444
|
-
|
|
4445
|
-
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4906
|
+
type = task.blockedSegment;
|
|
4907
|
+
null === type
|
|
4908
|
+
? "hidden" !== props.mode &&
|
|
4909
|
+
((type = task.keyPath),
|
|
4910
|
+
(task.keyPath = keyPath),
|
|
4911
|
+
renderNode(request, task, props.children, -1),
|
|
4912
|
+
(task.keyPath = type))
|
|
4913
|
+
: "hidden" !== props.mode &&
|
|
4914
|
+
(type.chunks.push(startActivityBoundary),
|
|
4915
|
+
(type.lastPushedText = !1),
|
|
4916
|
+
(newProps = task.keyPath),
|
|
4917
|
+
(task.keyPath = keyPath),
|
|
4918
|
+
renderNode(request, task, props.children, -1),
|
|
4919
|
+
(task.keyPath = newProps),
|
|
4920
|
+
type.chunks.push(endActivityBoundary),
|
|
4921
|
+
(type.lastPushedText = !1));
|
|
4449
4922
|
return;
|
|
4450
4923
|
case REACT_SUSPENSE_LIST_TYPE:
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4454
|
-
|
|
4924
|
+
a: {
|
|
4925
|
+
type = props.children;
|
|
4926
|
+
props = props.revealOrder;
|
|
4927
|
+
if (
|
|
4928
|
+
"forwards" === props ||
|
|
4929
|
+
"backwards" === props ||
|
|
4930
|
+
"unstable_legacy-backwards" === props
|
|
4931
|
+
) {
|
|
4932
|
+
if (isArrayImpl(type)) {
|
|
4933
|
+
renderSuspenseListRows(request, task, keyPath, type, props);
|
|
4934
|
+
break a;
|
|
4935
|
+
}
|
|
4936
|
+
if ((newProps = getIteratorFn(type)))
|
|
4937
|
+
if ((newProps = newProps.call(type))) {
|
|
4938
|
+
defaultProps = newProps.next();
|
|
4939
|
+
if (!defaultProps.done) {
|
|
4940
|
+
do defaultProps = newProps.next();
|
|
4941
|
+
while (!defaultProps.done);
|
|
4942
|
+
renderSuspenseListRows(request, task, keyPath, type, props);
|
|
4943
|
+
}
|
|
4944
|
+
break a;
|
|
4945
|
+
}
|
|
4946
|
+
}
|
|
4947
|
+
"together" === props
|
|
4948
|
+
? ((props = task.keyPath),
|
|
4949
|
+
(newProps = task.row),
|
|
4950
|
+
(defaultProps = task.row = createSuspenseListRow(null)),
|
|
4951
|
+
(defaultProps.boundaries = []),
|
|
4952
|
+
(defaultProps.together = !0),
|
|
4953
|
+
(task.keyPath = keyPath),
|
|
4954
|
+
renderNodeDestructive(request, task, type, -1),
|
|
4955
|
+
0 === --defaultProps.pendingTasks &&
|
|
4956
|
+
finishSuspenseListRow(request, defaultProps),
|
|
4957
|
+
(task.keyPath = props),
|
|
4958
|
+
(task.row = newProps),
|
|
4959
|
+
null !== newProps &&
|
|
4960
|
+
0 < defaultProps.pendingTasks &&
|
|
4961
|
+
(newProps.pendingTasks++, (defaultProps.next = newProps)))
|
|
4962
|
+
: ((props = task.keyPath),
|
|
4963
|
+
(task.keyPath = keyPath),
|
|
4964
|
+
renderNodeDestructive(request, task, type, -1),
|
|
4965
|
+
(task.keyPath = props));
|
|
4966
|
+
}
|
|
4455
4967
|
return;
|
|
4456
4968
|
case REACT_VIEW_TRANSITION_TYPE:
|
|
4457
4969
|
case REACT_SCOPE_TYPE:
|
|
@@ -4459,43 +4971,61 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4459
4971
|
case REACT_SUSPENSE_TYPE:
|
|
4460
4972
|
a: if (null !== task.replay) {
|
|
4461
4973
|
type = task.keyPath;
|
|
4974
|
+
newProps = task.formatContext;
|
|
4975
|
+
defaultProps = task.row;
|
|
4462
4976
|
task.keyPath = keyPath;
|
|
4977
|
+
task.formatContext = getSuspenseContentFormatContext(
|
|
4978
|
+
request.resumableState,
|
|
4979
|
+
newProps
|
|
4980
|
+
);
|
|
4981
|
+
task.row = null;
|
|
4463
4982
|
keyPath = props.children;
|
|
4464
4983
|
try {
|
|
4465
4984
|
renderNode(request, task, keyPath, -1);
|
|
4466
4985
|
} finally {
|
|
4467
|
-
task.keyPath = type
|
|
4986
|
+
(task.keyPath = type),
|
|
4987
|
+
(task.formatContext = newProps),
|
|
4988
|
+
(task.row = defaultProps);
|
|
4468
4989
|
}
|
|
4469
4990
|
} else {
|
|
4470
4991
|
type = task.keyPath;
|
|
4471
|
-
|
|
4472
|
-
|
|
4473
|
-
|
|
4474
|
-
propName
|
|
4475
|
-
|
|
4992
|
+
ref = task.formatContext;
|
|
4993
|
+
var prevRow = task.row;
|
|
4994
|
+
propName$44 = task.blockedBoundary;
|
|
4995
|
+
propName = task.blockedPreamble;
|
|
4996
|
+
var parentHoistableState = task.hoistableState,
|
|
4997
|
+
parentSegment = task.blockedSegment,
|
|
4998
|
+
fallback = props.fallback;
|
|
4476
4999
|
props = props.children;
|
|
4477
5000
|
var fallbackAbortSet = new Set();
|
|
4478
5001
|
var newBoundary =
|
|
4479
5002
|
2 > task.formatContext.insertionMode
|
|
4480
5003
|
? createSuspenseBoundary(
|
|
4481
5004
|
request,
|
|
5005
|
+
task.row,
|
|
4482
5006
|
fallbackAbortSet,
|
|
4483
5007
|
createPreambleState(),
|
|
4484
5008
|
createPreambleState()
|
|
4485
5009
|
)
|
|
4486
|
-
: createSuspenseBoundary(
|
|
5010
|
+
: createSuspenseBoundary(
|
|
5011
|
+
request,
|
|
5012
|
+
task.row,
|
|
5013
|
+
fallbackAbortSet,
|
|
5014
|
+
null,
|
|
5015
|
+
null
|
|
5016
|
+
);
|
|
4487
5017
|
null !== request.trackedPostpones &&
|
|
4488
5018
|
(newBoundary.trackedContentKeyPath = keyPath);
|
|
4489
5019
|
var boundarySegment = createPendingSegment(
|
|
4490
5020
|
request,
|
|
4491
|
-
|
|
5021
|
+
parentSegment.chunks.length,
|
|
4492
5022
|
newBoundary,
|
|
4493
5023
|
task.formatContext,
|
|
4494
5024
|
!1,
|
|
4495
5025
|
!1
|
|
4496
5026
|
);
|
|
4497
|
-
|
|
4498
|
-
|
|
5027
|
+
parentSegment.children.push(boundarySegment);
|
|
5028
|
+
parentSegment.lastPushedText = !1;
|
|
4499
5029
|
var contentRootSegment = createPendingSegment(
|
|
4500
5030
|
request,
|
|
4501
5031
|
0,
|
|
@@ -4506,29 +5036,38 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4506
5036
|
);
|
|
4507
5037
|
contentRootSegment.parentFlushed = !0;
|
|
4508
5038
|
if (null !== request.trackedPostpones) {
|
|
4509
|
-
newProps =
|
|
4510
|
-
defaultProps = [
|
|
4511
|
-
|
|
4512
|
-
|
|
5039
|
+
newProps = task.componentStack;
|
|
5040
|
+
defaultProps = [keyPath[0], "Suspense Fallback", keyPath[2]];
|
|
5041
|
+
initialState = [defaultProps[1], defaultProps[2], [], null];
|
|
5042
|
+
request.trackedPostpones.workingMap.set(defaultProps, initialState);
|
|
5043
|
+
newBoundary.trackedFallbackNode = initialState;
|
|
4513
5044
|
task.blockedSegment = boundarySegment;
|
|
4514
5045
|
task.blockedPreamble = newBoundary.fallbackPreamble;
|
|
4515
|
-
task.keyPath =
|
|
5046
|
+
task.keyPath = defaultProps;
|
|
5047
|
+
task.formatContext = getSuspenseFallbackFormatContext(
|
|
5048
|
+
request.resumableState,
|
|
5049
|
+
ref
|
|
5050
|
+
);
|
|
5051
|
+
task.componentStack =
|
|
5052
|
+
replaceSuspenseComponentStackWithSuspenseFallbackStack(newProps);
|
|
4516
5053
|
boundarySegment.status = 6;
|
|
4517
5054
|
try {
|
|
4518
|
-
renderNode(request, task,
|
|
5055
|
+
renderNode(request, task, fallback, -1),
|
|
4519
5056
|
boundarySegment.lastPushedText &&
|
|
4520
5057
|
boundarySegment.textEmbedded &&
|
|
4521
5058
|
boundarySegment.chunks.push(textSeparator),
|
|
4522
|
-
(boundarySegment.status = 1)
|
|
5059
|
+
(boundarySegment.status = 1),
|
|
5060
|
+
finishedSegment(request, propName$44, boundarySegment);
|
|
4523
5061
|
} catch (thrownValue) {
|
|
4524
5062
|
throw (
|
|
4525
5063
|
((boundarySegment.status = 12 === request.status ? 3 : 4),
|
|
4526
5064
|
thrownValue)
|
|
4527
5065
|
);
|
|
4528
5066
|
} finally {
|
|
4529
|
-
(task.blockedSegment =
|
|
4530
|
-
(task.blockedPreamble =
|
|
4531
|
-
(task.keyPath = type)
|
|
5067
|
+
(task.blockedSegment = parentSegment),
|
|
5068
|
+
(task.blockedPreamble = propName),
|
|
5069
|
+
(task.keyPath = type),
|
|
5070
|
+
(task.formatContext = ref);
|
|
4532
5071
|
}
|
|
4533
5072
|
task = createRenderTask(
|
|
4534
5073
|
request,
|
|
@@ -4541,11 +5080,14 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4541
5080
|
newBoundary.contentState,
|
|
4542
5081
|
task.abortSet,
|
|
4543
5082
|
keyPath,
|
|
4544
|
-
|
|
5083
|
+
getSuspenseContentFormatContext(
|
|
5084
|
+
request.resumableState,
|
|
5085
|
+
task.formatContext
|
|
5086
|
+
),
|
|
4545
5087
|
task.context,
|
|
4546
5088
|
task.treeContext,
|
|
4547
|
-
|
|
4548
|
-
|
|
5089
|
+
null,
|
|
5090
|
+
newProps
|
|
4549
5091
|
);
|
|
4550
5092
|
pushComponentStack(task);
|
|
4551
5093
|
request.pingedTasks.push(task);
|
|
@@ -4555,6 +5097,11 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4555
5097
|
task.hoistableState = newBoundary.contentState;
|
|
4556
5098
|
task.blockedSegment = contentRootSegment;
|
|
4557
5099
|
task.keyPath = keyPath;
|
|
5100
|
+
task.formatContext = getSuspenseContentFormatContext(
|
|
5101
|
+
request.resumableState,
|
|
5102
|
+
ref
|
|
5103
|
+
);
|
|
5104
|
+
task.row = null;
|
|
4558
5105
|
contentRootSegment.status = 6;
|
|
4559
5106
|
try {
|
|
4560
5107
|
if (
|
|
@@ -4563,22 +5110,33 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4563
5110
|
contentRootSegment.textEmbedded &&
|
|
4564
5111
|
contentRootSegment.chunks.push(textSeparator),
|
|
4565
5112
|
(contentRootSegment.status = 1),
|
|
5113
|
+
finishedSegment(request, newBoundary, contentRootSegment),
|
|
4566
5114
|
queueCompletedSegment(newBoundary, contentRootSegment),
|
|
4567
5115
|
0 === newBoundary.pendingTasks && 0 === newBoundary.status)
|
|
4568
5116
|
) {
|
|
4569
|
-
|
|
4570
|
-
|
|
4571
|
-
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4575
|
-
|
|
5117
|
+
if (
|
|
5118
|
+
((newBoundary.status = 1),
|
|
5119
|
+
!isEligibleForOutlining(request, newBoundary))
|
|
5120
|
+
) {
|
|
5121
|
+
null !== prevRow &&
|
|
5122
|
+
0 === --prevRow.pendingTasks &&
|
|
5123
|
+
finishSuspenseListRow(request, prevRow);
|
|
5124
|
+
0 === request.pendingRootTasks &&
|
|
5125
|
+
task.blockedPreamble &&
|
|
5126
|
+
preparePreamble(request);
|
|
5127
|
+
break a;
|
|
5128
|
+
}
|
|
5129
|
+
} else
|
|
5130
|
+
null !== prevRow &&
|
|
5131
|
+
prevRow.together &&
|
|
5132
|
+
tryToResolveTogetherRow(request, prevRow);
|
|
5133
|
+
} catch (thrownValue$31) {
|
|
4576
5134
|
(newBoundary.status = 4),
|
|
4577
5135
|
12 === request.status
|
|
4578
5136
|
? ((contentRootSegment.status = 3),
|
|
4579
5137
|
(newProps = request.fatalError))
|
|
4580
5138
|
: ((contentRootSegment.status = 4),
|
|
4581
|
-
(newProps = thrownValue$
|
|
5139
|
+
(newProps = thrownValue$31)),
|
|
4582
5140
|
(defaultProps = getThrownInfo(task.componentStack)),
|
|
4583
5141
|
(initialState = logRecoverableError(
|
|
4584
5142
|
request,
|
|
@@ -4588,28 +5146,35 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4588
5146
|
(newBoundary.errorDigest = initialState),
|
|
4589
5147
|
untrackBoundary(request, newBoundary);
|
|
4590
5148
|
} finally {
|
|
4591
|
-
(task.blockedBoundary =
|
|
4592
|
-
(task.blockedPreamble =
|
|
5149
|
+
(task.blockedBoundary = propName$44),
|
|
5150
|
+
(task.blockedPreamble = propName),
|
|
4593
5151
|
(task.hoistableState = parentHoistableState),
|
|
4594
|
-
(task.blockedSegment =
|
|
4595
|
-
(task.keyPath = type)
|
|
5152
|
+
(task.blockedSegment = parentSegment),
|
|
5153
|
+
(task.keyPath = type),
|
|
5154
|
+
(task.formatContext = ref),
|
|
5155
|
+
(task.row = prevRow);
|
|
4596
5156
|
}
|
|
4597
5157
|
task = createRenderTask(
|
|
4598
5158
|
request,
|
|
4599
5159
|
null,
|
|
4600
|
-
|
|
5160
|
+
fallback,
|
|
4601
5161
|
-1,
|
|
4602
|
-
|
|
5162
|
+
propName$44,
|
|
4603
5163
|
boundarySegment,
|
|
4604
5164
|
newBoundary.fallbackPreamble,
|
|
4605
5165
|
newBoundary.fallbackState,
|
|
4606
5166
|
fallbackAbortSet,
|
|
4607
5167
|
[keyPath[0], "Suspense Fallback", keyPath[2]],
|
|
4608
|
-
|
|
5168
|
+
getSuspenseFallbackFormatContext(
|
|
5169
|
+
request.resumableState,
|
|
5170
|
+
task.formatContext
|
|
5171
|
+
),
|
|
4609
5172
|
task.context,
|
|
4610
5173
|
task.treeContext,
|
|
4611
|
-
task.
|
|
4612
|
-
|
|
5174
|
+
task.row,
|
|
5175
|
+
replaceSuspenseComponentStackWithSuspenseFallbackStack(
|
|
5176
|
+
task.componentStack
|
|
5177
|
+
)
|
|
4613
5178
|
);
|
|
4614
5179
|
pushComponentStack(task);
|
|
4615
5180
|
request.pingedTasks.push(task);
|
|
@@ -4621,9 +5186,9 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4621
5186
|
switch (type.$$typeof) {
|
|
4622
5187
|
case REACT_FORWARD_REF_TYPE:
|
|
4623
5188
|
if ("ref" in props)
|
|
4624
|
-
for (
|
|
4625
|
-
"ref" !==
|
|
4626
|
-
(newProps[
|
|
5189
|
+
for (parentSegment in ((newProps = {}), props))
|
|
5190
|
+
"ref" !== parentSegment &&
|
|
5191
|
+
(newProps[parentSegment] = props[parentSegment]);
|
|
4627
5192
|
else newProps = props;
|
|
4628
5193
|
type = renderWithHooks(
|
|
4629
5194
|
request,
|
|
@@ -4646,7 +5211,6 @@ function renderElement(request, task, keyPath, type, props, ref) {
|
|
|
4646
5211
|
case REACT_MEMO_TYPE:
|
|
4647
5212
|
renderElement(request, task, keyPath, type.type, props, ref);
|
|
4648
5213
|
return;
|
|
4649
|
-
case REACT_PROVIDER_TYPE:
|
|
4650
5214
|
case REACT_CONTEXT_TYPE:
|
|
4651
5215
|
defaultProps = props.children;
|
|
4652
5216
|
newProps = task.keyPath;
|
|
@@ -4713,6 +5277,7 @@ function resumeNode(request, task, segmentId, node, childIndex) {
|
|
|
4713
5277
|
(task.blockedSegment = resumedSegment),
|
|
4714
5278
|
renderNode(request, task, node, childIndex),
|
|
4715
5279
|
(resumedSegment.status = 1),
|
|
5280
|
+
finishedSegment(request, blockedBoundary, resumedSegment),
|
|
4716
5281
|
null === blockedBoundary
|
|
4717
5282
|
? (request.completedRootSegment = resumedSegment)
|
|
4718
5283
|
: (queueCompletedSegment(blockedBoundary, resumedSegment),
|
|
@@ -4790,17 +5355,20 @@ function retryNode(request, task) {
|
|
|
4790
5355
|
"function" === typeof x.then)
|
|
4791
5356
|
)
|
|
4792
5357
|
throw (
|
|
4793
|
-
(task.node === keyOrIndex
|
|
5358
|
+
(task.node === keyOrIndex
|
|
5359
|
+
? (task.replay = replay)
|
|
5360
|
+
: childIndex.splice(node, 1),
|
|
4794
5361
|
x)
|
|
4795
5362
|
);
|
|
4796
5363
|
task.replay.pendingTasks--;
|
|
4797
5364
|
props = getThrownInfo(task.componentStack);
|
|
4798
|
-
key =
|
|
5365
|
+
key = request;
|
|
5366
|
+
request = task.blockedBoundary;
|
|
4799
5367
|
type = x;
|
|
4800
|
-
props = logRecoverableError(
|
|
5368
|
+
props = logRecoverableError(key, type, props);
|
|
4801
5369
|
abortRemainingReplayNodes(
|
|
4802
|
-
request,
|
|
4803
5370
|
key,
|
|
5371
|
+
request,
|
|
4804
5372
|
childNodes,
|
|
4805
5373
|
name,
|
|
4806
5374
|
type,
|
|
@@ -4825,6 +5393,8 @@ function retryNode(request, task) {
|
|
|
4825
5393
|
node$jscomp$0 =
|
|
4826
5394
|
null === node$jscomp$0[4] ? null : node$jscomp$0[4][3];
|
|
4827
5395
|
var prevKeyPath = task.keyPath,
|
|
5396
|
+
prevContext = task.formatContext,
|
|
5397
|
+
prevRow = task.row,
|
|
4828
5398
|
previousReplaySet = task.replay,
|
|
4829
5399
|
parentBoundary = task.blockedBoundary,
|
|
4830
5400
|
parentHoistableState = task.hoistableState,
|
|
@@ -4835,12 +5405,14 @@ function retryNode(request, task) {
|
|
|
4835
5405
|
2 > task.formatContext.insertionMode
|
|
4836
5406
|
? createSuspenseBoundary(
|
|
4837
5407
|
request,
|
|
5408
|
+
task.row,
|
|
4838
5409
|
fallbackAbortSet,
|
|
4839
5410
|
createPreambleState(),
|
|
4840
5411
|
createPreambleState()
|
|
4841
5412
|
)
|
|
4842
5413
|
: createSuspenseBoundary(
|
|
4843
5414
|
request,
|
|
5415
|
+
task.row,
|
|
4844
5416
|
fallbackAbortSet,
|
|
4845
5417
|
null,
|
|
4846
5418
|
null
|
|
@@ -4850,6 +5422,11 @@ function retryNode(request, task) {
|
|
|
4850
5422
|
task.blockedBoundary = props;
|
|
4851
5423
|
task.hoistableState = props.contentState;
|
|
4852
5424
|
task.keyPath = key;
|
|
5425
|
+
task.formatContext = getSuspenseContentFormatContext(
|
|
5426
|
+
request.resumableState,
|
|
5427
|
+
prevContext
|
|
5428
|
+
);
|
|
5429
|
+
task.row = null;
|
|
4853
5430
|
task.replay = {
|
|
4854
5431
|
nodes: ref,
|
|
4855
5432
|
slots: name,
|
|
@@ -4885,9 +5462,11 @@ function retryNode(request, task) {
|
|
|
4885
5462
|
(task.blockedBoundary = parentBoundary),
|
|
4886
5463
|
(task.hoistableState = parentHoistableState),
|
|
4887
5464
|
(task.replay = previousReplaySet),
|
|
4888
|
-
(task.keyPath = prevKeyPath)
|
|
5465
|
+
(task.keyPath = prevKeyPath),
|
|
5466
|
+
(task.formatContext = prevContext),
|
|
5467
|
+
(task.row = prevRow);
|
|
4889
5468
|
}
|
|
4890
|
-
|
|
5469
|
+
childNodes = createReplayTask(
|
|
4891
5470
|
request,
|
|
4892
5471
|
null,
|
|
4893
5472
|
{
|
|
@@ -4901,14 +5480,19 @@ function retryNode(request, task) {
|
|
|
4901
5480
|
props.fallbackState,
|
|
4902
5481
|
fallbackAbortSet,
|
|
4903
5482
|
[key[0], "Suspense Fallback", key[2]],
|
|
4904
|
-
|
|
5483
|
+
getSuspenseFallbackFormatContext(
|
|
5484
|
+
request.resumableState,
|
|
5485
|
+
task.formatContext
|
|
5486
|
+
),
|
|
4905
5487
|
task.context,
|
|
4906
5488
|
task.treeContext,
|
|
4907
|
-
task.
|
|
4908
|
-
|
|
5489
|
+
task.row,
|
|
5490
|
+
replaceSuspenseComponentStackWithSuspenseFallbackStack(
|
|
5491
|
+
task.componentStack
|
|
5492
|
+
)
|
|
4909
5493
|
);
|
|
4910
|
-
pushComponentStack(
|
|
4911
|
-
request.pingedTasks.push(
|
|
5494
|
+
pushComponentStack(childNodes);
|
|
5495
|
+
request.pingedTasks.push(childNodes);
|
|
4912
5496
|
}
|
|
4913
5497
|
}
|
|
4914
5498
|
childIndex.splice(node, 1);
|
|
@@ -4933,22 +5517,17 @@ function retryNode(request, task) {
|
|
|
4933
5517
|
renderChildrenArray(request, task, node, childIndex);
|
|
4934
5518
|
return;
|
|
4935
5519
|
}
|
|
4936
|
-
|
|
4937
|
-
|
|
4938
|
-
|
|
4939
|
-
|
|
4940
|
-
|
|
4941
|
-
|
|
4942
|
-
|
|
4943
|
-
|
|
4944
|
-
|
|
4945
|
-
|
|
4946
|
-
do props.push(node.value), (node = childNodes.next());
|
|
4947
|
-
while (!node.done);
|
|
4948
|
-
renderChildrenArray(request, task, props, childIndex);
|
|
5520
|
+
if ((childNodes = getIteratorFn(node)))
|
|
5521
|
+
if ((childNodes = childNodes.call(node))) {
|
|
5522
|
+
node = childNodes.next();
|
|
5523
|
+
if (!node.done) {
|
|
5524
|
+
props = [];
|
|
5525
|
+
do props.push(node.value), (node = childNodes.next());
|
|
5526
|
+
while (!node.done);
|
|
5527
|
+
renderChildrenArray(request, task, props, childIndex);
|
|
5528
|
+
}
|
|
5529
|
+
return;
|
|
4949
5530
|
}
|
|
4950
|
-
return;
|
|
4951
|
-
}
|
|
4952
5531
|
if ("function" === typeof node.then)
|
|
4953
5532
|
return (
|
|
4954
5533
|
(task.thenableState = null),
|
|
@@ -5068,15 +5647,114 @@ function renderChildrenArray(request, task, children, childIndex) {
|
|
|
5068
5647
|
task.treeContext = replay;
|
|
5069
5648
|
task.keyPath = prevKeyPath;
|
|
5070
5649
|
}
|
|
5071
|
-
function
|
|
5072
|
-
|
|
5073
|
-
|
|
5074
|
-
|
|
5075
|
-
|
|
5076
|
-
|
|
5077
|
-
|
|
5078
|
-
|
|
5079
|
-
|
|
5650
|
+
function trackPostponedBoundary(request, trackedPostpones, boundary) {
|
|
5651
|
+
boundary.status = 5;
|
|
5652
|
+
boundary.rootSegmentID = request.nextSegmentId++;
|
|
5653
|
+
request = boundary.trackedContentKeyPath;
|
|
5654
|
+
if (null === request)
|
|
5655
|
+
throw Error(
|
|
5656
|
+
"It should not be possible to postpone at the root. This is a bug in React."
|
|
5657
|
+
);
|
|
5658
|
+
var fallbackReplayNode = boundary.trackedFallbackNode,
|
|
5659
|
+
children = [],
|
|
5660
|
+
boundaryNode = trackedPostpones.workingMap.get(request);
|
|
5661
|
+
if (void 0 === boundaryNode)
|
|
5662
|
+
return (
|
|
5663
|
+
(boundary = [
|
|
5664
|
+
request[1],
|
|
5665
|
+
request[2],
|
|
5666
|
+
children,
|
|
5667
|
+
null,
|
|
5668
|
+
fallbackReplayNode,
|
|
5669
|
+
boundary.rootSegmentID
|
|
5670
|
+
]),
|
|
5671
|
+
trackedPostpones.workingMap.set(request, boundary),
|
|
5672
|
+
addToReplayParent(boundary, request[0], trackedPostpones),
|
|
5673
|
+
boundary
|
|
5674
|
+
);
|
|
5675
|
+
boundaryNode[4] = fallbackReplayNode;
|
|
5676
|
+
boundaryNode[5] = boundary.rootSegmentID;
|
|
5677
|
+
return boundaryNode;
|
|
5678
|
+
}
|
|
5679
|
+
function trackPostpone(request, trackedPostpones, task, segment) {
|
|
5680
|
+
segment.status = 5;
|
|
5681
|
+
var keyPath = task.keyPath,
|
|
5682
|
+
boundary = task.blockedBoundary;
|
|
5683
|
+
if (null === boundary)
|
|
5684
|
+
(segment.id = request.nextSegmentId++),
|
|
5685
|
+
(trackedPostpones.rootSlots = segment.id),
|
|
5686
|
+
null !== request.completedRootSegment &&
|
|
5687
|
+
(request.completedRootSegment.status = 5);
|
|
5688
|
+
else {
|
|
5689
|
+
if (null !== boundary && 0 === boundary.status) {
|
|
5690
|
+
var boundaryNode = trackPostponedBoundary(
|
|
5691
|
+
request,
|
|
5692
|
+
trackedPostpones,
|
|
5693
|
+
boundary
|
|
5694
|
+
);
|
|
5695
|
+
if (
|
|
5696
|
+
boundary.trackedContentKeyPath === keyPath &&
|
|
5697
|
+
-1 === task.childIndex
|
|
5698
|
+
) {
|
|
5699
|
+
-1 === segment.id &&
|
|
5700
|
+
(segment.id = segment.parentFlushed
|
|
5701
|
+
? boundary.rootSegmentID
|
|
5702
|
+
: request.nextSegmentId++);
|
|
5703
|
+
boundaryNode[3] = segment.id;
|
|
5704
|
+
return;
|
|
5705
|
+
}
|
|
5706
|
+
}
|
|
5707
|
+
-1 === segment.id &&
|
|
5708
|
+
(segment.id =
|
|
5709
|
+
segment.parentFlushed && null !== boundary
|
|
5710
|
+
? boundary.rootSegmentID
|
|
5711
|
+
: request.nextSegmentId++);
|
|
5712
|
+
if (-1 === task.childIndex)
|
|
5713
|
+
null === keyPath
|
|
5714
|
+
? (trackedPostpones.rootSlots = segment.id)
|
|
5715
|
+
: ((task = trackedPostpones.workingMap.get(keyPath)),
|
|
5716
|
+
void 0 === task
|
|
5717
|
+
? ((task = [keyPath[1], keyPath[2], [], segment.id]),
|
|
5718
|
+
addToReplayParent(task, keyPath[0], trackedPostpones))
|
|
5719
|
+
: (task[3] = segment.id));
|
|
5720
|
+
else {
|
|
5721
|
+
if (null === keyPath)
|
|
5722
|
+
if (((request = trackedPostpones.rootSlots), null === request))
|
|
5723
|
+
request = trackedPostpones.rootSlots = {};
|
|
5724
|
+
else {
|
|
5725
|
+
if ("number" === typeof request)
|
|
5726
|
+
throw Error(
|
|
5727
|
+
"It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React."
|
|
5728
|
+
);
|
|
5729
|
+
}
|
|
5730
|
+
else if (
|
|
5731
|
+
((boundary = trackedPostpones.workingMap),
|
|
5732
|
+
(boundaryNode = boundary.get(keyPath)),
|
|
5733
|
+
void 0 === boundaryNode)
|
|
5734
|
+
)
|
|
5735
|
+
(request = {}),
|
|
5736
|
+
(boundaryNode = [keyPath[1], keyPath[2], [], request]),
|
|
5737
|
+
boundary.set(keyPath, boundaryNode),
|
|
5738
|
+
addToReplayParent(boundaryNode, keyPath[0], trackedPostpones);
|
|
5739
|
+
else if (((request = boundaryNode[3]), null === request))
|
|
5740
|
+
request = boundaryNode[3] = {};
|
|
5741
|
+
else if ("number" === typeof request)
|
|
5742
|
+
throw Error(
|
|
5743
|
+
"It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React."
|
|
5744
|
+
);
|
|
5745
|
+
request[task.childIndex] = segment.id;
|
|
5746
|
+
}
|
|
5747
|
+
}
|
|
5748
|
+
}
|
|
5749
|
+
function untrackBoundary(request, boundary) {
|
|
5750
|
+
request = request.trackedPostpones;
|
|
5751
|
+
null !== request &&
|
|
5752
|
+
((boundary = boundary.trackedContentKeyPath),
|
|
5753
|
+
null !== boundary &&
|
|
5754
|
+
((boundary = request.workingMap.get(boundary)),
|
|
5755
|
+
void 0 !== boundary &&
|
|
5756
|
+
((boundary.length = 4), (boundary[2] = []), (boundary[3] = null))));
|
|
5757
|
+
}
|
|
5080
5758
|
function spawnNewSuspendedReplayTask(request, task, thenableState) {
|
|
5081
5759
|
return createReplayTask(
|
|
5082
5760
|
request,
|
|
@@ -5091,8 +5769,8 @@ function spawnNewSuspendedReplayTask(request, task, thenableState) {
|
|
|
5091
5769
|
task.formatContext,
|
|
5092
5770
|
task.context,
|
|
5093
5771
|
task.treeContext,
|
|
5094
|
-
task.
|
|
5095
|
-
task.
|
|
5772
|
+
task.row,
|
|
5773
|
+
task.componentStack
|
|
5096
5774
|
);
|
|
5097
5775
|
}
|
|
5098
5776
|
function spawnNewSuspendedRenderTask(request, task, thenableState) {
|
|
@@ -5121,8 +5799,8 @@ function spawnNewSuspendedRenderTask(request, task, thenableState) {
|
|
|
5121
5799
|
task.formatContext,
|
|
5122
5800
|
task.context,
|
|
5123
5801
|
task.treeContext,
|
|
5124
|
-
task.
|
|
5125
|
-
task.
|
|
5802
|
+
task.row,
|
|
5803
|
+
task.componentStack
|
|
5126
5804
|
);
|
|
5127
5805
|
}
|
|
5128
5806
|
function renderNode(request, task, node, childIndex) {
|
|
@@ -5132,7 +5810,8 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5132
5810
|
previousTreeContext = task.treeContext,
|
|
5133
5811
|
previousComponentStack = task.componentStack,
|
|
5134
5812
|
segment = task.blockedSegment;
|
|
5135
|
-
if (null === segment)
|
|
5813
|
+
if (null === segment) {
|
|
5814
|
+
segment = task.replay;
|
|
5136
5815
|
try {
|
|
5137
5816
|
return renderNodeDestructive(request, task, node, childIndex);
|
|
5138
5817
|
} catch (thrownValue) {
|
|
@@ -5142,10 +5821,13 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5142
5821
|
thrownValue === SuspenseException
|
|
5143
5822
|
? getSuspendedThenable()
|
|
5144
5823
|
: thrownValue),
|
|
5145
|
-
"object" === typeof node && null !== node)
|
|
5824
|
+
12 !== request.status && "object" === typeof node && null !== node)
|
|
5146
5825
|
) {
|
|
5147
5826
|
if ("function" === typeof node.then) {
|
|
5148
|
-
childIndex =
|
|
5827
|
+
childIndex =
|
|
5828
|
+
thrownValue === SuspenseException
|
|
5829
|
+
? getThenableStateAfterSuspending()
|
|
5830
|
+
: null;
|
|
5149
5831
|
request = spawnNewSuspendedReplayTask(request, task, childIndex).ping;
|
|
5150
5832
|
node.then(request, request);
|
|
5151
5833
|
task.formatContext = previousFormatContext;
|
|
@@ -5153,11 +5835,15 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5153
5835
|
task.keyPath = previousKeyPath;
|
|
5154
5836
|
task.treeContext = previousTreeContext;
|
|
5155
5837
|
task.componentStack = previousComponentStack;
|
|
5838
|
+
task.replay = segment;
|
|
5156
5839
|
switchContext(previousContext);
|
|
5157
5840
|
return;
|
|
5158
5841
|
}
|
|
5159
5842
|
if ("Maximum call stack size exceeded" === node.message) {
|
|
5160
|
-
node =
|
|
5843
|
+
node =
|
|
5844
|
+
thrownValue === SuspenseException
|
|
5845
|
+
? getThenableStateAfterSuspending()
|
|
5846
|
+
: null;
|
|
5161
5847
|
node = spawnNewSuspendedReplayTask(request, task, node);
|
|
5162
5848
|
request.pingedTasks.push(node);
|
|
5163
5849
|
task.formatContext = previousFormatContext;
|
|
@@ -5165,31 +5851,36 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5165
5851
|
task.keyPath = previousKeyPath;
|
|
5166
5852
|
task.treeContext = previousTreeContext;
|
|
5167
5853
|
task.componentStack = previousComponentStack;
|
|
5854
|
+
task.replay = segment;
|
|
5168
5855
|
switchContext(previousContext);
|
|
5169
5856
|
return;
|
|
5170
5857
|
}
|
|
5171
5858
|
}
|
|
5172
5859
|
}
|
|
5173
|
-
else {
|
|
5860
|
+
} else {
|
|
5174
5861
|
var childrenLength = segment.children.length,
|
|
5175
5862
|
chunkLength = segment.chunks.length;
|
|
5176
5863
|
try {
|
|
5177
5864
|
return renderNodeDestructive(request, task, node, childIndex);
|
|
5178
|
-
} catch (thrownValue$
|
|
5865
|
+
} catch (thrownValue$63) {
|
|
5179
5866
|
if (
|
|
5180
5867
|
(resetHooksState(),
|
|
5181
5868
|
(segment.children.length = childrenLength),
|
|
5182
5869
|
(segment.chunks.length = chunkLength),
|
|
5183
5870
|
(node =
|
|
5184
|
-
thrownValue$
|
|
5871
|
+
thrownValue$63 === SuspenseException
|
|
5185
5872
|
? getSuspendedThenable()
|
|
5186
|
-
: thrownValue$
|
|
5187
|
-
"object" === typeof node && null !== node)
|
|
5873
|
+
: thrownValue$63),
|
|
5874
|
+
12 !== request.status && "object" === typeof node && null !== node)
|
|
5188
5875
|
) {
|
|
5189
5876
|
if ("function" === typeof node.then) {
|
|
5190
|
-
|
|
5191
|
-
|
|
5192
|
-
|
|
5877
|
+
segment = node;
|
|
5878
|
+
node =
|
|
5879
|
+
thrownValue$63 === SuspenseException
|
|
5880
|
+
? getThenableStateAfterSuspending()
|
|
5881
|
+
: null;
|
|
5882
|
+
request = spawnNewSuspendedRenderTask(request, task, node).ping;
|
|
5883
|
+
segment.then(request, request);
|
|
5193
5884
|
task.formatContext = previousFormatContext;
|
|
5194
5885
|
task.context = previousContext;
|
|
5195
5886
|
task.keyPath = previousKeyPath;
|
|
@@ -5199,9 +5890,12 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5199
5890
|
return;
|
|
5200
5891
|
}
|
|
5201
5892
|
if ("Maximum call stack size exceeded" === node.message) {
|
|
5202
|
-
|
|
5203
|
-
|
|
5204
|
-
|
|
5893
|
+
segment =
|
|
5894
|
+
thrownValue$63 === SuspenseException
|
|
5895
|
+
? getThenableStateAfterSuspending()
|
|
5896
|
+
: null;
|
|
5897
|
+
segment = spawnNewSuspendedRenderTask(request, task, segment);
|
|
5898
|
+
request.pingedTasks.push(segment);
|
|
5205
5899
|
task.formatContext = previousFormatContext;
|
|
5206
5900
|
task.context = previousContext;
|
|
5207
5901
|
task.keyPath = previousKeyPath;
|
|
@@ -5221,9 +5915,10 @@ function renderNode(request, task, node, childIndex) {
|
|
|
5221
5915
|
throw node;
|
|
5222
5916
|
}
|
|
5223
5917
|
function abortTaskSoft(task) {
|
|
5224
|
-
var boundary = task.blockedBoundary
|
|
5225
|
-
|
|
5226
|
-
null !==
|
|
5918
|
+
var boundary = task.blockedBoundary,
|
|
5919
|
+
segment = task.blockedSegment;
|
|
5920
|
+
null !== segment &&
|
|
5921
|
+
((segment.status = 3), finishedTask(this, boundary, task.row, segment));
|
|
5227
5922
|
}
|
|
5228
5923
|
function abortRemainingReplayNodes(
|
|
5229
5924
|
request$jscomp$0,
|
|
@@ -5250,6 +5945,7 @@ function abortRemainingReplayNodes(
|
|
|
5250
5945
|
errorDigest = errorDigest$jscomp$0,
|
|
5251
5946
|
resumedBoundary = createSuspenseBoundary(
|
|
5252
5947
|
request,
|
|
5948
|
+
null,
|
|
5253
5949
|
new Set(),
|
|
5254
5950
|
null,
|
|
5255
5951
|
null
|
|
@@ -5283,44 +5979,69 @@ function abortTask(task, request, error) {
|
|
|
5283
5979
|
if (6 === segment.status) return;
|
|
5284
5980
|
segment.status = 3;
|
|
5285
5981
|
}
|
|
5286
|
-
|
|
5982
|
+
var errorInfo = getThrownInfo(task.componentStack);
|
|
5287
5983
|
if (null === boundary) {
|
|
5288
5984
|
if (13 !== request.status && 14 !== request.status) {
|
|
5289
5985
|
boundary = task.replay;
|
|
5290
5986
|
if (null === boundary) {
|
|
5291
|
-
|
|
5292
|
-
|
|
5987
|
+
null !== request.trackedPostpones && null !== segment
|
|
5988
|
+
? ((boundary = request.trackedPostpones),
|
|
5989
|
+
logRecoverableError(request, error, errorInfo),
|
|
5990
|
+
trackPostpone(request, boundary, task, segment),
|
|
5991
|
+
finishedTask(request, null, task.row, segment))
|
|
5992
|
+
: (logRecoverableError(request, error, errorInfo),
|
|
5993
|
+
fatalError(request, error));
|
|
5293
5994
|
return;
|
|
5294
5995
|
}
|
|
5295
5996
|
boundary.pendingTasks--;
|
|
5296
5997
|
0 === boundary.pendingTasks &&
|
|
5297
5998
|
0 < boundary.nodes.length &&
|
|
5298
|
-
((
|
|
5999
|
+
((segment = logRecoverableError(request, error, errorInfo)),
|
|
5299
6000
|
abortRemainingReplayNodes(
|
|
5300
6001
|
request,
|
|
5301
6002
|
null,
|
|
5302
6003
|
boundary.nodes,
|
|
5303
6004
|
boundary.slots,
|
|
5304
6005
|
error,
|
|
5305
|
-
|
|
6006
|
+
segment
|
|
5306
6007
|
));
|
|
5307
6008
|
request.pendingRootTasks--;
|
|
5308
6009
|
0 === request.pendingRootTasks && completeShell(request);
|
|
5309
6010
|
}
|
|
5310
|
-
} else
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
5315
|
-
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
5319
|
-
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
boundary.
|
|
6011
|
+
} else {
|
|
6012
|
+
var trackedPostpones$64 = request.trackedPostpones;
|
|
6013
|
+
if (4 !== boundary.status) {
|
|
6014
|
+
if (null !== trackedPostpones$64 && null !== segment)
|
|
6015
|
+
return (
|
|
6016
|
+
logRecoverableError(request, error, errorInfo),
|
|
6017
|
+
trackPostpone(request, trackedPostpones$64, task, segment),
|
|
6018
|
+
boundary.fallbackAbortableTasks.forEach(function (fallbackTask) {
|
|
6019
|
+
return abortTask(fallbackTask, request, error);
|
|
6020
|
+
}),
|
|
6021
|
+
boundary.fallbackAbortableTasks.clear(),
|
|
6022
|
+
finishedTask(request, boundary, task.row, segment)
|
|
6023
|
+
);
|
|
6024
|
+
boundary.status = 4;
|
|
6025
|
+
segment = logRecoverableError(request, error, errorInfo);
|
|
6026
|
+
boundary.status = 4;
|
|
6027
|
+
boundary.errorDigest = segment;
|
|
6028
|
+
untrackBoundary(request, boundary);
|
|
6029
|
+
boundary.parentFlushed && request.clientRenderedBoundaries.push(boundary);
|
|
6030
|
+
}
|
|
6031
|
+
boundary.pendingTasks--;
|
|
6032
|
+
segment = boundary.row;
|
|
6033
|
+
null !== segment &&
|
|
6034
|
+
0 === --segment.pendingTasks &&
|
|
6035
|
+
finishSuspenseListRow(request, segment);
|
|
6036
|
+
boundary.fallbackAbortableTasks.forEach(function (fallbackTask) {
|
|
6037
|
+
return abortTask(fallbackTask, request, error);
|
|
6038
|
+
});
|
|
6039
|
+
boundary.fallbackAbortableTasks.clear();
|
|
6040
|
+
}
|
|
6041
|
+
task = task.row;
|
|
6042
|
+
null !== task &&
|
|
6043
|
+
0 === --task.pendingTasks &&
|
|
6044
|
+
finishSuspenseListRow(request, task);
|
|
5324
6045
|
request.allPendingTasks--;
|
|
5325
6046
|
0 === request.allPendingTasks && completeAll(request);
|
|
5326
6047
|
}
|
|
@@ -5414,10 +6135,28 @@ function queueCompletedSegment(boundary, segment) {
|
|
|
5414
6135
|
var childSegment = segment.children[0];
|
|
5415
6136
|
childSegment.id = segment.id;
|
|
5416
6137
|
childSegment.parentFlushed = !0;
|
|
5417
|
-
1
|
|
6138
|
+
(1 !== childSegment.status &&
|
|
6139
|
+
3 !== childSegment.status &&
|
|
6140
|
+
4 !== childSegment.status) ||
|
|
6141
|
+
queueCompletedSegment(boundary, childSegment);
|
|
5418
6142
|
} else boundary.completedSegments.push(segment);
|
|
5419
6143
|
}
|
|
5420
|
-
function
|
|
6144
|
+
function finishedSegment(request, boundary, segment) {
|
|
6145
|
+
if (null !== byteLengthOfChunk) {
|
|
6146
|
+
segment = segment.chunks;
|
|
6147
|
+
for (var segmentByteSize = 0, i = 0; i < segment.length; i++)
|
|
6148
|
+
segmentByteSize += byteLengthOfChunk(segment[i]);
|
|
6149
|
+
null === boundary
|
|
6150
|
+
? (request.byteSize += segmentByteSize)
|
|
6151
|
+
: (boundary.byteSize += segmentByteSize);
|
|
6152
|
+
}
|
|
6153
|
+
}
|
|
6154
|
+
function finishedTask(request, boundary, row, segment) {
|
|
6155
|
+
null !== row &&
|
|
6156
|
+
(0 === --row.pendingTasks
|
|
6157
|
+
? finishSuspenseListRow(request, row)
|
|
6158
|
+
: row.together && tryToResolveTogetherRow(request, row));
|
|
6159
|
+
request.allPendingTasks--;
|
|
5421
6160
|
if (null === boundary) {
|
|
5422
6161
|
if (null !== segment && segment.parentFlushed) {
|
|
5423
6162
|
if (null !== request.completedRootSegment)
|
|
@@ -5428,32 +6167,68 @@ function finishedTask(request, boundary, segment) {
|
|
|
5428
6167
|
}
|
|
5429
6168
|
request.pendingRootTasks--;
|
|
5430
6169
|
0 === request.pendingRootTasks && completeShell(request);
|
|
5431
|
-
} else
|
|
5432
|
-
boundary.pendingTasks
|
|
5433
|
-
|
|
5434
|
-
(0 === boundary.
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
|
|
5438
|
-
|
|
5439
|
-
|
|
5440
|
-
|
|
5441
|
-
|
|
5442
|
-
|
|
5443
|
-
|
|
5444
|
-
|
|
5445
|
-
|
|
5446
|
-
|
|
5447
|
-
|
|
5448
|
-
|
|
5449
|
-
|
|
5450
|
-
|
|
5451
|
-
|
|
5452
|
-
|
|
5453
|
-
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
|
-
|
|
6170
|
+
} else if ((boundary.pendingTasks--, 4 !== boundary.status))
|
|
6171
|
+
if (0 === boundary.pendingTasks)
|
|
6172
|
+
if (
|
|
6173
|
+
(0 === boundary.status && (boundary.status = 1),
|
|
6174
|
+
null !== segment &&
|
|
6175
|
+
segment.parentFlushed &&
|
|
6176
|
+
(1 === segment.status || 3 === segment.status) &&
|
|
6177
|
+
queueCompletedSegment(boundary, segment),
|
|
6178
|
+
boundary.parentFlushed && request.completedBoundaries.push(boundary),
|
|
6179
|
+
1 === boundary.status)
|
|
6180
|
+
)
|
|
6181
|
+
(row = boundary.row),
|
|
6182
|
+
null !== row &&
|
|
6183
|
+
hoistHoistables(row.hoistables, boundary.contentState),
|
|
6184
|
+
isEligibleForOutlining(request, boundary) ||
|
|
6185
|
+
(boundary.fallbackAbortableTasks.forEach(abortTaskSoft, request),
|
|
6186
|
+
boundary.fallbackAbortableTasks.clear(),
|
|
6187
|
+
null !== row &&
|
|
6188
|
+
0 === --row.pendingTasks &&
|
|
6189
|
+
finishSuspenseListRow(request, row)),
|
|
6190
|
+
0 === request.pendingRootTasks &&
|
|
6191
|
+
null === request.trackedPostpones &&
|
|
6192
|
+
null !== boundary.contentPreamble &&
|
|
6193
|
+
preparePreamble(request);
|
|
6194
|
+
else {
|
|
6195
|
+
if (
|
|
6196
|
+
5 === boundary.status &&
|
|
6197
|
+
((boundary = boundary.row), null !== boundary)
|
|
6198
|
+
) {
|
|
6199
|
+
if (null !== request.trackedPostpones) {
|
|
6200
|
+
row = request.trackedPostpones;
|
|
6201
|
+
var postponedRow = boundary.next;
|
|
6202
|
+
if (
|
|
6203
|
+
null !== postponedRow &&
|
|
6204
|
+
((segment = postponedRow.boundaries), null !== segment)
|
|
6205
|
+
)
|
|
6206
|
+
for (
|
|
6207
|
+
postponedRow.boundaries = null, postponedRow = 0;
|
|
6208
|
+
postponedRow < segment.length;
|
|
6209
|
+
postponedRow++
|
|
6210
|
+
) {
|
|
6211
|
+
var postponedBoundary = segment[postponedRow];
|
|
6212
|
+
trackPostponedBoundary(request, row, postponedBoundary);
|
|
6213
|
+
finishedTask(request, postponedBoundary, null, null);
|
|
6214
|
+
}
|
|
6215
|
+
}
|
|
6216
|
+
0 === --boundary.pendingTasks &&
|
|
6217
|
+
finishSuspenseListRow(request, boundary);
|
|
6218
|
+
}
|
|
6219
|
+
}
|
|
6220
|
+
else
|
|
6221
|
+
null === segment ||
|
|
6222
|
+
!segment.parentFlushed ||
|
|
6223
|
+
(1 !== segment.status && 3 !== segment.status) ||
|
|
6224
|
+
(queueCompletedSegment(boundary, segment),
|
|
6225
|
+
1 === boundary.completedSegments.length &&
|
|
6226
|
+
boundary.parentFlushed &&
|
|
6227
|
+
request.partialBoundaries.push(boundary)),
|
|
6228
|
+
(boundary = boundary.row),
|
|
6229
|
+
null !== boundary &&
|
|
6230
|
+
boundary.together &&
|
|
6231
|
+
tryToResolveTogetherRow(request, boundary);
|
|
5457
6232
|
0 === request.allPendingTasks && completeAll(request);
|
|
5458
6233
|
}
|
|
5459
6234
|
function performWork(request$jscomp$2) {
|
|
@@ -5497,7 +6272,12 @@ function performWork(request$jscomp$2) {
|
|
|
5497
6272
|
);
|
|
5498
6273
|
task.replay.pendingTasks--;
|
|
5499
6274
|
task.abortSet.delete(task);
|
|
5500
|
-
finishedTask(
|
|
6275
|
+
finishedTask(
|
|
6276
|
+
request$jscomp$0,
|
|
6277
|
+
task.blockedBoundary,
|
|
6278
|
+
task.row,
|
|
6279
|
+
null
|
|
6280
|
+
);
|
|
5501
6281
|
} catch (thrownValue) {
|
|
5502
6282
|
resetHooksState();
|
|
5503
6283
|
var x =
|
|
@@ -5511,7 +6291,10 @@ function performWork(request$jscomp$2) {
|
|
|
5511
6291
|
) {
|
|
5512
6292
|
var ping = task.ping;
|
|
5513
6293
|
x.then(ping, ping);
|
|
5514
|
-
task.thenableState =
|
|
6294
|
+
task.thenableState =
|
|
6295
|
+
thrownValue === SuspenseException
|
|
6296
|
+
? getThenableStateAfterSuspending()
|
|
6297
|
+
: null;
|
|
5515
6298
|
} else {
|
|
5516
6299
|
task.replay.pendingTasks--;
|
|
5517
6300
|
task.abortSet.delete(task);
|
|
@@ -5564,7 +6347,13 @@ function performWork(request$jscomp$2) {
|
|
|
5564
6347
|
request$jscomp$1.chunks.push(textSeparator),
|
|
5565
6348
|
task.abortSet.delete(task),
|
|
5566
6349
|
(request$jscomp$1.status = 1),
|
|
5567
|
-
|
|
6350
|
+
finishedSegment(request, task.blockedBoundary, request$jscomp$1),
|
|
6351
|
+
finishedTask(
|
|
6352
|
+
request,
|
|
6353
|
+
task.blockedBoundary,
|
|
6354
|
+
task.row,
|
|
6355
|
+
request$jscomp$1
|
|
6356
|
+
);
|
|
5568
6357
|
} catch (thrownValue) {
|
|
5569
6358
|
resetHooksState();
|
|
5570
6359
|
request$jscomp$1.children.length = childrenLength;
|
|
@@ -5575,39 +6364,64 @@ function performWork(request$jscomp$2) {
|
|
|
5575
6364
|
: 12 === request.status
|
|
5576
6365
|
? request.fatalError
|
|
5577
6366
|
: thrownValue;
|
|
5578
|
-
if (
|
|
6367
|
+
if (12 === request.status && null !== request.trackedPostpones) {
|
|
6368
|
+
var trackedPostpones = request.trackedPostpones,
|
|
6369
|
+
thrownInfo = getThrownInfo(task.componentStack);
|
|
6370
|
+
task.abortSet.delete(task);
|
|
6371
|
+
logRecoverableError(request, x$jscomp$0, thrownInfo);
|
|
6372
|
+
trackPostpone(request, trackedPostpones, task, request$jscomp$1);
|
|
6373
|
+
finishedTask(
|
|
6374
|
+
request,
|
|
6375
|
+
task.blockedBoundary,
|
|
6376
|
+
task.row,
|
|
6377
|
+
request$jscomp$1
|
|
6378
|
+
);
|
|
6379
|
+
} else if (
|
|
5579
6380
|
"object" === typeof x$jscomp$0 &&
|
|
5580
6381
|
null !== x$jscomp$0 &&
|
|
5581
6382
|
"function" === typeof x$jscomp$0.then
|
|
5582
6383
|
) {
|
|
5583
6384
|
request$jscomp$1.status = 0;
|
|
5584
|
-
task.thenableState =
|
|
6385
|
+
task.thenableState =
|
|
6386
|
+
thrownValue === SuspenseException
|
|
6387
|
+
? getThenableStateAfterSuspending()
|
|
6388
|
+
: null;
|
|
5585
6389
|
var ping$jscomp$0 = task.ping;
|
|
5586
6390
|
x$jscomp$0.then(ping$jscomp$0, ping$jscomp$0);
|
|
5587
6391
|
} else {
|
|
5588
6392
|
var errorInfo$jscomp$0 = getThrownInfo(task.componentStack);
|
|
5589
6393
|
task.abortSet.delete(task);
|
|
5590
6394
|
request$jscomp$1.status = 4;
|
|
5591
|
-
var boundary$jscomp$0 = task.blockedBoundary
|
|
6395
|
+
var boundary$jscomp$0 = task.blockedBoundary,
|
|
6396
|
+
row = task.row;
|
|
6397
|
+
null !== row &&
|
|
6398
|
+
0 === --row.pendingTasks &&
|
|
6399
|
+
finishSuspenseListRow(request, row);
|
|
6400
|
+
request.allPendingTasks--;
|
|
5592
6401
|
request$jscomp$0 = logRecoverableError(
|
|
5593
6402
|
request,
|
|
5594
6403
|
x$jscomp$0,
|
|
5595
6404
|
errorInfo$jscomp$0
|
|
5596
6405
|
);
|
|
5597
|
-
null === boundary$jscomp$0
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5608
|
-
|
|
5609
|
-
|
|
5610
|
-
|
|
6406
|
+
if (null === boundary$jscomp$0) fatalError(request, x$jscomp$0);
|
|
6407
|
+
else if (
|
|
6408
|
+
(boundary$jscomp$0.pendingTasks--,
|
|
6409
|
+
4 !== boundary$jscomp$0.status)
|
|
6410
|
+
) {
|
|
6411
|
+
boundary$jscomp$0.status = 4;
|
|
6412
|
+
boundary$jscomp$0.errorDigest = request$jscomp$0;
|
|
6413
|
+
untrackBoundary(request, boundary$jscomp$0);
|
|
6414
|
+
var boundaryRow = boundary$jscomp$0.row;
|
|
6415
|
+
null !== boundaryRow &&
|
|
6416
|
+
0 === --boundaryRow.pendingTasks &&
|
|
6417
|
+
finishSuspenseListRow(request, boundaryRow);
|
|
6418
|
+
boundary$jscomp$0.parentFlushed &&
|
|
6419
|
+
request.clientRenderedBoundaries.push(boundary$jscomp$0);
|
|
6420
|
+
0 === request.pendingRootTasks &&
|
|
6421
|
+
null === request.trackedPostpones &&
|
|
6422
|
+
null !== boundary$jscomp$0.contentPreamble &&
|
|
6423
|
+
preparePreamble(request);
|
|
6424
|
+
}
|
|
5611
6425
|
0 === request.allPendingTasks && completeAll(request);
|
|
5612
6426
|
}
|
|
5613
6427
|
} finally {
|
|
@@ -5663,6 +6477,7 @@ function preparePreambleFromSegment(
|
|
|
5663
6477
|
switch (boundary.status) {
|
|
5664
6478
|
case 1:
|
|
5665
6479
|
hoistPreambleState(request.renderState, preamble);
|
|
6480
|
+
request.byteSize += boundary.byteSize;
|
|
5666
6481
|
segment = boundary.completedSegments[0];
|
|
5667
6482
|
if (!segment)
|
|
5668
6483
|
throw Error(
|
|
@@ -5695,17 +6510,16 @@ function preparePreamble(request) {
|
|
|
5695
6510
|
null === request.completedPreambleSegments
|
|
5696
6511
|
) {
|
|
5697
6512
|
var collectedPreambleSegments = [],
|
|
6513
|
+
originalRequestByteSize = request.byteSize,
|
|
5698
6514
|
hasPendingPreambles = preparePreambleFromSegment(
|
|
5699
6515
|
request,
|
|
5700
6516
|
request.completedRootSegment,
|
|
5701
6517
|
collectedPreambleSegments
|
|
5702
6518
|
),
|
|
5703
6519
|
preamble = request.renderState.preamble;
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
(
|
|
5707
|
-
)
|
|
5708
|
-
request.completedPreambleSegments = collectedPreambleSegments;
|
|
6520
|
+
!1 === hasPendingPreambles || (preamble.headChunks && preamble.bodyChunks)
|
|
6521
|
+
? (request.completedPreambleSegments = collectedPreambleSegments)
|
|
6522
|
+
: (request.byteSize = originalRequestByteSize);
|
|
5709
6523
|
}
|
|
5710
6524
|
}
|
|
5711
6525
|
function flushSubtree(request, destination, segment, hoistableState) {
|
|
@@ -5741,38 +6555,39 @@ function flushSubtree(request, destination, segment, hoistableState) {
|
|
|
5741
6555
|
chunkIdx < chunks.length &&
|
|
5742
6556
|
(r = writeChunkAndReturn(destination, chunks[chunkIdx]));
|
|
5743
6557
|
return r;
|
|
6558
|
+
case 3:
|
|
6559
|
+
return !0;
|
|
5744
6560
|
default:
|
|
5745
6561
|
throw Error(
|
|
5746
6562
|
"Aborted, errored or already flushed boundaries should not be flushed again. This is a bug in React."
|
|
5747
6563
|
);
|
|
5748
6564
|
}
|
|
5749
6565
|
}
|
|
6566
|
+
var flushedByteSize = 0;
|
|
5750
6567
|
function flushSegment(request, destination, segment, hoistableState) {
|
|
5751
6568
|
var boundary = segment.boundary;
|
|
5752
6569
|
if (null === boundary)
|
|
5753
6570
|
return flushSubtree(request, destination, segment, hoistableState);
|
|
5754
6571
|
boundary.parentFlushed = !0;
|
|
5755
6572
|
if (4 === boundary.status) {
|
|
5756
|
-
var
|
|
6573
|
+
var row = boundary.row;
|
|
6574
|
+
null !== row &&
|
|
6575
|
+
0 === --row.pendingTasks &&
|
|
6576
|
+
finishSuspenseListRow(request, row);
|
|
6577
|
+
boundary = boundary.errorDigest;
|
|
5757
6578
|
writeChunkAndReturn(destination, startClientRenderedSuspenseBoundary);
|
|
5758
6579
|
writeChunk(destination, clientRenderedSuspenseBoundaryError1);
|
|
5759
|
-
|
|
6580
|
+
boundary &&
|
|
5760
6581
|
(writeChunk(destination, clientRenderedSuspenseBoundaryError1A),
|
|
5761
|
-
writeChunk(destination, escapeTextForBrowser(
|
|
6582
|
+
writeChunk(destination, escapeTextForBrowser(boundary)),
|
|
5762
6583
|
writeChunk(
|
|
5763
6584
|
destination,
|
|
5764
6585
|
clientRenderedSuspenseBoundaryErrorAttrInterstitial
|
|
5765
6586
|
));
|
|
5766
6587
|
writeChunkAndReturn(destination, clientRenderedSuspenseBoundaryError2);
|
|
5767
6588
|
flushSubtree(request, destination, segment, hoistableState);
|
|
5768
|
-
|
|
5769
|
-
|
|
5770
|
-
return writeChunkAndReturn(destination, endSuspenseBoundary);
|
|
5771
|
-
}
|
|
5772
|
-
if (1 !== boundary.status)
|
|
5773
|
-
return (
|
|
5774
|
-
0 === boundary.status &&
|
|
5775
|
-
(boundary.rootSegmentID = request.nextSegmentId++),
|
|
6589
|
+
} else if (1 !== boundary.status)
|
|
6590
|
+
0 === boundary.status && (boundary.rootSegmentID = request.nextSegmentId++),
|
|
5776
6591
|
0 < boundary.completedSegments.length &&
|
|
5777
6592
|
request.partialBoundaries.push(boundary),
|
|
5778
6593
|
writeStartPendingSuspenseBoundary(
|
|
@@ -5780,41 +6595,38 @@ function flushSegment(request, destination, segment, hoistableState) {
|
|
|
5780
6595
|
request.renderState,
|
|
5781
6596
|
boundary.rootSegmentID
|
|
5782
6597
|
),
|
|
5783
|
-
hoistableState &&
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
|
|
5787
|
-
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5792
|
-
);
|
|
5793
|
-
if (boundary.byteSize > request.progressiveChunkSize)
|
|
5794
|
-
return (
|
|
5795
|
-
(boundary.rootSegmentID = request.nextSegmentId++),
|
|
6598
|
+
hoistableState && hoistHoistables(hoistableState, boundary.fallbackState),
|
|
6599
|
+
flushSubtree(request, destination, segment, hoistableState);
|
|
6600
|
+
else if (
|
|
6601
|
+
!flushingPartialBoundaries &&
|
|
6602
|
+
isEligibleForOutlining(request, boundary) &&
|
|
6603
|
+
(flushedByteSize + boundary.byteSize > request.progressiveChunkSize ||
|
|
6604
|
+
hasSuspenseyContent(boundary.contentState))
|
|
6605
|
+
)
|
|
6606
|
+
(boundary.rootSegmentID = request.nextSegmentId++),
|
|
5796
6607
|
request.completedBoundaries.push(boundary),
|
|
5797
6608
|
writeStartPendingSuspenseBoundary(
|
|
5798
6609
|
destination,
|
|
5799
6610
|
request.renderState,
|
|
5800
6611
|
boundary.rootSegmentID
|
|
5801
6612
|
),
|
|
5802
|
-
flushSubtree(request, destination, segment, hoistableState)
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
|
|
5806
|
-
|
|
5807
|
-
segment
|
|
5808
|
-
|
|
5809
|
-
|
|
5810
|
-
|
|
5811
|
-
|
|
5812
|
-
|
|
5813
|
-
|
|
5814
|
-
|
|
5815
|
-
|
|
5816
|
-
|
|
5817
|
-
|
|
6613
|
+
flushSubtree(request, destination, segment, hoistableState);
|
|
6614
|
+
else {
|
|
6615
|
+
flushedByteSize += boundary.byteSize;
|
|
6616
|
+
hoistableState && hoistHoistables(hoistableState, boundary.contentState);
|
|
6617
|
+
segment = boundary.row;
|
|
6618
|
+
null !== segment &&
|
|
6619
|
+
isEligibleForOutlining(request, boundary) &&
|
|
6620
|
+
0 === --segment.pendingTasks &&
|
|
6621
|
+
finishSuspenseListRow(request, segment);
|
|
6622
|
+
writeChunkAndReturn(destination, startCompletedSuspenseBoundary);
|
|
6623
|
+
segment = boundary.completedSegments;
|
|
6624
|
+
if (1 !== segment.length)
|
|
6625
|
+
throw Error(
|
|
6626
|
+
"A previously unvisited boundary must have exactly one root segment. This is a bug in React."
|
|
6627
|
+
);
|
|
6628
|
+
flushSegment(request, destination, segment[0], hoistableState);
|
|
6629
|
+
}
|
|
5818
6630
|
return writeChunkAndReturn(destination, endSuspenseBoundary);
|
|
5819
6631
|
}
|
|
5820
6632
|
function flushSegmentContainer(request, destination, segment, hoistableState) {
|
|
@@ -5828,6 +6640,7 @@ function flushSegmentContainer(request, destination, segment, hoistableState) {
|
|
|
5828
6640
|
return writeEndSegment(destination, segment.parentFormatContext);
|
|
5829
6641
|
}
|
|
5830
6642
|
function flushCompletedBoundary(request, destination, boundary) {
|
|
6643
|
+
flushedByteSize = boundary.byteSize;
|
|
5831
6644
|
for (
|
|
5832
6645
|
var completedSegments = boundary.completedSegments, i = 0;
|
|
5833
6646
|
i < completedSegments.length;
|
|
@@ -5840,6 +6653,11 @@ function flushCompletedBoundary(request, destination, boundary) {
|
|
|
5840
6653
|
completedSegments[i]
|
|
5841
6654
|
);
|
|
5842
6655
|
completedSegments.length = 0;
|
|
6656
|
+
completedSegments = boundary.row;
|
|
6657
|
+
null !== completedSegments &&
|
|
6658
|
+
isEligibleForOutlining(request, boundary) &&
|
|
6659
|
+
0 === --completedSegments.pendingTasks &&
|
|
6660
|
+
finishSuspenseListRow(request, completedSegments);
|
|
5843
6661
|
writeHoistablesForBoundary(
|
|
5844
6662
|
destination,
|
|
5845
6663
|
boundary.contentState,
|
|
@@ -5852,18 +6670,22 @@ function flushCompletedBoundary(request, destination, boundary) {
|
|
|
5852
6670
|
var requiresStyleInsertion = request.stylesToHoist;
|
|
5853
6671
|
request.stylesToHoist = !1;
|
|
5854
6672
|
writeChunk(destination, request.startInlineScript);
|
|
6673
|
+
writeChunk(destination, endOfStartTag);
|
|
5855
6674
|
requiresStyleInsertion
|
|
5856
|
-
? 0 === (completedSegments.instructions &
|
|
5857
|
-
|
|
5858
|
-
writeChunk(destination,
|
|
5859
|
-
|
|
6675
|
+
? (0 === (completedSegments.instructions & 4) &&
|
|
6676
|
+
((completedSegments.instructions |= 4),
|
|
6677
|
+
writeChunk(destination, clientRenderScriptFunctionOnly)),
|
|
6678
|
+
0 === (completedSegments.instructions & 2) &&
|
|
6679
|
+
((completedSegments.instructions |= 2),
|
|
6680
|
+
writeChunk(destination, completeBoundaryScriptFunctionOnly)),
|
|
6681
|
+
0 === (completedSegments.instructions & 8)
|
|
5860
6682
|
? ((completedSegments.instructions |= 8),
|
|
5861
6683
|
writeChunk(destination, completeBoundaryWithStylesScript1FullPartial))
|
|
5862
|
-
: writeChunk(destination, completeBoundaryWithStylesScript1Partial)
|
|
5863
|
-
: 0 === (completedSegments.instructions & 2)
|
|
5864
|
-
|
|
5865
|
-
writeChunk(destination,
|
|
5866
|
-
|
|
6684
|
+
: writeChunk(destination, completeBoundaryWithStylesScript1Partial))
|
|
6685
|
+
: (0 === (completedSegments.instructions & 2) &&
|
|
6686
|
+
((completedSegments.instructions |= 2),
|
|
6687
|
+
writeChunk(destination, completeBoundaryScriptFunctionOnly)),
|
|
6688
|
+
writeChunk(destination, completeBoundaryScript1Partial));
|
|
5867
6689
|
completedSegments = i.toString(16);
|
|
5868
6690
|
writeChunk(destination, request.boundaryPrefix);
|
|
5869
6691
|
writeChunk(destination, completedSegments);
|
|
@@ -5899,6 +6721,7 @@ function flushPartiallyCompletedSegment(
|
|
|
5899
6721
|
boundary = request.resumableState;
|
|
5900
6722
|
request = request.renderState;
|
|
5901
6723
|
writeChunk(destination, request.startInlineScript);
|
|
6724
|
+
writeChunk(destination, endOfStartTag);
|
|
5902
6725
|
0 === (boundary.instructions & 1)
|
|
5903
6726
|
? ((boundary.instructions |= 1),
|
|
5904
6727
|
writeChunk(destination, completeSegmentScript1Full))
|
|
@@ -5912,6 +6735,7 @@ function flushPartiallyCompletedSegment(
|
|
|
5912
6735
|
destination = writeChunkAndReturn(destination, completeSegmentScriptEnd);
|
|
5913
6736
|
return destination;
|
|
5914
6737
|
}
|
|
6738
|
+
var flushingPartialBoundaries = !1;
|
|
5915
6739
|
function flushCompletedQueues(request, destination) {
|
|
5916
6740
|
currentView = new Uint8Array(2048);
|
|
5917
6741
|
writtenBytes = 0;
|
|
@@ -5924,7 +6748,9 @@ function flushCompletedQueues(request, destination) {
|
|
|
5924
6748
|
if (5 === completedRootSegment.status) return;
|
|
5925
6749
|
var completedPreambleSegments = request.completedPreambleSegments;
|
|
5926
6750
|
if (null === completedPreambleSegments) return;
|
|
5927
|
-
|
|
6751
|
+
flushedByteSize = request.byteSize;
|
|
6752
|
+
var resumableState = request.resumableState,
|
|
6753
|
+
renderState = request.renderState,
|
|
5928
6754
|
preamble = renderState.preamble,
|
|
5929
6755
|
htmlChunks = preamble.htmlChunks,
|
|
5930
6756
|
headChunks = preamble.headChunks,
|
|
@@ -5955,7 +6781,9 @@ function flushCompletedQueues(request, destination) {
|
|
|
5955
6781
|
renderState.fontPreloads.clear();
|
|
5956
6782
|
renderState.highImagePreloads.forEach(flushResource, destination);
|
|
5957
6783
|
renderState.highImagePreloads.clear();
|
|
6784
|
+
currentlyFlushingRenderState = renderState;
|
|
5958
6785
|
renderState.styles.forEach(flushStylesInPreamble, destination);
|
|
6786
|
+
currentlyFlushingRenderState = null;
|
|
5959
6787
|
var importMapChunks = renderState.importMapChunks;
|
|
5960
6788
|
for (i$jscomp$0 = 0; i$jscomp$0 < importMapChunks.length; i$jscomp$0++)
|
|
5961
6789
|
writeChunk(destination, importMapChunks[i$jscomp$0]);
|
|
@@ -5965,17 +6793,18 @@ function flushCompletedQueues(request, destination) {
|
|
|
5965
6793
|
renderState.scripts.clear();
|
|
5966
6794
|
renderState.bulkPreloads.forEach(flushResource, destination);
|
|
5967
6795
|
renderState.bulkPreloads.clear();
|
|
6796
|
+
htmlChunks || headChunks || (resumableState.instructions |= 32);
|
|
5968
6797
|
var hoistableChunks = renderState.hoistableChunks;
|
|
5969
6798
|
for (i$jscomp$0 = 0; i$jscomp$0 < hoistableChunks.length; i$jscomp$0++)
|
|
5970
6799
|
writeChunk(destination, hoistableChunks[i$jscomp$0]);
|
|
5971
6800
|
for (
|
|
5972
|
-
|
|
5973
|
-
|
|
5974
|
-
|
|
6801
|
+
resumableState = hoistableChunks.length = 0;
|
|
6802
|
+
resumableState < completedPreambleSegments.length;
|
|
6803
|
+
resumableState++
|
|
5975
6804
|
) {
|
|
5976
|
-
var segments = completedPreambleSegments[
|
|
5977
|
-
for (
|
|
5978
|
-
flushSegment(request, destination, segments[
|
|
6805
|
+
var segments = completedPreambleSegments[resumableState];
|
|
6806
|
+
for (renderState = 0; renderState < segments.length; renderState++)
|
|
6807
|
+
flushSegment(request, destination, segments[renderState], null);
|
|
5979
6808
|
}
|
|
5980
6809
|
var preamble$jscomp$0 = request.renderState.preamble,
|
|
5981
6810
|
headChunks$jscomp$0 = preamble$jscomp$0.headChunks;
|
|
@@ -5991,11 +6820,36 @@ function flushCompletedQueues(request, destination) {
|
|
|
5991
6820
|
writeChunk(destination, bodyChunks[completedPreambleSegments]);
|
|
5992
6821
|
flushSegment(request, destination, completedRootSegment, null);
|
|
5993
6822
|
request.completedRootSegment = null;
|
|
5994
|
-
|
|
6823
|
+
var renderState$jscomp$0 = request.renderState;
|
|
6824
|
+
if (
|
|
6825
|
+
0 !== request.allPendingTasks ||
|
|
6826
|
+
0 !== request.clientRenderedBoundaries.length ||
|
|
6827
|
+
0 !== request.completedBoundaries.length ||
|
|
6828
|
+
(null !== request.trackedPostpones &&
|
|
6829
|
+
(0 !== request.trackedPostpones.rootNodes.length ||
|
|
6830
|
+
null !== request.trackedPostpones.rootSlots))
|
|
6831
|
+
) {
|
|
6832
|
+
var resumableState$jscomp$0 = request.resumableState;
|
|
6833
|
+
if (0 === (resumableState$jscomp$0.instructions & 64)) {
|
|
6834
|
+
resumableState$jscomp$0.instructions |= 64;
|
|
6835
|
+
writeChunk(destination, renderState$jscomp$0.startInlineScript);
|
|
6836
|
+
if (0 === (resumableState$jscomp$0.instructions & 32)) {
|
|
6837
|
+
resumableState$jscomp$0.instructions |= 32;
|
|
6838
|
+
var shellId = "_" + resumableState$jscomp$0.idPrefix + "R_";
|
|
6839
|
+
writeChunk(destination, completedShellIdAttributeStart);
|
|
6840
|
+
writeChunk(destination, escapeTextForBrowser(shellId));
|
|
6841
|
+
writeChunk(destination, attributeEnd);
|
|
6842
|
+
}
|
|
6843
|
+
writeChunk(destination, endOfStartTag);
|
|
6844
|
+
writeChunk(destination, shellTimeRuntimeScript);
|
|
6845
|
+
writeChunkAndReturn(destination, endInlineScript);
|
|
6846
|
+
}
|
|
6847
|
+
}
|
|
6848
|
+
writeBootstrap(destination, renderState$jscomp$0);
|
|
5995
6849
|
}
|
|
5996
|
-
var renderState$jscomp$
|
|
6850
|
+
var renderState$jscomp$1 = request.renderState;
|
|
5997
6851
|
completedRootSegment = 0;
|
|
5998
|
-
var viewportChunks$jscomp$0 = renderState$jscomp$
|
|
6852
|
+
var viewportChunks$jscomp$0 = renderState$jscomp$1.viewportChunks;
|
|
5999
6853
|
for (
|
|
6000
6854
|
completedRootSegment = 0;
|
|
6001
6855
|
completedRootSegment < viewportChunks$jscomp$0.length;
|
|
@@ -6003,21 +6857,21 @@ function flushCompletedQueues(request, destination) {
|
|
|
6003
6857
|
)
|
|
6004
6858
|
writeChunk(destination, viewportChunks$jscomp$0[completedRootSegment]);
|
|
6005
6859
|
viewportChunks$jscomp$0.length = 0;
|
|
6006
|
-
renderState$jscomp$
|
|
6007
|
-
renderState$jscomp$
|
|
6008
|
-
renderState$jscomp$
|
|
6009
|
-
renderState$jscomp$
|
|
6010
|
-
renderState$jscomp$
|
|
6860
|
+
renderState$jscomp$1.preconnects.forEach(flushResource, destination);
|
|
6861
|
+
renderState$jscomp$1.preconnects.clear();
|
|
6862
|
+
renderState$jscomp$1.fontPreloads.forEach(flushResource, destination);
|
|
6863
|
+
renderState$jscomp$1.fontPreloads.clear();
|
|
6864
|
+
renderState$jscomp$1.highImagePreloads.forEach(
|
|
6011
6865
|
flushResource,
|
|
6012
6866
|
destination
|
|
6013
6867
|
);
|
|
6014
|
-
renderState$jscomp$
|
|
6015
|
-
renderState$jscomp$
|
|
6016
|
-
renderState$jscomp$
|
|
6017
|
-
renderState$jscomp$
|
|
6018
|
-
renderState$jscomp$
|
|
6019
|
-
renderState$jscomp$
|
|
6020
|
-
var hoistableChunks$jscomp$0 = renderState$jscomp$
|
|
6868
|
+
renderState$jscomp$1.highImagePreloads.clear();
|
|
6869
|
+
renderState$jscomp$1.styles.forEach(preloadLateStyles, destination);
|
|
6870
|
+
renderState$jscomp$1.scripts.forEach(flushResource, destination);
|
|
6871
|
+
renderState$jscomp$1.scripts.clear();
|
|
6872
|
+
renderState$jscomp$1.bulkPreloads.forEach(flushResource, destination);
|
|
6873
|
+
renderState$jscomp$1.bulkPreloads.clear();
|
|
6874
|
+
var hoistableChunks$jscomp$0 = renderState$jscomp$1.hoistableChunks;
|
|
6021
6875
|
for (
|
|
6022
6876
|
completedRootSegment = 0;
|
|
6023
6877
|
completedRootSegment < hoistableChunks$jscomp$0.length;
|
|
@@ -6028,33 +6882,34 @@ function flushCompletedQueues(request, destination) {
|
|
|
6028
6882
|
var clientRenderedBoundaries = request.clientRenderedBoundaries;
|
|
6029
6883
|
for (i = 0; i < clientRenderedBoundaries.length; i++) {
|
|
6030
6884
|
var boundary = clientRenderedBoundaries[i];
|
|
6031
|
-
renderState$jscomp$
|
|
6032
|
-
var resumableState = request.resumableState,
|
|
6033
|
-
renderState$jscomp$
|
|
6885
|
+
renderState$jscomp$1 = destination;
|
|
6886
|
+
var resumableState$jscomp$1 = request.resumableState,
|
|
6887
|
+
renderState$jscomp$2 = request.renderState,
|
|
6034
6888
|
id = boundary.rootSegmentID,
|
|
6035
6889
|
errorDigest = boundary.errorDigest;
|
|
6036
6890
|
writeChunk(
|
|
6037
|
-
renderState$jscomp$
|
|
6038
|
-
renderState$jscomp$
|
|
6891
|
+
renderState$jscomp$1,
|
|
6892
|
+
renderState$jscomp$2.startInlineScript
|
|
6039
6893
|
);
|
|
6040
|
-
|
|
6041
|
-
|
|
6042
|
-
|
|
6043
|
-
|
|
6044
|
-
|
|
6045
|
-
writeChunk(renderState$jscomp$
|
|
6046
|
-
writeChunk(renderState$jscomp$
|
|
6894
|
+
writeChunk(renderState$jscomp$1, endOfStartTag);
|
|
6895
|
+
0 === (resumableState$jscomp$1.instructions & 4)
|
|
6896
|
+
? ((resumableState$jscomp$1.instructions |= 4),
|
|
6897
|
+
writeChunk(renderState$jscomp$1, clientRenderScript1Full))
|
|
6898
|
+
: writeChunk(renderState$jscomp$1, clientRenderScript1Partial);
|
|
6899
|
+
writeChunk(renderState$jscomp$1, renderState$jscomp$2.boundaryPrefix);
|
|
6900
|
+
writeChunk(renderState$jscomp$1, id.toString(16));
|
|
6901
|
+
writeChunk(renderState$jscomp$1, clientRenderScript1A);
|
|
6047
6902
|
errorDigest &&
|
|
6048
6903
|
(writeChunk(
|
|
6049
|
-
renderState$jscomp$
|
|
6904
|
+
renderState$jscomp$1,
|
|
6050
6905
|
clientRenderErrorScriptArgInterstitial
|
|
6051
6906
|
),
|
|
6052
6907
|
writeChunk(
|
|
6053
|
-
renderState$jscomp$
|
|
6908
|
+
renderState$jscomp$1,
|
|
6054
6909
|
escapeJSStringsForInstructionScripts(errorDigest || "")
|
|
6055
6910
|
));
|
|
6056
6911
|
var JSCompiler_inline_result = writeChunkAndReturn(
|
|
6057
|
-
renderState$jscomp$
|
|
6912
|
+
renderState$jscomp$1,
|
|
6058
6913
|
clientRenderScriptEnd
|
|
6059
6914
|
);
|
|
6060
6915
|
if (!JSCompiler_inline_result) {
|
|
@@ -6079,14 +6934,15 @@ function flushCompletedQueues(request, destination) {
|
|
|
6079
6934
|
completeWriting(destination);
|
|
6080
6935
|
currentView = new Uint8Array(2048);
|
|
6081
6936
|
writtenBytes = 0;
|
|
6082
|
-
destinationHasCapacity$1 = !0;
|
|
6937
|
+
flushingPartialBoundaries = destinationHasCapacity$1 = !0;
|
|
6083
6938
|
var partialBoundaries = request.partialBoundaries;
|
|
6084
6939
|
for (i = 0; i < partialBoundaries.length; i++) {
|
|
6085
|
-
var boundary$
|
|
6940
|
+
var boundary$70 = partialBoundaries[i];
|
|
6086
6941
|
a: {
|
|
6087
6942
|
clientRenderedBoundaries = request;
|
|
6088
6943
|
boundary = destination;
|
|
6089
|
-
|
|
6944
|
+
flushedByteSize = boundary$70.byteSize;
|
|
6945
|
+
var completedSegments = boundary$70.completedSegments;
|
|
6090
6946
|
for (
|
|
6091
6947
|
JSCompiler_inline_result = 0;
|
|
6092
6948
|
JSCompiler_inline_result < completedSegments.length;
|
|
@@ -6096,7 +6952,7 @@ function flushCompletedQueues(request, destination) {
|
|
|
6096
6952
|
!flushPartiallyCompletedSegment(
|
|
6097
6953
|
clientRenderedBoundaries,
|
|
6098
6954
|
boundary,
|
|
6099
|
-
boundary$
|
|
6955
|
+
boundary$70,
|
|
6100
6956
|
completedSegments[JSCompiler_inline_result]
|
|
6101
6957
|
)
|
|
6102
6958
|
) {
|
|
@@ -6106,9 +6962,20 @@ function flushCompletedQueues(request, destination) {
|
|
|
6106
6962
|
break a;
|
|
6107
6963
|
}
|
|
6108
6964
|
completedSegments.splice(0, JSCompiler_inline_result);
|
|
6965
|
+
var row = boundary$70.row;
|
|
6966
|
+
null !== row &&
|
|
6967
|
+
row.together &&
|
|
6968
|
+
1 === boundary$70.pendingTasks &&
|
|
6969
|
+
(1 === row.pendingTasks
|
|
6970
|
+
? unblockSuspenseListRow(
|
|
6971
|
+
clientRenderedBoundaries,
|
|
6972
|
+
row,
|
|
6973
|
+
row.hoistables
|
|
6974
|
+
)
|
|
6975
|
+
: row.pendingTasks--);
|
|
6109
6976
|
JSCompiler_inline_result$jscomp$0 = writeHoistablesForBoundary(
|
|
6110
6977
|
boundary,
|
|
6111
|
-
boundary$
|
|
6978
|
+
boundary$70.contentState,
|
|
6112
6979
|
clientRenderedBoundaries.renderState
|
|
6113
6980
|
);
|
|
6114
6981
|
}
|
|
@@ -6120,6 +6987,7 @@ function flushCompletedQueues(request, destination) {
|
|
|
6120
6987
|
}
|
|
6121
6988
|
}
|
|
6122
6989
|
partialBoundaries.splice(0, i);
|
|
6990
|
+
flushingPartialBoundaries = !1;
|
|
6123
6991
|
var largeBoundaries = request.completedBoundaries;
|
|
6124
6992
|
for (i = 0; i < largeBoundaries.length; i++)
|
|
6125
6993
|
if (!flushCompletedBoundary(request, destination, largeBoundaries[i])) {
|
|
@@ -6131,20 +6999,20 @@ function flushCompletedQueues(request, destination) {
|
|
|
6131
6999
|
largeBoundaries.splice(0, i);
|
|
6132
7000
|
}
|
|
6133
7001
|
} finally {
|
|
6134
|
-
|
|
6135
|
-
|
|
6136
|
-
|
|
6137
|
-
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
|
|
6143
|
-
|
|
6144
|
-
|
|
6145
|
-
|
|
6146
|
-
|
|
6147
|
-
|
|
7002
|
+
(flushingPartialBoundaries = !1),
|
|
7003
|
+
0 === request.allPendingTasks &&
|
|
7004
|
+
0 === request.clientRenderedBoundaries.length &&
|
|
7005
|
+
0 === request.completedBoundaries.length
|
|
7006
|
+
? ((request.flushScheduled = !1),
|
|
7007
|
+
(i = request.resumableState),
|
|
7008
|
+
i.hasBody && writeChunk(destination, endChunkForTag("body")),
|
|
7009
|
+
i.hasHtml && writeChunk(destination, endChunkForTag("html")),
|
|
7010
|
+
completeWriting(destination),
|
|
7011
|
+
flushBuffered(destination),
|
|
7012
|
+
(request.status = 14),
|
|
7013
|
+
destination.end(),
|
|
7014
|
+
(request.destination = null))
|
|
7015
|
+
: (completeWriting(destination), flushBuffered(destination));
|
|
6148
7016
|
}
|
|
6149
7017
|
}
|
|
6150
7018
|
function startWork(request) {
|
|
@@ -6210,17 +7078,75 @@ function abort(request, reason) {
|
|
|
6210
7078
|
}
|
|
6211
7079
|
null !== request.destination &&
|
|
6212
7080
|
flushCompletedQueues(request, request.destination);
|
|
6213
|
-
} catch (error$
|
|
6214
|
-
logRecoverableError(request, error$
|
|
7081
|
+
} catch (error$72) {
|
|
7082
|
+
logRecoverableError(request, error$72, {}), fatalError(request, error$72);
|
|
6215
7083
|
}
|
|
6216
7084
|
}
|
|
7085
|
+
function addToReplayParent(node, parentKeyPath, trackedPostpones) {
|
|
7086
|
+
if (null === parentKeyPath) trackedPostpones.rootNodes.push(node);
|
|
7087
|
+
else {
|
|
7088
|
+
var workingMap = trackedPostpones.workingMap,
|
|
7089
|
+
parentNode = workingMap.get(parentKeyPath);
|
|
7090
|
+
void 0 === parentNode &&
|
|
7091
|
+
((parentNode = [parentKeyPath[1], parentKeyPath[2], [], null]),
|
|
7092
|
+
workingMap.set(parentKeyPath, parentNode),
|
|
7093
|
+
addToReplayParent(parentNode, parentKeyPath[0], trackedPostpones));
|
|
7094
|
+
parentNode[2].push(node);
|
|
7095
|
+
}
|
|
7096
|
+
}
|
|
7097
|
+
function getPostponedState(request) {
|
|
7098
|
+
var trackedPostpones = request.trackedPostpones;
|
|
7099
|
+
if (
|
|
7100
|
+
null === trackedPostpones ||
|
|
7101
|
+
(0 === trackedPostpones.rootNodes.length &&
|
|
7102
|
+
null === trackedPostpones.rootSlots)
|
|
7103
|
+
)
|
|
7104
|
+
return (request.trackedPostpones = null);
|
|
7105
|
+
if (
|
|
7106
|
+
null === request.completedRootSegment ||
|
|
7107
|
+
(5 !== request.completedRootSegment.status &&
|
|
7108
|
+
null !== request.completedPreambleSegments)
|
|
7109
|
+
) {
|
|
7110
|
+
var nextSegmentId = request.nextSegmentId;
|
|
7111
|
+
var replaySlots = trackedPostpones.rootSlots;
|
|
7112
|
+
var resumableState = request.resumableState;
|
|
7113
|
+
resumableState.bootstrapScriptContent = void 0;
|
|
7114
|
+
resumableState.bootstrapScripts = void 0;
|
|
7115
|
+
resumableState.bootstrapModules = void 0;
|
|
7116
|
+
} else {
|
|
7117
|
+
nextSegmentId = 0;
|
|
7118
|
+
replaySlots = -1;
|
|
7119
|
+
resumableState = request.resumableState;
|
|
7120
|
+
var renderState = request.renderState;
|
|
7121
|
+
resumableState.nextFormID = 0;
|
|
7122
|
+
resumableState.hasBody = !1;
|
|
7123
|
+
resumableState.hasHtml = !1;
|
|
7124
|
+
resumableState.unknownResources = { font: renderState.resets.font };
|
|
7125
|
+
resumableState.dnsResources = renderState.resets.dns;
|
|
7126
|
+
resumableState.connectResources = renderState.resets.connect;
|
|
7127
|
+
resumableState.imageResources = renderState.resets.image;
|
|
7128
|
+
resumableState.styleResources = renderState.resets.style;
|
|
7129
|
+
resumableState.scriptResources = {};
|
|
7130
|
+
resumableState.moduleUnknownResources = {};
|
|
7131
|
+
resumableState.moduleScriptResources = {};
|
|
7132
|
+
resumableState.instructions = 0;
|
|
7133
|
+
}
|
|
7134
|
+
return {
|
|
7135
|
+
nextSegmentId: nextSegmentId,
|
|
7136
|
+
rootFormatContext: request.rootFormatContext,
|
|
7137
|
+
progressiveChunkSize: request.progressiveChunkSize,
|
|
7138
|
+
resumableState: request.resumableState,
|
|
7139
|
+
replayNodes: trackedPostpones.rootNodes,
|
|
7140
|
+
replaySlots: replaySlots
|
|
7141
|
+
};
|
|
7142
|
+
}
|
|
6217
7143
|
function ensureCorrectIsomorphicReactVersion() {
|
|
6218
7144
|
var isomorphicReactPackageVersion = React.version;
|
|
6219
|
-
if ("19.
|
|
7145
|
+
if ("19.2.4" !== isomorphicReactPackageVersion)
|
|
6220
7146
|
throw Error(
|
|
6221
7147
|
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
|
|
6222
7148
|
(isomorphicReactPackageVersion +
|
|
6223
|
-
"\n - react-dom: 19.
|
|
7149
|
+
"\n - react-dom: 19.2.4\nLearn more: https://react.dev/warnings/version-mismatch")
|
|
6224
7150
|
);
|
|
6225
7151
|
}
|
|
6226
7152
|
ensureCorrectIsomorphicReactVersion();
|
|
@@ -6265,8 +7191,62 @@ function createRequestImpl(children, options) {
|
|
|
6265
7191
|
options ? options.formState : void 0
|
|
6266
7192
|
);
|
|
6267
7193
|
}
|
|
7194
|
+
function createFakeWritableFromReadableStreamController$1(controller) {
|
|
7195
|
+
return {
|
|
7196
|
+
write: function (chunk) {
|
|
7197
|
+
"string" === typeof chunk && (chunk = textEncoder.encode(chunk));
|
|
7198
|
+
controller.enqueue(chunk);
|
|
7199
|
+
return !0;
|
|
7200
|
+
},
|
|
7201
|
+
end: function () {
|
|
7202
|
+
controller.close();
|
|
7203
|
+
},
|
|
7204
|
+
destroy: function (error) {
|
|
7205
|
+
"function" === typeof controller.error
|
|
7206
|
+
? controller.error(error)
|
|
7207
|
+
: controller.close();
|
|
7208
|
+
}
|
|
7209
|
+
};
|
|
7210
|
+
}
|
|
7211
|
+
function resumeRequestImpl(children, postponedState, options) {
|
|
7212
|
+
return resumeRequest(
|
|
7213
|
+
children,
|
|
7214
|
+
postponedState,
|
|
7215
|
+
createRenderState(
|
|
7216
|
+
postponedState.resumableState,
|
|
7217
|
+
options ? options.nonce : void 0,
|
|
7218
|
+
void 0,
|
|
7219
|
+
void 0,
|
|
7220
|
+
void 0,
|
|
7221
|
+
void 0
|
|
7222
|
+
),
|
|
7223
|
+
options ? options.onError : void 0,
|
|
7224
|
+
options ? options.onAllReady : void 0,
|
|
7225
|
+
options ? options.onShellReady : void 0,
|
|
7226
|
+
options ? options.onShellError : void 0,
|
|
7227
|
+
void 0,
|
|
7228
|
+
options ? options.onPostpone : void 0
|
|
7229
|
+
);
|
|
7230
|
+
}
|
|
6268
7231
|
ensureCorrectIsomorphicReactVersion();
|
|
6269
|
-
function
|
|
7232
|
+
function createFakeWritableFromReadableStreamController(controller) {
|
|
7233
|
+
return {
|
|
7234
|
+
write: function (chunk) {
|
|
7235
|
+
"string" === typeof chunk && (chunk = textEncoder.encode(chunk));
|
|
7236
|
+
controller.enqueue(chunk);
|
|
7237
|
+
return !0;
|
|
7238
|
+
},
|
|
7239
|
+
end: function () {
|
|
7240
|
+
controller.close();
|
|
7241
|
+
},
|
|
7242
|
+
destroy: function (error) {
|
|
7243
|
+
"function" === typeof controller.error
|
|
7244
|
+
? controller.error(error)
|
|
7245
|
+
: controller.close();
|
|
7246
|
+
}
|
|
7247
|
+
};
|
|
7248
|
+
}
|
|
7249
|
+
function createFakeWritableFromReadable(readable) {
|
|
6270
7250
|
return {
|
|
6271
7251
|
write: function (chunk) {
|
|
6272
7252
|
return readable.push(chunk);
|
|
@@ -6279,6 +7259,76 @@ function createFakeWritable(readable) {
|
|
|
6279
7259
|
}
|
|
6280
7260
|
};
|
|
6281
7261
|
}
|
|
7262
|
+
exports.prerender = function (children, options) {
|
|
7263
|
+
return new Promise(function (resolve, reject) {
|
|
7264
|
+
var onHeaders = options ? options.onHeaders : void 0,
|
|
7265
|
+
onHeadersImpl;
|
|
7266
|
+
onHeaders &&
|
|
7267
|
+
(onHeadersImpl = function (headersDescriptor) {
|
|
7268
|
+
onHeaders(new Headers(headersDescriptor));
|
|
7269
|
+
});
|
|
7270
|
+
var resources = createResumableState(
|
|
7271
|
+
options ? options.identifierPrefix : void 0,
|
|
7272
|
+
options ? options.unstable_externalRuntimeSrc : void 0,
|
|
7273
|
+
options ? options.bootstrapScriptContent : void 0,
|
|
7274
|
+
options ? options.bootstrapScripts : void 0,
|
|
7275
|
+
options ? options.bootstrapModules : void 0
|
|
7276
|
+
),
|
|
7277
|
+
request = createPrerenderRequest(
|
|
7278
|
+
children,
|
|
7279
|
+
resources,
|
|
7280
|
+
createRenderState(
|
|
7281
|
+
resources,
|
|
7282
|
+
void 0,
|
|
7283
|
+
options ? options.unstable_externalRuntimeSrc : void 0,
|
|
7284
|
+
options ? options.importMap : void 0,
|
|
7285
|
+
onHeadersImpl,
|
|
7286
|
+
options ? options.maxHeadersLength : void 0
|
|
7287
|
+
),
|
|
7288
|
+
createRootFormatContext(options ? options.namespaceURI : void 0),
|
|
7289
|
+
options ? options.progressiveChunkSize : void 0,
|
|
7290
|
+
options ? options.onError : void 0,
|
|
7291
|
+
function () {
|
|
7292
|
+
var writable,
|
|
7293
|
+
stream = new ReadableStream(
|
|
7294
|
+
{
|
|
7295
|
+
type: "bytes",
|
|
7296
|
+
start: function (controller) {
|
|
7297
|
+
writable =
|
|
7298
|
+
createFakeWritableFromReadableStreamController(controller);
|
|
7299
|
+
},
|
|
7300
|
+
pull: function () {
|
|
7301
|
+
startFlowing(request, writable);
|
|
7302
|
+
},
|
|
7303
|
+
cancel: function (reason) {
|
|
7304
|
+
request.destination = null;
|
|
7305
|
+
abort(request, reason);
|
|
7306
|
+
}
|
|
7307
|
+
},
|
|
7308
|
+
{ highWaterMark: 0 }
|
|
7309
|
+
);
|
|
7310
|
+
stream = { postponed: getPostponedState(request), prelude: stream };
|
|
7311
|
+
resolve(stream);
|
|
7312
|
+
},
|
|
7313
|
+
void 0,
|
|
7314
|
+
void 0,
|
|
7315
|
+
reject,
|
|
7316
|
+
options ? options.onPostpone : void 0
|
|
7317
|
+
);
|
|
7318
|
+
if (options && options.signal) {
|
|
7319
|
+
var signal = options.signal;
|
|
7320
|
+
if (signal.aborted) abort(request, signal.reason);
|
|
7321
|
+
else {
|
|
7322
|
+
var listener = function () {
|
|
7323
|
+
abort(request, signal.reason);
|
|
7324
|
+
signal.removeEventListener("abort", listener);
|
|
7325
|
+
};
|
|
7326
|
+
signal.addEventListener("abort", listener);
|
|
7327
|
+
}
|
|
7328
|
+
}
|
|
7329
|
+
startWork(request);
|
|
7330
|
+
});
|
|
7331
|
+
};
|
|
6282
7332
|
exports.prerenderToNodeStream = function (children, options) {
|
|
6283
7333
|
return new Promise(function (resolve, reject) {
|
|
6284
7334
|
var resumableState = createResumableState(
|
|
@@ -6308,8 +7358,12 @@ exports.prerenderToNodeStream = function (children, options) {
|
|
|
6308
7358
|
startFlowing(request, writable);
|
|
6309
7359
|
}
|
|
6310
7360
|
}),
|
|
6311
|
-
writable =
|
|
6312
|
-
|
|
7361
|
+
writable = createFakeWritableFromReadable(readable);
|
|
7362
|
+
readable = {
|
|
7363
|
+
postponed: getPostponedState(request),
|
|
7364
|
+
prelude: readable
|
|
7365
|
+
};
|
|
7366
|
+
resolve(readable);
|
|
6313
7367
|
},
|
|
6314
7368
|
void 0,
|
|
6315
7369
|
void 0,
|
|
@@ -6369,4 +7423,285 @@ exports.renderToPipeableStream = function (children, options) {
|
|
|
6369
7423
|
}
|
|
6370
7424
|
};
|
|
6371
7425
|
};
|
|
6372
|
-
exports.
|
|
7426
|
+
exports.renderToReadableStream = function (children, options) {
|
|
7427
|
+
return new Promise(function (resolve, reject) {
|
|
7428
|
+
var onFatalError,
|
|
7429
|
+
onAllReady,
|
|
7430
|
+
allReady = new Promise(function (res, rej) {
|
|
7431
|
+
onAllReady = res;
|
|
7432
|
+
onFatalError = rej;
|
|
7433
|
+
}),
|
|
7434
|
+
onHeaders = options ? options.onHeaders : void 0,
|
|
7435
|
+
onHeadersImpl;
|
|
7436
|
+
onHeaders &&
|
|
7437
|
+
(onHeadersImpl = function (headersDescriptor) {
|
|
7438
|
+
onHeaders(new Headers(headersDescriptor));
|
|
7439
|
+
});
|
|
7440
|
+
var resumableState = createResumableState(
|
|
7441
|
+
options ? options.identifierPrefix : void 0,
|
|
7442
|
+
options ? options.unstable_externalRuntimeSrc : void 0,
|
|
7443
|
+
options ? options.bootstrapScriptContent : void 0,
|
|
7444
|
+
options ? options.bootstrapScripts : void 0,
|
|
7445
|
+
options ? options.bootstrapModules : void 0
|
|
7446
|
+
),
|
|
7447
|
+
request = createRequest(
|
|
7448
|
+
children,
|
|
7449
|
+
resumableState,
|
|
7450
|
+
createRenderState(
|
|
7451
|
+
resumableState,
|
|
7452
|
+
options ? options.nonce : void 0,
|
|
7453
|
+
options ? options.unstable_externalRuntimeSrc : void 0,
|
|
7454
|
+
options ? options.importMap : void 0,
|
|
7455
|
+
onHeadersImpl,
|
|
7456
|
+
options ? options.maxHeadersLength : void 0
|
|
7457
|
+
),
|
|
7458
|
+
createRootFormatContext(options ? options.namespaceURI : void 0),
|
|
7459
|
+
options ? options.progressiveChunkSize : void 0,
|
|
7460
|
+
options ? options.onError : void 0,
|
|
7461
|
+
onAllReady,
|
|
7462
|
+
function () {
|
|
7463
|
+
var writable,
|
|
7464
|
+
stream = new ReadableStream(
|
|
7465
|
+
{
|
|
7466
|
+
type: "bytes",
|
|
7467
|
+
start: function (controller) {
|
|
7468
|
+
writable =
|
|
7469
|
+
createFakeWritableFromReadableStreamController$1(
|
|
7470
|
+
controller
|
|
7471
|
+
);
|
|
7472
|
+
},
|
|
7473
|
+
pull: function () {
|
|
7474
|
+
startFlowing(request, writable);
|
|
7475
|
+
},
|
|
7476
|
+
cancel: function (reason) {
|
|
7477
|
+
request.destination = null;
|
|
7478
|
+
abort(request, reason);
|
|
7479
|
+
}
|
|
7480
|
+
},
|
|
7481
|
+
{ highWaterMark: 0 }
|
|
7482
|
+
);
|
|
7483
|
+
stream.allReady = allReady;
|
|
7484
|
+
resolve(stream);
|
|
7485
|
+
},
|
|
7486
|
+
function (error) {
|
|
7487
|
+
allReady.catch(function () {});
|
|
7488
|
+
reject(error);
|
|
7489
|
+
},
|
|
7490
|
+
onFatalError,
|
|
7491
|
+
options ? options.onPostpone : void 0,
|
|
7492
|
+
options ? options.formState : void 0
|
|
7493
|
+
);
|
|
7494
|
+
if (options && options.signal) {
|
|
7495
|
+
var signal = options.signal;
|
|
7496
|
+
if (signal.aborted) abort(request, signal.reason);
|
|
7497
|
+
else {
|
|
7498
|
+
var listener = function () {
|
|
7499
|
+
abort(request, signal.reason);
|
|
7500
|
+
signal.removeEventListener("abort", listener);
|
|
7501
|
+
};
|
|
7502
|
+
signal.addEventListener("abort", listener);
|
|
7503
|
+
}
|
|
7504
|
+
}
|
|
7505
|
+
startWork(request);
|
|
7506
|
+
});
|
|
7507
|
+
};
|
|
7508
|
+
exports.resume = function (children, postponedState, options) {
|
|
7509
|
+
return new Promise(function (resolve, reject) {
|
|
7510
|
+
var onFatalError,
|
|
7511
|
+
onAllReady,
|
|
7512
|
+
allReady = new Promise(function (res, rej) {
|
|
7513
|
+
onAllReady = res;
|
|
7514
|
+
onFatalError = rej;
|
|
7515
|
+
}),
|
|
7516
|
+
request = resumeRequest(
|
|
7517
|
+
children,
|
|
7518
|
+
postponedState,
|
|
7519
|
+
createRenderState(
|
|
7520
|
+
postponedState.resumableState,
|
|
7521
|
+
options ? options.nonce : void 0,
|
|
7522
|
+
void 0,
|
|
7523
|
+
void 0,
|
|
7524
|
+
void 0,
|
|
7525
|
+
void 0
|
|
7526
|
+
),
|
|
7527
|
+
options ? options.onError : void 0,
|
|
7528
|
+
onAllReady,
|
|
7529
|
+
function () {
|
|
7530
|
+
var writable,
|
|
7531
|
+
stream = new ReadableStream(
|
|
7532
|
+
{
|
|
7533
|
+
type: "bytes",
|
|
7534
|
+
start: function (controller) {
|
|
7535
|
+
writable =
|
|
7536
|
+
createFakeWritableFromReadableStreamController$1(
|
|
7537
|
+
controller
|
|
7538
|
+
);
|
|
7539
|
+
},
|
|
7540
|
+
pull: function () {
|
|
7541
|
+
startFlowing(request, writable);
|
|
7542
|
+
},
|
|
7543
|
+
cancel: function (reason) {
|
|
7544
|
+
request.destination = null;
|
|
7545
|
+
abort(request, reason);
|
|
7546
|
+
}
|
|
7547
|
+
},
|
|
7548
|
+
{ highWaterMark: 0 }
|
|
7549
|
+
);
|
|
7550
|
+
stream.allReady = allReady;
|
|
7551
|
+
resolve(stream);
|
|
7552
|
+
},
|
|
7553
|
+
function (error) {
|
|
7554
|
+
allReady.catch(function () {});
|
|
7555
|
+
reject(error);
|
|
7556
|
+
},
|
|
7557
|
+
onFatalError,
|
|
7558
|
+
options ? options.onPostpone : void 0
|
|
7559
|
+
);
|
|
7560
|
+
if (options && options.signal) {
|
|
7561
|
+
var signal = options.signal;
|
|
7562
|
+
if (signal.aborted) abort(request, signal.reason);
|
|
7563
|
+
else {
|
|
7564
|
+
var listener = function () {
|
|
7565
|
+
abort(request, signal.reason);
|
|
7566
|
+
signal.removeEventListener("abort", listener);
|
|
7567
|
+
};
|
|
7568
|
+
signal.addEventListener("abort", listener);
|
|
7569
|
+
}
|
|
7570
|
+
}
|
|
7571
|
+
startWork(request);
|
|
7572
|
+
});
|
|
7573
|
+
};
|
|
7574
|
+
exports.resumeAndPrerender = function (children, postponedState, options) {
|
|
7575
|
+
return new Promise(function (resolve, reject) {
|
|
7576
|
+
var request = resumeAndPrerenderRequest(
|
|
7577
|
+
children,
|
|
7578
|
+
postponedState,
|
|
7579
|
+
createRenderState(
|
|
7580
|
+
postponedState.resumableState,
|
|
7581
|
+
void 0,
|
|
7582
|
+
void 0,
|
|
7583
|
+
void 0,
|
|
7584
|
+
void 0,
|
|
7585
|
+
void 0
|
|
7586
|
+
),
|
|
7587
|
+
options ? options.onError : void 0,
|
|
7588
|
+
function () {
|
|
7589
|
+
var writable,
|
|
7590
|
+
stream = new ReadableStream(
|
|
7591
|
+
{
|
|
7592
|
+
type: "bytes",
|
|
7593
|
+
start: function (controller) {
|
|
7594
|
+
writable =
|
|
7595
|
+
createFakeWritableFromReadableStreamController(controller);
|
|
7596
|
+
},
|
|
7597
|
+
pull: function () {
|
|
7598
|
+
startFlowing(request, writable);
|
|
7599
|
+
},
|
|
7600
|
+
cancel: function (reason) {
|
|
7601
|
+
request.destination = null;
|
|
7602
|
+
abort(request, reason);
|
|
7603
|
+
}
|
|
7604
|
+
},
|
|
7605
|
+
{ highWaterMark: 0 }
|
|
7606
|
+
);
|
|
7607
|
+
stream = { postponed: getPostponedState(request), prelude: stream };
|
|
7608
|
+
resolve(stream);
|
|
7609
|
+
},
|
|
7610
|
+
void 0,
|
|
7611
|
+
void 0,
|
|
7612
|
+
reject,
|
|
7613
|
+
options ? options.onPostpone : void 0
|
|
7614
|
+
);
|
|
7615
|
+
if (options && options.signal) {
|
|
7616
|
+
var signal = options.signal;
|
|
7617
|
+
if (signal.aborted) abort(request, signal.reason);
|
|
7618
|
+
else {
|
|
7619
|
+
var listener = function () {
|
|
7620
|
+
abort(request, signal.reason);
|
|
7621
|
+
signal.removeEventListener("abort", listener);
|
|
7622
|
+
};
|
|
7623
|
+
signal.addEventListener("abort", listener);
|
|
7624
|
+
}
|
|
7625
|
+
}
|
|
7626
|
+
startWork(request);
|
|
7627
|
+
});
|
|
7628
|
+
};
|
|
7629
|
+
exports.resumeAndPrerenderToNodeStream = function (
|
|
7630
|
+
children,
|
|
7631
|
+
postponedState,
|
|
7632
|
+
options
|
|
7633
|
+
) {
|
|
7634
|
+
return new Promise(function (resolve, reject) {
|
|
7635
|
+
var request = resumeAndPrerenderRequest(
|
|
7636
|
+
children,
|
|
7637
|
+
postponedState,
|
|
7638
|
+
createRenderState(
|
|
7639
|
+
postponedState.resumableState,
|
|
7640
|
+
void 0,
|
|
7641
|
+
void 0,
|
|
7642
|
+
void 0,
|
|
7643
|
+
void 0,
|
|
7644
|
+
void 0
|
|
7645
|
+
),
|
|
7646
|
+
options ? options.onError : void 0,
|
|
7647
|
+
function () {
|
|
7648
|
+
var readable = new stream.Readable({
|
|
7649
|
+
read: function () {
|
|
7650
|
+
startFlowing(request, writable);
|
|
7651
|
+
}
|
|
7652
|
+
}),
|
|
7653
|
+
writable = createFakeWritableFromReadable(readable);
|
|
7654
|
+
readable = { postponed: getPostponedState(request), prelude: readable };
|
|
7655
|
+
resolve(readable);
|
|
7656
|
+
},
|
|
7657
|
+
void 0,
|
|
7658
|
+
void 0,
|
|
7659
|
+
reject,
|
|
7660
|
+
options ? options.onPostpone : void 0
|
|
7661
|
+
);
|
|
7662
|
+
if (options && options.signal) {
|
|
7663
|
+
var signal = options.signal;
|
|
7664
|
+
if (signal.aborted) abort(request, signal.reason);
|
|
7665
|
+
else {
|
|
7666
|
+
var listener = function () {
|
|
7667
|
+
abort(request, signal.reason);
|
|
7668
|
+
signal.removeEventListener("abort", listener);
|
|
7669
|
+
};
|
|
7670
|
+
signal.addEventListener("abort", listener);
|
|
7671
|
+
}
|
|
7672
|
+
}
|
|
7673
|
+
startWork(request);
|
|
7674
|
+
});
|
|
7675
|
+
};
|
|
7676
|
+
exports.resumeToPipeableStream = function (children, postponedState, options) {
|
|
7677
|
+
var request = resumeRequestImpl(children, postponedState, options),
|
|
7678
|
+
hasStartedFlowing = !1;
|
|
7679
|
+
startWork(request);
|
|
7680
|
+
return {
|
|
7681
|
+
pipe: function (destination) {
|
|
7682
|
+
if (hasStartedFlowing)
|
|
7683
|
+
throw Error(
|
|
7684
|
+
"React currently only supports piping to one writable stream."
|
|
7685
|
+
);
|
|
7686
|
+
hasStartedFlowing = !0;
|
|
7687
|
+
startFlowing(request, destination);
|
|
7688
|
+
destination.on("drain", createDrainHandler(destination, request));
|
|
7689
|
+
destination.on(
|
|
7690
|
+
"error",
|
|
7691
|
+
createCancelHandler(
|
|
7692
|
+
request,
|
|
7693
|
+
"The destination stream errored while writing data."
|
|
7694
|
+
)
|
|
7695
|
+
);
|
|
7696
|
+
destination.on(
|
|
7697
|
+
"close",
|
|
7698
|
+
createCancelHandler(request, "The destination stream closed early.")
|
|
7699
|
+
);
|
|
7700
|
+
return destination;
|
|
7701
|
+
},
|
|
7702
|
+
abort: function (reason) {
|
|
7703
|
+
abort(request, reason);
|
|
7704
|
+
}
|
|
7705
|
+
};
|
|
7706
|
+
};
|
|
7707
|
+
exports.version = "19.2.4";
|