react-server-dom-webpack 19.0.0-canary-4c12339ce-20240408 → 19.0.0-canary-96c584661-20240412
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/react-server-dom-webpack-client.browser.development.js +115 -100
- package/cjs/react-server-dom-webpack-client.browser.production.js +92 -72
- package/cjs/react-server-dom-webpack-client.browser.production.min.js +24 -24
- package/cjs/react-server-dom-webpack-client.browser.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-client.edge.development.js +123 -108
- package/cjs/react-server-dom-webpack-client.edge.production.js +100 -80
- package/cjs/react-server-dom-webpack-client.edge.production.min.js +24 -23
- package/cjs/react-server-dom-webpack-client.edge.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-client.node.development.js +123 -108
- package/cjs/react-server-dom-webpack-client.node.production.js +100 -80
- package/cjs/react-server-dom-webpack-client.node.production.min.js +23 -22
- package/cjs/react-server-dom-webpack-client.node.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-client.node.unbundled.development.js +123 -108
- package/cjs/react-server-dom-webpack-client.node.unbundled.production.js +100 -80
- package/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +22 -21
- package/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-node-register.js.map +1 -1
- package/cjs/react-server-dom-webpack-server.browser.development.js +75 -39
- package/cjs/react-server-dom-webpack-server.browser.production.js +70 -32
- package/cjs/react-server-dom-webpack-server.browser.production.min.js +68 -68
- package/cjs/react-server-dom-webpack-server.browser.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-server.edge.development.js +75 -39
- package/cjs/react-server-dom-webpack-server.edge.production.js +70 -32
- package/cjs/react-server-dom-webpack-server.edge.production.min.js +53 -53
- package/cjs/react-server-dom-webpack-server.edge.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-server.node.development.js +75 -39
- package/cjs/react-server-dom-webpack-server.node.production.js +70 -32
- package/cjs/react-server-dom-webpack-server.node.production.min.js +56 -56
- package/cjs/react-server-dom-webpack-server.node.production.min.js.map +1 -1
- package/cjs/react-server-dom-webpack-server.node.unbundled.development.js +75 -39
- package/cjs/react-server-dom-webpack-server.node.unbundled.production.js +70 -32
- package/cjs/react-server-dom-webpack-server.node.unbundled.production.min.js +53 -53
- package/cjs/react-server-dom-webpack-server.node.unbundled.production.min.js.map +1 -1
- package/package.json +3 -3
- package/umd/react-server-dom-webpack-client.browser.development.js +115 -100
- package/umd/react-server-dom-webpack-client.browser.production.min.js +24 -24
- package/umd/react-server-dom-webpack-server.browser.development.js +75 -39
- package/umd/react-server-dom-webpack-server.browser.production.min.js +53 -53
@@ -197,7 +197,7 @@ chunks, nonce) {
|
|
197
197
|
}
|
198
198
|
}
|
199
199
|
|
200
|
-
const ReactDOMSharedInternals = ReactDOM.
|
200
|
+
const ReactDOMSharedInternals = ReactDOM.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
201
201
|
|
202
202
|
function getCrossOriginString(input) {
|
203
203
|
if (typeof input === 'string') {
|
@@ -208,16 +208,18 @@ function getCrossOriginString(input) {
|
|
208
208
|
}
|
209
209
|
|
210
210
|
// This client file is in the shared folder because it applies to both SSR and browser contexts.
|
211
|
-
const ReactDOMCurrentDispatcher = ReactDOMSharedInternals.ReactDOMCurrentDispatcher;
|
212
211
|
function dispatchHint(code, model) {
|
213
|
-
const dispatcher =
|
212
|
+
const dispatcher = ReactDOMSharedInternals.d;
|
213
|
+
/* ReactDOMCurrentDispatcher */
|
214
214
|
|
215
215
|
switch (code) {
|
216
216
|
case 'D':
|
217
217
|
{
|
218
218
|
const refined = refineModel(code, model);
|
219
219
|
const href = refined;
|
220
|
-
dispatcher.
|
220
|
+
dispatcher.D(
|
221
|
+
/* prefetchDNS */
|
222
|
+
href);
|
221
223
|
return;
|
222
224
|
}
|
223
225
|
|
@@ -227,11 +229,15 @@ function dispatchHint(code, model) {
|
|
227
229
|
|
228
230
|
if (typeof refined === 'string') {
|
229
231
|
const href = refined;
|
230
|
-
dispatcher.
|
232
|
+
dispatcher.C(
|
233
|
+
/* preconnect */
|
234
|
+
href);
|
231
235
|
} else {
|
232
236
|
const href = refined[0];
|
233
237
|
const crossOrigin = refined[1];
|
234
|
-
dispatcher.
|
238
|
+
dispatcher.C(
|
239
|
+
/* preconnect */
|
240
|
+
href, crossOrigin);
|
235
241
|
}
|
236
242
|
|
237
243
|
return;
|
@@ -245,9 +251,13 @@ function dispatchHint(code, model) {
|
|
245
251
|
|
246
252
|
if (refined.length === 3) {
|
247
253
|
const options = refined[2];
|
248
|
-
dispatcher.
|
254
|
+
dispatcher.L(
|
255
|
+
/* preload */
|
256
|
+
href, as, options);
|
249
257
|
} else {
|
250
|
-
dispatcher.
|
258
|
+
dispatcher.L(
|
259
|
+
/* preload */
|
260
|
+
href, as);
|
251
261
|
}
|
252
262
|
|
253
263
|
return;
|
@@ -259,44 +269,56 @@ function dispatchHint(code, model) {
|
|
259
269
|
|
260
270
|
if (typeof refined === 'string') {
|
261
271
|
const href = refined;
|
262
|
-
dispatcher.
|
272
|
+
dispatcher.m(
|
273
|
+
/* preloadModule */
|
274
|
+
href);
|
263
275
|
} else {
|
264
276
|
const href = refined[0];
|
265
277
|
const options = refined[1];
|
266
|
-
dispatcher.
|
278
|
+
dispatcher.m(
|
279
|
+
/* preloadModule */
|
280
|
+
href, options);
|
267
281
|
}
|
268
282
|
|
269
283
|
return;
|
270
284
|
}
|
271
285
|
|
272
|
-
case '
|
286
|
+
case 'X':
|
273
287
|
{
|
274
288
|
const refined = refineModel(code, model);
|
275
289
|
|
276
290
|
if (typeof refined === 'string') {
|
277
291
|
const href = refined;
|
278
|
-
dispatcher.
|
292
|
+
dispatcher.X(
|
293
|
+
/* preinitScript */
|
294
|
+
href);
|
279
295
|
} else {
|
280
296
|
const href = refined[0];
|
281
|
-
const
|
282
|
-
|
283
|
-
|
297
|
+
const options = refined[1];
|
298
|
+
dispatcher.X(
|
299
|
+
/* preinitScript */
|
300
|
+
href, options);
|
284
301
|
}
|
285
302
|
|
286
303
|
return;
|
287
304
|
}
|
288
305
|
|
289
|
-
case '
|
306
|
+
case 'S':
|
290
307
|
{
|
291
308
|
const refined = refineModel(code, model);
|
292
309
|
|
293
310
|
if (typeof refined === 'string') {
|
294
311
|
const href = refined;
|
295
|
-
dispatcher.
|
312
|
+
dispatcher.S(
|
313
|
+
/* preinitStyle */
|
314
|
+
href);
|
296
315
|
} else {
|
297
316
|
const href = refined[0];
|
298
|
-
const
|
299
|
-
|
317
|
+
const precedence = refined[1] === 0 ? undefined : refined[1];
|
318
|
+
const options = refined.length === 3 ? refined[2] : undefined;
|
319
|
+
dispatcher.S(
|
320
|
+
/* preinitStyle */
|
321
|
+
href, precedence, options);
|
300
322
|
}
|
301
323
|
|
302
324
|
return;
|
@@ -308,11 +330,15 @@ function dispatchHint(code, model) {
|
|
308
330
|
|
309
331
|
if (typeof refined === 'string') {
|
310
332
|
const href = refined;
|
311
|
-
dispatcher.
|
333
|
+
dispatcher.M(
|
334
|
+
/* preinitModuleScript */
|
335
|
+
href);
|
312
336
|
} else {
|
313
337
|
const href = refined[0];
|
314
338
|
const options = refined[1];
|
315
|
-
dispatcher.
|
339
|
+
dispatcher.M(
|
340
|
+
/* preinitModuleScript */
|
341
|
+
href, options);
|
316
342
|
}
|
317
343
|
|
318
344
|
return;
|
@@ -325,14 +351,14 @@ function refineModel(code, model) {
|
|
325
351
|
return model;
|
326
352
|
}
|
327
353
|
function preinitScriptForSSR(href, nonce, crossOrigin) {
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
}
|
354
|
+
ReactDOMSharedInternals.d
|
355
|
+
/* ReactDOMCurrentDispatcher */
|
356
|
+
.X(
|
357
|
+
/* preinitScript */
|
358
|
+
href, {
|
359
|
+
crossOrigin: getCrossOriginString(crossOrigin),
|
360
|
+
nonce
|
361
|
+
});
|
336
362
|
}
|
337
363
|
|
338
364
|
// ATTENTION
|
@@ -1311,7 +1337,7 @@ function getChunk(response, id) {
|
|
1311
1337
|
return chunk;
|
1312
1338
|
}
|
1313
1339
|
|
1314
|
-
function createModelResolver(chunk, parentObject, key, cyclic) {
|
1340
|
+
function createModelResolver(chunk, parentObject, key, cyclic, response, map) {
|
1315
1341
|
let blocked;
|
1316
1342
|
|
1317
1343
|
if (initializingChunkBlockedModel) {
|
@@ -1328,11 +1354,11 @@ function createModelResolver(chunk, parentObject, key, cyclic) {
|
|
1328
1354
|
}
|
1329
1355
|
|
1330
1356
|
return value => {
|
1331
|
-
parentObject[key] = value; // If this is the root object for a model reference, where `blocked.value`
|
1357
|
+
parentObject[key] = map(response, value); // If this is the root object for a model reference, where `blocked.value`
|
1332
1358
|
// is a stale `null`, the resolved value can be used directly.
|
1333
1359
|
|
1334
1360
|
if (key === '' && blocked.value === null) {
|
1335
|
-
blocked.value =
|
1361
|
+
blocked.value = parentObject[key];
|
1336
1362
|
}
|
1337
1363
|
|
1338
1364
|
blocked.deps--;
|
@@ -1386,28 +1412,60 @@ function createServerReferenceProxy(response, metaData) {
|
|
1386
1412
|
return proxy;
|
1387
1413
|
}
|
1388
1414
|
|
1389
|
-
function getOutlinedModel(response, id) {
|
1415
|
+
function getOutlinedModel(response, id, parentObject, key, map) {
|
1390
1416
|
const chunk = getChunk(response, id);
|
1391
1417
|
|
1392
1418
|
switch (chunk.status) {
|
1393
1419
|
case RESOLVED_MODEL:
|
1394
1420
|
initializeModelChunk(chunk);
|
1395
1421
|
break;
|
1422
|
+
|
1423
|
+
case RESOLVED_MODULE:
|
1424
|
+
initializeModuleChunk(chunk);
|
1425
|
+
break;
|
1396
1426
|
} // The status might have changed after initialization.
|
1397
1427
|
|
1398
1428
|
|
1399
1429
|
switch (chunk.status) {
|
1400
1430
|
case INITIALIZED:
|
1401
|
-
|
1402
|
-
|
1403
|
-
|
1404
|
-
|
1431
|
+
const chunkValue = map(response, chunk.value);
|
1432
|
+
|
1433
|
+
return chunkValue;
|
1434
|
+
|
1435
|
+
case PENDING:
|
1436
|
+
case BLOCKED:
|
1437
|
+
case CYCLIC:
|
1438
|
+
const parentChunk = initializingChunk;
|
1439
|
+
chunk.then(createModelResolver(parentChunk, parentObject, key, chunk.status === CYCLIC, response, map), createModelReject(parentChunk));
|
1440
|
+
return null;
|
1405
1441
|
|
1406
1442
|
default:
|
1407
1443
|
throw chunk.reason;
|
1408
1444
|
}
|
1409
1445
|
}
|
1410
1446
|
|
1447
|
+
function createMap(response, model) {
|
1448
|
+
return new Map(model);
|
1449
|
+
}
|
1450
|
+
|
1451
|
+
function createSet(response, model) {
|
1452
|
+
return new Set(model);
|
1453
|
+
}
|
1454
|
+
|
1455
|
+
function createFormData(response, model) {
|
1456
|
+
const formData = new FormData();
|
1457
|
+
|
1458
|
+
for (let i = 0; i < model.length; i++) {
|
1459
|
+
formData.append(model[i][0], model[i][1]);
|
1460
|
+
}
|
1461
|
+
|
1462
|
+
return formData;
|
1463
|
+
}
|
1464
|
+
|
1465
|
+
function createModel(response, model) {
|
1466
|
+
return model;
|
1467
|
+
}
|
1468
|
+
|
1411
1469
|
function parseModelString(response, parentObject, key, value) {
|
1412
1470
|
if (value[0] === '$') {
|
1413
1471
|
if (value === '$') {
|
@@ -1455,8 +1513,7 @@ function parseModelString(response, parentObject, key, value) {
|
|
1455
1513
|
{
|
1456
1514
|
// Server Reference
|
1457
1515
|
const id = parseInt(value.slice(2), 16);
|
1458
|
-
|
1459
|
-
return createServerReferenceProxy(response, metadata);
|
1516
|
+
return getOutlinedModel(response, id, parentObject, key, createServerReferenceProxy);
|
1460
1517
|
}
|
1461
1518
|
|
1462
1519
|
case 'T':
|
@@ -1476,16 +1533,14 @@ function parseModelString(response, parentObject, key, value) {
|
|
1476
1533
|
{
|
1477
1534
|
// Map
|
1478
1535
|
const id = parseInt(value.slice(2), 16);
|
1479
|
-
|
1480
|
-
return new Map(data);
|
1536
|
+
return getOutlinedModel(response, id, parentObject, key, createMap);
|
1481
1537
|
}
|
1482
1538
|
|
1483
1539
|
case 'W':
|
1484
1540
|
{
|
1485
1541
|
// Set
|
1486
1542
|
const id = parseInt(value.slice(2), 16);
|
1487
|
-
|
1488
|
-
return new Set(data);
|
1543
|
+
return getOutlinedModel(response, id, parentObject, key, createSet);
|
1489
1544
|
}
|
1490
1545
|
|
1491
1546
|
case 'B':
|
@@ -1498,14 +1553,7 @@ function parseModelString(response, parentObject, key, value) {
|
|
1498
1553
|
{
|
1499
1554
|
// FormData
|
1500
1555
|
const id = parseInt(value.slice(2), 16);
|
1501
|
-
|
1502
|
-
const formData = new FormData();
|
1503
|
-
|
1504
|
-
for (let i = 0; i < data.length; i++) {
|
1505
|
-
formData.append(data[i][0], data[i][1]);
|
1506
|
-
}
|
1507
|
-
|
1508
|
-
return formData;
|
1556
|
+
return getOutlinedModel(response, id, parentObject, key, createFormData);
|
1509
1557
|
}
|
1510
1558
|
|
1511
1559
|
case 'I':
|
@@ -1555,35 +1603,7 @@ function parseModelString(response, parentObject, key, value) {
|
|
1555
1603
|
{
|
1556
1604
|
// We assume that anything else is a reference ID.
|
1557
1605
|
const id = parseInt(value.slice(1), 16);
|
1558
|
-
|
1559
|
-
|
1560
|
-
switch (chunk.status) {
|
1561
|
-
case RESOLVED_MODEL:
|
1562
|
-
initializeModelChunk(chunk);
|
1563
|
-
break;
|
1564
|
-
|
1565
|
-
case RESOLVED_MODULE:
|
1566
|
-
initializeModuleChunk(chunk);
|
1567
|
-
break;
|
1568
|
-
} // The status might have changed after initialization.
|
1569
|
-
|
1570
|
-
|
1571
|
-
switch (chunk.status) {
|
1572
|
-
case INITIALIZED:
|
1573
|
-
const chunkValue = chunk.value;
|
1574
|
-
|
1575
|
-
return chunkValue;
|
1576
|
-
|
1577
|
-
case PENDING:
|
1578
|
-
case BLOCKED:
|
1579
|
-
case CYCLIC:
|
1580
|
-
const parentChunk = initializingChunk;
|
1581
|
-
chunk.then(createModelResolver(parentChunk, parentObject, key, chunk.status === CYCLIC), createModelReject(parentChunk));
|
1582
|
-
return null;
|
1583
|
-
|
1584
|
-
default:
|
1585
|
-
throw chunk.reason;
|
1586
|
-
}
|
1606
|
+
return getOutlinedModel(response, id, parentObject, key, createModel);
|
1587
1607
|
}
|
1588
1608
|
}
|
1589
1609
|
}
|
@@ -9,14 +9,14 @@
|
|
9
9
|
*/
|
10
10
|
'use strict';var aa=require("react-dom"),ba={stream:!0};function ca(a,b){if(a){var c=a[b[0]];if(a=c[b[2]])c=a.name;else{a=c["*"];if(!a)throw Error('Could not find the module "'+b[0]+'" in the React SSR Manifest. This is probably a bug in the React Server Components bundler.');c=b[2]}return 4===b.length?[a.id,a.chunks,c,1]:[a.id,a.chunks,c]}return b}var u=new Map;
|
11
11
|
function v(a){var b=__webpack_require__(a);if("function"!==typeof b.then||"fulfilled"===b.status)return null;b.then(function(c){b.status="fulfilled";b.value=c},function(c){b.status="rejected";b.reason=c});return b}function da(){}
|
12
|
-
function ea(a){for(var b=a[1],c=[],d=0;d<b.length;){var f=b[d++];b[d++];var g=u.get(f);if(void 0===g){g=__webpack_chunk_load__(f);c.push(g);var
|
13
|
-
function fa(a,b,c){if(null!==a)for(var d=1;d<b.length;d+=2){var f=c,g=w.
|
14
|
-
function
|
15
|
-
function H(a,b,c,d,f){function g(q,e){if(null===e)return null;if("object"===typeof e){switch(e.$$typeof){case
|
16
|
-
null!==r&&"function"===typeof r.then){
|
17
|
-
var na=
|
18
|
-
return"$T"+E(c,e).toString(16)}return e}if("string"===typeof e){if("Z"===e[e.length-1]&&this[q]instanceof Date)return"$D"+e;p="$"===e[0]?"$"+e:e;return p}if("boolean"===typeof e)return e;if("number"===typeof e)return ka(e);if("undefined"===typeof e)return"$undefined";if("function"===typeof e){p=F.get(e);if(void 0!==p)return p=JSON.stringify(p,g),null===
|
19
|
-
return"$T"+E(c,e).toString(16)}if("symbol"===typeof e){if(void 0===c)throw Error("Symbols cannot be passed to a Server Function without a temporary reference set. Pass a TemporaryReferenceSet to the options.");return"$T"+E(c,e).toString(16)}if("bigint"===typeof e)return"$n"+e.toString(10);throw Error("Type "+typeof e+" is not supported as an argument to a Server Function.");}var
|
12
|
+
function ea(a){for(var b=a[1],c=[],d=0;d<b.length;){var f=b[d++];b[d++];var g=u.get(f);if(void 0===g){g=__webpack_chunk_load__(f);c.push(g);var l=u.set.bind(u,f,null);g.then(l,da);u.set(f,g)}else null!==g&&c.push(g)}return 4===a.length?0===c.length?v(a[0]):Promise.all(c).then(function(){return v(a[0])}):0<c.length?Promise.all(c):null}
|
13
|
+
function fa(a,b,c){if(null!==a)for(var d=1;d<b.length;d+=2){var f=c,g=w.d,l=g.X,k=a.prefix+b[d];var m=a.crossOrigin;m="string"===typeof m?"use-credentials"===m?m:"":void 0;l.call(g,k,{crossOrigin:m,nonce:f})}}var w=aa.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,A=Symbol.for("react.element"),B=Symbol.for("react.lazy"),C=Symbol.iterator;function ha(a){if(null===a||"object"!==typeof a)return null;a=C&&a[C]||a["@@iterator"];return"function"===typeof a?a:null}var ia=Array.isArray,D=Object.getPrototypeOf;
|
14
|
+
function E(a,b){var c=a.length;a.push(b);return c}var ja=Object.prototype,F=new WeakMap;function ka(a){return Number.isFinite(a)?0===a&&-Infinity===1/a?"$-0":a:Infinity===a?"$Infinity":-Infinity===a?"$-Infinity":"$NaN"}
|
15
|
+
function H(a,b,c,d,f){function g(q,e){if(null===e)return null;if("object"===typeof e){switch(e.$$typeof){case A:if(void 0===c)throw Error("React Element cannot be passed to Server Functions from the Client without a temporary reference set. Pass a TemporaryReferenceSet to the options.");return"$T"+E(c,e).toString(16);case B:q=e._payload;var h=e._init;null===m&&(m=new FormData);k++;try{var p=h(q),n=l++,t=JSON.stringify(p,g);m.append(b+n,t);return"$"+n.toString(16)}catch(r){if("object"===typeof r&&
|
16
|
+
null!==r&&"function"===typeof r.then){k++;var y=l++;p=function(){try{var z=JSON.stringify(e,g),G=m;G.append(b+y,z);k--;0===k&&d(G)}catch(ma){f(ma)}};r.then(p,p);return"$"+y.toString(16)}f(r);return null}finally{k--}}if("function"===typeof e.then){null===m&&(m=new FormData);k++;var x=l++;e.then(function(r){try{var z=JSON.stringify(r,g);r=m;r.append(b+x,z);k--;0===k&&d(r)}catch(G){f(G)}},function(r){f(r)});return"$@"+x.toString(16)}if(ia(e))return e;if(e instanceof FormData){null===m&&(m=new FormData);
|
17
|
+
var na=m;p=l++;var oa=b+p+"_";e.forEach(function(r,z){na.append(oa+z,r)});return"$K"+p.toString(16)}if(e instanceof Map)return p=JSON.stringify(Array.from(e),g),null===m&&(m=new FormData),n=l++,m.append(b+n,p),"$Q"+n.toString(16);if(e instanceof Set)return p=JSON.stringify(Array.from(e),g),null===m&&(m=new FormData),n=l++,m.append(b+n,p),"$W"+n.toString(16);if(ha(e))return Array.from(e);p=D(e);if(p!==ja&&(null===p||null!==D(p))){if(void 0===c)throw Error("Only plain objects, and a few built-ins, can be passed to Server Actions. Classes or null prototypes are not supported.");
|
18
|
+
return"$T"+E(c,e).toString(16)}return e}if("string"===typeof e){if("Z"===e[e.length-1]&&this[q]instanceof Date)return"$D"+e;p="$"===e[0]?"$"+e:e;return p}if("boolean"===typeof e)return e;if("number"===typeof e)return ka(e);if("undefined"===typeof e)return"$undefined";if("function"===typeof e){p=F.get(e);if(void 0!==p)return p=JSON.stringify(p,g),null===m&&(m=new FormData),n=l++,m.set(b+n,p),"$F"+n.toString(16);if(void 0===c)throw Error("Client Functions cannot be passed directly to Server Functions. Only Functions passed from the Server can be passed back again.");
|
19
|
+
return"$T"+E(c,e).toString(16)}if("symbol"===typeof e){if(void 0===c)throw Error("Symbols cannot be passed to a Server Function without a temporary reference set. Pass a TemporaryReferenceSet to the options.");return"$T"+E(c,e).toString(16)}if("bigint"===typeof e)return"$n"+e.toString(10);throw Error("Type "+typeof e+" is not supported as an argument to a Server Function.");}var l=1,k=0,m=null;a=JSON.stringify(a,g);null===m?d(a):(m.set(b+"0",a),0===k&&d(m))}var I=new WeakMap;
|
20
20
|
function la(a){var b,c,d=new Promise(function(f,g){b=f;c=g});H(a,"",void 0,function(f){if("string"===typeof f){var g=new FormData;g.append("0",f);f=g}d.status="fulfilled";d.value=f;b(f)},function(f){d.status="rejected";d.reason=f;c(f)});return d}
|
21
21
|
function pa(a){var b=F.get(this);if(!b)throw Error("Tried to encode a Server Action from a different instance than the encoder is from. This is a bug in React.");var c=null;if(null!==b.bound){c=I.get(b);c||(c=la(b),I.set(b,c));if("rejected"===c.status)throw c.reason;if("fulfilled"!==c.status)throw c;b=c.value;var d=new FormData;b.forEach(function(f,g){d.append("$ACTION_"+a+":"+g,f)});c=d;b="$ACTION_REF_"+a}else b="$ACTION_ID_"+b.id;return{name:b,method:"POST",encType:"multipart/form-data",data:c}}
|
22
22
|
function J(a,b){var c=F.get(this);if(!c)throw Error("Tried to encode a Server Action from a different instance than the encoder is from. This is a bug in React.");if(c.id!==a)return!1;var d=c.bound;if(null===d)return 0===b;switch(d.status){case "fulfilled":return d.value.length===b;case "pending":throw d;case "rejected":throw d.reason;default:throw"string"!==typeof d.status&&(d.status="pending",d.then(function(f){d.status="fulfilled";d.value=f},function(f){d.status="rejected";d.reason=f})),d;}}
|
@@ -25,21 +25,22 @@ function L(){var a=qa.apply(this,arguments),b=F.get(this);if(b){var c=ra.call(ar
|
|
25
25
|
function M(a,b,c,d){this.status=a;this.value=b;this.reason=c;this._response=d}M.prototype=Object.create(Promise.prototype);M.prototype.then=function(a,b){switch(this.status){case "resolved_model":N(this);break;case "resolved_module":O(this)}switch(this.status){case "fulfilled":a(this.value);break;case "pending":case "blocked":case "cyclic":a&&(null===this.value&&(this.value=[]),this.value.push(a));b&&(null===this.reason&&(this.reason=[]),this.reason.push(b));break;default:b(this.reason)}};
|
26
26
|
function ta(a){switch(a.status){case "resolved_model":N(a);break;case "resolved_module":O(a)}switch(a.status){case "fulfilled":return a.value;case "pending":case "blocked":case "cyclic":throw a;default:throw a.reason;}}function P(a,b){for(var c=0;c<a.length;c++)(0,a[c])(b)}function Q(a,b,c){switch(a.status){case "fulfilled":P(b,a.value);break;case "pending":case "blocked":case "cyclic":a.value=b;a.reason=c;break;case "rejected":c&&P(c,a.reason)}}
|
27
27
|
function R(a,b){if("pending"===a.status||"blocked"===a.status){var c=a.reason;a.status="rejected";a.reason=b;null!==c&&P(c,b)}}function S(a,b){if("pending"===a.status||"blocked"===a.status){var c=a.value,d=a.reason;a.status="resolved_module";a.value=b;null!==c&&(O(a),Q(a,c,d))}}var T=null,U=null;
|
28
|
-
function N(a){var b=T,c=U;T=a;U=null;var d=a.value;a.status="cyclic";a.value=null;a.reason=null;try{var f=JSON.parse(d,a._response._fromJSON);if(null!==U&&0<U.deps)U.value=f,a.status="blocked",a.value=null,a.reason=null;else{var g=a.value;a.status="fulfilled";a.value=f;null!==g&&P(g,f)}}catch(
|
28
|
+
function N(a){var b=T,c=U;T=a;U=null;var d=a.value;a.status="cyclic";a.value=null;a.reason=null;try{var f=JSON.parse(d,a._response._fromJSON);if(null!==U&&0<U.deps)U.value=f,a.status="blocked",a.value=null,a.reason=null;else{var g=a.value;a.status="fulfilled";a.value=f;null!==g&&P(g,f)}}catch(l){a.status="rejected",a.reason=l}finally{T=b,U=c}}
|
29
29
|
function O(a){try{var b=a.value,c=__webpack_require__(b[0]);if(4===b.length&&"function"===typeof c.then)if("fulfilled"===c.status)c=c.value;else throw c.reason;var d="*"===b[2]?c:""===b[2]?c.__esModule?c.default:c:c[b[2]];a.status="fulfilled";a.value=d}catch(f){a.status="rejected",a.reason=f}}function V(a,b){a._chunks.forEach(function(c){"pending"===c.status&&R(c,b)})}function W(a,b){var c=a._chunks,d=c.get(b);d||(d=new M("pending",null,null,a),c.set(b,d));return d}
|
30
|
-
function ua(a,b,c,d){if(U){var
|
31
|
-
function wa(a,b){function c(){var f=Array.prototype.slice.call(arguments),g=b.bound;return g?"fulfilled"===g.status?d(b.id,g.value.concat(f)):Promise.resolve(g).then(function(
|
32
|
-
function
|
33
|
-
if(0
|
34
|
-
|
35
|
-
function
|
36
|
-
function
|
37
|
-
function
|
38
|
-
function
|
39
|
-
|
40
|
-
break;case "
|
41
|
-
|
42
|
-
|
43
|
-
|
30
|
+
function ua(a,b,c,d,f,g){if(U){var l=U;d||l.deps++}else l=U={deps:d?0:1,value:null};return function(k){b[c]=g(f,k);""===c&&null===l.value&&(l.value=b[c]);l.deps--;0===l.deps&&"blocked"===a.status&&(k=a.value,a.status="fulfilled",a.value=l.value,null!==k&&P(k,l.value))}}function va(a){return function(b){return R(a,b)}}
|
31
|
+
function wa(a,b){function c(){var f=Array.prototype.slice.call(arguments),g=b.bound;return g?"fulfilled"===g.status?d(b.id,g.value.concat(f)):Promise.resolve(g).then(function(l){return d(b.id,l.concat(f))}):d(b.id,f)}var d=a._callServer;K(c,b,a._encodeFormAction);return c}
|
32
|
+
function X(a,b,c,d,f){b=W(a,b);switch(b.status){case "resolved_model":N(b);break;case "resolved_module":O(b)}switch(b.status){case "fulfilled":return f(a,b.value);case "pending":case "blocked":case "cyclic":var g=T;b.then(ua(g,c,d,"cyclic"===b.status,a,f),va(g));return null;default:throw b.reason;}}function xa(a,b){return new Map(b)}function ya(a,b){return new Set(b)}function za(a,b){a=new FormData;for(var c=0;c<b.length;c++)a.append(b[c][0],b[c][1]);return a}function Aa(a,b){return b}
|
33
|
+
function Ba(a,b,c,d){if("$"===d[0]){if("$"===d)return A;switch(d[1]){case "$":return d.slice(1);case "L":return b=parseInt(d.slice(2),16),a=W(a,b),{$$typeof:B,_payload:a,_init:ta};case "@":if(2===d.length)return new Promise(function(){});b=parseInt(d.slice(2),16);return W(a,b);case "S":return Symbol.for(d.slice(2));case "F":return d=parseInt(d.slice(2),16),X(a,d,b,c,wa);case "T":b=parseInt(d.slice(2),16);a=a._tempRefs;if(null==a)throw Error("Missing a temporary reference set but the RSC response returned a temporary reference. Pass a temporaryReference option with the set that was used with the reply.");
|
34
|
+
if(0>b||b>=a.length)throw Error("The RSC response contained a reference that doesn't exist in the temporary reference set. Always pass the matching set that was used to create the reply when parsing its response.");return a[b];case "Q":return d=parseInt(d.slice(2),16),X(a,d,b,c,xa);case "W":return d=parseInt(d.slice(2),16),X(a,d,b,c,ya);case "B":return;case "K":return d=parseInt(d.slice(2),16),X(a,d,b,c,za);case "I":return Infinity;case "-":return"$-0"===d?-0:-Infinity;case "N":return NaN;case "u":return;
|
35
|
+
case "D":return new Date(Date.parse(d.slice(2)));case "n":return BigInt(d.slice(2));default:return d=parseInt(d.slice(1),16),X(a,d,b,c,Aa)}}return d}function Ca(){throw Error('Trying to call a function from "use server" but the callServer option was not implemented in your router runtime.');}
|
36
|
+
function Da(a,b,c){var d=a._chunks,f=d.get(b);c=JSON.parse(c,a._fromJSON);var g=ca(a._bundlerConfig,c);fa(a._moduleLoading,c[1],a._nonce);if(c=ea(g)){if(f){var l=f;l.status="blocked"}else l=new M("blocked",null,null,a),d.set(b,l);c.then(function(){return S(l,g)},function(k){return R(l,k)})}else f?S(f,g):d.set(b,new M("resolved_module",g,null,a))}
|
37
|
+
function Ea(a){return function(b,c){return"string"===typeof c?Ba(a,this,b,c):"object"===typeof c&&null!==c?(b=c[0]===A?{$$typeof:A,type:c[1],key:c[2],ref:null,props:c[3]}:c,b):c}}function Y(){throw Error("Server Functions cannot be called during initial render. This would create a fetch waterfall. Try to use a Server Component to pass data to Client Components instead.");}
|
38
|
+
function Z(a){var b=a.ssrManifest.moduleMap,c=a.ssrManifest.moduleLoading,d=a.encodeFormAction,f="string"===typeof a.nonce?a.nonce:void 0;a=a&&a.temporaryReferences?a.temporaryReferences:void 0;var g=new Map;b={_bundlerConfig:b,_moduleLoading:c,_callServer:void 0!==Y?Y:Ca,_encodeFormAction:d,_nonce:f,_chunks:g,_stringDecoder:new TextDecoder,_fromJSON:null,_rowState:0,_rowID:0,_rowTag:0,_rowLength:0,_buffer:[],_tempRefs:a};b._fromJSON=Ea(b);return b}
|
39
|
+
function Fa(a,b){function c(g){var l=g.value;if(g.done)V(a,Error("Connection closed."));else{var k=0,m=a._rowState,q=a._rowID,e=a._rowTag,h=a._rowLength;g=a._buffer;for(var p=l.length;k<p;){var n=-1;switch(m){case 0:n=l[k++];58===n?m=1:q=q<<4|(96<n?n-87:n-48);continue;case 1:m=l[k];84===m?(e=m,m=2,k++):64<m&&91>m?(e=m,m=3,k++):(e=0,m=3);continue;case 2:n=l[k++];44===n?m=4:h=h<<4|(96<n?n-87:n-48);continue;case 3:n=l.indexOf(10,k);break;case 4:n=k+h,n>l.length&&(n=-1)}var t=l.byteOffset+k;if(-1<n){k=
|
40
|
+
new Uint8Array(l.buffer,t,n-k);h=a;t=e;var y=h._stringDecoder;e="";for(var x=0;x<g.length;x++)e+=y.decode(g[x],ba);e+=y.decode(k);switch(t){case 73:Da(h,q,e);break;case 72:q=e[0];e=e.slice(1);h=JSON.parse(e,h._fromJSON);e=w.d;switch(q){case "D":e.D(h);break;case "C":"string"===typeof h?e.C(h):e.C(h[0],h[1]);break;case "L":q=h[0];k=h[1];3===h.length?e.L(q,k,h[2]):e.L(q,k);break;case "m":"string"===typeof h?e.m(h):e.m(h[0],h[1]);break;case "X":"string"===typeof h?e.X(h):e.X(h[0],h[1]);break;case "S":"string"===
|
41
|
+
typeof h?e.S(h):e.S(h[0],0===h[1]?void 0:h[1],3===h.length?h[2]:void 0);break;case "M":"string"===typeof h?e.M(h):e.M(h[0],h[1])}break;case 69:e=JSON.parse(e);k=e.digest;e=Error("An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error.");e.stack="Error: "+e.message;e.digest=k;k=h._chunks;(t=k.get(q))?
|
42
|
+
R(t,e):k.set(q,new M("rejected",null,e,h));break;case 84:h._chunks.set(q,new M("fulfilled",e,null,h));break;case 68:case 87:throw Error("Failed to read a RSC payload created by a development version of React on the server while using a production version on the client. Always use matching versions on the server and the client.");default:k=h._chunks,(t=k.get(q))?(h=t,q=e,"pending"===h.status&&(e=h.value,k=h.reason,h.status="resolved_model",h.value=q,null!==e&&(N(h),Q(h,e,k)))):k.set(q,new M("resolved_model",
|
43
|
+
e,null,h))}k=n;3===m&&k++;h=q=e=m=0;g.length=0}else{l=new Uint8Array(l.buffer,t,l.byteLength-k);g.push(l);h-=l.byteLength;break}}a._rowState=m;a._rowID=q;a._rowTag=e;a._rowLength=h;return f.read().then(c).catch(d)}}function d(g){V(a,g)}var f=b.getReader();f.read().then(c).catch(d)}exports.createFromFetch=function(a,b){var c=Z(b);a.then(function(d){Fa(c,d.body)},function(d){V(c,d)});return W(c,0)};exports.createFromReadableStream=function(a,b){b=Z(b);Fa(b,a);return W(b,0)};
|
44
|
+
exports.createServerReference=function(a){return sa(a,Y)};exports.createTemporaryReferenceSet=function(){return[]};exports.encodeReply=function(a,b){return new Promise(function(c,d){H(a,"",b&&b.temporaryReferences?b.temporaryReferences:void 0,c,d)})};
|
44
45
|
|
45
46
|
//# sourceMappingURL=react-server-dom-webpack-client.edge.production.min.js.map
|