react-dom 19.2.0-canary-197d6a04-20250424 → 19.2.0-canary-143d3e1b-20250425

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.
@@ -299,14 +299,14 @@ ReactDOMSharedInternals.d = {
299
299
  };
300
300
  var PRELOAD_NO_CREDS = [];
301
301
  stringToPrecomputedChunk('"></template>');
302
- var startInlineScript = stringToPrecomputedChunk("<script>"),
302
+ var startInlineScript = stringToPrecomputedChunk("<script"),
303
303
  endInlineScript = stringToPrecomputedChunk("\x3c/script>"),
304
304
  startScriptSrc = stringToPrecomputedChunk('<script src="'),
305
305
  startModuleSrc = stringToPrecomputedChunk('<script type="module" src="'),
306
- scriptNonce = stringToPrecomputedChunk('" nonce="'),
307
- scriptIntegirty = stringToPrecomputedChunk('" integrity="'),
308
- scriptCrossOrigin = stringToPrecomputedChunk('" crossorigin="'),
309
- endAsyncScript = stringToPrecomputedChunk('" async="">\x3c/script>'),
306
+ scriptNonce = stringToPrecomputedChunk(' nonce="'),
307
+ scriptIntegirty = stringToPrecomputedChunk(' integrity="'),
308
+ scriptCrossOrigin = stringToPrecomputedChunk(' crossorigin="'),
309
+ endAsyncScript = stringToPrecomputedChunk(' async="">\x3c/script>'),
310
310
  scriptRegex = /(<\/|<)(s)(cript)/gi;
