@expo/cli 1.0.0-canary-20250404-3c3b5fd → 1.0.0-canary-20250701-6a945c5

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.
Files changed (182) hide show
  1. package/README.md +33 -24
  2. package/build/bin/cli +1 -1
  3. package/build/metro-require/require.js +6 -4
  4. package/build/src/api/user/actions.js +25 -11
  5. package/build/src/api/user/actions.js.map +1 -1
  6. package/build/src/customize/templates.js +15 -1
  7. package/build/src/customize/templates.js.map +1 -1
  8. package/build/src/export/exportApp.js +26 -14
  9. package/build/src/export/exportApp.js.map +1 -1
  10. package/build/src/export/exportAsync.js +6 -0
  11. package/build/src/export/exportAsync.js.map +1 -1
  12. package/build/src/export/exportHermes.js +2 -2
  13. package/build/src/export/exportHermes.js.map +1 -1
  14. package/build/src/export/persistMetroAssets.js.map +1 -1
  15. package/build/src/install/checkPackages.js +22 -4
  16. package/build/src/install/checkPackages.js.map +1 -1
  17. package/build/src/install/index.js +3 -1
  18. package/build/src/install/index.js.map +1 -1
  19. package/build/src/install/resolveOptions.js +7 -2
  20. package/build/src/install/resolveOptions.js.map +1 -1
  21. package/build/src/install/utils/checkPackagesCompatibility.js +1 -1
  22. package/build/src/install/utils/checkPackagesCompatibility.js.map +1 -1
  23. package/build/src/lint/ESlintPrerequisite.js +32 -48
  24. package/build/src/lint/ESlintPrerequisite.js.map +1 -1
  25. package/build/src/lint/index.js +45 -47
  26. package/build/src/lint/index.js.map +1 -1
  27. package/build/src/lint/lintAsync.js +150 -4
  28. package/build/src/lint/lintAsync.js.map +1 -1
  29. package/build/src/lint/resolveOptions.js +115 -0
  30. package/build/src/lint/resolveOptions.js.map +1 -0
  31. package/build/src/prebuild/renameTemplateAppName.js +4 -1
  32. package/build/src/prebuild/renameTemplateAppName.js.map +1 -1
  33. package/build/src/prebuild/resolveTemplate.js +4 -4
  34. package/build/src/prebuild/resolveTemplate.js.map +1 -1
  35. package/build/src/prebuild/updatePackageJson.js +19 -9
  36. package/build/src/prebuild/updatePackageJson.js.map +1 -1
  37. package/build/src/run/android/resolveOptions.js +13 -1
  38. package/build/src/run/android/resolveOptions.js.map +1 -1
  39. package/build/src/run/android/runAndroidAsync.js +39 -17
  40. package/build/src/run/android/runAndroidAsync.js.map +1 -1
  41. package/build/src/run/ios/XcodeBuild.js +3 -3
  42. package/build/src/run/ios/XcodeBuild.js.map +1 -1
  43. package/build/src/run/ios/options/resolveOptions.js +13 -1
  44. package/build/src/run/ios/options/resolveOptions.js.map +1 -1
  45. package/build/src/run/ios/runIosAsync.js +38 -7
  46. package/build/src/run/ios/runIosAsync.js.map +1 -1
  47. package/build/src/start/doctor/SecurityBinPrerequisite.js +1 -1
  48. package/build/src/start/doctor/SecurityBinPrerequisite.js.map +1 -1
  49. package/build/src/start/doctor/apple/XcodePrerequisite.js +1 -1
  50. package/build/src/start/doctor/apple/XcodePrerequisite.js.map +1 -1
  51. package/build/src/start/doctor/dependencies/ensureDependenciesAsync.js +1 -1
  52. package/build/src/start/doctor/dependencies/ensureDependenciesAsync.js.map +1 -1
  53. package/build/src/start/doctor/dependencies/resolvePackages.js +1 -1
  54. package/build/src/start/doctor/dependencies/resolvePackages.js.map +1 -1
  55. package/build/src/start/doctor/ngrok/ExternalModule.js +1 -1
  56. package/build/src/start/doctor/ngrok/ExternalModule.js.map +1 -1
  57. package/build/src/start/index.js +1 -1
  58. package/build/src/start/index.js.map +1 -1
  59. package/build/src/start/platforms/PlatformManager.js +1 -1
  60. package/build/src/start/platforms/PlatformManager.js.map +1 -1
  61. package/build/src/start/platforms/android/AndroidPlatformManager.js +1 -1
  62. package/build/src/start/platforms/android/AndroidPlatformManager.js.map +1 -1
  63. package/build/src/start/platforms/android/getDevices.js +1 -1
  64. package/build/src/start/platforms/android/getDevices.js.map +1 -1
  65. package/build/src/start/platforms/ios/AppleDeviceManager.js +1 -1
  66. package/build/src/start/platforms/ios/AppleDeviceManager.js.map +1 -1
  67. package/build/src/start/platforms/ios/xcrun.js +1 -1
  68. package/build/src/start/platforms/ios/xcrun.js.map +1 -1
  69. package/build/src/start/project/dotExpo.js +5 -0
  70. package/build/src/start/project/dotExpo.js.map +1 -1
  71. package/build/src/start/resolveOptions.js +3 -0
  72. package/build/src/start/resolveOptions.js.map +1 -1
  73. package/build/src/start/server/metro/MetroBundlerDevServer.js +38 -26
  74. package/build/src/start/server/metro/MetroBundlerDevServer.js.map +1 -1
  75. package/build/src/start/server/metro/MetroTerminalReporter.js +29 -2
  76. package/build/src/start/server/metro/MetroTerminalReporter.js.map +1 -1
  77. package/build/src/start/server/metro/createExpoFallbackResolver.js +6 -4
  78. package/build/src/start/server/metro/createExpoFallbackResolver.js.map +1 -1
  79. package/build/src/start/server/metro/createJResolver.js +2 -2
  80. package/build/src/start/server/metro/createJResolver.js.map +1 -1
  81. package/build/src/start/server/metro/createServerComponentsMiddleware.js +16 -5
  82. package/build/src/start/server/metro/createServerComponentsMiddleware.js.map +1 -1
  83. package/build/src/start/server/metro/debugging/createDebugMiddleware.js +19 -19
  84. package/build/src/start/server/metro/debugging/createDebugMiddleware.js.map +1 -1
  85. package/build/src/start/server/metro/externals.js +1 -1
  86. package/build/src/start/server/metro/externals.js.map +1 -1
  87. package/build/src/start/server/metro/instantiateMetro.js +13 -8
  88. package/build/src/start/server/metro/instantiateMetro.js.map +1 -1
  89. package/build/src/start/server/metro/log-box/LogBoxSymbolication.js +21 -2
  90. package/build/src/start/server/metro/log-box/LogBoxSymbolication.js.map +1 -1
  91. package/build/src/start/server/metro/log-box/formatProjectFilePath.js +15 -12
  92. package/build/src/start/server/metro/log-box/formatProjectFilePath.js.map +1 -1
  93. package/build/src/start/server/metro/metroErrorInterface.js +19 -8
  94. package/build/src/start/server/metro/metroErrorInterface.js.map +1 -1
  95. package/build/src/start/server/metro/runServer-fork.js +1 -1
  96. package/build/src/start/server/metro/runServer-fork.js.map +1 -1
  97. package/build/src/start/server/metro/withMetroMultiPlatform.js +7 -12
  98. package/build/src/start/server/metro/withMetroMultiPlatform.js.map +1 -1
  99. package/build/src/start/server/middleware/CorsMiddleware.js +1 -1
  100. package/build/src/start/server/middleware/CorsMiddleware.js.map +1 -1
  101. package/build/src/start/server/middleware/ManifestMiddleware.js +4 -8
  102. package/build/src/start/server/middleware/ManifestMiddleware.js.map +1 -1
  103. package/build/src/start/server/middleware/inspector/JsInspector.js +2 -25
  104. package/build/src/start/server/middleware/inspector/JsInspector.js.map +1 -1
  105. package/build/src/start/server/middleware/metroOptions.js +2 -26
  106. package/build/src/start/server/middleware/metroOptions.js.map +1 -1
  107. package/build/src/utils/build-cache-providers/helpers.js +61 -0
  108. package/build/src/utils/build-cache-providers/helpers.js.map +1 -0
  109. package/build/src/utils/build-cache-providers/index.js +283 -0
  110. package/build/src/utils/build-cache-providers/index.js.map +1 -0
  111. package/build/src/utils/codesigning.js +14 -2
  112. package/build/src/utils/codesigning.js.map +1 -1
  113. package/build/src/utils/exit.js +0 -1
  114. package/build/src/utils/exit.js.map +1 -1
  115. package/build/src/utils/ip.js +7 -104
  116. package/build/src/utils/ip.js.map +1 -1
  117. package/build/src/utils/modifyConfigAsync.js +1 -1
  118. package/build/src/utils/modifyConfigAsync.js.map +1 -1
  119. package/build/src/utils/resolveArgs.js +8 -0
  120. package/build/src/utils/resolveArgs.js.map +1 -1
  121. package/build/src/utils/scheme.js +1 -1
  122. package/build/src/utils/scheme.js.map +1 -1
  123. package/build/src/utils/telemetry/clients/FetchClient.js +2 -2
  124. package/build/src/utils/telemetry/clients/FetchClient.js.map +1 -1
  125. package/build/src/utils/telemetry/utils/context.js +1 -1
  126. package/build/src/utils/tsconfig/evaluateTsConfig.js +7 -2
  127. package/build/src/utils/tsconfig/evaluateTsConfig.js.map +1 -1
  128. package/build/src/utils/variadic.js +63 -6
  129. package/build/src/utils/variadic.js.map +1 -1
  130. package/package.json +20 -20
  131. package/static/canary/react-is/cjs/react-is.development.js +118 -185
  132. package/static/canary/react-is/cjs/react-is.production.js +2 -2
  133. package/static/canary/react-native/Libraries/Renderer/implementations/ReactFabric-dev.js +16582 -26565
  134. package/static/canary/react-native/Libraries/Renderer/implementations/ReactFabric-prod.js +3495 -3357
  135. package/static/canary/react-native/Libraries/Renderer/implementations/ReactFabric-profiling.js +3929 -3801
  136. package/static/canary/react-native/Libraries/Renderer/implementations/ReactNativeRenderer-dev.js +16869 -27032
  137. package/static/canary/react-native/Libraries/Renderer/implementations/ReactNativeRenderer-prod.js +3535 -3428
  138. package/static/canary/react-native/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.js +4198 -4095
  139. package/static/canary/scheduler/cjs/scheduler-unstable_mock.development.js +387 -684
  140. package/static/canary/scheduler/cjs/scheduler-unstable_mock.production.js +0 -9
  141. package/static/canary/scheduler/cjs/scheduler-unstable_post_task.development.js +137 -195
  142. package/static/canary/scheduler/cjs/scheduler-unstable_post_task.production.js +0 -5
  143. package/static/canary/scheduler/cjs/scheduler.development.js +339 -600
  144. package/static/canary/scheduler/cjs/scheduler.native.development.js +324 -512
  145. package/static/canary/scheduler/cjs/scheduler.native.production.js +6 -5
  146. package/static/canary/scheduler/cjs/scheduler.production.js +16 -17
  147. package/static/canary-full/react/cjs/react-compiler-runtime.development.js +13 -68
  148. package/static/canary-full/react/cjs/react-jsx-dev-runtime.development.js +317 -1251
  149. package/static/canary-full/react/cjs/react-jsx-dev-runtime.react-server.development.js +353 -1286
  150. package/static/canary-full/react/cjs/react-jsx-runtime.development.js +326 -1279
  151. package/static/canary-full/react/cjs/react-jsx-runtime.react-server.development.js +353 -1286
  152. package/static/canary-full/react/cjs/react.development.js +1204 -2771
  153. package/static/canary-full/react/cjs/react.production.js +25 -20
  154. package/static/canary-full/react/cjs/react.react-server.development.js +783 -2162
  155. package/static/canary-full/react/cjs/react.react-server.production.js +13 -63
  156. package/static/canary-full/react/package.json +1 -1
  157. package/static/canary-full/react-dom/cjs/react-dom-client.development.js +24847 -37099
  158. package/static/canary-full/react-dom/cjs/react-dom-client.production.js +8261 -7475
  159. package/static/canary-full/react-dom/cjs/react-dom-profiling.development.js +25252 -37571
  160. package/static/canary-full/react-dom/cjs/react-dom-profiling.profiling.js +9442 -8662
  161. package/static/canary-full/react-dom/cjs/react-dom-server-legacy.browser.development.js +8944 -11568
  162. package/static/canary-full/react-dom/cjs/react-dom-server-legacy.browser.production.js +1378 -944
  163. package/static/canary-full/react-dom/cjs/react-dom-server-legacy.node.development.js +8944 -11568
  164. package/static/canary-full/react-dom/cjs/react-dom-server-legacy.node.production.js +1386 -954
  165. package/static/canary-full/react-dom/cjs/react-dom-server.browser.development.js +9344 -11600
  166. package/static/canary-full/react-dom/cjs/react-dom-server.browser.production.js +1545 -954
  167. package/static/canary-full/react-dom/cjs/react-dom-server.bun.development.js +8286 -11064
  168. package/static/canary-full/react-dom/cjs/react-dom-server.bun.production.js +1437 -976
  169. package/static/canary-full/react-dom/cjs/react-dom-server.edge.development.js +9356 -11609
  170. package/static/canary-full/react-dom/cjs/react-dom-server.edge.production.js +1542 -970
  171. package/static/canary-full/react-dom/cjs/react-dom-server.node.development.js +9227 -11571
  172. package/static/canary-full/react-dom/cjs/react-dom-server.node.production.js +1787 -1183
  173. package/static/canary-full/react-dom/cjs/react-dom-test-utils.development.js +13 -59
  174. package/static/canary-full/react-dom/cjs/react-dom.development.js +402 -604
  175. package/static/canary-full/react-dom/cjs/react-dom.production.js +4 -3
  176. package/static/canary-full/react-dom/cjs/react-dom.react-server.development.js +322 -382
  177. package/static/canary-full/react-dom/cjs/react-dom.react-server.production.js +6 -7
  178. package/static/canary-full/react-dom/package.json +5 -5
  179. package/static/canary-full/react-dom/static.browser.js +1 -0
  180. package/static/canary-full/react-dom/static.edge.js +1 -0
  181. package/static/canary-full/react-dom/static.node.js +1 -0
  182. package/static/template/eslint.config.js +10 -0
@@ -49,9 +49,10 @@ var React = require("react"),
49
49
  REACT_MEMO_TYPE = Symbol.for("react.memo"),
50
50
  REACT_LAZY_TYPE = Symbol.for("react.lazy"),
51
51
  REACT_SCOPE_TYPE = Symbol.for("react.scope"),
52
- REACT_DEBUG_TRACING_MODE_TYPE = Symbol.for("react.debug_trace_mode"),
53
- REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen"),
52
+ REACT_ACTIVITY_TYPE = Symbol.for("react.activity"),
54
53
  REACT_LEGACY_HIDDEN_TYPE = Symbol.for("react.legacy_hidden"),
54
+ REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel"),
55
+ REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
55
56
  MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
56
57
  isArrayImpl = Array.isArray;
57
58
  function murmurhash3_32_gc(key, seed) {
@@ -313,6 +314,14 @@ function createResumableState(
313
314
  moduleScriptResources: {}
314
315
  };
315
316
  }
317
+ function createPreambleState() {
318
+ return {
319
+ htmlChunks: null,
320
+ headChunks: null,
321
+ bodyChunks: null,
322
+ contribution: 0
323
+ };
324
+ }
316
325
  function createFormatContext(insertionMode, selectedValue, tagScope) {
317
326
  return {
318
327
  insertionMode: insertionMode,
@@ -331,31 +340,32 @@ function getChildFormatContext(parentContext, type, props) {
331
340
  parentContext.tagScope
332
341
  );
333
342
  case "svg":
334
- return createFormatContext(3, null, parentContext.tagScope);
343
+ return createFormatContext(4, null, parentContext.tagScope);
335
344
  case "picture":
336
345
  return createFormatContext(2, null, parentContext.tagScope | 2);
337
346
  case "math":
338
- return createFormatContext(4, null, parentContext.tagScope);
347
+ return createFormatContext(5, null, parentContext.tagScope);
339
348
  case "foreignObject":
340
349
  return createFormatContext(2, null, parentContext.tagScope);
341
350
  case "table":
342
- return createFormatContext(5, null, parentContext.tagScope);
351
+ return createFormatContext(6, null, parentContext.tagScope);
343
352
  case "thead":
344
353
  case "tbody":
345
354
  case "tfoot":
346
- return createFormatContext(6, null, parentContext.tagScope);
355
+ return createFormatContext(7, null, parentContext.tagScope);
347
356
  case "colgroup":
348
- return createFormatContext(8, null, parentContext.tagScope);
357
+ return createFormatContext(9, null, parentContext.tagScope);
349
358
  case "tr":
350
- return createFormatContext(7, null, parentContext.tagScope);
359
+ return createFormatContext(8, null, parentContext.tagScope);
360
+ case "head":
361
+ if (2 > parentContext.insertionMode)
362
+ return createFormatContext(3, null, parentContext.tagScope);
363
+ break;
364
+ case "html":
365
+ if (0 === parentContext.insertionMode)
366
+ return createFormatContext(1, null, parentContext.tagScope);
351
367
  }
352
- return 5 <= parentContext.insertionMode
353
- ? createFormatContext(2, null, parentContext.tagScope)
354
- : 0 === parentContext.insertionMode
355
- ? "html" === type
356
- ? createFormatContext(1, null, parentContext.tagScope)
357
- : createFormatContext(2, null, parentContext.tagScope)
358
- : 1 === parentContext.insertionMode
368
+ return 6 <= parentContext.insertionMode || 2 > parentContext.insertionMode
359
369
  ? createFormatContext(2, null, parentContext.tagScope)
360
370
  : parentContext;
361
371
  }
@@ -419,20 +429,28 @@ var actionJavaScriptURL = escapeTextForBrowser(
419
429
  );
420
430
  function pushAdditionalFormField(value, key) {
421
431
  this.push('<input type="hidden"');
422
- if ("string" !== typeof value)
423
- throw Error(
424
- "File/Blob fields are not yet supported in progressive forms. It probably means you are closing over binary data or FormData in a Server Action."
425
- );
432
+ validateAdditionalFormField(value);
426
433
  pushStringAttribute(this, "name", key);
427
434
  pushStringAttribute(this, "value", value);
428
435
  this.push("/>");
429
436
  }
437
+ function validateAdditionalFormField(value) {
438
+ if ("string" !== typeof value)
439
+ throw Error(
440
+ "File/Blob fields are not yet supported in progressive forms. Will fallback to client hydration."
441
+ );
442
+ }
430
443
  function getCustomFormFields(resumableState, formAction) {
431
444
  if ("function" === typeof formAction.$$FORM_ACTION) {
432
445
  var id = resumableState.nextFormID++;
433
446
  resumableState = resumableState.idPrefix + id;
434
447
  try {
435
- return formAction.$$FORM_ACTION(resumableState);
448
+ var customFields = formAction.$$FORM_ACTION(resumableState);
449
+ if (customFields) {
450
+ var formData = customFields.data;
451
+ null != formData && formData.forEach(validateAdditionalFormField);
452
+ }
453
+ return customFields;
436
454
  } catch (x) {
437
455
  if ("object" === typeof x && null !== x && "function" === typeof x.then)
438
456
  throw x;
@@ -773,6 +791,29 @@ function pushScriptImpl(target, props) {
773
791
  target.push(endChunkForTag("script"));
774
792
  return null;
775
793
  }
794
+ function pushStartSingletonElement(target, props, tag) {
795
+ target.push(startChunkForTag(tag));
796
+ var innerHTML = (tag = null),
797
+ propKey;
798
+ for (propKey in props)
799
+ if (hasOwnProperty.call(props, propKey)) {
800
+ var propValue = props[propKey];
801
+ if (null != propValue)
802
+ switch (propKey) {
803
+ case "children":
804
+ tag = propValue;
805
+ break;
806
+ case "dangerouslySetInnerHTML":
807
+ innerHTML = propValue;
808
+ break;
809
+ default:
810
+ pushAttribute(target, propKey, propValue);
811
+ }
812
+ }
813
+ target.push(">");
814
+ pushInnerHTML(target, innerHTML, tag);
815
+ return tag;
816
+ }
776
817
  function pushStartGenericElement(target, props, tag) {
777
818
  target.push(startChunkForTag(tag));
778
819
  var innerHTML = (tag = null),
@@ -815,6 +856,7 @@ function pushStartInstance(
815
856
  props,
816
857
  resumableState,
817
858
  renderState,
859
+ preambleState,
818
860
  hoistableState,
819
861
  formatContext,
820
862
  textEmbedded,
@@ -1250,28 +1292,70 @@ function pushStartInstance(
1250
1292
  }
1251
1293
  target$jscomp$0.push(">");
1252
1294
  return null;
1295
+ case "object":
1296
+ target$jscomp$0.push(startChunkForTag("object"));
1297
+ var children$jscomp$5 = null,
1298
+ innerHTML$jscomp$4 = null,
1299
+ propKey$jscomp$7;
1300
+ for (propKey$jscomp$7 in props)
1301
+ if (hasOwnProperty.call(props, propKey$jscomp$7)) {
1302
+ var propValue$jscomp$7 = props[propKey$jscomp$7];
1303
+ if (null != propValue$jscomp$7)
1304
+ switch (propKey$jscomp$7) {
1305
+ case "children":
1306
+ children$jscomp$5 = propValue$jscomp$7;
1307
+ break;
1308
+ case "dangerouslySetInnerHTML":
1309
+ innerHTML$jscomp$4 = propValue$jscomp$7;
1310
+ break;
1311
+ case "data":
1312
+ var sanitizedValue = sanitizeURL("" + propValue$jscomp$7);
1313
+ if ("" === sanitizedValue) break;
1314
+ target$jscomp$0.push(
1315
+ " ",
1316
+ "data",
1317
+ '="',
1318
+ escapeTextForBrowser(sanitizedValue),
1319
+ '"'
1320
+ );
1321
+ break;
1322
+ default:
1323
+ pushAttribute(
1324
+ target$jscomp$0,
1325
+ propKey$jscomp$7,
1326
+ propValue$jscomp$7
1327
+ );
1328
+ }
1329
+ }
1330
+ target$jscomp$0.push(">");
1331
+ pushInnerHTML(target$jscomp$0, innerHTML$jscomp$4, children$jscomp$5);
1332
+ if ("string" === typeof children$jscomp$5) {
1333
+ target$jscomp$0.push(escapeTextForBrowser(children$jscomp$5));
1334
+ var JSCompiler_inline_result$jscomp$2 = null;
1335
+ } else JSCompiler_inline_result$jscomp$2 = children$jscomp$5;
1336
+ return JSCompiler_inline_result$jscomp$2;
1253
1337
  case "title":
1254
1338
  if (
1255
- 3 === formatContext.insertionMode ||
1339
+ 4 === formatContext.insertionMode ||
1256
1340
  formatContext.tagScope & 1 ||
1257
1341
  null != props.itemProp
1258
1342
  )
1259
- var JSCompiler_inline_result$jscomp$2 = pushTitleImpl(
1343
+ var JSCompiler_inline_result$jscomp$3 = pushTitleImpl(
1260
1344
  target$jscomp$0,
1261
1345
  props
1262
1346
  );
1263
1347
  else
1264
1348
  isFallback
1265
- ? (JSCompiler_inline_result$jscomp$2 = null)
1349
+ ? (JSCompiler_inline_result$jscomp$3 = null)
1266
1350
  : (pushTitleImpl(renderState.hoistableChunks, props),
1267
- (JSCompiler_inline_result$jscomp$2 = void 0));
1268
- return JSCompiler_inline_result$jscomp$2;
1351
+ (JSCompiler_inline_result$jscomp$3 = void 0));
1352
+ return JSCompiler_inline_result$jscomp$3;
1269
1353
  case "link":
1270
1354
  var rel = props.rel,
1271
1355
  href = props.href,
1272
1356
  precedence = props.precedence;
1273
1357
  if (
1274
- 3 === formatContext.insertionMode ||
1358
+ 4 === formatContext.insertionMode ||
1275
1359
  formatContext.tagScope & 1 ||
1276
1360
  null != props.itemProp ||
1277
1361
  "string" !== typeof rel ||
@@ -1279,7 +1363,7 @@ function pushStartInstance(
1279
1363
  "" === href
1280
1364
  ) {
1281
1365
  pushLinkImpl(target$jscomp$0, props);
1282
- var JSCompiler_inline_result$jscomp$3 = null;
1366
+ var JSCompiler_inline_result$jscomp$4 = null;
1283
1367
  } else if ("stylesheet" === props.rel)
1284
1368
  if (
1285
1369
  "string" !== typeof precedence ||
@@ -1287,7 +1371,7 @@ function pushStartInstance(
1287
1371
  props.onLoad ||
1288
1372
  props.onError
1289
1373
  )
1290
- JSCompiler_inline_result$jscomp$3 = pushLinkImpl(
1374
+ JSCompiler_inline_result$jscomp$4 = pushLinkImpl(
1291
1375
  target$jscomp$0,
1292
1376
  props
1293
1377
  );
@@ -1330,19 +1414,19 @@ function pushStartInstance(
1330
1414
  hoistableState.stylesheets.add(resource$9);
1331
1415
  }
1332
1416
  textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
1333
- JSCompiler_inline_result$jscomp$3 = null;
1417
+ JSCompiler_inline_result$jscomp$4 = null;
1334
1418
  }
1335
1419
  else
1336
1420
  props.onLoad || props.onError
1337
- ? (JSCompiler_inline_result$jscomp$3 = pushLinkImpl(
1421
+ ? (JSCompiler_inline_result$jscomp$4 = pushLinkImpl(
1338
1422
  target$jscomp$0,
1339
1423
  props
1340
1424
  ))
1341
1425
  : (textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e"),
1342
- (JSCompiler_inline_result$jscomp$3 = isFallback
1426
+ (JSCompiler_inline_result$jscomp$4 = isFallback
1343
1427
  ? null
1344
1428
  : pushLinkImpl(renderState.hoistableChunks, props)));
1345
- return JSCompiler_inline_result$jscomp$3;
1429
+ return JSCompiler_inline_result$jscomp$4;
1346
1430
  case "script":
1347
1431
  var asyncProp = props.async;
1348
1432
  if (
@@ -1353,11 +1437,11 @@ function pushStartInstance(
1353
1437
  "symbol" === typeof asyncProp ||
1354
1438
  props.onLoad ||
1355
1439
  props.onError ||
1356
- 3 === formatContext.insertionMode ||
1440
+ 4 === formatContext.insertionMode ||
1357
1441
  formatContext.tagScope & 1 ||
1358
1442
  null != props.itemProp
1359
1443
  )
1360
- var JSCompiler_inline_result$jscomp$4 = pushScriptImpl(
1444
+ var JSCompiler_inline_result$jscomp$5 = pushScriptImpl(
1361
1445
  target$jscomp$0,
1362
1446
  props
1363
1447
  );
@@ -1387,14 +1471,14 @@ function pushStartInstance(
1387
1471
  pushScriptImpl(resource$jscomp$0, scriptProps);
1388
1472
  }
1389
1473
  textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
1390
- JSCompiler_inline_result$jscomp$4 = null;
1474
+ JSCompiler_inline_result$jscomp$5 = null;
1391
1475
  }
1392
- return JSCompiler_inline_result$jscomp$4;
1476
+ return JSCompiler_inline_result$jscomp$5;
1393
1477
  case "style":
1394
1478
  var precedence$jscomp$0 = props.precedence,
1395
1479
  href$jscomp$0 = props.href;
1396
1480
  if (
1397
- 3 === formatContext.insertionMode ||
1481
+ 4 === formatContext.insertionMode ||
1398
1482
  formatContext.tagScope & 1 ||
1399
1483
  null != props.itemProp ||
1400
1484
  "string" !== typeof precedence$jscomp$0 ||
@@ -1402,42 +1486,42 @@ function pushStartInstance(
1402
1486
  "" === href$jscomp$0
1403
1487
  ) {
1404
1488
  target$jscomp$0.push(startChunkForTag("style"));
1405
- var children$jscomp$5 = null,
1406
- innerHTML$jscomp$4 = null,
1407
- propKey$jscomp$7;
1408
- for (propKey$jscomp$7 in props)
1409
- if (hasOwnProperty.call(props, propKey$jscomp$7)) {
1410
- var propValue$jscomp$7 = props[propKey$jscomp$7];
1411
- if (null != propValue$jscomp$7)
1412
- switch (propKey$jscomp$7) {
1489
+ var children$jscomp$6 = null,
1490
+ innerHTML$jscomp$5 = null,
1491
+ propKey$jscomp$8;
1492
+ for (propKey$jscomp$8 in props)
1493
+ if (hasOwnProperty.call(props, propKey$jscomp$8)) {
1494
+ var propValue$jscomp$8 = props[propKey$jscomp$8];
1495
+ if (null != propValue$jscomp$8)
1496
+ switch (propKey$jscomp$8) {
1413
1497
  case "children":
1414
- children$jscomp$5 = propValue$jscomp$7;
1498
+ children$jscomp$6 = propValue$jscomp$8;
1415
1499
  break;
1416
1500
  case "dangerouslySetInnerHTML":
1417
- innerHTML$jscomp$4 = propValue$jscomp$7;
1501
+ innerHTML$jscomp$5 = propValue$jscomp$8;
1418
1502
  break;
1419
1503
  default:
1420
1504
  pushAttribute(
1421
1505
  target$jscomp$0,
1422
- propKey$jscomp$7,
1423
- propValue$jscomp$7
1506
+ propKey$jscomp$8,
1507
+ propValue$jscomp$8
1424
1508
  );
1425
1509
  }
1426
1510
  }
1427
1511
  target$jscomp$0.push(">");
1428
- var child = Array.isArray(children$jscomp$5)
1429
- ? 2 > children$jscomp$5.length
1430
- ? children$jscomp$5[0]
1512
+ var child = Array.isArray(children$jscomp$6)
1513
+ ? 2 > children$jscomp$6.length
1514
+ ? children$jscomp$6[0]
1431
1515
  : null
1432
- : children$jscomp$5;
1516
+ : children$jscomp$6;
1433
1517
  "function" !== typeof child &&
1434
1518
  "symbol" !== typeof child &&
1435
1519
  null !== child &&
1436
1520
  void 0 !== child &&
1437
1521
  target$jscomp$0.push(("" + child).replace(styleRegex, styleReplacer));
1438
- pushInnerHTML(target$jscomp$0, innerHTML$jscomp$4, children$jscomp$5);
1522
+ pushInnerHTML(target$jscomp$0, innerHTML$jscomp$5, children$jscomp$6);
1439
1523
  target$jscomp$0.push(endChunkForTag("style"));
1440
- var JSCompiler_inline_result$jscomp$5 = null;
1524
+ var JSCompiler_inline_result$jscomp$6 = null;
1441
1525
  } else {
1442
1526
  var styleQueue$jscomp$0 = renderState.styles.get(precedence$jscomp$0);
1443
1527
  if (
@@ -1459,26 +1543,26 @@ function pushStartInstance(
1459
1543
  }),
1460
1544
  renderState.styles.set(precedence$jscomp$0, styleQueue$jscomp$0));
1461
1545
  var target = styleQueue$jscomp$0.rules,
1462
- children$jscomp$6 = null,
1463
- innerHTML$jscomp$5 = null,
1464
- propKey$jscomp$8;
1465
- for (propKey$jscomp$8 in props)
1466
- if (hasOwnProperty.call(props, propKey$jscomp$8)) {
1467
- var propValue$jscomp$8 = props[propKey$jscomp$8];
1468
- if (null != propValue$jscomp$8)
1469
- switch (propKey$jscomp$8) {
1546
+ children$jscomp$7 = null,
1547
+ innerHTML$jscomp$6 = null,
1548
+ propKey$jscomp$9;
1549
+ for (propKey$jscomp$9 in props)
1550
+ if (hasOwnProperty.call(props, propKey$jscomp$9)) {
1551
+ var propValue$jscomp$9 = props[propKey$jscomp$9];
1552
+ if (null != propValue$jscomp$9)
1553
+ switch (propKey$jscomp$9) {
1470
1554
  case "children":
1471
- children$jscomp$6 = propValue$jscomp$8;
1555
+ children$jscomp$7 = propValue$jscomp$9;
1472
1556
  break;
1473
1557
  case "dangerouslySetInnerHTML":
1474
- innerHTML$jscomp$5 = propValue$jscomp$8;
1558
+ innerHTML$jscomp$6 = propValue$jscomp$9;
1475
1559
  }
1476
1560
  }
1477
- var child$jscomp$0 = Array.isArray(children$jscomp$6)
1478
- ? 2 > children$jscomp$6.length
1479
- ? children$jscomp$6[0]
1561
+ var child$jscomp$0 = Array.isArray(children$jscomp$7)
1562
+ ? 2 > children$jscomp$7.length
1563
+ ? children$jscomp$7[0]
1480
1564
  : null
1481
- : children$jscomp$6;
1565
+ : children$jscomp$7;
1482
1566
  "function" !== typeof child$jscomp$0 &&
1483
1567
  "symbol" !== typeof child$jscomp$0 &&
1484
1568
  null !== child$jscomp$0 &&
@@ -1486,85 +1570,85 @@ function pushStartInstance(
1486
1570
  target.push(
1487
1571
  ("" + child$jscomp$0).replace(styleRegex, styleReplacer)
1488
1572
  );
1489
- pushInnerHTML(target, innerHTML$jscomp$5, children$jscomp$6);
1573
+ pushInnerHTML(target, innerHTML$jscomp$6, children$jscomp$7);
1490
1574
  }
1491
1575
  styleQueue$jscomp$0 &&
1492
1576
  hoistableState &&
1493
1577
  hoistableState.styles.add(styleQueue$jscomp$0);
1494
1578
  textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
1495
- JSCompiler_inline_result$jscomp$5 = void 0;
1579
+ JSCompiler_inline_result$jscomp$6 = void 0;
1496
1580
  }
1497
- return JSCompiler_inline_result$jscomp$5;
1581
+ return JSCompiler_inline_result$jscomp$6;
1498
1582
  case "meta":
1499
1583
  if (
1500
- 3 === formatContext.insertionMode ||
1584
+ 4 === formatContext.insertionMode ||
1501
1585
  formatContext.tagScope & 1 ||
1502
1586
  null != props.itemProp
1503
1587
  )
1504
- var JSCompiler_inline_result$jscomp$6 = pushSelfClosing(
1588
+ var JSCompiler_inline_result$jscomp$7 = pushSelfClosing(
1505
1589
  target$jscomp$0,
1506
1590
  props,
1507
1591
  "meta"
1508
1592
  );
1509
1593
  else
1510
1594
  textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e"),
1511
- (JSCompiler_inline_result$jscomp$6 = isFallback
1595
+ (JSCompiler_inline_result$jscomp$7 = isFallback
1512
1596
  ? null
1513
1597
  : "string" === typeof props.charSet
1514
- ? pushSelfClosing(renderState.charsetChunks, props, "meta")
1515
- : "viewport" === props.name
1516
- ? pushSelfClosing(renderState.viewportChunks, props, "meta")
1517
- : pushSelfClosing(renderState.hoistableChunks, props, "meta"));
1518
- return JSCompiler_inline_result$jscomp$6;
1598
+ ? pushSelfClosing(renderState.charsetChunks, props, "meta")
1599
+ : "viewport" === props.name
1600
+ ? pushSelfClosing(renderState.viewportChunks, props, "meta")
1601
+ : pushSelfClosing(renderState.hoistableChunks, props, "meta"));
1602
+ return JSCompiler_inline_result$jscomp$7;
1519
1603
  case "listing":
1520
1604
  case "pre":
1521
1605
  target$jscomp$0.push(startChunkForTag(type));
1522
- var children$jscomp$7 = null,
1523
- innerHTML$jscomp$6 = null,
1524
- propKey$jscomp$9;
1525
- for (propKey$jscomp$9 in props)
1526
- if (hasOwnProperty.call(props, propKey$jscomp$9)) {
1527
- var propValue$jscomp$9 = props[propKey$jscomp$9];
1528
- if (null != propValue$jscomp$9)
1529
- switch (propKey$jscomp$9) {
1606
+ var children$jscomp$8 = null,
1607
+ innerHTML$jscomp$7 = null,
1608
+ propKey$jscomp$10;
1609
+ for (propKey$jscomp$10 in props)
1610
+ if (hasOwnProperty.call(props, propKey$jscomp$10)) {
1611
+ var propValue$jscomp$10 = props[propKey$jscomp$10];
1612
+ if (null != propValue$jscomp$10)
1613
+ switch (propKey$jscomp$10) {
1530
1614
  case "children":
1531
- children$jscomp$7 = propValue$jscomp$9;
1615
+ children$jscomp$8 = propValue$jscomp$10;
1532
1616
  break;
1533
1617
  case "dangerouslySetInnerHTML":
1534
- innerHTML$jscomp$6 = propValue$jscomp$9;
1618
+ innerHTML$jscomp$7 = propValue$jscomp$10;
1535
1619
  break;
1536
1620
  default:
1537
1621
  pushAttribute(
1538
1622
  target$jscomp$0,
1539
- propKey$jscomp$9,
1540
- propValue$jscomp$9
1623
+ propKey$jscomp$10,
1624
+ propValue$jscomp$10
1541
1625
  );
1542
1626
  }
1543
1627
  }
1544
1628
  target$jscomp$0.push(">");
1545
- if (null != innerHTML$jscomp$6) {
1546
- if (null != children$jscomp$7)
1629
+ if (null != innerHTML$jscomp$7) {
1630
+ if (null != children$jscomp$8)
1547
1631
  throw Error(
1548
1632
  "Can only set one of `children` or `props.dangerouslySetInnerHTML`."
1549
1633
  );
1550
1634
  if (
1551
- "object" !== typeof innerHTML$jscomp$6 ||
1552
- !("__html" in innerHTML$jscomp$6)
1635
+ "object" !== typeof innerHTML$jscomp$7 ||
1636
+ !("__html" in innerHTML$jscomp$7)
1553
1637
  )
1554
1638
  throw Error(
1555
1639
  "`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information."
1556
1640
  );
1557
- var html = innerHTML$jscomp$6.__html;
1641
+ var html = innerHTML$jscomp$7.__html;
1558
1642
  null !== html &&
1559
1643
  void 0 !== html &&
1560
1644
  ("string" === typeof html && 0 < html.length && "\n" === html[0]
1561
1645
  ? target$jscomp$0.push("\n", html)
1562
1646
  : target$jscomp$0.push("" + html));
1563
1647
  }
1564
- "string" === typeof children$jscomp$7 &&
1565
- "\n" === children$jscomp$7[0] &&
1648
+ "string" === typeof children$jscomp$8 &&
1649
+ "\n" === children$jscomp$8[0] &&
1566
1650
  target$jscomp$0.push("\n");
1567
- return children$jscomp$7;
1651
+ return children$jscomp$8;
1568
1652
  case "img":
1569
1653
  var src = props.src,
1570
1654
  srcSet = props.srcSet;
@@ -1606,7 +1690,7 @@ function pushStartInstance(
1606
1690
  ) {
1607
1691
  resumableState.imageResources[key$jscomp$0] = PRELOAD_NO_CREDS;
1608
1692
  var input = props.crossOrigin;
1609
- var JSCompiler_inline_result$jscomp$7 =
1693
+ var JSCompiler_inline_result$jscomp$8 =
1610
1694
  "string" === typeof input
1611
1695
  ? "use-credentials" === input
1612
1696
  ? input
@@ -1616,19 +1700,20 @@ function pushStartInstance(
1616
1700
  header;
1617
1701
  headers &&
1618
1702
  0 < headers.remainingCapacity &&
1703
+ "string" !== typeof props.srcSet &&
1619
1704
  ("high" === props.fetchPriority ||
1620
1705
  500 > headers.highImagePreloads.length) &&
1621
1706
  ((header = getPreloadAsHeader(src, "image", {
1622
1707
  imageSrcSet: props.srcSet,
1623
1708
  imageSizes: props.sizes,
1624
- crossOrigin: JSCompiler_inline_result$jscomp$7,
1709
+ crossOrigin: JSCompiler_inline_result$jscomp$8,
1625
1710
  integrity: props.integrity,
1626
1711
  nonce: props.nonce,
1627
1712
  type: props.type,
1628
1713
  fetchPriority: props.fetchPriority,
1629
1714
  referrerPolicy: props.refererPolicy
1630
1715
  })),
1631
- 2 <= (headers.remainingCapacity -= header.length))
1716
+ 0 <= (headers.remainingCapacity -= header.length + 2))
1632
1717
  ? ((renderState.resets.image[key$jscomp$0] = PRELOAD_NO_CREDS),
1633
1718
  headers.highImagePreloads && (headers.highImagePreloads += ", "),
1634
1719
  (headers.highImagePreloads += header))
@@ -1639,7 +1724,7 @@ function pushStartInstance(
1639
1724
  href: srcSet ? void 0 : src,
1640
1725
  imageSrcSet: srcSet,
1641
1726
  imageSizes: sizes,
1642
- crossOrigin: JSCompiler_inline_result$jscomp$7,
1727
+ crossOrigin: JSCompiler_inline_result$jscomp$8,
1643
1728
  integrity: props.integrity,
1644
1729
  type: props.type,
1645
1730
  fetchPriority: props.fetchPriority,
@@ -1675,58 +1760,79 @@ function pushStartInstance(
1675
1760
  case "missing-glyph":
1676
1761
  break;
1677
1762
  case "head":
1678
- if (2 > formatContext.insertionMode && null === renderState.headChunks) {
1679
- renderState.headChunks = [];
1680
- var JSCompiler_inline_result$jscomp$8 = pushStartGenericElement(
1681
- renderState.headChunks,
1763
+ if (2 > formatContext.insertionMode) {
1764
+ var preamble = preambleState || renderState.preamble;
1765
+ if (preamble.headChunks)
1766
+ throw Error("The `<head>` tag may only be rendered once.");
1767
+ preamble.headChunks = [];
1768
+ var JSCompiler_inline_result$jscomp$9 = pushStartSingletonElement(
1769
+ preamble.headChunks,
1682
1770
  props,
1683
1771
  "head"
1684
1772
  );
1685
1773
  } else
1686
- JSCompiler_inline_result$jscomp$8 = pushStartGenericElement(
1774
+ JSCompiler_inline_result$jscomp$9 = pushStartGenericElement(
1687
1775
  target$jscomp$0,
1688
1776
  props,
1689
1777
  "head"
1690
1778
  );
1691
- return JSCompiler_inline_result$jscomp$8;
1779
+ return JSCompiler_inline_result$jscomp$9;
1780
+ case "body":
1781
+ if (2 > formatContext.insertionMode) {
1782
+ var preamble$jscomp$0 = preambleState || renderState.preamble;
1783
+ if (preamble$jscomp$0.bodyChunks)
1784
+ throw Error("The `<body>` tag may only be rendered once.");
1785
+ preamble$jscomp$0.bodyChunks = [];
1786
+ var JSCompiler_inline_result$jscomp$10 = pushStartSingletonElement(
1787
+ preamble$jscomp$0.bodyChunks,
1788
+ props,
1789
+ "body"
1790
+ );
1791
+ } else
1792
+ JSCompiler_inline_result$jscomp$10 = pushStartGenericElement(
1793
+ target$jscomp$0,
1794
+ props,
1795
+ "body"
1796
+ );
1797
+ return JSCompiler_inline_result$jscomp$10;
1692
1798
  case "html":
1693
- if (
1694
- 0 === formatContext.insertionMode &&
1695
- null === renderState.htmlChunks
1696
- ) {
1697
- renderState.htmlChunks = [""];
1698
- var JSCompiler_inline_result$jscomp$9 = pushStartGenericElement(
1699
- renderState.htmlChunks,
1799
+ if (0 === formatContext.insertionMode) {
1800
+ var preamble$jscomp$1 = preambleState || renderState.preamble;
1801
+ if (preamble$jscomp$1.htmlChunks)
1802
+ throw Error("The `<html>` tag may only be rendered once.");
1803
+ preamble$jscomp$1.htmlChunks = [""];
1804
+ var JSCompiler_inline_result$jscomp$11 = pushStartSingletonElement(
1805
+ preamble$jscomp$1.htmlChunks,
1700
1806
  props,
1701
1807
  "html"
1702
1808
  );
1703
1809
  } else
1704
- JSCompiler_inline_result$jscomp$9 = pushStartGenericElement(
1810
+ JSCompiler_inline_result$jscomp$11 = pushStartGenericElement(
1705
1811
  target$jscomp$0,
1706
1812
  props,
1707
1813
  "html"
1708
1814
  );
1709
- return JSCompiler_inline_result$jscomp$9;
1815
+ return JSCompiler_inline_result$jscomp$11;
1710
1816
  default:
1711
1817
  if (-1 !== type.indexOf("-")) {
1712
1818
  target$jscomp$0.push(startChunkForTag(type));
1713
- var children$jscomp$8 = null,
1714
- innerHTML$jscomp$7 = null,
1715
- propKey$jscomp$10;
1716
- for (propKey$jscomp$10 in props)
1717
- if (hasOwnProperty.call(props, propKey$jscomp$10)) {
1718
- var propValue$jscomp$10 = props[propKey$jscomp$10];
1719
- if (null != propValue$jscomp$10) {
1720
- var attributeName = propKey$jscomp$10;
1721
- switch (propKey$jscomp$10) {
1819
+ var children$jscomp$9 = null,
1820
+ innerHTML$jscomp$8 = null,
1821
+ propKey$jscomp$11;
1822
+ for (propKey$jscomp$11 in props)
1823
+ if (hasOwnProperty.call(props, propKey$jscomp$11)) {
1824
+ var propValue$jscomp$11 = props[propKey$jscomp$11];
1825
+ if (null != propValue$jscomp$11) {
1826
+ var attributeName = propKey$jscomp$11;
1827
+ switch (propKey$jscomp$11) {
1722
1828
  case "children":
1723
- children$jscomp$8 = propValue$jscomp$10;
1829
+ children$jscomp$9 = propValue$jscomp$11;
1724
1830
  break;
1725
1831
  case "dangerouslySetInnerHTML":
1726
- innerHTML$jscomp$7 = propValue$jscomp$10;
1832
+ innerHTML$jscomp$8 = propValue$jscomp$11;
1727
1833
  break;
1728
1834
  case "style":
1729
- pushStyleAttribute(target$jscomp$0, propValue$jscomp$10);
1835
+ pushStyleAttribute(target$jscomp$0, propValue$jscomp$11);
1730
1836
  break;
1731
1837
  case "suppressContentEditableWarning":
1732
1838
  case "suppressHydrationWarning":
@@ -1736,18 +1842,18 @@ function pushStartInstance(
1736
1842
  attributeName = "class";
1737
1843
  default:
1738
1844
  if (
1739
- isAttributeNameSafe(propKey$jscomp$10) &&
1740
- "function" !== typeof propValue$jscomp$10 &&
1741
- "symbol" !== typeof propValue$jscomp$10 &&
1742
- !1 !== propValue$jscomp$10
1845
+ isAttributeNameSafe(propKey$jscomp$11) &&
1846
+ "function" !== typeof propValue$jscomp$11 &&
1847
+ "symbol" !== typeof propValue$jscomp$11 &&
1848
+ !1 !== propValue$jscomp$11
1743
1849
  ) {
1744
- if (!0 === propValue$jscomp$10) propValue$jscomp$10 = "";
1745
- else if ("object" === typeof propValue$jscomp$10) continue;
1850
+ if (!0 === propValue$jscomp$11) propValue$jscomp$11 = "";
1851
+ else if ("object" === typeof propValue$jscomp$11) continue;
1746
1852
  target$jscomp$0.push(
1747
1853
  " ",
1748
1854
  attributeName,
1749
1855
  '="',
1750
- escapeTextForBrowser(propValue$jscomp$10),
1856
+ escapeTextForBrowser(propValue$jscomp$11),
1751
1857
  '"'
1752
1858
  );
1753
1859
  }
@@ -1755,8 +1861,8 @@ function pushStartInstance(
1755
1861
  }
1756
1862
  }
1757
1863
  target$jscomp$0.push(">");
1758
- pushInnerHTML(target$jscomp$0, innerHTML$jscomp$7, children$jscomp$8);
1759
- return children$jscomp$8;
1864
+ pushInnerHTML(target$jscomp$0, innerHTML$jscomp$8, children$jscomp$9);
1865
+ return children$jscomp$9;
1760
1866
  }
1761
1867
  }
1762
1868
  return pushStartGenericElement(target$jscomp$0, props, type);
@@ -1767,6 +1873,21 @@ function endChunkForTag(tag) {
1767
1873
  void 0 === chunk && ((chunk = "</" + tag + ">"), endTagCache.set(tag, chunk));
1768
1874
  return chunk;
1769
1875
  }
1876
+ function hoistPreambleState(renderState, preambleState) {
1877
+ renderState = renderState.preamble;
1878
+ null === renderState.htmlChunks &&
1879
+ preambleState.htmlChunks &&
1880
+ ((renderState.htmlChunks = preambleState.htmlChunks),
1881
+ (preambleState.contribution |= 1));
1882
+ null === renderState.headChunks &&
1883
+ preambleState.headChunks &&
1884
+ ((renderState.headChunks = preambleState.headChunks),
1885
+ (preambleState.contribution |= 4));
1886
+ null === renderState.bodyChunks &&
1887
+ preambleState.bodyChunks &&
1888
+ ((renderState.bodyChunks = preambleState.bodyChunks),
1889
+ (preambleState.contribution |= 2));
1890
+ }
1770
1891
  function writeBootstrap(destination, renderState) {
1771
1892
  renderState = renderState.bootstrapChunks;
1772
1893
  for (var i = 0; i < renderState.length - 1; i++)
@@ -1786,10 +1907,18 @@ function writeStartPendingSuspenseBoundary(destination, renderState, id) {
1786
1907
  destination.push(renderState);
1787
1908
  return destination.push('"></template>');
1788
1909
  }
1910
+ function writePreambleContribution(destination, preambleState) {
1911
+ preambleState = preambleState.contribution;
1912
+ 0 !== preambleState &&
1913
+ (destination.push("\x3c!--"),
1914
+ destination.push("" + preambleState),
1915
+ destination.push("--\x3e"));
1916
+ }
1789
1917
  function writeStartSegment(destination, renderState, formatContext, id) {
1790
1918
  switch (formatContext.insertionMode) {
1791
1919
  case 0:
1792
1920
  case 1:
1921
+ case 3:
1793
1922
  case 2:
1794
1923
  return (
1795
1924
  destination.push('<div hidden id="'),
@@ -1798,7 +1927,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1798
1927
  destination.push(renderState),
1799
1928
  destination.push('">')
1800
1929
  );
1801
- case 3:
1930
+ case 4:
1802
1931
  return (
1803
1932
  destination.push('<svg aria-hidden="true" style="display:none" id="'),
1804
1933
  destination.push(renderState.segmentPrefix),
@@ -1806,7 +1935,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1806
1935
  destination.push(renderState),
1807
1936
  destination.push('">')
1808
1937
  );
1809
- case 4:
1938
+ case 5:
1810
1939
  return (
1811
1940
  destination.push('<math aria-hidden="true" style="display:none" id="'),
1812
1941
  destination.push(renderState.segmentPrefix),
@@ -1814,7 +1943,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1814
1943
  destination.push(renderState),
1815
1944
  destination.push('">')
1816
1945
  );
1817
- case 5:
1946
+ case 6:
1818
1947
  return (
1819
1948
  destination.push('<table hidden id="'),
1820
1949
  destination.push(renderState.segmentPrefix),
@@ -1822,7 +1951,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1822
1951
  destination.push(renderState),
1823
1952
  destination.push('">')
1824
1953
  );
1825
- case 6:
1954
+ case 7:
1826
1955
  return (
1827
1956
  destination.push('<table hidden><tbody id="'),
1828
1957
  destination.push(renderState.segmentPrefix),
@@ -1830,7 +1959,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1830
1959
  destination.push(renderState),
1831
1960
  destination.push('">')
1832
1961
  );
1833
- case 7:
1962
+ case 8:
1834
1963
  return (
1835
1964
  destination.push('<table hidden><tr id="'),
1836
1965
  destination.push(renderState.segmentPrefix),
@@ -1838,7 +1967,7 @@ function writeStartSegment(destination, renderState, formatContext, id) {
1838
1967
  destination.push(renderState),
1839
1968
  destination.push('">')
1840
1969
  );
1841
- case 8:
1970
+ case 9:
1842
1971
  return (
1843
1972
  destination.push('<table hidden><colgroup id="'),
1844
1973
  destination.push(renderState.segmentPrefix),
@@ -1854,19 +1983,20 @@ function writeEndSegment(destination, formatContext) {
1854
1983
  switch (formatContext.insertionMode) {
1855
1984
  case 0:
1856
1985
  case 1:
1986
+ case 3:
1857
1987
  case 2:
1858
1988
  return destination.push("</div>");
1859
- case 3:
1860
- return destination.push("</svg>");
1861
1989
  case 4:
1862
- return destination.push("</math>");
1990
+ return destination.push("</svg>");
1863
1991
  case 5:
1864
- return destination.push("</table>");
1992
+ return destination.push("</math>");
1865
1993
  case 6:
1866
- return destination.push("</tbody></table>");
1994
+ return destination.push("</table>");
1867
1995
  case 7:
1868
- return destination.push("</tr></table>");
1996
+ return destination.push("</tbody></table>");
1869
1997
  case 8:
1998
+ return destination.push("</tr></table>");
1999
+ case 9:
1870
2000
  return destination.push("</colgroup></table>");
1871
2001
  default:
1872
2002
  throw Error("Unknown insertion mode. This is a bug in React.");
@@ -2141,7 +2271,7 @@ function prefetchDNS(href) {
2141
2271
  escapeHrefForLinkHeaderURLContextReplacer
2142
2272
  ) +
2143
2273
  ">; rel=dns-prefetch"),
2144
- 2 <= (resumableState.remainingCapacity -= header.length));
2274
+ 0 <= (resumableState.remainingCapacity -= header.length + 2));
2145
2275
  JSCompiler_temp
2146
2276
  ? ((renderState.resets.dns[href] = null),
2147
2277
  resumableState.preconnects && (resumableState.preconnects += ", "),
@@ -2164,8 +2294,8 @@ function preconnect(href, crossOrigin) {
2164
2294
  "use-credentials" === crossOrigin
2165
2295
  ? "credentials"
2166
2296
  : "string" === typeof crossOrigin
2167
- ? "anonymous"
2168
- : "default";
2297
+ ? "anonymous"
2298
+ : "default";
2169
2299
  if (!resumableState.connectResources[bucket].hasOwnProperty(href)) {
2170
2300
  resumableState.connectResources[bucket][href] = null;
2171
2301
  resumableState = renderState.headers;
@@ -2190,7 +2320,7 @@ function preconnect(href, crossOrigin) {
2190
2320
  }
2191
2321
  JSCompiler_temp =
2192
2322
  ((header = JSCompiler_temp),
2193
- 2 <= (resumableState.remainingCapacity -= header.length));
2323
+ 0 <= (resumableState.remainingCapacity -= header.length + 2));
2194
2324
  }
2195
2325
  JSCompiler_temp
2196
2326
  ? ((renderState.resets.connect[bucket][href] = null),
@@ -2230,9 +2360,10 @@ function preload(href, as, options) {
2230
2360
  var header;
2231
2361
  resumableState &&
2232
2362
  0 < resumableState.remainingCapacity &&
2363
+ "string" !== typeof imageSrcSet &&
2233
2364
  "high" === fetchPriority &&
2234
2365
  ((header = getPreloadAsHeader(href, as, options)),
2235
- 2 <= (resumableState.remainingCapacity -= header.length))
2366
+ 0 <= (resumableState.remainingCapacity -= header.length + 2))
2236
2367
  ? ((renderState.resets.image[key] = PRELOAD_NO_CREDS),
2237
2368
  resumableState.highImagePreloads &&
2238
2369
  (resumableState.highImagePreloads += ", "),
@@ -2298,7 +2429,7 @@ function preload(href, as, options) {
2298
2429
  0 < resumableState.remainingCapacity &&
2299
2430
  "font" === as &&
2300
2431
  ((key = getPreloadAsHeader(href, as, options)),
2301
- 2 <= (resumableState.remainingCapacity -= key.length))
2432
+ 0 <= (resumableState.remainingCapacity -= key.length + 2))
2302
2433
  )
2303
2434
  (renderState.resets.font[href] = PRELOAD_NO_CREDS),
2304
2435
  resumableState.fontPreloads &&
@@ -2534,16 +2665,17 @@ function createRenderState(resumableState, generateStaticMarkup) {
2534
2665
  "\x3c/script>"
2535
2666
  );
2536
2667
  bootstrapScriptContent = idPrefix + "P:";
2537
- var JSCompiler_object_inline_segmentPrefix_1483 = idPrefix + "S:";
2668
+ var JSCompiler_object_inline_segmentPrefix_1542 = idPrefix + "S:";
2538
2669
  idPrefix += "B:";
2539
- var JSCompiler_object_inline_preconnects_1497 = new Set(),
2540
- JSCompiler_object_inline_fontPreloads_1498 = new Set(),
2541
- JSCompiler_object_inline_highImagePreloads_1499 = new Set(),
2542
- JSCompiler_object_inline_styles_1500 = new Map(),
2543
- JSCompiler_object_inline_bootstrapScripts_1501 = new Set(),
2544
- JSCompiler_object_inline_scripts_1502 = new Set(),
2545
- JSCompiler_object_inline_bulkPreloads_1503 = new Set(),
2546
- JSCompiler_object_inline_preloads_1504 = {
2670
+ var JSCompiler_object_inline_preamble_1545 = createPreambleState(),
2671
+ JSCompiler_object_inline_preconnects_1555 = new Set(),
2672
+ JSCompiler_object_inline_fontPreloads_1556 = new Set(),
2673
+ JSCompiler_object_inline_highImagePreloads_1557 = new Set(),
2674
+ JSCompiler_object_inline_styles_1558 = new Map(),
2675
+ JSCompiler_object_inline_bootstrapScripts_1559 = new Set(),
2676
+ JSCompiler_object_inline_scripts_1560 = new Set(),
2677
+ JSCompiler_object_inline_bulkPreloads_1561 = new Set(),
2678
+ JSCompiler_object_inline_preloads_1562 = {
2547
2679
  images: new Map(),
2548
2680
  stylesheets: new Map(),
2549
2681
  scripts: new Map(),
@@ -2572,15 +2704,15 @@ function createRenderState(resumableState, generateStaticMarkup) {
2572
2704
  "string" === typeof scriptConfig || null == scriptConfig.crossOrigin
2573
2705
  ? void 0
2574
2706
  : "use-credentials" === scriptConfig.crossOrigin
2575
- ? "use-credentials"
2576
- : ""));
2707
+ ? "use-credentials"
2708
+ : ""));
2577
2709
  scriptConfig = resumableState;
2578
2710
  var href = src;
2579
2711
  scriptConfig.scriptResources[href] = null;
2580
2712
  scriptConfig.moduleScriptResources[href] = null;
2581
2713
  scriptConfig = [];
2582
2714
  pushLinkImpl(scriptConfig, props);
2583
- JSCompiler_object_inline_bootstrapScripts_1501.add(scriptConfig);
2715
+ JSCompiler_object_inline_bootstrapScripts_1559.add(scriptConfig);
2584
2716
  bootstrapChunks.push('<script src="', escapeTextForBrowser(src));
2585
2717
  "string" === typeof integrity &&
2586
2718
  bootstrapChunks.push('" integrity="', escapeTextForBrowser(integrity));
@@ -2613,15 +2745,15 @@ function createRenderState(resumableState, generateStaticMarkup) {
2613
2745
  "string" === typeof props || null == props.crossOrigin
2614
2746
  ? void 0
2615
2747
  : "use-credentials" === props.crossOrigin
2616
- ? "use-credentials"
2617
- : "")),
2748
+ ? "use-credentials"
2749
+ : "")),
2618
2750
  (props = resumableState),
2619
2751
  (scriptConfig = i),
2620
2752
  (props.scriptResources[scriptConfig] = null),
2621
2753
  (props.moduleScriptResources[scriptConfig] = null),
2622
2754
  (props = []),
2623
2755
  pushLinkImpl(props, integrity),
2624
- JSCompiler_object_inline_bootstrapScripts_1501.add(props),
2756
+ JSCompiler_object_inline_bootstrapScripts_1559.add(props),
2625
2757
  bootstrapChunks.push(
2626
2758
  '<script type="module" src="',
2627
2759
  escapeTextForBrowser(i)
@@ -2636,11 +2768,10 @@ function createRenderState(resumableState, generateStaticMarkup) {
2636
2768
  bootstrapChunks.push('" async="">\x3c/script>');
2637
2769
  return {
2638
2770
  placeholderPrefix: bootstrapScriptContent,
2639
- segmentPrefix: JSCompiler_object_inline_segmentPrefix_1483,
2771
+ segmentPrefix: JSCompiler_object_inline_segmentPrefix_1542,
2640
2772
  boundaryPrefix: idPrefix,
2641
2773
  startInlineScript: "<script>",
2642
- htmlChunks: null,
2643
- headChunks: null,
2774
+ preamble: JSCompiler_object_inline_preamble_1545,
2644
2775
  externalRuntimeScript: null,
2645
2776
  bootstrapChunks: bootstrapChunks,
2646
2777
  importMapChunks: [],
@@ -2656,14 +2787,14 @@ function createRenderState(resumableState, generateStaticMarkup) {
2656
2787
  charsetChunks: [],
2657
2788
  viewportChunks: [],
2658
2789
  hoistableChunks: [],
2659
- preconnects: JSCompiler_object_inline_preconnects_1497,
2660
- fontPreloads: JSCompiler_object_inline_fontPreloads_1498,
2661
- highImagePreloads: JSCompiler_object_inline_highImagePreloads_1499,
2662
- styles: JSCompiler_object_inline_styles_1500,
2663
- bootstrapScripts: JSCompiler_object_inline_bootstrapScripts_1501,
2664
- scripts: JSCompiler_object_inline_scripts_1502,
2665
- bulkPreloads: JSCompiler_object_inline_bulkPreloads_1503,
2666
- preloads: JSCompiler_object_inline_preloads_1504,
2790
+ preconnects: JSCompiler_object_inline_preconnects_1555,
2791
+ fontPreloads: JSCompiler_object_inline_fontPreloads_1556,
2792
+ highImagePreloads: JSCompiler_object_inline_highImagePreloads_1557,
2793
+ styles: JSCompiler_object_inline_styles_1558,
2794
+ bootstrapScripts: JSCompiler_object_inline_bootstrapScripts_1559,
2795
+ scripts: JSCompiler_object_inline_scripts_1560,
2796
+ bulkPreloads: JSCompiler_object_inline_bulkPreloads_1561,
2797
+ preloads: JSCompiler_object_inline_preloads_1562,
2667
2798
  stylesToHoist: !1,
2668
2799
  generateStaticMarkup: generateStaticMarkup
2669
2800
  };
@@ -2678,7 +2809,12 @@ function pushTextInstance(target, text, renderState, textEmbedded) {
2678
2809
  (target = !0));
2679
2810
  return target;
2680
2811
  }
2681
- var REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference");
2812
+ function pushSegmentFinale(target, renderState, lastPushedText, textEmbedded) {
2813
+ renderState.generateStaticMarkup ||
2814
+ (lastPushedText && textEmbedded && target.push("\x3c!-- --\x3e"));
2815
+ }
2816
+ var bind = Function.prototype.bind,
2817
+ REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference");
2682
2818
  function getComponentNameFromType(type) {
2683
2819
  if (null == type) return null;
2684
2820
  if ("function" === typeof type)
@@ -2689,8 +2825,6 @@ function getComponentNameFromType(type) {
2689
2825
  switch (type) {
2690
2826
  case REACT_FRAGMENT_TYPE:
2691
2827
  return "Fragment";
2692
- case REACT_PORTAL_TYPE:
2693
- return "Portal";
2694
2828
  case REACT_PROFILER_TYPE:
2695
2829
  return "Profiler";
2696
2830
  case REACT_STRICT_MODE_TYPE:
@@ -2699,9 +2833,13 @@ function getComponentNameFromType(type) {
2699
2833
  return "Suspense";
2700
2834
  case REACT_SUSPENSE_LIST_TYPE:
2701
2835
  return "SuspenseList";
2836
+ case REACT_ACTIVITY_TYPE:
2837
+ return "Activity";
2702
2838
  }
2703
2839
  if ("object" === typeof type)
2704
2840
  switch (type.$$typeof) {
2841
+ case REACT_PORTAL_TYPE:
2842
+ return "Portal";
2705
2843
  case REACT_CONTEXT_TYPE:
2706
2844
  return (type.displayName || "Context") + ".Provider";
2707
2845
  case REACT_CONSUMER_TYPE:
@@ -2789,18 +2927,15 @@ function switchContext(newSnapshot) {
2789
2927
  (null === prev
2790
2928
  ? pushAllNext(newSnapshot)
2791
2929
  : null === newSnapshot
2792
- ? popAllPrevious(prev)
2793
- : prev.depth === newSnapshot.depth
2794
- ? popToNearestCommonAncestor(prev, newSnapshot)
2795
- : prev.depth > newSnapshot.depth
2796
- ? popPreviousToCommonLevel(prev, newSnapshot)
2797
- : popNextToCommonLevel(prev, newSnapshot),
2930
+ ? popAllPrevious(prev)
2931
+ : prev.depth === newSnapshot.depth
2932
+ ? popToNearestCommonAncestor(prev, newSnapshot)
2933
+ : prev.depth > newSnapshot.depth
2934
+ ? popPreviousToCommonLevel(prev, newSnapshot)
2935
+ : popNextToCommonLevel(prev, newSnapshot),
2798
2936
  (currentActiveSnapshot = newSnapshot));
2799
2937
  }
2800
2938
  var classComponentUpdater = {
2801
- isMounted: function () {
2802
- return !1;
2803
- },
2804
2939
  enqueueSetState: function (inst, payload) {
2805
2940
  inst = inst._reactInternals;
2806
2941
  null !== inst.queue && inst.queue.push(payload);
@@ -2849,7 +2984,7 @@ function clz32Fallback(x) {
2849
2984
  return 0 === x ? 32 : (31 - ((log(x) / LN2) | 0)) | 0;
2850
2985
  }
2851
2986
  var SuspenseException = Error(
2852
- "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`"
2987
+ "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`."
2853
2988
  );
2854
2989
  function noop$2() {}
2855
2990
  function trackUsedThenable(thenableState, thenable, index) {
@@ -2941,9 +3076,9 @@ function createWorkInProgressHook() {
2941
3076
  (firstWorkInProgressHook = workInProgressHook = createHook()))
2942
3077
  : ((isReRender = !0), (workInProgressHook = firstWorkInProgressHook))
2943
3078
  : null === workInProgressHook.next
2944
- ? ((isReRender = !1),
2945
- (workInProgressHook = workInProgressHook.next = createHook()))
2946
- : ((isReRender = !0), (workInProgressHook = workInProgressHook.next));
3079
+ ? ((isReRender = !1),
3080
+ (workInProgressHook = workInProgressHook.next = createHook()))
3081
+ : ((isReRender = !0), (workInProgressHook = workInProgressHook.next));
2947
3082
  return workInProgressHook;
2948
3083
  }
2949
3084
  function getThenableStateAfterSuspending() {
@@ -2990,8 +3125,8 @@ function useReducer(reducer, initialArg, init) {
2990
3125
  ? initialArg()
2991
3126
  : initialArg
2992
3127
  : void 0 !== init
2993
- ? init(initialArg)
2994
- : initialArg;
3128
+ ? init(initialArg)
3129
+ : initialArg;
2995
3130
  workInProgressHook.memoizedState = reducer;
2996
3131
  reducer = workInProgressHook.queue = { last: null, dispatch: null };
2997
3132
  reducer = reducer.dispatch = dispatchAction.bind(
@@ -3123,100 +3258,107 @@ function unsupportedRefresh() {
3123
3258
  }
3124
3259
  function noop$1() {}
3125
3260
  var HooksDispatcher = {
3126
- readContext: function (context) {
3127
- return context._currentValue2;
3128
- },
3129
- use: function (usable) {
3130
- if (null !== usable && "object" === typeof usable) {
3131
- if ("function" === typeof usable.then) return unwrapThenable(usable);
3132
- if (usable.$$typeof === REACT_CONTEXT_TYPE) return usable._currentValue2;
3261
+ readContext: function (context) {
3262
+ return context._currentValue2;
3263
+ },
3264
+ use: function (usable) {
3265
+ if (null !== usable && "object" === typeof usable) {
3266
+ if ("function" === typeof usable.then) return unwrapThenable(usable);
3267
+ if (usable.$$typeof === REACT_CONTEXT_TYPE)
3268
+ return usable._currentValue2;
3269
+ }
3270
+ throw Error("An unsupported type was passed to use(): " + String(usable));
3271
+ },
3272
+ useContext: function (context) {
3273
+ resolveCurrentlyRenderingComponent();
3274
+ return context._currentValue2;
3275
+ },
3276
+ useMemo: useMemo,
3277
+ useReducer: useReducer,
3278
+ useRef: function (initialValue) {
3279
+ currentlyRenderingComponent = resolveCurrentlyRenderingComponent();
3280
+ workInProgressHook = createWorkInProgressHook();
3281
+ var previousRef = workInProgressHook.memoizedState;
3282
+ return null === previousRef
3283
+ ? ((initialValue = { current: initialValue }),
3284
+ (workInProgressHook.memoizedState = initialValue))
3285
+ : previousRef;
3286
+ },
3287
+ useState: function (initialState) {
3288
+ return useReducer(basicStateReducer, initialState);
3289
+ },
3290
+ useInsertionEffect: noop$1,
3291
+ useLayoutEffect: noop$1,
3292
+ useCallback: function (callback, deps) {
3293
+ return useMemo(function () {
3294
+ return callback;
3295
+ }, deps);
3296
+ },
3297
+ useImperativeHandle: noop$1,
3298
+ useEffect: noop$1,
3299
+ useDebugValue: noop$1,
3300
+ useDeferredValue: function (value, initialValue) {
3301
+ resolveCurrentlyRenderingComponent();
3302
+ return void 0 !== initialValue ? initialValue : value;
3303
+ },
3304
+ useTransition: function () {
3305
+ resolveCurrentlyRenderingComponent();
3306
+ return [!1, unsupportedStartTransition];
3307
+ },
3308
+ useId: function () {
3309
+ var JSCompiler_inline_result = currentlyRenderingTask.treeContext;
3310
+ var overflow = JSCompiler_inline_result.overflow;
3311
+ JSCompiler_inline_result = JSCompiler_inline_result.id;
3312
+ JSCompiler_inline_result =
3313
+ (
3314
+ JSCompiler_inline_result &
3315
+ ~(1 << (32 - clz32(JSCompiler_inline_result) - 1))
3316
+ ).toString(32) + overflow;
3317
+ var resumableState = currentResumableState;
3318
+ if (null === resumableState)
3319
+ throw Error(
3320
+ "Invalid hook call. Hooks can only be called inside of the body of a function component."
3321
+ );
3322
+ overflow = localIdCounter++;
3323
+ JSCompiler_inline_result =
3324
+ "\u00ab" + resumableState.idPrefix + "R" + JSCompiler_inline_result;
3325
+ 0 < overflow && (JSCompiler_inline_result += "H" + overflow.toString(32));
3326
+ return JSCompiler_inline_result + "\u00bb";
3327
+ },
3328
+ useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
3329
+ if (void 0 === getServerSnapshot)
3330
+ throw Error(
3331
+ "Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering."
3332
+ );
3333
+ return getServerSnapshot();
3334
+ },
3335
+ useOptimistic: function (passthrough) {
3336
+ resolveCurrentlyRenderingComponent();
3337
+ return [passthrough, unsupportedSetOptimisticState];
3338
+ },
3339
+ useActionState: useActionState,
3340
+ useFormState: useActionState,
3341
+ useHostTransitionStatus: function () {
3342
+ resolveCurrentlyRenderingComponent();
3343
+ return sharedNotPendingObject;
3344
+ },
3345
+ useMemoCache: function (size) {
3346
+ for (var data = Array(size), i = 0; i < size; i++)
3347
+ data[i] = REACT_MEMO_CACHE_SENTINEL;
3348
+ return data;
3349
+ },
3350
+ useCacheRefresh: function () {
3351
+ return unsupportedRefresh;
3133
3352
  }
3134
- throw Error("An unsupported type was passed to use(): " + String(usable));
3135
- },
3136
- useContext: function (context) {
3137
- resolveCurrentlyRenderingComponent();
3138
- return context._currentValue2;
3139
- },
3140
- useMemo: useMemo,
3141
- useReducer: useReducer,
3142
- useRef: function (initialValue) {
3143
- currentlyRenderingComponent = resolveCurrentlyRenderingComponent();
3144
- workInProgressHook = createWorkInProgressHook();
3145
- var previousRef = workInProgressHook.memoizedState;
3146
- return null === previousRef
3147
- ? ((initialValue = { current: initialValue }),
3148
- (workInProgressHook.memoizedState = initialValue))
3149
- : previousRef;
3150
- },
3151
- useState: function (initialState) {
3152
- return useReducer(basicStateReducer, initialState);
3153
- },
3154
- useInsertionEffect: noop$1,
3155
- useLayoutEffect: noop$1,
3156
- useCallback: function (callback, deps) {
3157
- return useMemo(function () {
3158
- return callback;
3159
- }, deps);
3160
- },
3161
- useImperativeHandle: noop$1,
3162
- useEffect: noop$1,
3163
- useDebugValue: noop$1,
3164
- useDeferredValue: function (value, initialValue) {
3165
- resolveCurrentlyRenderingComponent();
3166
- return void 0 !== initialValue ? initialValue : value;
3167
3353
  },
3168
- useTransition: function () {
3169
- resolveCurrentlyRenderingComponent();
3170
- return [!1, unsupportedStartTransition];
3171
- },
3172
- useId: function () {
3173
- var JSCompiler_inline_result = currentlyRenderingTask.treeContext;
3174
- var overflow = JSCompiler_inline_result.overflow;
3175
- JSCompiler_inline_result = JSCompiler_inline_result.id;
3176
- JSCompiler_inline_result =
3177
- (
3178
- JSCompiler_inline_result &
3179
- ~(1 << (32 - clz32(JSCompiler_inline_result) - 1))
3180
- ).toString(32) + overflow;
3181
- var resumableState = currentResumableState;
3182
- if (null === resumableState)
3183
- throw Error(
3184
- "Invalid hook call. Hooks can only be called inside of the body of a function component."
3185
- );
3186
- overflow = localIdCounter++;
3187
- JSCompiler_inline_result =
3188
- ":" + resumableState.idPrefix + "R" + JSCompiler_inline_result;
3189
- 0 < overflow && (JSCompiler_inline_result += "H" + overflow.toString(32));
3190
- return JSCompiler_inline_result + ":";
3191
- },
3192
- useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
3193
- if (void 0 === getServerSnapshot)
3194
- throw Error(
3195
- "Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering."
3196
- );
3197
- return getServerSnapshot();
3198
- },
3199
- useCacheRefresh: function () {
3200
- return unsupportedRefresh;
3201
- },
3202
- useHostTransitionStatus: function () {
3203
- resolveCurrentlyRenderingComponent();
3204
- return sharedNotPendingObject;
3205
- },
3206
- useOptimistic: function (passthrough) {
3207
- resolveCurrentlyRenderingComponent();
3208
- return [passthrough, unsupportedSetOptimisticState];
3209
- }
3210
- };
3211
- HooksDispatcher.useFormState = useActionState;
3212
- HooksDispatcher.useActionState = useActionState;
3213
- var currentResumableState = null,
3354
+ currentResumableState = null,
3214
3355
  DefaultAsyncDispatcher = {
3215
3356
  getCacheForType: function () {
3216
3357
  throw Error("Not implemented.");
3217
3358
  }
3218
3359
  },
3219
- prefix;
3360
+ prefix,
3361
+ suffix;
3220
3362
  function describeBuiltInComponentFrame(name) {
3221
3363
  if (void 0 === prefix)
3222
3364
  try {
@@ -3224,8 +3366,14 @@ function describeBuiltInComponentFrame(name) {
3224
3366
  } catch (x) {
3225
3367
  var match = x.stack.trim().match(/\n( *(at )?)/);
3226
3368
  prefix = (match && match[1]) || "";
3369
+ suffix =
3370
+ -1 < x.stack.indexOf("\n at")
3371
+ ? " (<anonymous>)"
3372
+ : -1 < x.stack.indexOf("@")
3373
+ ? "@unknown:0:0"
3374
+ : "";
3227
3375
  }
3228
- return "\n" + prefix + name;
3376
+ return "\n" + prefix + name + suffix;
3229
3377
  }
3230
3378
  var reentry = !1;
3231
3379
  function describeNativeComponentFrame(fn, construct) {
@@ -3233,62 +3381,64 @@ function describeNativeComponentFrame(fn, construct) {
3233
3381
  reentry = !0;
3234
3382
  var previousPrepareStackTrace = Error.prepareStackTrace;
3235
3383
  Error.prepareStackTrace = void 0;
3236
- var RunInRootFrame = {
3237
- DetermineComponentFrameRoot: function () {
3238
- try {
3239
- if (construct) {
3240
- var Fake = function () {
3241
- throw Error();
3242
- };
3243
- Object.defineProperty(Fake.prototype, "props", {
3244
- set: function () {
3384
+ try {
3385
+ var RunInRootFrame = {
3386
+ DetermineComponentFrameRoot: function () {
3387
+ try {
3388
+ if (construct) {
3389
+ var Fake = function () {
3245
3390
  throw Error();
3391
+ };
3392
+ Object.defineProperty(Fake.prototype, "props", {
3393
+ set: function () {
3394
+ throw Error();
3395
+ }
3396
+ });
3397
+ if ("object" === typeof Reflect && Reflect.construct) {
3398
+ try {
3399
+ Reflect.construct(Fake, []);
3400
+ } catch (x) {
3401
+ var control = x;
3402
+ }
3403
+ Reflect.construct(fn, [], Fake);
3404
+ } else {
3405
+ try {
3406
+ Fake.call();
3407
+ } catch (x$24) {
3408
+ control = x$24;
3409
+ }
3410
+ fn.call(Fake.prototype);
3246
3411
  }
3247
- });
3248
- if ("object" === typeof Reflect && Reflect.construct) {
3249
- try {
3250
- Reflect.construct(Fake, []);
3251
- } catch (x) {
3252
- var control = x;
3253
- }
3254
- Reflect.construct(fn, [], Fake);
3255
3412
  } else {
3256
3413
  try {
3257
- Fake.call();
3258
- } catch (x$24) {
3259
- control = x$24;
3414
+ throw Error();
3415
+ } catch (x$25) {
3416
+ control = x$25;
3260
3417
  }
3261
- fn.call(Fake.prototype);
3262
- }
3263
- } else {
3264
- try {
3265
- throw Error();
3266
- } catch (x$25) {
3267
- control = x$25;
3418
+ (Fake = fn()) &&
3419
+ "function" === typeof Fake.catch &&
3420
+ Fake.catch(function () {});
3268
3421
  }
3269
- (Fake = fn()) &&
3270
- "function" === typeof Fake.catch &&
3271
- Fake.catch(function () {});
3422
+ } catch (sample) {
3423
+ if (sample && control && "string" === typeof sample.stack)
3424
+ return [sample.stack, control.stack];
3272
3425
  }
3273
- } catch (sample) {
3274
- if (sample && control && "string" === typeof sample.stack)
3275
- return [sample.stack, control.stack];
3426
+ return [null, null];
3276
3427
  }
3277
- return [null, null];
3278
- }
3279
- };
3280
- RunInRootFrame.DetermineComponentFrameRoot.displayName =
3281
- "DetermineComponentFrameRoot";
3282
- var namePropDescriptor = Object.getOwnPropertyDescriptor(
3283
- RunInRootFrame.DetermineComponentFrameRoot,
3284
- "name"
3285
- );
3286
- namePropDescriptor &&
3287
- namePropDescriptor.configurable &&
3288
- Object.defineProperty(RunInRootFrame.DetermineComponentFrameRoot, "name", {
3289
- value: "DetermineComponentFrameRoot"
3290
- });
3291
- try {
3428
+ };
3429
+ RunInRootFrame.DetermineComponentFrameRoot.displayName =
3430
+ "DetermineComponentFrameRoot";
3431
+ var namePropDescriptor = Object.getOwnPropertyDescriptor(
3432
+ RunInRootFrame.DetermineComponentFrameRoot,
3433
+ "name"
3434
+ );
3435
+ namePropDescriptor &&
3436
+ namePropDescriptor.configurable &&
3437
+ Object.defineProperty(
3438
+ RunInRootFrame.DetermineComponentFrameRoot,
3439
+ "name",
3440
+ { value: "DetermineComponentFrameRoot" }
3441
+ );
3292
3442
  var _RunInRootFrame$Deter = RunInRootFrame.DetermineComponentFrameRoot(),
3293
3443
  sampleStack = _RunInRootFrame$Deter[0],
3294
3444
  controlStack = _RunInRootFrame$Deter[1];
@@ -3359,11 +3509,107 @@ function describeNativeComponentFrame(fn, construct) {
3359
3509
  ? describeBuiltInComponentFrame(previousPrepareStackTrace)
3360
3510
  : "";
3361
3511
  }
3512
+ function describeComponentStackByType(type) {
3513
+ if ("string" === typeof type) return describeBuiltInComponentFrame(type);
3514
+ if ("function" === typeof type)
3515
+ return type.prototype && type.prototype.isReactComponent
3516
+ ? describeNativeComponentFrame(type, !0)
3517
+ : describeNativeComponentFrame(type, !1);
3518
+ if ("object" === typeof type && null !== type) {
3519
+ switch (type.$$typeof) {
3520
+ case REACT_FORWARD_REF_TYPE:
3521
+ return describeNativeComponentFrame(type.render, !1);
3522
+ case REACT_MEMO_TYPE:
3523
+ return describeNativeComponentFrame(type.type, !1);
3524
+ case REACT_LAZY_TYPE:
3525
+ var lazyComponent = type,
3526
+ payload = lazyComponent._payload;
3527
+ lazyComponent = lazyComponent._init;
3528
+ try {
3529
+ type = lazyComponent(payload);
3530
+ } catch (x) {
3531
+ return describeBuiltInComponentFrame("Lazy");
3532
+ }
3533
+ return describeComponentStackByType(type);
3534
+ }
3535
+ if ("string" === typeof type.name)
3536
+ return (
3537
+ (payload = type.env),
3538
+ describeBuiltInComponentFrame(
3539
+ type.name + (payload ? " [" + payload + "]" : "")
3540
+ )
3541
+ );
3542
+ }
3543
+ switch (type) {
3544
+ case REACT_SUSPENSE_LIST_TYPE:
3545
+ return describeBuiltInComponentFrame("SuspenseList");
3546
+ case REACT_SUSPENSE_TYPE:
3547
+ return describeBuiltInComponentFrame("Suspense");
3548
+ }
3549
+ return "";
3550
+ }
3362
3551
  function defaultErrorHandler(error) {
3363
- console.error(error);
3552
+ if (
3553
+ "object" === typeof error &&
3554
+ null !== error &&
3555
+ "string" === typeof error.environmentName
3556
+ ) {
3557
+ var JSCompiler_inline_result = error.environmentName;
3558
+ error = [error].slice(0);
3559
+ "string" === typeof error[0]
3560
+ ? error.splice(
3561
+ 0,
3562
+ 1,
3563
+ "[%s] " + error[0],
3564
+ " " + JSCompiler_inline_result + " "
3565
+ )
3566
+ : error.splice(0, 0, "[%s] ", " " + JSCompiler_inline_result + " ");
3567
+ error.unshift(console);
3568
+ JSCompiler_inline_result = bind.apply(console.error, error);
3569
+ JSCompiler_inline_result();
3570
+ } else console.error(error);
3364
3571
  return null;
3365
3572
  }
3366
3573
  function noop() {}
3574
+ function RequestInstance(
3575
+ resumableState,
3576
+ renderState,
3577
+ rootFormatContext,
3578
+ progressiveChunkSize,
3579
+ onError,
3580
+ onAllReady,
3581
+ onShellReady,
3582
+ onShellError,
3583
+ onFatalError,
3584
+ onPostpone,
3585
+ formState
3586
+ ) {
3587
+ var abortSet = new Set();
3588
+ this.destination = null;
3589
+ this.flushScheduled = !1;
3590
+ this.resumableState = resumableState;
3591
+ this.renderState = renderState;
3592
+ this.rootFormatContext = rootFormatContext;
3593
+ this.progressiveChunkSize =
3594
+ void 0 === progressiveChunkSize ? 12800 : progressiveChunkSize;
3595
+ this.status = 10;
3596
+ this.fatalError = null;
3597
+ this.pendingRootTasks = this.allPendingTasks = this.nextSegmentId = 0;
3598
+ this.completedPreambleSegments = this.completedRootSegment = null;
3599
+ this.abortableTasks = abortSet;
3600
+ this.pingedTasks = [];
3601
+ this.clientRenderedBoundaries = [];
3602
+ this.completedBoundaries = [];
3603
+ this.partialBoundaries = [];
3604
+ this.trackedPostpones = null;
3605
+ this.onError = void 0 === onError ? defaultErrorHandler : onError;
3606
+ this.onPostpone = void 0 === onPostpone ? noop : onPostpone;
3607
+ this.onAllReady = void 0 === onAllReady ? noop : onAllReady;
3608
+ this.onShellReady = void 0 === onShellReady ? noop : onShellReady;
3609
+ this.onShellError = void 0 === onShellError ? noop : onShellError;
3610
+ this.onFatalError = void 0 === onFatalError ? noop : onFatalError;
3611
+ this.formState = void 0 === formState ? null : formState;
3612
+ }
3367
3613
  function createRequest(
3368
3614
  children,
3369
3615
  resumableState,
@@ -3378,36 +3624,19 @@ function createRequest(
3378
3624
  onPostpone,
3379
3625
  formState
3380
3626
  ) {
3381
- var pingedTasks = [],
3382
- abortSet = new Set();
3383
- resumableState = {
3384
- destination: null,
3385
- flushScheduled: !1,
3386
- resumableState: resumableState,
3387
- renderState: renderState,
3388
- rootFormatContext: rootFormatContext,
3389
- progressiveChunkSize:
3390
- void 0 === progressiveChunkSize ? 12800 : progressiveChunkSize,
3391
- status: 0,
3392
- fatalError: null,
3393
- nextSegmentId: 0,
3394
- allPendingTasks: 0,
3395
- pendingRootTasks: 0,
3396
- completedRootSegment: null,
3397
- abortableTasks: abortSet,
3398
- pingedTasks: pingedTasks,
3399
- clientRenderedBoundaries: [],
3400
- completedBoundaries: [],
3401
- partialBoundaries: [],
3402
- trackedPostpones: null,
3403
- onError: void 0 === onError ? defaultErrorHandler : onError,
3404
- onPostpone: void 0 === onPostpone ? noop : onPostpone,
3405
- onAllReady: void 0 === onAllReady ? noop : onAllReady,
3406
- onShellReady: void 0 === onShellReady ? noop : onShellReady,
3407
- onShellError: void 0 === onShellError ? noop : onShellError,
3408
- onFatalError: void 0 === onFatalError ? noop : onFatalError,
3409
- formState: void 0 === formState ? null : formState
3410
- };
3627
+ resumableState = new RequestInstance(
3628
+ resumableState,
3629
+ renderState,
3630
+ rootFormatContext,
3631
+ progressiveChunkSize,
3632
+ onError,
3633
+ onAllReady,
3634
+ onShellReady,
3635
+ onShellError,
3636
+ onFatalError,
3637
+ onPostpone,
3638
+ formState
3639
+ );
3411
3640
  renderState = createPendingSegment(
3412
3641
  resumableState,
3413
3642
  0,
@@ -3425,16 +3654,17 @@ function createRequest(
3425
3654
  null,
3426
3655
  renderState,
3427
3656
  null,
3428
- abortSet,
3657
+ null,
3658
+ resumableState.abortableTasks,
3429
3659
  null,
3430
3660
  rootFormatContext,
3431
- emptyContextObject,
3432
3661
  null,
3433
3662
  emptyTreeContext,
3434
3663
  null,
3435
3664
  !1
3436
3665
  );
3437
- pingedTasks.push(children);
3666
+ pushComponentStack(children);
3667
+ resumableState.pingedTasks.push(children);
3438
3668
  return resumableState;
3439
3669
  }
3440
3670
  var currentRequest = null;
@@ -3444,7 +3674,12 @@ function pingTask(request, task) {
3444
3674
  ((request.flushScheduled = null !== request.destination),
3445
3675
  performWork(request));
3446
3676
  }
3447
- function createSuspenseBoundary(request, fallbackAbortableTasks) {
3677
+ function createSuspenseBoundary(
3678
+ request,
3679
+ fallbackAbortableTasks,
3680
+ contentPreamble,
3681
+ fallbackPreamble
3682
+ ) {
3448
3683
  return {
3449
3684
  status: 0,
3450
3685
  rootSegmentID: -1,
@@ -3456,6 +3691,8 @@ function createSuspenseBoundary(request, fallbackAbortableTasks) {
3456
3691
  errorDigest: null,
3457
3692
  contentState: createHoistableState(),
3458
3693
  fallbackState: createHoistableState(),
3694
+ contentPreamble: contentPreamble,
3695
+ fallbackPreamble: fallbackPreamble,
3459
3696
  trackedContentKeyPath: null,
3460
3697
  trackedFallbackNode: null
3461
3698
  };
@@ -3467,11 +3704,11 @@ function createRenderTask(
3467
3704
  childIndex,
3468
3705
  blockedBoundary,
3469
3706
  blockedSegment,
3707
+ blockedPreamble,
3470
3708
  hoistableState,
3471
3709
  abortSet,
3472
3710
  keyPath,
3473
3711
  formatContext,
3474
- legacyContext,
3475
3712
  context,
3476
3713
  treeContext,
3477
3714
  componentStack,
@@ -3490,11 +3727,11 @@ function createRenderTask(
3490
3727
  },
3491
3728
  blockedBoundary: blockedBoundary,
3492
3729
  blockedSegment: blockedSegment,
3730
+ blockedPreamble: blockedPreamble,
3493
3731
  hoistableState: hoistableState,
3494
3732
  abortSet: abortSet,
3495
3733
  keyPath: keyPath,
3496
3734
  formatContext: formatContext,
3497
- legacyContext: legacyContext,
3498
3735
  context: context,
3499
3736
  treeContext: treeContext,
3500
3737
  componentStack: componentStack,
@@ -3515,7 +3752,6 @@ function createReplayTask(
3515
3752
  abortSet,
3516
3753
  keyPath,
3517
3754
  formatContext,
3518
- legacyContext,
3519
3755
  context,
3520
3756
  treeContext,
3521
3757
  componentStack,
@@ -3535,11 +3771,11 @@ function createReplayTask(
3535
3771
  },
3536
3772
  blockedBoundary: blockedBoundary,
3537
3773
  blockedSegment: null,
3774
+ blockedPreamble: null,
3538
3775
  hoistableState: hoistableState,
3539
3776
  abortSet: abortSet,
3540
3777
  keyPath: keyPath,
3541
3778
  formatContext: formatContext,
3542
- legacyContext: legacyContext,
3543
3779
  context: context,
3544
3780
  treeContext: treeContext,
3545
3781
  componentStack: componentStack,
@@ -3559,58 +3795,66 @@ function createPendingSegment(
3559
3795
  ) {
3560
3796
  return {
3561
3797
  status: 0,
3798
+ parentFlushed: !1,
3562
3799
  id: -1,
3563
3800
  index: index,
3564
- parentFlushed: !1,
3565
3801
  chunks: [],
3566
3802
  children: [],
3803
+ preambleChildren: [],
3567
3804
  parentFormatContext: parentFormatContext,
3568
3805
  boundary: boundary,
3569
3806
  lastPushedText: lastPushedText,
3570
3807
  textEmbedded: textEmbedded
3571
3808
  };
3572
3809
  }
3573
- function createBuiltInComponentStack(task, type) {
3574
- return { tag: 0, parent: task.componentStack, type: type };
3810
+ function pushComponentStack(task) {
3811
+ var node = task.node;
3812
+ if ("object" === typeof node && null !== node)
3813
+ switch (node.$$typeof) {
3814
+ case REACT_ELEMENT_TYPE:
3815
+ task.componentStack = { parent: task.componentStack, type: node.type };
3816
+ }
3575
3817
  }
3576
- function getThrownInfo(request, node) {
3577
- if (node && null !== request.trackedPostpones) {
3578
- try {
3579
- request = "";
3580
- do {
3581
- switch (node.tag) {
3582
- case 0:
3583
- request += describeBuiltInComponentFrame(node.type);
3584
- break;
3585
- case 1:
3586
- request += describeNativeComponentFrame(node.type, !1);
3587
- break;
3588
- case 2:
3589
- request += describeNativeComponentFrame(node.type, !0);
3818
+ function getThrownInfo(node$jscomp$0) {
3819
+ var errorInfo = {};
3820
+ node$jscomp$0 &&
3821
+ Object.defineProperty(errorInfo, "componentStack", {
3822
+ configurable: !0,
3823
+ enumerable: !0,
3824
+ get: function () {
3825
+ try {
3826
+ var info = "",
3827
+ node = node$jscomp$0;
3828
+ do
3829
+ (info += describeComponentStackByType(node.type)),
3830
+ (node = node.parent);
3831
+ while (node);
3832
+ var JSCompiler_inline_result = info;
3833
+ } catch (x) {
3834
+ JSCompiler_inline_result =
3835
+ "\nError generating stack: " + x.message + "\n" + x.stack;
3590
3836
  }
3591
- node = node.parent;
3592
- } while (node);
3593
- var JSCompiler_temp = request;
3594
- } catch (x) {
3595
- JSCompiler_temp =
3596
- "\nError generating stack: " + x.message + "\n" + x.stack;
3597
- }
3598
- JSCompiler_temp = { componentStack: JSCompiler_temp };
3599
- } else JSCompiler_temp = {};
3600
- return JSCompiler_temp;
3837
+ Object.defineProperty(errorInfo, "componentStack", {
3838
+ value: JSCompiler_inline_result
3839
+ });
3840
+ return JSCompiler_inline_result;
3841
+ }
3842
+ });
3843
+ return errorInfo;
3601
3844
  }
3602
3845
  function logRecoverableError(request, error, errorInfo) {
3603
- request = request.onError(error, errorInfo);
3604
- if (null == request || "string" === typeof request) return request;
3846
+ request = request.onError;
3847
+ error = request(error, errorInfo);
3848
+ if (null == error || "string" === typeof error) return error;
3605
3849
  }
3606
3850
  function fatalError(request, error) {
3607
- var onShellError = request.onShellError;
3608
- onShellError(error);
3609
- onShellError = request.onFatalError;
3851
+ var onShellError = request.onShellError,
3852
+ onFatalError = request.onFatalError;
3610
3853
  onShellError(error);
3854
+ onFatalError(error);
3611
3855
  null !== request.destination
3612
- ? ((request.status = 2), request.destination.destroy(error))
3613
- : ((request.status = 1), (request.fatalError = error));
3856
+ ? ((request.status = 14), request.destination.destroy(error))
3857
+ : ((request.status = 13), (request.fatalError = error));
3614
3858
  }
3615
3859
  function renderWithHooks(request, task, keyPath, Component, props, secondArg) {
3616
3860
  var prevThenableState = task.thenableState;
@@ -3663,171 +3907,179 @@ function finishFunctionComponent(
3663
3907
  renderNode(request, task, children, -1),
3664
3908
  (task.treeContext = keyPath))
3665
3909
  : didEmitActionStateMarkers
3666
- ? renderNode(request, task, children, -1)
3667
- : renderNodeDestructive(request, task, children, -1);
3910
+ ? renderNode(request, task, children, -1)
3911
+ : renderNodeDestructive(request, task, children, -1);
3668
3912
  task.keyPath = actionStateCount;
3669
3913
  }
3670
3914
  function renderElement(request, task, keyPath, type, props, ref) {
3671
3915
  if ("function" === typeof type)
3672
3916
  if (type.prototype && type.prototype.isReactComponent) {
3673
- var JSCompiler_inline_result = props;
3917
+ var newProps = props;
3674
3918
  if ("ref" in props) {
3675
- JSCompiler_inline_result = {};
3919
+ newProps = {};
3676
3920
  for (var propName in props)
3677
- "ref" !== propName &&
3678
- (JSCompiler_inline_result[propName] = props[propName]);
3921
+ "ref" !== propName && (newProps[propName] = props[propName]);
3679
3922
  }
3680
3923
  var defaultProps = type.defaultProps;
3681
3924
  if (defaultProps) {
3682
- JSCompiler_inline_result === props &&
3683
- (JSCompiler_inline_result = assign(
3684
- {},
3685
- JSCompiler_inline_result,
3686
- props
3687
- ));
3688
- for (var propName$31 in defaultProps)
3689
- void 0 === JSCompiler_inline_result[propName$31] &&
3690
- (JSCompiler_inline_result[propName$31] = defaultProps[propName$31]);
3925
+ newProps === props && (newProps = assign({}, newProps, props));
3926
+ for (var propName$33 in defaultProps)
3927
+ void 0 === newProps[propName$33] &&
3928
+ (newProps[propName$33] = defaultProps[propName$33]);
3691
3929
  }
3692
- props = task.componentStack;
3693
- task.componentStack = { tag: 2, parent: task.componentStack, type: type };
3694
- defaultProps = emptyContextObject;
3930
+ props = newProps;
3931
+ newProps = emptyContextObject;
3932
+ defaultProps = type.contextType;
3933
+ "object" === typeof defaultProps &&
3934
+ null !== defaultProps &&
3935
+ (newProps = defaultProps._currentValue2);
3936
+ newProps = new type(props, newProps);
3937
+ var initialState = void 0 !== newProps.state ? newProps.state : null;
3938
+ newProps.updater = classComponentUpdater;
3939
+ newProps.props = props;
3940
+ newProps.state = initialState;
3941
+ defaultProps = { queue: [], replace: !1 };
3942
+ newProps._reactInternals = defaultProps;
3695
3943
  ref = type.contextType;
3696
- "object" === typeof ref &&
3697
- null !== ref &&
3698
- (defaultProps = ref._currentValue2);
3699
- defaultProps = new type(JSCompiler_inline_result, defaultProps);
3700
- propName$31 = void 0 !== defaultProps.state ? defaultProps.state : null;
3701
- defaultProps.updater = classComponentUpdater;
3702
- defaultProps.props = JSCompiler_inline_result;
3703
- defaultProps.state = propName$31;
3704
- ref = { queue: [], replace: !1 };
3705
- defaultProps._reactInternals = ref;
3706
- var contextType = type.contextType;
3707
- defaultProps.context =
3708
- "object" === typeof contextType && null !== contextType
3709
- ? contextType._currentValue2
3944
+ newProps.context =
3945
+ "object" === typeof ref && null !== ref
3946
+ ? ref._currentValue2
3710
3947
  : emptyContextObject;
3711
- contextType = type.getDerivedStateFromProps;
3712
- "function" === typeof contextType &&
3713
- ((contextType = contextType(JSCompiler_inline_result, propName$31)),
3714
- (propName$31 =
3715
- null === contextType || void 0 === contextType
3716
- ? propName$31
3717
- : assign({}, propName$31, contextType)),
3718
- (defaultProps.state = propName$31));
3948
+ ref = type.getDerivedStateFromProps;
3949
+ "function" === typeof ref &&
3950
+ ((ref = ref(props, initialState)),
3951
+ (initialState =
3952
+ null === ref || void 0 === ref
3953
+ ? initialState
3954
+ : assign({}, initialState, ref)),
3955
+ (newProps.state = initialState));
3719
3956
  if (
3720
3957
  "function" !== typeof type.getDerivedStateFromProps &&
3721
- "function" !== typeof defaultProps.getSnapshotBeforeUpdate &&
3722
- ("function" === typeof defaultProps.UNSAFE_componentWillMount ||
3723
- "function" === typeof defaultProps.componentWillMount)
3958
+ "function" !== typeof newProps.getSnapshotBeforeUpdate &&
3959
+ ("function" === typeof newProps.UNSAFE_componentWillMount ||
3960
+ "function" === typeof newProps.componentWillMount)
3724
3961
  )
3725
3962
  if (
3726
- ((type = defaultProps.state),
3727
- "function" === typeof defaultProps.componentWillMount &&
3728
- defaultProps.componentWillMount(),
3729
- "function" === typeof defaultProps.UNSAFE_componentWillMount &&
3730
- defaultProps.UNSAFE_componentWillMount(),
3731
- type !== defaultProps.state &&
3963
+ ((type = newProps.state),
3964
+ "function" === typeof newProps.componentWillMount &&
3965
+ newProps.componentWillMount(),
3966
+ "function" === typeof newProps.UNSAFE_componentWillMount &&
3967
+ newProps.UNSAFE_componentWillMount(),
3968
+ type !== newProps.state &&
3732
3969
  classComponentUpdater.enqueueReplaceState(
3733
- defaultProps,
3734
- defaultProps.state,
3970
+ newProps,
3971
+ newProps.state,
3735
3972
  null
3736
3973
  ),
3737
- null !== ref.queue && 0 < ref.queue.length)
3974
+ null !== defaultProps.queue && 0 < defaultProps.queue.length)
3738
3975
  )
3739
3976
  if (
3740
- ((type = ref.queue),
3741
- (contextType = ref.replace),
3742
- (ref.queue = null),
3743
- (ref.replace = !1),
3744
- contextType && 1 === type.length)
3977
+ ((type = defaultProps.queue),
3978
+ (ref = defaultProps.replace),
3979
+ (defaultProps.queue = null),
3980
+ (defaultProps.replace = !1),
3981
+ ref && 1 === type.length)
3745
3982
  )
3746
- defaultProps.state = type[0];
3983
+ newProps.state = type[0];
3747
3984
  else {
3748
- ref = contextType ? type[0] : defaultProps.state;
3749
- propName$31 = !0;
3750
- for (
3751
- contextType = contextType ? 1 : 0;
3752
- contextType < type.length;
3753
- contextType++
3754
- )
3755
- (propName = type[contextType]),
3756
- (propName =
3757
- "function" === typeof propName
3758
- ? propName.call(
3759
- defaultProps,
3760
- ref,
3761
- JSCompiler_inline_result,
3762
- void 0
3763
- )
3764
- : propName),
3765
- null != propName &&
3766
- (propName$31
3767
- ? ((propName$31 = !1), (ref = assign({}, ref, propName)))
3768
- : assign(ref, propName));
3769
- defaultProps.state = ref;
3985
+ defaultProps = ref ? type[0] : newProps.state;
3986
+ initialState = !0;
3987
+ for (ref = ref ? 1 : 0; ref < type.length; ref++)
3988
+ (propName$33 = type[ref]),
3989
+ (propName$33 =
3990
+ "function" === typeof propName$33
3991
+ ? propName$33.call(newProps, defaultProps, props, void 0)
3992
+ : propName$33),
3993
+ null != propName$33 &&
3994
+ (initialState
3995
+ ? ((initialState = !1),
3996
+ (defaultProps = assign({}, defaultProps, propName$33)))
3997
+ : assign(defaultProps, propName$33));
3998
+ newProps.state = defaultProps;
3770
3999
  }
3771
- else ref.queue = null;
3772
- type = defaultProps.render();
3773
- JSCompiler_inline_result = task.keyPath;
4000
+ else defaultProps.queue = null;
4001
+ type = newProps.render();
4002
+ if (12 === request.status) throw null;
4003
+ props = task.keyPath;
3774
4004
  task.keyPath = keyPath;
3775
4005
  renderNodeDestructive(request, task, type, -1);
3776
- task.keyPath = JSCompiler_inline_result;
3777
- task.componentStack = props;
3778
- } else
3779
- (JSCompiler_inline_result = task.componentStack),
3780
- (task.componentStack = {
3781
- tag: 1,
3782
- parent: task.componentStack,
3783
- type: type
3784
- }),
3785
- (type = renderWithHooks(request, task, keyPath, type, props, void 0)),
3786
- finishFunctionComponent(
3787
- request,
3788
- task,
3789
- keyPath,
3790
- type,
3791
- 0 !== localIdCounter,
3792
- actionStateCounter,
3793
- actionStateMatchingIndex
3794
- ),
3795
- (task.componentStack = JSCompiler_inline_result);
3796
- else if ("string" === typeof type) {
3797
- JSCompiler_inline_result = task.componentStack;
3798
- task.componentStack = createBuiltInComponentStack(task, type);
3799
- defaultProps = task.blockedSegment;
3800
- if (null === defaultProps)
3801
- (defaultProps = props.children),
3802
- (ref = task.formatContext),
3803
- (propName$31 = task.keyPath),
3804
- (task.formatContext = getChildFormatContext(ref, type, props)),
4006
+ task.keyPath = props;
4007
+ } else {
4008
+ type = renderWithHooks(request, task, keyPath, type, props, void 0);
4009
+ if (12 === request.status) throw null;
4010
+ finishFunctionComponent(
4011
+ request,
4012
+ task,
4013
+ keyPath,
4014
+ type,
4015
+ 0 !== localIdCounter,
4016
+ actionStateCounter,
4017
+ actionStateMatchingIndex
4018
+ );
4019
+ }
4020
+ else if ("string" === typeof type)
4021
+ if (((newProps = task.blockedSegment), null === newProps))
4022
+ (newProps = props.children),
4023
+ (defaultProps = task.formatContext),
4024
+ (initialState = task.keyPath),
4025
+ (task.formatContext = getChildFormatContext(defaultProps, type, props)),
3805
4026
  (task.keyPath = keyPath),
3806
- renderNode(request, task, defaultProps, -1),
3807
- (task.formatContext = ref),
3808
- (task.keyPath = propName$31);
4027
+ renderNode(request, task, newProps, -1),
4028
+ (task.formatContext = defaultProps),
4029
+ (task.keyPath = initialState);
3809
4030
  else {
3810
- propName$31 = pushStartInstance(
3811
- defaultProps.chunks,
4031
+ ref = pushStartInstance(
4032
+ newProps.chunks,
3812
4033
  type,
3813
4034
  props,
3814
4035
  request.resumableState,
3815
4036
  request.renderState,
4037
+ task.blockedPreamble,
3816
4038
  task.hoistableState,
3817
4039
  task.formatContext,
3818
- defaultProps.lastPushedText,
4040
+ newProps.lastPushedText,
3819
4041
  task.isFallback
3820
4042
  );
3821
- defaultProps.lastPushedText = !1;
3822
- ref = task.formatContext;
3823
- contextType = task.keyPath;
3824
- task.formatContext = getChildFormatContext(ref, type, props);
4043
+ newProps.lastPushedText = !1;
4044
+ defaultProps = task.formatContext;
4045
+ initialState = task.keyPath;
3825
4046
  task.keyPath = keyPath;
3826
- renderNode(request, task, propName$31, -1);
3827
- task.formatContext = ref;
3828
- task.keyPath = contextType;
4047
+ 3 ===
4048
+ (task.formatContext = getChildFormatContext(defaultProps, type, props))
4049
+ .insertionMode
4050
+ ? ((keyPath = createPendingSegment(
4051
+ request,
4052
+ 0,
4053
+ null,
4054
+ task.formatContext,
4055
+ !1,
4056
+ !1
4057
+ )),
4058
+ newProps.preambleChildren.push(keyPath),
4059
+ (keyPath = createRenderTask(
4060
+ request,
4061
+ null,
4062
+ ref,
4063
+ -1,
4064
+ task.blockedBoundary,
4065
+ keyPath,
4066
+ task.blockedPreamble,
4067
+ task.hoistableState,
4068
+ request.abortableTasks,
4069
+ task.keyPath,
4070
+ task.formatContext,
4071
+ task.context,
4072
+ task.treeContext,
4073
+ task.componentStack,
4074
+ task.isFallback
4075
+ )),
4076
+ pushComponentStack(keyPath),
4077
+ request.pingedTasks.push(keyPath))
4078
+ : renderNode(request, task, ref, -1);
4079
+ task.formatContext = defaultProps;
4080
+ task.keyPath = initialState;
3829
4081
  a: {
3830
- keyPath = defaultProps.chunks;
4082
+ task = newProps.chunks;
3831
4083
  request = request.resumableState;
3832
4084
  switch (type) {
3833
4085
  case "title":
@@ -3850,26 +4102,27 @@ function renderElement(request, task, keyPath, type, props, ref) {
3850
4102
  case "wbr":
3851
4103
  break a;
3852
4104
  case "body":
3853
- if (1 >= ref.insertionMode) {
4105
+ if (1 >= defaultProps.insertionMode) {
3854
4106
  request.hasBody = !0;
3855
4107
  break a;
3856
4108
  }
3857
4109
  break;
3858
4110
  case "html":
3859
- if (0 === ref.insertionMode) {
4111
+ if (0 === defaultProps.insertionMode) {
3860
4112
  request.hasHtml = !0;
3861
4113
  break a;
3862
4114
  }
4115
+ break;
4116
+ case "head":
4117
+ if (1 >= defaultProps.insertionMode) break a;
3863
4118
  }
3864
- keyPath.push(endChunkForTag(type));
4119
+ task.push(endChunkForTag(type));
3865
4120
  }
3866
- defaultProps.lastPushedText = !1;
4121
+ newProps.lastPushedText = !1;
3867
4122
  }
3868
- task.componentStack = JSCompiler_inline_result;
3869
- } else {
4123
+ else {
3870
4124
  switch (type) {
3871
4125
  case REACT_LEGACY_HIDDEN_TYPE:
3872
- case REACT_DEBUG_TRACING_MODE_TYPE:
3873
4126
  case REACT_STRICT_MODE_TYPE:
3874
4127
  case REACT_PROFILER_TYPE:
3875
4128
  case REACT_FRAGMENT_TYPE:
@@ -3878,7 +4131,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
3878
4131
  renderNodeDestructive(request, task, props.children, -1);
3879
4132
  task.keyPath = type;
3880
4133
  return;
3881
- case REACT_OFFSCREEN_TYPE:
4134
+ case REACT_ACTIVITY_TYPE:
3882
4135
  "hidden" !== props.mode &&
3883
4136
  ((type = task.keyPath),
3884
4137
  (task.keyPath = keyPath),
@@ -3886,14 +4139,12 @@ function renderElement(request, task, keyPath, type, props, ref) {
3886
4139
  (task.keyPath = type));
3887
4140
  return;
3888
4141
  case REACT_SUSPENSE_LIST_TYPE:
3889
- type = task.componentStack;
3890
- task.componentStack = createBuiltInComponentStack(task, "SuspenseList");
3891
- JSCompiler_inline_result = task.keyPath;
4142
+ type = task.keyPath;
3892
4143
  task.keyPath = keyPath;
3893
4144
  renderNodeDestructive(request, task, props.children, -1);
3894
- task.keyPath = JSCompiler_inline_result;
3895
- task.componentStack = type;
4145
+ task.keyPath = type;
3896
4146
  return;
4147
+ case REACT_VIEW_TRANSITION_TYPE:
3897
4148
  case REACT_SCOPE_TYPE:
3898
4149
  throw Error("ReactDOMServer does not yet support scope components.");
3899
4150
  case REACT_SUSPENSE_TYPE:
@@ -3907,31 +4158,35 @@ function renderElement(request, task, keyPath, type, props, ref) {
3907
4158
  task.keyPath = type;
3908
4159
  }
3909
4160
  } else {
3910
- var previousComponentStack = task.componentStack;
3911
- type = task.componentStack = createBuiltInComponentStack(
3912
- task,
3913
- "Suspense"
3914
- );
3915
- var prevKeyPath = task.keyPath;
3916
- ref = task.blockedBoundary;
3917
- var parentHoistableState = task.hoistableState,
3918
- parentSegment = task.blockedSegment;
3919
- propName$31 = props.fallback;
3920
- var content = props.children;
3921
- props = new Set();
3922
- contextType = createSuspenseBoundary(request, props);
4161
+ type = task.keyPath;
4162
+ var parentBoundary = task.blockedBoundary;
4163
+ ref = task.blockedPreamble;
4164
+ var parentHoistableState = task.hoistableState;
4165
+ propName$33 = task.blockedSegment;
4166
+ propName = props.fallback;
4167
+ props = props.children;
4168
+ var fallbackAbortSet = new Set();
4169
+ var newBoundary =
4170
+ 2 > task.formatContext.insertionMode
4171
+ ? createSuspenseBoundary(
4172
+ request,
4173
+ fallbackAbortSet,
4174
+ createPreambleState(),
4175
+ createPreambleState()
4176
+ )
4177
+ : createSuspenseBoundary(request, fallbackAbortSet, null, null);
3923
4178
  null !== request.trackedPostpones &&
3924
- (contextType.trackedContentKeyPath = keyPath);
3925
- propName = createPendingSegment(
4179
+ (newBoundary.trackedContentKeyPath = keyPath);
4180
+ var boundarySegment = createPendingSegment(
3926
4181
  request,
3927
- parentSegment.chunks.length,
3928
- contextType,
4182
+ propName$33.chunks.length,
4183
+ newBoundary,
3929
4184
  task.formatContext,
3930
4185
  !1,
3931
4186
  !1
3932
4187
  );
3933
- parentSegment.children.push(propName);
3934
- parentSegment.lastPushedText = !1;
4188
+ propName$33.children.push(boundarySegment);
4189
+ propName$33.lastPushedText = !1;
3935
4190
  var contentRootSegment = createPendingSegment(
3936
4191
  request,
3937
4192
  0,
@@ -3941,108 +4196,138 @@ function renderElement(request, task, keyPath, type, props, ref) {
3941
4196
  !1
3942
4197
  );
3943
4198
  contentRootSegment.parentFlushed = !0;
3944
- task.blockedBoundary = contextType;
3945
- task.hoistableState = contextType.contentState;
3946
- task.blockedSegment = contentRootSegment;
3947
- task.keyPath = keyPath;
3948
- try {
3949
- if (
3950
- (renderNode(request, task, content, -1),
3951
- request.renderState.generateStaticMarkup ||
3952
- (contentRootSegment.lastPushedText &&
3953
- contentRootSegment.textEmbedded &&
3954
- contentRootSegment.chunks.push("\x3c!-- --\x3e")),
3955
- (contentRootSegment.status = 1),
3956
- queueCompletedSegment(contextType, contentRootSegment),
3957
- 0 === contextType.pendingTasks && 0 === contextType.status)
3958
- ) {
3959
- contextType.status = 1;
3960
- task.componentStack = previousComponentStack;
3961
- break a;
4199
+ if (null !== request.trackedPostpones) {
4200
+ newProps = [keyPath[0], "Suspense Fallback", keyPath[2]];
4201
+ defaultProps = [newProps[1], newProps[2], [], null];
4202
+ request.trackedPostpones.workingMap.set(newProps, defaultProps);
4203
+ newBoundary.trackedFallbackNode = defaultProps;
4204
+ task.blockedSegment = boundarySegment;
4205
+ task.blockedPreamble = newBoundary.fallbackPreamble;
4206
+ task.keyPath = newProps;
4207
+ boundarySegment.status = 6;
4208
+ try {
4209
+ renderNode(request, task, propName, -1),
4210
+ pushSegmentFinale(
4211
+ boundarySegment.chunks,
4212
+ request.renderState,
4213
+ boundarySegment.lastPushedText,
4214
+ boundarySegment.textEmbedded
4215
+ ),
4216
+ (boundarySegment.status = 1);
4217
+ } catch (thrownValue) {
4218
+ throw (
4219
+ ((boundarySegment.status = 12 === request.status ? 3 : 4),
4220
+ thrownValue)
4221
+ );
4222
+ } finally {
4223
+ (task.blockedSegment = propName$33),
4224
+ (task.blockedPreamble = ref),
4225
+ (task.keyPath = type);
3962
4226
  }
3963
- } catch (error) {
3964
- (contentRootSegment.status = 4),
3965
- (contextType.status = 4),
3966
- (JSCompiler_inline_result = getThrownInfo(
3967
- request,
3968
- task.componentStack
3969
- )),
3970
- (defaultProps = logRecoverableError(
3971
- request,
3972
- error,
3973
- JSCompiler_inline_result
3974
- )),
3975
- (contextType.errorDigest = defaultProps),
3976
- untrackBoundary(request, contextType);
3977
- } finally {
3978
- (task.blockedBoundary = ref),
3979
- (task.hoistableState = parentHoistableState),
3980
- (task.blockedSegment = parentSegment),
3981
- (task.keyPath = prevKeyPath),
3982
- (task.componentStack = previousComponentStack);
4227
+ task = createRenderTask(
4228
+ request,
4229
+ null,
4230
+ props,
4231
+ -1,
4232
+ newBoundary,
4233
+ contentRootSegment,
4234
+ newBoundary.contentPreamble,
4235
+ newBoundary.contentState,
4236
+ task.abortSet,
4237
+ keyPath,
4238
+ task.formatContext,
4239
+ task.context,
4240
+ task.treeContext,
4241
+ task.componentStack,
4242
+ task.isFallback
4243
+ );
4244
+ pushComponentStack(task);
4245
+ request.pingedTasks.push(task);
4246
+ } else {
4247
+ task.blockedBoundary = newBoundary;
4248
+ task.blockedPreamble = newBoundary.contentPreamble;
4249
+ task.hoistableState = newBoundary.contentState;
4250
+ task.blockedSegment = contentRootSegment;
4251
+ task.keyPath = keyPath;
4252
+ contentRootSegment.status = 6;
4253
+ try {
4254
+ if (
4255
+ (renderNode(request, task, props, -1),
4256
+ pushSegmentFinale(
4257
+ contentRootSegment.chunks,
4258
+ request.renderState,
4259
+ contentRootSegment.lastPushedText,
4260
+ contentRootSegment.textEmbedded
4261
+ ),
4262
+ (contentRootSegment.status = 1),
4263
+ queueCompletedSegment(newBoundary, contentRootSegment),
4264
+ 0 === newBoundary.pendingTasks && 0 === newBoundary.status)
4265
+ ) {
4266
+ newBoundary.status = 1;
4267
+ 0 === request.pendingRootTasks &&
4268
+ task.blockedPreamble &&
4269
+ preparePreamble(request);
4270
+ break a;
4271
+ }
4272
+ } catch (thrownValue$28) {
4273
+ (newBoundary.status = 4),
4274
+ 12 === request.status
4275
+ ? ((contentRootSegment.status = 3),
4276
+ (newProps = request.fatalError))
4277
+ : ((contentRootSegment.status = 4),
4278
+ (newProps = thrownValue$28)),
4279
+ (defaultProps = getThrownInfo(task.componentStack)),
4280
+ (initialState = logRecoverableError(
4281
+ request,
4282
+ newProps,
4283
+ defaultProps
4284
+ )),
4285
+ (newBoundary.errorDigest = initialState),
4286
+ untrackBoundary(request, newBoundary);
4287
+ } finally {
4288
+ (task.blockedBoundary = parentBoundary),
4289
+ (task.blockedPreamble = ref),
4290
+ (task.hoistableState = parentHoistableState),
4291
+ (task.blockedSegment = propName$33),
4292
+ (task.keyPath = type);
4293
+ }
4294
+ task = createRenderTask(
4295
+ request,
4296
+ null,
4297
+ propName,
4298
+ -1,
4299
+ parentBoundary,
4300
+ boundarySegment,
4301
+ newBoundary.fallbackPreamble,
4302
+ newBoundary.fallbackState,
4303
+ fallbackAbortSet,
4304
+ [keyPath[0], "Suspense Fallback", keyPath[2]],
4305
+ task.formatContext,
4306
+ task.context,
4307
+ task.treeContext,
4308
+ task.componentStack,
4309
+ !0
4310
+ );
4311
+ pushComponentStack(task);
4312
+ request.pingedTasks.push(task);
3983
4313
  }
3984
- JSCompiler_inline_result = [
3985
- keyPath[0],
3986
- "Suspense Fallback",
3987
- keyPath[2]
3988
- ];
3989
- defaultProps = request.trackedPostpones;
3990
- null !== defaultProps &&
3991
- ((previousComponentStack = [
3992
- JSCompiler_inline_result[1],
3993
- JSCompiler_inline_result[2],
3994
- [],
3995
- null
3996
- ]),
3997
- defaultProps.workingMap.set(
3998
- JSCompiler_inline_result,
3999
- previousComponentStack
4000
- ),
4001
- 5 === contextType.status
4002
- ? (defaultProps.workingMap.get(keyPath)[4] =
4003
- previousComponentStack)
4004
- : (contextType.trackedFallbackNode = previousComponentStack));
4005
- task = createRenderTask(
4006
- request,
4007
- null,
4008
- propName$31,
4009
- -1,
4010
- ref,
4011
- propName,
4012
- contextType.fallbackState,
4013
- props,
4014
- JSCompiler_inline_result,
4015
- task.formatContext,
4016
- task.legacyContext,
4017
- task.context,
4018
- task.treeContext,
4019
- type,
4020
- !0
4021
- );
4022
- request.pingedTasks.push(task);
4023
4314
  }
4024
4315
  return;
4025
4316
  }
4026
4317
  if ("object" === typeof type && null !== type)
4027
4318
  switch (type.$$typeof) {
4028
4319
  case REACT_FORWARD_REF_TYPE:
4029
- JSCompiler_inline_result = task.componentStack;
4030
- task.componentStack = {
4031
- tag: 1,
4032
- parent: task.componentStack,
4033
- type: type.render
4034
- };
4035
4320
  if ("ref" in props)
4036
- for (contextType in ((defaultProps = {}), props))
4037
- "ref" !== contextType &&
4038
- (defaultProps[contextType] = props[contextType]);
4039
- else defaultProps = props;
4321
+ for (newBoundary in ((newProps = {}), props))
4322
+ "ref" !== newBoundary &&
4323
+ (newProps[newBoundary] = props[newBoundary]);
4324
+ else newProps = props;
4040
4325
  type = renderWithHooks(
4041
4326
  request,
4042
4327
  task,
4043
4328
  keyPath,
4044
4329
  type.render,
4045
- defaultProps,
4330
+ newProps,
4046
4331
  ref
4047
4332
  );
4048
4333
  finishFunctionComponent(
@@ -4054,7 +4339,6 @@ function renderElement(request, task, keyPath, type, props, ref) {
4054
4339
  actionStateCounter,
4055
4340
  actionStateMatchingIndex
4056
4341
  );
4057
- task.componentStack = JSCompiler_inline_result;
4058
4342
  return;
4059
4343
  case REACT_MEMO_TYPE:
4060
4344
  renderElement(request, task, keyPath, type.type, props, ref);
@@ -4062,16 +4346,16 @@ function renderElement(request, task, keyPath, type, props, ref) {
4062
4346
  case REACT_PROVIDER_TYPE:
4063
4347
  case REACT_CONTEXT_TYPE:
4064
4348
  defaultProps = props.children;
4065
- JSCompiler_inline_result = task.keyPath;
4349
+ newProps = task.keyPath;
4066
4350
  props = props.value;
4067
- ref = type._currentValue2;
4351
+ initialState = type._currentValue2;
4068
4352
  type._currentValue2 = props;
4069
- propName$31 = currentActiveSnapshot;
4353
+ ref = currentActiveSnapshot;
4070
4354
  currentActiveSnapshot = type = {
4071
- parent: propName$31,
4072
- depth: null === propName$31 ? 0 : propName$31.depth + 1,
4355
+ parent: ref,
4356
+ depth: null === ref ? 0 : ref.depth + 1,
4073
4357
  context: type,
4074
- parentValue: ref,
4358
+ parentValue: initialState,
4075
4359
  value: props
4076
4360
  };
4077
4361
  task.context = type;
@@ -4085,7 +4369,7 @@ function renderElement(request, task, keyPath, type, props, ref) {
4085
4369
  request.context._currentValue2 = request.parentValue;
4086
4370
  request = currentActiveSnapshot = request.parent;
4087
4371
  task.context = request;
4088
- task.keyPath = JSCompiler_inline_result;
4372
+ task.keyPath = newProps;
4089
4373
  return;
4090
4374
  case REACT_CONSUMER_TYPE:
4091
4375
  props = props.children;
@@ -4096,12 +4380,10 @@ function renderElement(request, task, keyPath, type, props, ref) {
4096
4380
  task.keyPath = props;
4097
4381
  return;
4098
4382
  case REACT_LAZY_TYPE:
4099
- JSCompiler_inline_result = task.componentStack;
4100
- task.componentStack = createBuiltInComponentStack(task, "Lazy");
4101
- defaultProps = type._init;
4102
- type = defaultProps(type._payload);
4103
- renderElement(request, task, keyPath, type, props, void 0);
4104
- task.componentStack = JSCompiler_inline_result;
4383
+ newProps = type._init;
4384
+ type = newProps(type._payload);
4385
+ if (12 === request.status) throw null;
4386
+ renderElement(request, task, keyPath, type, props, ref);
4105
4387
  return;
4106
4388
  }
4107
4389
  throw Error(
@@ -4137,23 +4419,29 @@ function resumeNode(request, task, segmentId, node, childIndex) {
4137
4419
  (task.replay = prevReplay), (task.blockedSegment = null);
4138
4420
  }
4139
4421
  }
4140
- function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4141
- if (null !== task.replay && "number" === typeof task.replay.slots)
4142
- resumeNode(request, task, task.replay.slots, node$jscomp$0, childIndex);
4143
- else if (
4144
- ((task.node = node$jscomp$0),
4145
- (task.childIndex = childIndex),
4146
- null !== node$jscomp$0)
4147
- ) {
4148
- if ("object" === typeof node$jscomp$0) {
4149
- switch (node$jscomp$0.$$typeof) {
4422
+ function renderNodeDestructive(request, task, node, childIndex) {
4423
+ null !== task.replay && "number" === typeof task.replay.slots
4424
+ ? resumeNode(request, task, task.replay.slots, node, childIndex)
4425
+ : ((task.node = node),
4426
+ (task.childIndex = childIndex),
4427
+ (node = task.componentStack),
4428
+ pushComponentStack(task),
4429
+ retryNode(request, task),
4430
+ (task.componentStack = node));
4431
+ }
4432
+ function retryNode(request, task) {
4433
+ var node = task.node,
4434
+ childIndex = task.childIndex;
4435
+ if (null !== node) {
4436
+ if ("object" === typeof node) {
4437
+ switch (node.$$typeof) {
4150
4438
  case REACT_ELEMENT_TYPE:
4151
- var type = node$jscomp$0.type,
4152
- key = node$jscomp$0.key,
4153
- props = node$jscomp$0.props;
4154
- node$jscomp$0 = props.ref;
4155
- var ref = void 0 !== node$jscomp$0 ? node$jscomp$0 : null;
4156
- var name = getComponentNameFromType(type),
4439
+ var type = node.type,
4440
+ key = node.key,
4441
+ props = node.props;
4442
+ node = props.ref;
4443
+ var ref = void 0 !== node ? node : null,
4444
+ name = getComponentNameFromType(type),
4157
4445
  keyOrIndex =
4158
4446
  null == key ? (-1 === childIndex ? 0 : childIndex) : key;
4159
4447
  key = [task.keyPath, name, keyOrIndex];
@@ -4161,24 +4449,20 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4161
4449
  a: {
4162
4450
  var replay = task.replay;
4163
4451
  childIndex = replay.nodes;
4164
- for (
4165
- node$jscomp$0 = 0;
4166
- node$jscomp$0 < childIndex.length;
4167
- node$jscomp$0++
4168
- ) {
4169
- var node = childIndex[node$jscomp$0];
4170
- if (keyOrIndex === node[1]) {
4171
- if (4 === node.length) {
4172
- if (null !== name && name !== node[0])
4452
+ for (node = 0; node < childIndex.length; node++) {
4453
+ var node$jscomp$0 = childIndex[node];
4454
+ if (keyOrIndex === node$jscomp$0[1]) {
4455
+ if (4 === node$jscomp$0.length) {
4456
+ if (null !== name && name !== node$jscomp$0[0])
4173
4457
  throw Error(
4174
4458
  "Expected the resume to render <" +
4175
- node[0] +
4459
+ node$jscomp$0[0] +
4176
4460
  "> in this slot but instead it rendered <" +
4177
4461
  name +
4178
4462
  ">. The tree doesn't match so React will fallback to client rendering."
4179
4463
  );
4180
- var childNodes = node[2];
4181
- name = node[3];
4464
+ var childNodes = node$jscomp$0[2];
4465
+ name = node$jscomp$0[3];
4182
4466
  keyOrIndex = task.node;
4183
4467
  task.replay = {
4184
4468
  nodes: childNodes,
@@ -4207,14 +4491,13 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4207
4491
  x)
4208
4492
  );
4209
4493
  task.replay.pendingTasks--;
4210
- props = getThrownInfo(request, task.componentStack);
4211
- key = request;
4212
- request = task.blockedBoundary;
4494
+ props = getThrownInfo(task.componentStack);
4495
+ key = task.blockedBoundary;
4213
4496
  type = x;
4214
- props = logRecoverableError(key, type, props);
4497
+ props = logRecoverableError(request, type, props);
4215
4498
  abortRemainingReplayNodes(
4216
- key,
4217
4499
  request,
4500
+ key,
4218
4501
  childNodes,
4219
4502
  name,
4220
4503
  type,
@@ -4231,29 +4514,39 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4231
4514
  );
4232
4515
  b: {
4233
4516
  replay = void 0;
4234
- type = node[5];
4235
- ref = node[2];
4236
- name = node[3];
4237
- keyOrIndex = null === node[4] ? [] : node[4][2];
4238
- node = null === node[4] ? null : node[4][3];
4239
- var previousComponentStack = task.componentStack,
4240
- suspenseComponentStack = (task.componentStack =
4241
- createBuiltInComponentStack(task, "Suspense")),
4242
- prevKeyPath = task.keyPath,
4517
+ type = node$jscomp$0[5];
4518
+ ref = node$jscomp$0[2];
4519
+ name = node$jscomp$0[3];
4520
+ keyOrIndex =
4521
+ null === node$jscomp$0[4] ? [] : node$jscomp$0[4][2];
4522
+ node$jscomp$0 =
4523
+ null === node$jscomp$0[4] ? null : node$jscomp$0[4][3];
4524
+ var prevKeyPath = task.keyPath,
4243
4525
  previousReplaySet = task.replay,
4244
4526
  parentBoundary = task.blockedBoundary,
4245
4527
  parentHoistableState = task.hoistableState,
4246
- content = props.children;
4247
- props = props.fallback;
4248
- var fallbackAbortSet = new Set(),
4249
- resumedBoundary = createSuspenseBoundary(
4250
- request,
4251
- fallbackAbortSet
4252
- );
4253
- resumedBoundary.parentFlushed = !0;
4254
- resumedBoundary.rootSegmentID = type;
4255
- task.blockedBoundary = resumedBoundary;
4256
- task.hoistableState = resumedBoundary.contentState;
4528
+ content = props.children,
4529
+ fallback = props.fallback,
4530
+ fallbackAbortSet = new Set();
4531
+ props =
4532
+ 2 > task.formatContext.insertionMode
4533
+ ? createSuspenseBoundary(
4534
+ request,
4535
+ fallbackAbortSet,
4536
+ createPreambleState(),
4537
+ createPreambleState()
4538
+ )
4539
+ : createSuspenseBoundary(
4540
+ request,
4541
+ fallbackAbortSet,
4542
+ null,
4543
+ null
4544
+ );
4545
+ props.parentFlushed = !0;
4546
+ props.rootSegmentID = type;
4547
+ task.blockedBoundary = props;
4548
+ task.hoistableState = props.contentState;
4549
+ task.keyPath = key;
4257
4550
  task.replay = {
4258
4551
  nodes: ref,
4259
4552
  slots: name,
@@ -4269,58 +4562,53 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4269
4562
  "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
4270
4563
  );
4271
4564
  task.replay.pendingTasks--;
4272
- if (
4273
- 0 === resumedBoundary.pendingTasks &&
4274
- 0 === resumedBoundary.status
4275
- ) {
4276
- resumedBoundary.status = 1;
4277
- request.completedBoundaries.push(resumedBoundary);
4565
+ if (0 === props.pendingTasks && 0 === props.status) {
4566
+ props.status = 1;
4567
+ request.completedBoundaries.push(props);
4278
4568
  break b;
4279
4569
  }
4280
4570
  } catch (error) {
4281
- (resumedBoundary.status = 4),
4282
- (childNodes = getThrownInfo(
4283
- request,
4284
- task.componentStack
4285
- )),
4571
+ (props.status = 4),
4572
+ (childNodes = getThrownInfo(task.componentStack)),
4286
4573
  (replay = logRecoverableError(
4287
4574
  request,
4288
4575
  error,
4289
4576
  childNodes
4290
4577
  )),
4291
- (resumedBoundary.errorDigest = replay),
4578
+ (props.errorDigest = replay),
4292
4579
  task.replay.pendingTasks--,
4293
- request.clientRenderedBoundaries.push(
4294
- resumedBoundary
4295
- );
4580
+ request.clientRenderedBoundaries.push(props);
4296
4581
  } finally {
4297
4582
  (task.blockedBoundary = parentBoundary),
4298
4583
  (task.hoistableState = parentHoistableState),
4299
4584
  (task.replay = previousReplaySet),
4300
- (task.keyPath = prevKeyPath),
4301
- (task.componentStack = previousComponentStack);
4585
+ (task.keyPath = prevKeyPath);
4302
4586
  }
4303
4587
  task = createReplayTask(
4304
4588
  request,
4305
4589
  null,
4306
- { nodes: keyOrIndex, slots: node, pendingTasks: 0 },
4307
- props,
4590
+ {
4591
+ nodes: keyOrIndex,
4592
+ slots: node$jscomp$0,
4593
+ pendingTasks: 0
4594
+ },
4595
+ fallback,
4308
4596
  -1,
4309
4597
  parentBoundary,
4310
- resumedBoundary.fallbackState,
4598
+ props.fallbackState,
4311
4599
  fallbackAbortSet,
4312
4600
  [key[0], "Suspense Fallback", key[2]],
4313
4601
  task.formatContext,
4314
- task.legacyContext,
4315
4602
  task.context,
4316
4603
  task.treeContext,
4317
- suspenseComponentStack,
4604
+ task.componentStack,
4318
4605
  !0
4319
4606
  );
4607
+ pushComponentStack(task);
4320
4608
  request.pingedTasks.push(task);
4321
4609
  }
4322
4610
  }
4323
- childIndex.splice(node$jscomp$0, 1);
4611
+ childIndex.splice(node, 1);
4324
4612
  break a;
4325
4613
  }
4326
4614
  }
@@ -4332,80 +4620,68 @@ function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
4332
4620
  "Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render."
4333
4621
  );
4334
4622
  case REACT_LAZY_TYPE:
4335
- childNodes = task.componentStack;
4336
- task.componentStack = createBuiltInComponentStack(task, "Lazy");
4337
- props = node$jscomp$0._init;
4338
- node$jscomp$0 = props(node$jscomp$0._payload);
4339
- task.componentStack = childNodes;
4340
- renderNodeDestructive(request, task, node$jscomp$0, childIndex);
4623
+ childNodes = node._init;
4624
+ node = childNodes(node._payload);
4625
+ if (12 === request.status) throw null;
4626
+ renderNodeDestructive(request, task, node, childIndex);
4341
4627
  return;
4342
4628
  }
4343
- if (isArrayImpl(node$jscomp$0)) {
4344
- renderChildrenArray(request, task, node$jscomp$0, childIndex);
4629
+ if (isArrayImpl(node)) {
4630
+ renderChildrenArray(request, task, node, childIndex);
4345
4631
  return;
4346
4632
  }
4347
- null === node$jscomp$0 || "object" !== typeof node$jscomp$0
4633
+ null === node || "object" !== typeof node
4348
4634
  ? (childNodes = null)
4349
4635
  : ((childNodes =
4350
- (MAYBE_ITERATOR_SYMBOL && node$jscomp$0[MAYBE_ITERATOR_SYMBOL]) ||
4351
- node$jscomp$0["@@iterator"]),
4636
+ (MAYBE_ITERATOR_SYMBOL && node[MAYBE_ITERATOR_SYMBOL]) ||
4637
+ node["@@iterator"]),
4352
4638
  (childNodes = "function" === typeof childNodes ? childNodes : null));
4353
- if (childNodes && (childNodes = childNodes.call(node$jscomp$0))) {
4354
- node$jscomp$0 = childNodes.next();
4355
- if (!node$jscomp$0.done) {
4639
+ if (childNodes && (childNodes = childNodes.call(node))) {
4640
+ node = childNodes.next();
4641
+ if (!node.done) {
4356
4642
  props = [];
4357
- do
4358
- props.push(node$jscomp$0.value),
4359
- (node$jscomp$0 = childNodes.next());
4360
- while (!node$jscomp$0.done);
4643
+ do props.push(node.value), (node = childNodes.next());
4644
+ while (!node.done);
4361
4645
  renderChildrenArray(request, task, props, childIndex);
4362
4646
  }
4363
4647
  return;
4364
4648
  }
4365
- if ("function" === typeof node$jscomp$0.then)
4649
+ if ("function" === typeof node.then)
4366
4650
  return (
4367
4651
  (task.thenableState = null),
4368
- renderNodeDestructive(
4369
- request,
4370
- task,
4371
- unwrapThenable(node$jscomp$0),
4372
- childIndex
4373
- )
4652
+ renderNodeDestructive(request, task, unwrapThenable(node), childIndex)
4374
4653
  );
4375
- if (node$jscomp$0.$$typeof === REACT_CONTEXT_TYPE)
4654
+ if (node.$$typeof === REACT_CONTEXT_TYPE)
4376
4655
  return renderNodeDestructive(
4377
4656
  request,
4378
4657
  task,
4379
- node$jscomp$0._currentValue2,
4658
+ node._currentValue2,
4380
4659
  childIndex
4381
4660
  );
4382
- childIndex = Object.prototype.toString.call(node$jscomp$0);
4661
+ childIndex = Object.prototype.toString.call(node);
4383
4662
  throw Error(
4384
4663
  "Objects are not valid as a React child (found: " +
4385
4664
  ("[object Object]" === childIndex
4386
- ? "object with keys {" + Object.keys(node$jscomp$0).join(", ") + "}"
4665
+ ? "object with keys {" + Object.keys(node).join(", ") + "}"
4387
4666
  : childIndex) +
4388
4667
  "). If you meant to render a collection of children, use an array instead."
4389
4668
  );
4390
4669
  }
4391
- if ("string" === typeof node$jscomp$0)
4670
+ if ("string" === typeof node)
4392
4671
  (childIndex = task.blockedSegment),
4393
4672
  null !== childIndex &&
4394
4673
  (childIndex.lastPushedText = pushTextInstance(
4395
4674
  childIndex.chunks,
4396
- node$jscomp$0,
4675
+ node,
4397
4676
  request.renderState,
4398
4677
  childIndex.lastPushedText
4399
4678
  ));
4400
- else if (
4401
- "number" === typeof node$jscomp$0 ||
4402
- "bigint" === typeof node$jscomp$0
4403
- )
4679
+ else if ("number" === typeof node || "bigint" === typeof node)
4404
4680
  (childIndex = task.blockedSegment),
4405
4681
  null !== childIndex &&
4406
4682
  (childIndex.lastPushedText = pushTextInstance(
4407
4683
  childIndex.chunks,
4408
- "" + node$jscomp$0,
4684
+ "" + node,
4409
4685
  request.renderState,
4410
4686
  childIndex.lastPushedText
4411
4687
  ));
@@ -4443,7 +4719,7 @@ function renderChildrenArray(request, task, children, childIndex) {
4443
4719
  )
4444
4720
  throw x;
4445
4721
  task.replay.pendingTasks--;
4446
- children = getThrownInfo(request, task.componentStack);
4722
+ children = getThrownInfo(task.componentStack);
4447
4723
  var boundary = task.blockedBoundary,
4448
4724
  error = x;
4449
4725
  children = logRecoverableError(request, error, children);
@@ -4498,9 +4774,56 @@ function untrackBoundary(request, boundary) {
4498
4774
  void 0 !== boundary &&
4499
4775
  ((boundary.length = 4), (boundary[2] = []), (boundary[3] = null))));
4500
4776
  }
4777
+ function spawnNewSuspendedReplayTask(request, task, thenableState) {
4778
+ return createReplayTask(
4779
+ request,
4780
+ thenableState,
4781
+ task.replay,
4782
+ task.node,
4783
+ task.childIndex,
4784
+ task.blockedBoundary,
4785
+ task.hoistableState,
4786
+ task.abortSet,
4787
+ task.keyPath,
4788
+ task.formatContext,
4789
+ task.context,
4790
+ task.treeContext,
4791
+ task.componentStack,
4792
+ task.isFallback
4793
+ );
4794
+ }
4795
+ function spawnNewSuspendedRenderTask(request, task, thenableState) {
4796
+ var segment = task.blockedSegment,
4797
+ newSegment = createPendingSegment(
4798
+ request,
4799
+ segment.chunks.length,
4800
+ null,
4801
+ task.formatContext,
4802
+ segment.lastPushedText,
4803
+ !0
4804
+ );
4805
+ segment.children.push(newSegment);
4806
+ segment.lastPushedText = !1;
4807
+ return createRenderTask(
4808
+ request,
4809
+ thenableState,
4810
+ task.node,
4811
+ task.childIndex,
4812
+ task.blockedBoundary,
4813
+ newSegment,
4814
+ task.blockedPreamble,
4815
+ task.hoistableState,
4816
+ task.abortSet,
4817
+ task.keyPath,
4818
+ task.formatContext,
4819
+ task.context,
4820
+ task.treeContext,
4821
+ task.componentStack,
4822
+ task.isFallback
4823
+ );
4824
+ }
4501
4825
  function renderNode(request, task, node, childIndex) {
4502
4826
  var previousFormatContext = task.formatContext,
4503
- previousLegacyContext = task.legacyContext,
4504
4827
  previousContext = task.context,
4505
4828
  previousKeyPath = task.keyPath,
4506
4829
  previousTreeContext = task.treeContext,
@@ -4516,37 +4839,32 @@ function renderNode(request, task, node, childIndex) {
4516
4839
  thrownValue === SuspenseException
4517
4840
  ? getSuspendedThenable()
4518
4841
  : thrownValue),
4519
- "object" === typeof node &&
4520
- null !== node &&
4521
- "function" === typeof node.then)
4842
+ "object" === typeof node && null !== node)
4522
4843
  ) {
4523
- childIndex = getThenableStateAfterSuspending();
4524
- request = createReplayTask(
4525
- request,
4526
- childIndex,
4527
- task.replay,
4528
- task.node,
4529
- task.childIndex,
4530
- task.blockedBoundary,
4531
- task.hoistableState,
4532
- task.abortSet,
4533
- task.keyPath,
4534
- task.formatContext,
4535
- task.legacyContext,
4536
- task.context,
4537
- task.treeContext,
4538
- null !== task.componentStack ? task.componentStack.parent : null,
4539
- task.isFallback
4540
- ).ping;
4541
- node.then(request, request);
4542
- task.formatContext = previousFormatContext;
4543
- task.legacyContext = previousLegacyContext;
4544
- task.context = previousContext;
4545
- task.keyPath = previousKeyPath;
4546
- task.treeContext = previousTreeContext;
4547
- task.componentStack = previousComponentStack;
4548
- switchContext(previousContext);
4549
- return;
4844
+ if ("function" === typeof node.then) {
4845
+ childIndex = getThenableStateAfterSuspending();
4846
+ request = spawnNewSuspendedReplayTask(request, task, childIndex).ping;
4847
+ node.then(request, request);
4848
+ task.formatContext = previousFormatContext;
4849
+ task.context = previousContext;
4850
+ task.keyPath = previousKeyPath;
4851
+ task.treeContext = previousTreeContext;
4852
+ task.componentStack = previousComponentStack;
4853
+ switchContext(previousContext);
4854
+ return;
4855
+ }
4856
+ if ("Maximum call stack size exceeded" === node.message) {
4857
+ node = getThenableStateAfterSuspending();
4858
+ node = spawnNewSuspendedReplayTask(request, task, node);
4859
+ request.pingedTasks.push(node);
4860
+ task.formatContext = previousFormatContext;
4861
+ task.context = previousContext;
4862
+ task.keyPath = previousKeyPath;
4863
+ task.treeContext = previousTreeContext;
4864
+ task.componentStack = previousComponentStack;
4865
+ switchContext(previousContext);
4866
+ return;
4867
+ }
4550
4868
  }
4551
4869
  }
4552
4870
  else {
@@ -4554,62 +4872,45 @@ function renderNode(request, task, node, childIndex) {
4554
4872
  chunkLength = segment.chunks.length;
4555
4873
  try {
4556
4874
  return renderNodeDestructive(request, task, node, childIndex);
4557
- } catch (thrownValue$40) {
4875
+ } catch (thrownValue$48) {
4558
4876
  if (
4559
4877
  (resetHooksState(),
4560
4878
  (segment.children.length = childrenLength),
4561
4879
  (segment.chunks.length = chunkLength),
4562
4880
  (node =
4563
- thrownValue$40 === SuspenseException
4881
+ thrownValue$48 === SuspenseException
4564
4882
  ? getSuspendedThenable()
4565
- : thrownValue$40),
4566
- "object" === typeof node &&
4567
- null !== node &&
4568
- "function" === typeof node.then)
4883
+ : thrownValue$48),
4884
+ "object" === typeof node && null !== node)
4569
4885
  ) {
4570
- childIndex = getThenableStateAfterSuspending();
4571
- segment = task.blockedSegment;
4572
- childrenLength = createPendingSegment(
4573
- request,
4574
- segment.chunks.length,
4575
- null,
4576
- task.formatContext,
4577
- segment.lastPushedText,
4578
- !0
4579
- );
4580
- segment.children.push(childrenLength);
4581
- segment.lastPushedText = !1;
4582
- request = createRenderTask(
4583
- request,
4584
- childIndex,
4585
- task.node,
4586
- task.childIndex,
4587
- task.blockedBoundary,
4588
- childrenLength,
4589
- task.hoistableState,
4590
- task.abortSet,
4591
- task.keyPath,
4592
- task.formatContext,
4593
- task.legacyContext,
4594
- task.context,
4595
- task.treeContext,
4596
- null !== task.componentStack ? task.componentStack.parent : null,
4597
- task.isFallback
4598
- ).ping;
4599
- node.then(request, request);
4600
- task.formatContext = previousFormatContext;
4601
- task.legacyContext = previousLegacyContext;
4602
- task.context = previousContext;
4603
- task.keyPath = previousKeyPath;
4604
- task.treeContext = previousTreeContext;
4605
- task.componentStack = previousComponentStack;
4606
- switchContext(previousContext);
4607
- return;
4886
+ if ("function" === typeof node.then) {
4887
+ childIndex = getThenableStateAfterSuspending();
4888
+ request = spawnNewSuspendedRenderTask(request, task, childIndex).ping;
4889
+ node.then(request, request);
4890
+ task.formatContext = previousFormatContext;
4891
+ task.context = previousContext;
4892
+ task.keyPath = previousKeyPath;
4893
+ task.treeContext = previousTreeContext;
4894
+ task.componentStack = previousComponentStack;
4895
+ switchContext(previousContext);
4896
+ return;
4897
+ }
4898
+ if ("Maximum call stack size exceeded" === node.message) {
4899
+ node = getThenableStateAfterSuspending();
4900
+ node = spawnNewSuspendedRenderTask(request, task, node);
4901
+ request.pingedTasks.push(node);
4902
+ task.formatContext = previousFormatContext;
4903
+ task.context = previousContext;
4904
+ task.keyPath = previousKeyPath;
4905
+ task.treeContext = previousTreeContext;
4906
+ task.componentStack = previousComponentStack;
4907
+ switchContext(previousContext);
4908
+ return;
4909
+ }
4608
4910
  }
4609
4911
  }
4610
4912
  }
4611
4913
  task.formatContext = previousFormatContext;
4612
- task.legacyContext = previousLegacyContext;
4613
4914
  task.context = previousContext;
4614
4915
  task.keyPath = previousKeyPath;
4615
4916
  task.treeContext = previousTreeContext;
@@ -4644,7 +4945,12 @@ function abortRemainingReplayNodes(
4644
4945
  node = node[5];
4645
4946
  var request = request$jscomp$0,
4646
4947
  errorDigest = errorDigest$jscomp$0,
4647
- resumedBoundary = createSuspenseBoundary(request, new Set());
4948
+ resumedBoundary = createSuspenseBoundary(
4949
+ request,
4950
+ new Set(),
4951
+ null,
4952
+ null
4953
+ );
4648
4954
  resumedBoundary.parentFlushed = !0;
4649
4955
  resumedBoundary.rootSegmentID = node;
4650
4956
  resumedBoundary.status = 4;
@@ -4670,26 +4976,30 @@ function abortRemainingReplayNodes(
4670
4976
  function abortTask(task, request, error) {
4671
4977
  var boundary = task.blockedBoundary,
4672
4978
  segment = task.blockedSegment;
4673
- null !== segment && (segment.status = 3);
4979
+ if (null !== segment) {
4980
+ if (6 === segment.status) return;
4981
+ segment.status = 3;
4982
+ }
4983
+ segment = getThrownInfo(task.componentStack);
4674
4984
  if (null === boundary) {
4675
- if (((boundary = {}), 1 !== request.status && 2 !== request.status)) {
4676
- task = task.replay;
4677
- if (null === task) {
4678
- logRecoverableError(request, error, boundary);
4985
+ if (13 !== request.status && 14 !== request.status) {
4986
+ boundary = task.replay;
4987
+ if (null === boundary) {
4988
+ logRecoverableError(request, error, segment);
4679
4989
  fatalError(request, error);
4680
4990
  return;
4681
4991
  }
4682
- task.pendingTasks--;
4683
- 0 === task.pendingTasks &&
4684
- 0 < task.nodes.length &&
4685
- ((boundary = logRecoverableError(request, error, boundary)),
4992
+ boundary.pendingTasks--;
4993
+ 0 === boundary.pendingTasks &&
4994
+ 0 < boundary.nodes.length &&
4995
+ ((task = logRecoverableError(request, error, segment)),
4686
4996
  abortRemainingReplayNodes(
4687
4997
  request,
4688
4998
  null,
4689
- task.nodes,
4690
- task.slots,
4999
+ boundary.nodes,
5000
+ boundary.slots,
4691
5001
  error,
4692
- boundary
5002
+ task
4693
5003
  ));
4694
5004
  request.pendingRootTasks--;
4695
5005
  0 === request.pendingRootTasks && completeShell(request);
@@ -4698,8 +5008,8 @@ function abortTask(task, request, error) {
4698
5008
  boundary.pendingTasks--,
4699
5009
  4 !== boundary.status &&
4700
5010
  ((boundary.status = 4),
4701
- (task = getThrownInfo(request, task.componentStack)),
4702
- (task = logRecoverableError(request, error, task)),
5011
+ (task = logRecoverableError(request, error, segment)),
5012
+ (boundary.status = 4),
4703
5013
  (boundary.errorDigest = task),
4704
5014
  untrackBoundary(request, boundary),
4705
5015
  boundary.parentFlushed &&
@@ -4753,7 +5063,7 @@ function safelyEmitEarlyPreloads(request, shellComplete) {
4753
5063
  referrerPolicy: props$jscomp$0.referrerPolicy,
4754
5064
  media: props$jscomp$0.media
4755
5065
  });
4756
- if (2 <= (headers.remainingCapacity -= header.length))
5066
+ if (0 <= (headers.remainingCapacity -= header.length + 2))
4757
5067
  (renderState.resets.style[key] = PRELOAD_NO_CREDS),
4758
5068
  linkHeader && (linkHeader += ", "),
4759
5069
  (linkHeader += header),
@@ -4774,6 +5084,7 @@ function safelyEmitEarlyPreloads(request, shellComplete) {
4774
5084
  }
4775
5085
  function completeShell(request) {
4776
5086
  null === request.trackedPostpones && safelyEmitEarlyPreloads(request, !0);
5087
+ null === request.trackedPostpones && preparePreamble(request);
4777
5088
  request.onShellError = noop;
4778
5089
  request = request.onShellReady;
4779
5090
  request();
@@ -4786,6 +5097,7 @@ function completeAll(request) {
4786
5097
  : null === request.completedRootSegment ||
4787
5098
  5 !== request.completedRootSegment.status
4788
5099
  );
5100
+ preparePreamble(request);
4789
5101
  request = request.onAllReady;
4790
5102
  request();
4791
5103
  }
@@ -4826,7 +5138,11 @@ function finishedTask(request, boundary, segment) {
4826
5138
  request.completedBoundaries.push(boundary),
4827
5139
  1 === boundary.status &&
4828
5140
  (boundary.fallbackAbortableTasks.forEach(abortTaskSoft, request),
4829
- boundary.fallbackAbortableTasks.clear()))
5141
+ boundary.fallbackAbortableTasks.clear(),
5142
+ 0 === request.pendingRootTasks &&
5143
+ null === request.trackedPostpones &&
5144
+ null !== boundary.contentPreamble &&
5145
+ preparePreamble(request)))
4830
5146
  : null !== segment &&
4831
5147
  segment.parentFlushed &&
4832
5148
  1 === segment.status &&
@@ -4838,7 +5154,7 @@ function finishedTask(request, boundary, segment) {
4838
5154
  0 === request.allPendingTasks && completeAll(request);
4839
5155
  }
4840
5156
  function performWork(request$jscomp$2) {
4841
- if (2 !== request$jscomp$2.status) {
5157
+ if (14 !== request$jscomp$2.status && 13 !== request$jscomp$2.status) {
4842
5158
  var prevContext = currentActiveSnapshot,
4843
5159
  prevDispatcher = ReactSharedInternals.H;
4844
5160
  ReactSharedInternals.H = HooksDispatcher;
@@ -4860,12 +5176,15 @@ function performWork(request$jscomp$2) {
4860
5176
  if (0 !== task.replay.pendingTasks) {
4861
5177
  switchContext(task.context);
4862
5178
  try {
4863
- renderNodeDestructive(
4864
- request$jscomp$0,
4865
- task,
4866
- task.node,
4867
- task.childIndex
4868
- );
5179
+ "number" === typeof task.replay.slots
5180
+ ? resumeNode(
5181
+ request$jscomp$0,
5182
+ task,
5183
+ task.replay.slots,
5184
+ task.node,
5185
+ task.childIndex
5186
+ )
5187
+ : retryNode(request$jscomp$0, task);
4869
5188
  if (
4870
5189
  1 === task.replay.pendingTasks &&
4871
5190
  0 < task.replay.nodes.length
@@ -4890,19 +5209,17 @@ function performWork(request$jscomp$2) {
4890
5209
  var ping = task.ping;
4891
5210
  x.then(ping, ping);
4892
5211
  task.thenableState = getThenableStateAfterSuspending();
4893
- null !== task.componentStack &&
4894
- (task.componentStack = task.componentStack.parent);
4895
5212
  } else {
4896
5213
  task.replay.pendingTasks--;
4897
5214
  task.abortSet.delete(task);
4898
- var errorInfo = getThrownInfo(
4899
- request$jscomp$0,
4900
- task.componentStack
4901
- );
5215
+ var errorInfo = getThrownInfo(task.componentStack);
4902
5216
  request = void 0;
4903
5217
  var request$jscomp$1 = request$jscomp$0,
4904
5218
  boundary = task.blockedBoundary,
4905
- error$jscomp$0 = x,
5219
+ error$jscomp$0 =
5220
+ 12 === request$jscomp$0.status
5221
+ ? request$jscomp$0.fatalError
5222
+ : x,
4906
5223
  replayNodes = task.replay.nodes,
4907
5224
  resumeSlots = task.replay.slots;
4908
5225
  request = logRecoverableError(
@@ -4933,15 +5250,18 @@ function performWork(request$jscomp$2) {
4933
5250
  (request$jscomp$1 = segment),
4934
5251
  0 === request$jscomp$1.status)
4935
5252
  ) {
5253
+ request$jscomp$1.status = 6;
4936
5254
  switchContext(task.context);
4937
5255
  var childrenLength = request$jscomp$1.children.length,
4938
5256
  chunkLength = request$jscomp$1.chunks.length;
4939
5257
  try {
4940
- renderNodeDestructive(request, task, task.node, task.childIndex),
4941
- request.renderState.generateStaticMarkup ||
4942
- (request$jscomp$1.lastPushedText &&
4943
- request$jscomp$1.textEmbedded &&
4944
- request$jscomp$1.chunks.push("\x3c!-- --\x3e")),
5258
+ retryNode(request, task),
5259
+ pushSegmentFinale(
5260
+ request$jscomp$1.chunks,
5261
+ request.renderState,
5262
+ request$jscomp$1.lastPushedText,
5263
+ request$jscomp$1.textEmbedded
5264
+ ),
4945
5265
  task.abortSet.delete(task),
4946
5266
  (request$jscomp$1.status = 1),
4947
5267
  finishedTask(request, task.blockedBoundary, request$jscomp$1);
@@ -4952,22 +5272,20 @@ function performWork(request$jscomp$2) {
4952
5272
  var x$jscomp$0 =
4953
5273
  thrownValue === SuspenseException
4954
5274
  ? getSuspendedThenable()
4955
- : thrownValue;
5275
+ : 12 === request.status
5276
+ ? request.fatalError
5277
+ : thrownValue;
4956
5278
  if (
4957
5279
  "object" === typeof x$jscomp$0 &&
4958
5280
  null !== x$jscomp$0 &&
4959
5281
  "function" === typeof x$jscomp$0.then
4960
5282
  ) {
5283
+ request$jscomp$1.status = 0;
5284
+ task.thenableState = getThenableStateAfterSuspending();
4961
5285
  var ping$jscomp$0 = task.ping;
4962
5286
  x$jscomp$0.then(ping$jscomp$0, ping$jscomp$0);
4963
- task.thenableState = getThenableStateAfterSuspending();
4964
- null !== task.componentStack &&
4965
- (task.componentStack = task.componentStack.parent);
4966
5287
  } else {
4967
- var errorInfo$jscomp$0 = getThrownInfo(
4968
- request,
4969
- task.componentStack
4970
- );
5288
+ var errorInfo$jscomp$0 = getThrownInfo(task.componentStack);
4971
5289
  task.abortSet.delete(task);
4972
5290
  request$jscomp$1.status = 4;
4973
5291
  var boundary$jscomp$0 = task.blockedBoundary;
@@ -4984,9 +5302,11 @@ function performWork(request$jscomp$2) {
4984
5302
  (boundary$jscomp$0.errorDigest = request$jscomp$0),
4985
5303
  untrackBoundary(request, boundary$jscomp$0),
4986
5304
  boundary$jscomp$0.parentFlushed &&
4987
- request.clientRenderedBoundaries.push(
4988
- boundary$jscomp$0
4989
- )));
5305
+ request.clientRenderedBoundaries.push(boundary$jscomp$0),
5306
+ 0 === request.pendingRootTasks &&
5307
+ null === request.trackedPostpones &&
5308
+ null !== boundary$jscomp$0.contentPreamble &&
5309
+ preparePreamble(request)));
4990
5310
  request.allPendingTasks--;
4991
5311
  0 === request.allPendingTasks && completeAll(request);
4992
5312
  }
@@ -5009,6 +5329,85 @@ function performWork(request$jscomp$2) {
5009
5329
  }
5010
5330
  }
5011
5331
  }
5332
+ function preparePreambleFromSubtree(
5333
+ request,
5334
+ segment,
5335
+ collectedPreambleSegments
5336
+ ) {
5337
+ segment.preambleChildren.length &&
5338
+ collectedPreambleSegments.push(segment.preambleChildren);
5339
+ for (var pendingPreambles = !1, i = 0; i < segment.children.length; i++)
5340
+ pendingPreambles =
5341
+ preparePreambleFromSegment(
5342
+ request,
5343
+ segment.children[i],
5344
+ collectedPreambleSegments
5345
+ ) || pendingPreambles;
5346
+ return pendingPreambles;
5347
+ }
5348
+ function preparePreambleFromSegment(
5349
+ request,
5350
+ segment,
5351
+ collectedPreambleSegments
5352
+ ) {
5353
+ var boundary = segment.boundary;
5354
+ if (null === boundary)
5355
+ return preparePreambleFromSubtree(
5356
+ request,
5357
+ segment,
5358
+ collectedPreambleSegments
5359
+ );
5360
+ var preamble = boundary.contentPreamble,
5361
+ fallbackPreamble = boundary.fallbackPreamble;
5362
+ if (null === preamble || null === fallbackPreamble) return !1;
5363
+ switch (boundary.status) {
5364
+ case 1:
5365
+ hoistPreambleState(request.renderState, preamble);
5366
+ segment = boundary.completedSegments[0];
5367
+ if (!segment)
5368
+ throw Error(
5369
+ "A previously unvisited boundary must have exactly one root segment. This is a bug in React."
5370
+ );
5371
+ return preparePreambleFromSubtree(
5372
+ request,
5373
+ segment,
5374
+ collectedPreambleSegments
5375
+ );
5376
+ case 5:
5377
+ if (null !== request.trackedPostpones) return !0;
5378
+ case 4:
5379
+ if (1 === segment.status)
5380
+ return (
5381
+ hoistPreambleState(request.renderState, fallbackPreamble),
5382
+ preparePreambleFromSubtree(
5383
+ request,
5384
+ segment,
5385
+ collectedPreambleSegments
5386
+ )
5387
+ );
5388
+ default:
5389
+ return !0;
5390
+ }
5391
+ }
5392
+ function preparePreamble(request) {
5393
+ if (
5394
+ request.completedRootSegment &&
5395
+ null === request.completedPreambleSegments
5396
+ ) {
5397
+ var collectedPreambleSegments = [],
5398
+ hasPendingPreambles = preparePreambleFromSegment(
5399
+ request,
5400
+ request.completedRootSegment,
5401
+ collectedPreambleSegments
5402
+ ),
5403
+ preamble = request.renderState.preamble;
5404
+ if (
5405
+ !1 === hasPendingPreambles ||
5406
+ (preamble.headChunks && preamble.bodyChunks)
5407
+ )
5408
+ request.completedPreambleSegments = collectedPreambleSegments;
5409
+ }
5410
+ }
5012
5411
  function flushSubtree(request, destination, segment, hoistableState) {
5013
5412
  segment.parentFlushed = !0;
5014
5413
  switch (segment.status) {
@@ -5052,24 +5451,26 @@ function flushSegment(request, destination, segment, hoistableState) {
5052
5451
  if (null === boundary)
5053
5452
  return flushSubtree(request, destination, segment, hoistableState);
5054
5453
  boundary.parentFlushed = !0;
5055
- if (4 === boundary.status)
5056
- return (
5057
- request.renderState.generateStaticMarkup ||
5058
- ((boundary = boundary.errorDigest),
5059
- destination.push("\x3c!--$!--\x3e"),
5060
- destination.push("<template"),
5061
- boundary &&
5062
- (destination.push(' data-dgst="'),
5063
- (boundary = escapeTextForBrowser(boundary)),
5064
- destination.push(boundary),
5065
- destination.push('"')),
5066
- destination.push("></template>")),
5067
- flushSubtree(request, destination, segment, hoistableState),
5068
- (request = request.renderState.generateStaticMarkup
5069
- ? !0
5070
- : destination.push("\x3c!--/$--\x3e")),
5071
- request
5072
- );
5454
+ if (4 === boundary.status) {
5455
+ if (!request.renderState.generateStaticMarkup) {
5456
+ var errorDigest = boundary.errorDigest;
5457
+ destination.push("\x3c!--$!--\x3e");
5458
+ destination.push("<template");
5459
+ errorDigest &&
5460
+ (destination.push(' data-dgst="'),
5461
+ (errorDigest = escapeTextForBrowser(errorDigest)),
5462
+ destination.push(errorDigest),
5463
+ destination.push('"'));
5464
+ destination.push("></template>");
5465
+ }
5466
+ flushSubtree(request, destination, segment, hoistableState);
5467
+ request.renderState.generateStaticMarkup
5468
+ ? (destination = !0)
5469
+ : ((request = boundary.fallbackPreamble) &&
5470
+ writePreambleContribution(destination, request),
5471
+ (destination = destination.push("\x3c!--/$--\x3e")));
5472
+ return destination;
5473
+ }
5073
5474
  if (1 !== boundary.status)
5074
5475
  return (
5075
5476
  0 === boundary.status &&
@@ -5115,10 +5516,12 @@ function flushSegment(request, destination, segment, hoistableState) {
5115
5516
  "A previously unvisited boundary must have exactly one root segment. This is a bug in React."
5116
5517
  );
5117
5518
  flushSegment(request, destination, segment[0], hoistableState);
5118
- request = request.renderState.generateStaticMarkup
5119
- ? !0
5120
- : destination.push("\x3c!--/$--\x3e");
5121
- return request;
5519
+ request.renderState.generateStaticMarkup
5520
+ ? (destination = !0)
5521
+ : ((request = boundary.contentPreamble) &&
5522
+ writePreambleContribution(destination, request),
5523
+ (destination = destination.push("\x3c!--/$--\x3e")));
5524
+ return destination;
5122
5525
  }
5123
5526
  function flushSegmentContainer(request, destination, segment, hoistableState) {
5124
5527
  writeStartSegment(
@@ -5159,20 +5562,20 @@ function flushCompletedBoundary(request, destination, boundary) {
5159
5562
  ? 0 === (completedSegments.instructions & 2)
5160
5563
  ? ((completedSegments.instructions |= 10),
5161
5564
  destination.push(
5162
- '$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(r,t,w){for(var u=$RC,n=$RM,p=new Map,q=document,g,b,h=q.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&n.set(b.getAttribute("href"),b),p.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var f=w[b++];if(!f){k=!1;b=0;continue}var c=!1,m=0;var d=f[m++];if(a=n.get(d)){var e=a._p;c=!0}else{a=q.createElement("link");a.href=d;a.rel="stylesheet";for(a.dataset.precedence=\nl=f[m++];e=f[m++];)a.setAttribute(e,f[m++]);e=a._p=new Promise(function(x,y){a.onload=x;a.onerror=y});n.set(d,a)}d=a.getAttribute("media");!e||"l"===e.s||d&&!matchMedia(d).matches||h.push(e);if(c)continue}else{a=v[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=p.get(l)||g;c===g&&(g=a);p.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=q.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(u.bind(null,r,t,""),u.bind(null,r,t,"Resource failed to load"))};$RR("'
5565
+ '$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("'
5163
5566
  ))
5164
5567
  : 0 === (completedSegments.instructions & 8)
5165
- ? ((completedSegments.instructions |= 8),
5568
+ ? ((completedSegments.instructions |= 8),
5569
+ destination.push(
5570
+ '$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("'
5571
+ ))
5572
+ : destination.push('$RR("')
5573
+ : 0 === (completedSegments.instructions & 2)
5574
+ ? ((completedSegments.instructions |= 2),
5166
5575
  destination.push(
5167
- '$RM=new Map;\n$RR=function(r,t,w){for(var u=$RC,n=$RM,p=new Map,q=document,g,b,h=q.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&n.set(b.getAttribute("href"),b),p.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var f=w[b++];if(!f){k=!1;b=0;continue}var c=!1,m=0;var d=f[m++];if(a=n.get(d)){var e=a._p;c=!0}else{a=q.createElement("link");a.href=d;a.rel="stylesheet";for(a.dataset.precedence=\nl=f[m++];e=f[m++];)a.setAttribute(e,f[m++]);e=a._p=new Promise(function(x,y){a.onload=x;a.onerror=y});n.set(d,a)}d=a.getAttribute("media");!e||"l"===e.s||d&&!matchMedia(d).matches||h.push(e);if(c)continue}else{a=v[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=p.get(l)||g;c===g&&(g=a);p.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=q.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(u.bind(null,r,t,""),u.bind(null,r,t,"Resource failed to load"))};$RR("'
5576
+ '$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()}};$RC("'
5168
5577
  ))
5169
- : destination.push('$RR("')
5170
- : 0 === (completedSegments.instructions & 2)
5171
- ? ((completedSegments.instructions |= 2),
5172
- destination.push(
5173
- '$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()}};$RC("'
5174
- ))
5175
- : destination.push('$RC("');
5578
+ : destination.push('$RC("');
5176
5579
  completedSegments = i.toString(16);
5177
5580
  destination.push(request.boundaryPrefix);
5178
5581
  destination.push(completedSegments);
@@ -5230,9 +5633,12 @@ function flushCompletedQueues(request, destination) {
5230
5633
  completedRootSegment = request.completedRootSegment;
5231
5634
  if (null !== completedRootSegment) {
5232
5635
  if (5 === completedRootSegment.status) return;
5636
+ var completedPreambleSegments = request.completedPreambleSegments;
5637
+ if (null === completedPreambleSegments) return;
5233
5638
  var renderState = request.renderState,
5234
- htmlChunks = renderState.htmlChunks,
5235
- headChunks = renderState.headChunks,
5639
+ preamble = renderState.preamble,
5640
+ htmlChunks = preamble.htmlChunks,
5641
+ headChunks = preamble.headChunks,
5236
5642
  i$jscomp$0;
5237
5643
  if (htmlChunks) {
5238
5644
  for (i$jscomp$0 = 0; i$jscomp$0 < htmlChunks.length; i$jscomp$0++)
@@ -5275,11 +5681,29 @@ function flushCompletedQueues(request, destination) {
5275
5681
  var hoistableChunks = renderState.hoistableChunks;
5276
5682
  for (i$jscomp$0 = 0; i$jscomp$0 < hoistableChunks.length; i$jscomp$0++)
5277
5683
  destination.push(hoistableChunks[i$jscomp$0]);
5278
- hoistableChunks.length = 0;
5279
- if (htmlChunks && null === headChunks) {
5684
+ for (
5685
+ renderState = hoistableChunks.length = 0;
5686
+ renderState < completedPreambleSegments.length;
5687
+ renderState++
5688
+ ) {
5689
+ var segments = completedPreambleSegments[renderState];
5690
+ for (preamble = 0; preamble < segments.length; preamble++)
5691
+ flushSegment(request, destination, segments[preamble], null);
5692
+ }
5693
+ var preamble$jscomp$0 = request.renderState.preamble,
5694
+ headChunks$jscomp$0 = preamble$jscomp$0.headChunks;
5695
+ if (preamble$jscomp$0.htmlChunks || headChunks$jscomp$0) {
5280
5696
  var chunk$jscomp$0 = endChunkForTag("head");
5281
5697
  destination.push(chunk$jscomp$0);
5282
5698
  }
5699
+ var bodyChunks = preamble$jscomp$0.bodyChunks;
5700
+ if (bodyChunks)
5701
+ for (
5702
+ completedPreambleSegments = 0;
5703
+ completedPreambleSegments < bodyChunks.length;
5704
+ completedPreambleSegments++
5705
+ )
5706
+ destination.push(bodyChunks[completedPreambleSegments]);
5283
5707
  flushSegment(request, destination, completedRootSegment, null);
5284
5708
  request.completedRootSegment = null;
5285
5709
  writeBootstrap(destination, request.renderState);
@@ -5365,11 +5789,11 @@ function flushCompletedQueues(request, destination) {
5365
5789
  completedBoundaries.splice(0, i);
5366
5790
  var partialBoundaries = request.partialBoundaries;
5367
5791
  for (i = 0; i < partialBoundaries.length; i++) {
5368
- var boundary$44 = partialBoundaries[i];
5792
+ var boundary$51 = partialBoundaries[i];
5369
5793
  a: {
5370
5794
  clientRenderedBoundaries = request;
5371
5795
  boundary = destination;
5372
- var completedSegments = boundary$44.completedSegments;
5796
+ var completedSegments = boundary$51.completedSegments;
5373
5797
  for (
5374
5798
  JSCompiler_inline_result = 0;
5375
5799
  JSCompiler_inline_result < completedSegments.length;
@@ -5379,7 +5803,7 @@ function flushCompletedQueues(request, destination) {
5379
5803
  !flushPartiallyCompletedSegment(
5380
5804
  clientRenderedBoundaries,
5381
5805
  boundary,
5382
- boundary$44,
5806
+ boundary$51,
5383
5807
  completedSegments[JSCompiler_inline_result]
5384
5808
  )
5385
5809
  ) {
@@ -5391,7 +5815,7 @@ function flushCompletedQueues(request, destination) {
5391
5815
  completedSegments.splice(0, JSCompiler_inline_result);
5392
5816
  JSCompiler_inline_result$jscomp$0 = writeHoistablesForBoundary(
5393
5817
  boundary,
5394
- boundary$44.contentState,
5818
+ boundary$51.contentState,
5395
5819
  clientRenderedBoundaries.renderState
5396
5820
  );
5397
5821
  }
@@ -5424,6 +5848,7 @@ function flushCompletedQueues(request, destination) {
5424
5848
  ((partialBoundaries = endChunkForTag("body")),
5425
5849
  destination.push(partialBoundaries)),
5426
5850
  i.hasHtml && ((i = endChunkForTag("html")), destination.push(i)),
5851
+ (request.status = 14),
5427
5852
  destination.push(null),
5428
5853
  (request.destination = null));
5429
5854
  }
@@ -5442,9 +5867,9 @@ function enqueueFlush(request) {
5442
5867
  }
5443
5868
  }
5444
5869
  function startFlowing(request, destination) {
5445
- if (1 === request.status)
5446
- (request.status = 2), destination.destroy(request.fatalError);
5447
- else if (2 !== request.status && null === request.destination) {
5870
+ if (13 === request.status)
5871
+ (request.status = 14), destination.destroy(request.fatalError);
5872
+ else if (14 !== request.status && null === request.destination) {
5448
5873
  request.destination = destination;
5449
5874
  try {
5450
5875
  flushCompletedQueues(request, destination);
@@ -5454,13 +5879,19 @@ function startFlowing(request, destination) {
5454
5879
  }
5455
5880
  }
5456
5881
  function abort(request, reason) {
5882
+ if (11 === request.status || 10 === request.status) request.status = 12;
5457
5883
  try {
5458
5884
  var abortableTasks = request.abortableTasks;
5459
5885
  if (0 < abortableTasks.size) {
5460
5886
  var error =
5461
5887
  void 0 === reason
5462
5888
  ? Error("The render was aborted by the server without a reason.")
5463
- : reason;
5889
+ : "object" === typeof reason &&
5890
+ null !== reason &&
5891
+ "function" === typeof reason.then
5892
+ ? Error("The render was aborted by the server with a promise.")
5893
+ : reason;
5894
+ request.fatalError = error;
5464
5895
  abortableTasks.forEach(function (task) {
5465
5896
  return abortTask(task, request, error);
5466
5897
  });
@@ -5468,8 +5899,8 @@ function abort(request, reason) {
5468
5899
  }
5469
5900
  null !== request.destination &&
5470
5901
  flushCompletedQueues(request, request.destination);
5471
- } catch (error$46) {
5472
- logRecoverableError(request, error$46, {}), fatalError(request, error$46);
5902
+ } catch (error$53) {
5903
+ logRecoverableError(request, error$53, {}), fatalError(request, error$53);
5473
5904
  }
5474
5905
  }
5475
5906
  function onError() {}
@@ -5501,6 +5932,7 @@ function renderToStringImpl(
5501
5932
  );
5502
5933
  children.flushScheduled = null !== children.destination;
5503
5934
  performWork(children);
5935
+ 10 === children.status && (children.status = 11);
5504
5936
  null === children.trackedPostpones &&
5505
5937
  safelyEmitEarlyPreloads(children, 0 === children.pendingRootTasks);
5506
5938
  abort(children, abortReason);
@@ -5537,4 +5969,4 @@ exports.renderToString = function (children, options) {
5537
5969
  'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToPipeableStream" which supports Suspense on the server'
5538
5970
  );
5539
5971
  };
5540
- exports.version = "19.0.0-beta-4508873393-20240430";
5972
+ exports.version = "19.2.0-canary-5252281c-20250408";