311
311
  function scriptReplacer(match, prefix, s, suffix) {
312
312
  return "" + prefix + ("s" === s ? "\\u0073" : "\\u0053") + suffix;
@@ -327,7 +327,7 @@ function createRenderState(
327
327
  void 0 === nonce
328
328
  ? startInlineScript
329
329
  : stringToPrecomputedChunk(
330
- '<script nonce="' + escapeTextForBrowser(nonce) + '">'
330
+ '<script nonce="' + escapeTextForBrowser(nonce) + '"'
331
331
  ),
332
332
  idPrefix = resumableState.idPrefix;
333
333
  externalRuntimeConfig = [];
@@ -335,11 +335,13 @@ function createRenderState(
335
335
  bootstrapScripts = resumableState.bootstrapScripts,
336
336
  bootstrapModules = resumableState.bootstrapModules;
337
337
  void 0 !== bootstrapScriptContent &&
338
+ (externalRuntimeConfig.push(inlineScriptWithNonce),
339
+ pushCompletedShellIdAttribute(externalRuntimeConfig, resumableState),
338
340
  externalRuntimeConfig.push(
339
- inlineScriptWithNonce,
341
+ endOfStartTag,
340
342
  ("" + bootstrapScriptContent).replace(scriptRegex, scriptReplacer),
341
343
  endInlineScript
342
- );
344
+ ));
343
345
  bootstrapScriptContent = [];
344
346
  void 0 !== importMap &&
345
347
  (bootstrapScriptContent.push(importMapScriptStart),
@@ -426,20 +428,28 @@ function createRenderState(
426
428
  onHeaders.bootstrapScripts.add(scriptConfig);
427
429
  externalRuntimeConfig.push(
428
430
  startScriptSrc,
429
- escapeTextForBrowser(maxHeadersLength)
431
+ escapeTextForBrowser(maxHeadersLength),
432
+ attributeEnd
430
433
  );
431
434
  nonce &&
432
- externalRuntimeConfig.push(scriptNonce, escapeTextForBrowser(nonce));
435
+ externalRuntimeConfig.push(
436
+ scriptNonce,
437
+ escapeTextForBrowser(nonce),
438
+ attributeEnd
439
+ );
433
440
  "string" === typeof idPrefix &&
434
441
  externalRuntimeConfig.push(
435
442
  scriptIntegirty,
436
- escapeTextForBrowser(idPrefix)
443
+ escapeTextForBrowser(idPrefix),
444
+ attributeEnd
437
445
  );
438
446
  "string" === typeof inlineScriptWithNonce &&
439
447
  externalRuntimeConfig.push(
440
448
  scriptCrossOrigin,
441
- escapeTextForBrowser(inlineScriptWithNonce)
449
+ escapeTextForBrowser(inlineScriptWithNonce),
450
+ attributeEnd
442
451
  );
452
+ pushCompletedShellIdAttribute(externalRuntimeConfig, resumableState);
443
453
  externalRuntimeConfig.push(endAsyncScript);
444
454
  }
445
455
  if (void 0 !== bootstrapModules)
@@ -478,20 +488,28 @@ function createRenderState(
478
488
  onHeaders.bootstrapScripts.add(bootstrapScriptContent),
479
489
  externalRuntimeConfig.push(
480
490
  startModuleSrc,
481
- escapeTextForBrowser(importMap)
491
+ escapeTextForBrowser(importMap),
492
+ attributeEnd
482
493
  ),
483
494
  nonce &&
484
- externalRuntimeConfig.push(scriptNonce, escapeTextForBrowser(nonce)),
495
+ externalRuntimeConfig.push(
496
+ scriptNonce,
497
+ escapeTextForBrowser(nonce),
498
+ attributeEnd
499
+ ),
485
500
  "string" === typeof inlineScriptWithNonce &&
486
501
  externalRuntimeConfig.push(
487
502
  scriptIntegirty,
488
- escapeTextForBrowser(inlineScriptWithNonce)
503
+ escapeTextForBrowser(inlineScriptWithNonce),
504
+ attributeEnd
489
505
  ),
490
506
  "string" === typeof maxHeadersLength &&
491
507
  externalRuntimeConfig.push(
492
508
  scriptCrossOrigin,
493
- escapeTextForBrowser(maxHeadersLength)
509
+ escapeTextForBrowser(maxHeadersLength),
510
+ attributeEnd
494
511
  ),
512
+ pushCompletedShellIdAttribute(externalRuntimeConfig, resumableState),
495
513
  externalRuntimeConfig.push(endAsyncScript);
496
514
  return onHeaders;
497
515
  }
@@ -976,13 +994,25 @@ var selectedMarkerAttribute = stringToPrecomputedChunk(' selected=""'),
976
994
  'addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error(\'React form unexpectedly submitted.\')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});'
977
995
  );
978
996
  function injectFormReplayingRuntime(resumableState, renderState) {
979
- 0 === (resumableState.instructions & 16) &&
980
- ((resumableState.instructions |= 16),
981
- renderState.bootstrapChunks.unshift(
982
- renderState.startInlineScript,
983
- formReplayingRuntimeScript,
984
- endInlineScript
985
- ));
997
+ if (0 === (resumableState.instructions & 16)) {
998
+ resumableState.instructions |= 16;
999
+ var preamble = renderState.preamble,
1000
+ bootstrapChunks = renderState.bootstrapChunks;
1001
+ (preamble.htmlChunks || preamble.headChunks) && 0 === bootstrapChunks.length
1002
+ ? (bootstrapChunks.push(renderState.startInlineScript),
1003
+ pushCompletedShellIdAttribute(bootstrapChunks, resumableState),
1004
+ bootstrapChunks.push(
1005
+ endOfStartTag,
1006
+ formReplayingRuntimeScript,
1007
+ endInlineScript
1008
+ ))
1009
+ : bootstrapChunks.unshift(
1010
+ renderState.startInlineScript,
1011
+ endOfStartTag,
1012
+ formReplayingRuntimeScript,
1013
+ endInlineScript
1014
+ );
1015
+ }
986
1016
  }
987
1017
  var formStateMarkerIsMatching = stringToPrecomputedChunk("\x3c!--F!--\x3e"),
988
1018
  formStateMarkerIsNotMatching = stringToPrecomputedChunk("\x3c!--F--\x3e");
@@ -2549,6 +2579,20 @@ function preloadLateStyles(styleQueue) {
2549
2579
  styleQueue.sheets.forEach(preloadLateStyle, this);
2550
2580
  styleQueue.sheets.clear();
2551
2581
  }
2582
+ var blockingRenderChunkStart = stringToPrecomputedChunk(
2583
+ '<link rel="expect" href="#'
2584
+ ),
2585
+ blockingRenderChunkEnd = stringToPrecomputedChunk('" blocking="render"/>'),
2586
+ completedShellIdAttributeStart = stringToPrecomputedChunk(' id="');
2587
+ function pushCompletedShellIdAttribute(target, resumableState) {
2588
+ 0 === (resumableState.instructions & 32) &&
2589
+ ((resumableState.instructions |= 32),
2590
+ target.push(
2591
+ completedShellIdAttributeStart,
2592
+ escapeTextForBrowser("\u00ab" + resumableState.idPrefix + "R\u00bb"),
2593
+ attributeEnd
2594
+ ));
2595
+ }
2552
2596
  var arrayFirstOpenBracket = stringToPrecomputedChunk("["),
2553
2597
  arraySubsequentOpenBracket = stringToPrecomputedChunk(",["),
2554
2598
  arrayInterstitial = stringToPrecomputedChunk(","),
@@ -5846,6 +5890,7 @@ function flushCompletedBoundary(request, destination, boundary) {
5846
5890
  var requiresStyleInsertion = request.stylesToHoist;
5847
5891
  request.stylesToHoist = !1;
5848
5892
  writeChunk(destination, request.startInlineScript);
5893
+ writeChunk(destination, endOfStartTag);
5849
5894
  requiresStyleInsertion
5850
5895
  ? 0 === (completedSegments.instructions & 2)
5851
5896
  ? ((completedSegments.instructions |= 10),
@@ -5893,6 +5938,7 @@ function flushPartiallyCompletedSegment(
5893
5938
  boundary = request.resumableState;
5894
5939
  request = request.renderState;
5895
5940
  writeChunk(destination, request.startInlineScript);
5941
+ writeChunk(destination, endOfStartTag);
5896
5942
  0 === (boundary.instructions & 1)
5897
5943
  ? ((boundary.instructions |= 1),
5898
5944
  writeChunk(destination, completeSegmentScript1Full))
@@ -5918,7 +5964,8 @@ function flushCompletedQueues(request, destination) {
5918
5964
  if (5 === completedRootSegment.status) return;
5919
5965
  var completedPreambleSegments = request.completedPreambleSegments;
5920
5966
  if (null === completedPreambleSegments) return;
5921
- var renderState = request.renderState,
5967
+ var resumableState = request.resumableState,
5968
+ renderState = request.renderState,
5922
5969
  preamble = renderState.preamble,
5923
5970
  htmlChunks = preamble.htmlChunks,
5924
5971
  headChunks = preamble.headChunks,
@@ -5959,17 +6006,23 @@ function flushCompletedQueues(request, destination) {
5959
6006
  renderState.scripts.clear();
5960
6007
  renderState.bulkPreloads.forEach(flushResource, destination);
5961
6008
  renderState.bulkPreloads.clear();
6009
+ if (htmlChunks || headChunks) {
6010
+ var shellId = "\u00ab" + resumableState.idPrefix + "R\u00bb";
6011
+ writeChunk(destination, blockingRenderChunkStart);
6012
+ writeChunk(destination, escapeTextForBrowser(shellId));
6013
+ writeChunk(destination, blockingRenderChunkEnd);
6014
+ }
5962
6015
  var hoistableChunks = renderState.hoistableChunks;
5963
6016
  for (i$jscomp$0 = 0; i$jscomp$0 < hoistableChunks.length; i$jscomp$0++)
5964
6017
  writeChunk(destination, hoistableChunks[i$jscomp$0]);
5965
6018
  for (
5966
- renderState = hoistableChunks.length = 0;
5967
- renderState < completedPreambleSegments.length;
5968
- renderState++
6019
+ resumableState = hoistableChunks.length = 0;
6020
+ resumableState < completedPreambleSegments.length;
6021
+ resumableState++
5969
6022
  ) {
5970
- var segments = completedPreambleSegments[renderState];
5971
- for (preamble = 0; preamble < segments.length; preamble++)
5972
- flushSegment(request, destination, segments[preamble], null);
6023
+ var segments = completedPreambleSegments[resumableState];
6024
+ for (renderState = 0; renderState < segments.length; renderState++)
6025
+ flushSegment(request, destination, segments[renderState], null);
5973
6026
  }
5974
6027
  var preamble$jscomp$0 = request.renderState.preamble,
5975
6028
  headChunks$jscomp$0 = preamble$jscomp$0.headChunks;
@@ -5985,11 +6038,26 @@ function flushCompletedQueues(request, destination) {
5985
6038
  writeChunk(destination, bodyChunks[completedPreambleSegments]);
5986
6039
  flushSegment(request, destination, completedRootSegment, null);
5987
6040
  request.completedRootSegment = null;
5988
- writeBootstrap(destination, request.renderState);
6041
+ var resumableState$jscomp$0 = request.resumableState,
6042
+ renderState$jscomp$0 = request.renderState,
6043
+ preamble$jscomp$1 = renderState$jscomp$0.preamble;
6044
+ if (
6045
+ (preamble$jscomp$1.htmlChunks || preamble$jscomp$1.headChunks) &&
6046
+ 0 === (resumableState$jscomp$0.instructions & 32)
6047
+ ) {
6048
+ var bootstrapChunks = renderState$jscomp$0.bootstrapChunks;
6049
+ bootstrapChunks.push(startChunkForTag("template"));
6050
+ pushCompletedShellIdAttribute(
6051
+ bootstrapChunks,
6052
+ resumableState$jscomp$0
6053
+ );
6054
+ bootstrapChunks.push(endOfStartTag, endChunkForTag("template"));
6055
+ }
6056
+ writeBootstrap(destination, renderState$jscomp$0);
5989
6057
  }
5990
- var renderState$jscomp$0 = request.renderState;
6058
+ var renderState$jscomp$1 = request.renderState;
5991
6059
  completedRootSegment = 0;
5992
- var viewportChunks$jscomp$0 = renderState$jscomp$0.viewportChunks;
6060
+ var viewportChunks$jscomp$0 = renderState$jscomp$1.viewportChunks;
5993
6061
  for (
5994
6062
  completedRootSegment = 0;
5995
6063
  completedRootSegment < viewportChunks$jscomp$0.length;
@@ -5997,21 +6065,21 @@ function flushCompletedQueues(request, destination) {
5997
6065
  )
5998
6066
  writeChunk(destination, viewportChunks$jscomp$0[completedRootSegment]);
5999
6067
  viewportChunks$jscomp$0.length = 0;
6000
- renderState$jscomp$0.preconnects.forEach(flushResource, destination);
6001
- renderState$jscomp$0.preconnects.clear();
6002
- renderState$jscomp$0.fontPreloads.forEach(flushResource, destination);
6003
- renderState$jscomp$0.fontPreloads.clear();
6004
- renderState$jscomp$0.highImagePreloads.forEach(
6068
+ renderState$jscomp$1.preconnects.forEach(flushResource, destination);
6069
+ renderState$jscomp$1.preconnects.clear();
6070
+ renderState$jscomp$1.fontPreloads.forEach(flushResource, destination);
6071
+ renderState$jscomp$1.fontPreloads.clear();
6072
+ renderState$jscomp$1.highImagePreloads.forEach(
6005
6073
  flushResource,
6006
6074
  destination
6007
6075
  );
6008
- renderState$jscomp$0.highImagePreloads.clear();
6009
- renderState$jscomp$0.styles.forEach(preloadLateStyles, destination);
6010
- renderState$jscomp$0.scripts.forEach(flushResource, destination);
6011
- renderState$jscomp$0.scripts.clear();
6012
- renderState$jscomp$0.bulkPreloads.forEach(flushResource, destination);
6013
- renderState$jscomp$0.bulkPreloads.clear();
6014
- var hoistableChunks$jscomp$0 = renderState$jscomp$0.hoistableChunks;
6076
+ renderState$jscomp$1.highImagePreloads.clear();
6077
+ renderState$jscomp$1.styles.forEach(preloadLateStyles, destination);
6078
+ renderState$jscomp$1.scripts.forEach(flushResource, destination);
6079
+ renderState$jscomp$1.scripts.clear();
6080
+ renderState$jscomp$1.bulkPreloads.forEach(flushResource, destination);
6081
+ renderState$jscomp$1.bulkPreloads.clear();
6082
+ var hoistableChunks$jscomp$0 = renderState$jscomp$1.hoistableChunks;
6015
6083
  for (
6016
6084
  completedRootSegment = 0;
6017
6085
  completedRootSegment < hoistableChunks$jscomp$0.length;
@@ -6022,33 +6090,34 @@ function flushCompletedQueues(request, destination) {
6022
6090
  var clientRenderedBoundaries = request.clientRenderedBoundaries;
6023
6091
  for (i = 0; i < clientRenderedBoundaries.length; i++) {
6024
6092
  var boundary = clientRenderedBoundaries[i];
6025
- renderState$jscomp$0 = destination;
6026
- var resumableState = request.resumableState,
6027
- renderState$jscomp$1 = request.renderState,
6093
+ renderState$jscomp$1 = destination;
6094
+ var resumableState$jscomp$1 = request.resumableState,
6095
+ renderState$jscomp$2 = request.renderState,
6028
6096
  id = boundary.rootSegmentID,
6029
6097
  errorDigest = boundary.errorDigest;
6030
6098
  writeChunk(
6031
- renderState$jscomp$0,
6032
- renderState$jscomp$1.startInlineScript
6099
+ renderState$jscomp$1,
6100
+ renderState$jscomp$2.startInlineScript
6033
6101
  );
6034
- 0 === (resumableState.instructions & 4)
6035
- ? ((resumableState.instructions |= 4),
6036
- writeChunk(renderState$jscomp$0, clientRenderScript1Full))
6037
- : writeChunk(renderState$jscomp$0, clientRenderScript1Partial);
6038
- writeChunk(renderState$jscomp$0, renderState$jscomp$1.boundaryPrefix);
6039
- writeChunk(renderState$jscomp$0, id.toString(16));
6040
- writeChunk(renderState$jscomp$0, clientRenderScript1A);
6102
+ writeChunk(renderState$jscomp$1, endOfStartTag);
6103
+ 0 === (resumableState$jscomp$1.instructions & 4)
6104
+ ? ((resumableState$jscomp$1.instructions |= 4),
6105
+ writeChunk(renderState$jscomp$1, clientRenderScript1Full))
6106
+ : writeChunk(renderState$jscomp$1, clientRenderScript1Partial);
6107
+ writeChunk(renderState$jscomp$1, renderState$jscomp$2.boundaryPrefix);
6108
+ writeChunk(renderState$jscomp$1, id.toString(16));
6109
+ writeChunk(renderState$jscomp$1, clientRenderScript1A);
6041
6110
  errorDigest &&
6042
6111
  (writeChunk(
6043
- renderState$jscomp$0,
6112
+ renderState$jscomp$1,
6044
6113
  clientRenderErrorScriptArgInterstitial
6045
6114
  ),
6046
6115
  writeChunk(
6047
- renderState$jscomp$0,
6116
+ renderState$jscomp$1,
6048
6117
  escapeJSStringsForInstructionScripts(errorDigest || "")
6049
6118
  ));
6050
6119
  var JSCompiler_inline_result = writeChunkAndReturn(
6051
- renderState$jscomp$0,
6120
+ renderState$jscomp$1,
6052
6121
  clientRenderScriptEnd
6053
6122
  );
6054
6123
  if (!JSCompiler_inline_result) {
@@ -6210,11 +6279,11 @@ function abort(request, reason) {
6210
6279
  }
6211
6280
  function ensureCorrectIsomorphicReactVersion() {
6212
6281
  var isomorphicReactPackageVersion = React.version;
6213
- if ("19.2.0-canary-197d6a04-20250424" !== isomorphicReactPackageVersion)
6282
+ if ("19.2.0-canary-143d3e1b-20250425" !== isomorphicReactPackageVersion)
6214
6283
  throw Error(
6215
6284
  'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
6216
6285
  (isomorphicReactPackageVersion +
6217
- "\n - react-dom: 19.2.0-canary-197d6a04-20250424\nLearn more: https://react.dev/warnings/version-mismatch")
6286
+ "\n - react-dom: 19.2.0-canary-143d3e1b-20250425\nLearn more: https://react.dev/warnings/version-mismatch")
6218
6287
  );
6219
6288
  }
6220
6289
  ensureCorrectIsomorphicReactVersion();
@@ -6363,4 +6432,4 @@ exports.renderToPipeableStream = function (children, options) {
6363
6432
  }
6364
6433
  };
6365
6434
  };
6366
- exports.version = "19.2.0-canary-197d6a04-20250424";
6435
+ exports.version = "19.2.0-canary-143d3e1b-20250425";
@@ -416,7 +416,7 @@
416
416
  exports.useFormStatus = function () {
417
417
  return resolveDispatcher().useHostTransitionStatus();
418
418
  };
419
- exports.version = "19.2.0-canary-197d6a04-20250424";
419
+ exports.version = "19.2.0-canary-143d3e1b-20250425";
420
420
  "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
421
421
  "function" ===
422
422
  typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -207,4 +207,4 @@ exports.useFormState = function (action, initialState, permalink) {
207
207
  exports.useFormStatus = function () {
208
208
  return ReactSharedInternals.H.useHostTransitionStatus();
209
209
  };
210
- exports.version = "19.2.0-canary-197d6a04-20250424";
210
+ exports.version = "19.2.0-canary-143d3e1b-20250425";
@@ -336,5 +336,5 @@
336
336
  }))
337
337
  : Internals.d.m(href));
338
338
  };
339
- exports.version = "19.2.0-canary-197d6a04-20250424";
339
+ exports.version = "19.2.0-canary-143d3e1b-20250425";
340
340
  })();
@@ -149,4 +149,4 @@ exports.preloadModule = function (href, options) {
149
149
  });
150
150
  } else Internals.d.m(href);
151
151
  };
152
- exports.version = "19.2.0-canary-197d6a04-20250424";
152
+ exports.version = "19.2.0-canary-143d3e1b-20250425";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-dom",
3
- "version": "19.2.0-canary-197d6a04-20250424",
3
+ "version": "19.2.0-canary-143d3e1b-20250425",
4
4
  "description": "React package for working with the DOM.",
5
5
  "main": "index.js",
6
6
  "repository": {
@@ -17,10 +17,10 @@
17
17
  },
18
18
  "homepage": "https://react.dev/",
19
19
  "dependencies": {
20
- "scheduler": "0.27.0-canary-197d6a04-20250424"
20
+ "scheduler": "0.27.0-canary-143d3e1b-20250425"
21
21
  },
22
22
  "peerDependencies": {
23
- "react": "19.2.0-canary-197d6a04-20250424"
23
+ "react": "19.2.0-canary-143d3e1b-20250425"
24
24
  },
25
25
  "files": [
26
26
  "LICENSE",