react-server-dom-turbopack 19.1.7 → 19.1.9
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-turbopack-client.browser.development.js +2 -2
- package/cjs/react-server-dom-turbopack-server.browser.development.js +29 -29
- package/cjs/react-server-dom-turbopack-server.browser.production.js +26 -29
- package/cjs/react-server-dom-turbopack-server.edge.development.js +37 -36
- package/cjs/react-server-dom-turbopack-server.edge.production.js +34 -36
- package/cjs/react-server-dom-turbopack-server.node.development.js +99 -62
- package/cjs/react-server-dom-turbopack-server.node.production.js +95 -58
- package/package.json +5 -5
|
@@ -2730,10 +2730,10 @@
|
|
|
2730
2730
|
return hook.checkDCE ? !0 : !1;
|
|
2731
2731
|
})({
|
|
2732
2732
|
bundleType: 1,
|
|
2733
|
-
version: "19.1.
|
|
2733
|
+
version: "19.1.9",
|
|
2734
2734
|
rendererPackageName: "react-server-dom-turbopack",
|
|
2735
2735
|
currentDispatcherRef: ReactSharedInternals,
|
|
2736
|
-
reconcilerVersion: "19.1.
|
|
2736
|
+
reconcilerVersion: "19.1.9",
|
|
2737
2737
|
getCurrentComponentInfo: function () {
|
|
2738
2738
|
return currentOwnerInDEV;
|
|
2739
2739
|
}
|
|
@@ -918,7 +918,7 @@
|
|
|
918
918
|
erroredTask(request, streamTask, reason),
|
|
919
919
|
enqueueFlush(request),
|
|
920
920
|
"function" === typeof iterator.throw &&
|
|
921
|
-
iterator.throw(reason).then(
|
|
921
|
+
iterator.throw(reason).then(noop, noop));
|
|
922
922
|
}
|
|
923
923
|
function abortIterable(reason) {
|
|
924
924
|
aborted ||
|
|
@@ -927,7 +927,7 @@
|
|
|
927
927
|
erroredTask(request, streamTask, reason),
|
|
928
928
|
enqueueFlush(request),
|
|
929
929
|
"function" === typeof iterator.throw &&
|
|
930
|
-
iterator.throw(reason).then(
|
|
930
|
+
iterator.throw(reason).then(noop, noop));
|
|
931
931
|
}
|
|
932
932
|
var isIterator = iterable === iterator,
|
|
933
933
|
streamTask = createTask(
|
|
@@ -4401,44 +4401,44 @@
|
|
|
4401
4401
|
};
|
|
4402
4402
|
exports.decodeAction = function (body, serverManifest) {
|
|
4403
4403
|
var formData = new FormData(),
|
|
4404
|
-
|
|
4405
|
-
seenActions = new Set();
|
|
4404
|
+
maybeActionKey = null;
|
|
4406
4405
|
body.forEach(function (value, key) {
|
|
4407
4406
|
key.startsWith("$ACTION_")
|
|
4408
4407
|
? key.startsWith("$ACTION_REF_")
|
|
4409
|
-
?
|
|
4410
|
-
|
|
4411
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
4412
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
4413
|
-
(action = loadServerReference(serverManifest, value)))
|
|
4414
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
4415
|
-
!seenActions.has(key) &&
|
|
4416
|
-
(seenActions.add(key),
|
|
4417
|
-
(value = key.slice(11)),
|
|
4418
|
-
(action = loadServerReference(serverManifest, {
|
|
4419
|
-
id: value,
|
|
4420
|
-
bound: null
|
|
4421
|
-
})))
|
|
4408
|
+
? (maybeActionKey = key)
|
|
4409
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
4422
4410
|
: formData.append(key, value);
|
|
4423
4411
|
});
|
|
4424
|
-
|
|
4425
|
-
|
|
4426
|
-
|
|
4427
|
-
|
|
4428
|
-
|
|
4412
|
+
if (null === maybeActionKey) return null;
|
|
4413
|
+
var actionKey = maybeActionKey,
|
|
4414
|
+
action = null;
|
|
4415
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
4416
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
4417
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
4418
|
+
(action = loadServerReference(serverManifest, body));
|
|
4419
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
4420
|
+
(body = actionKey.slice(11)),
|
|
4421
|
+
(action = loadServerReference(serverManifest, {
|
|
4422
|
+
id: body,
|
|
4423
|
+
bound: null
|
|
4424
|
+
}));
|
|
4425
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
4426
|
+
return action.then(function (fn) {
|
|
4427
|
+
return fn.bind(null, formData);
|
|
4428
|
+
});
|
|
4429
4429
|
};
|
|
4430
4430
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
4431
4431
|
var keyPath = body.get("$ACTION_KEY");
|
|
4432
4432
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
4433
|
-
var
|
|
4433
|
+
var actionKey = null;
|
|
4434
4434
|
body.forEach(function (value, key) {
|
|
4435
|
-
key.startsWith("$ACTION_REF_") &&
|
|
4436
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
4437
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
4435
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
4438
4436
|
});
|
|
4439
|
-
if (null ===
|
|
4440
|
-
var
|
|
4441
|
-
|
|
4437
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
4438
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
4439
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
4440
|
+
var referenceId = body.id;
|
|
4441
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
4442
4442
|
return null === bound
|
|
4443
4443
|
? null
|
|
4444
4444
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -924,7 +924,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
924
924
|
erroredTask(request, streamTask, reason),
|
|
925
925
|
enqueueFlush(request),
|
|
926
926
|
"function" === typeof iterator.throw &&
|
|
927
|
-
iterator.throw(reason).then(
|
|
927
|
+
iterator.throw(reason).then(noop, noop));
|
|
928
928
|
}
|
|
929
929
|
function abortIterable(reason) {
|
|
930
930
|
aborted ||
|
|
@@ -933,7 +933,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
933
933
|
erroredTask(request, streamTask, reason),
|
|
934
934
|
enqueueFlush(request),
|
|
935
935
|
"function" === typeof iterator.throw &&
|
|
936
|
-
iterator.throw(reason).then(
|
|
936
|
+
iterator.throw(reason).then(noop, noop));
|
|
937
937
|
}
|
|
938
938
|
iterable = iterable === iterator;
|
|
939
939
|
var streamTask = createTask(
|
|
@@ -3128,44 +3128,41 @@ exports.createTemporaryReferenceSet = function () {
|
|
|
3128
3128
|
};
|
|
3129
3129
|
exports.decodeAction = function (body, serverManifest) {
|
|
3130
3130
|
var formData = new FormData(),
|
|
3131
|
-
|
|
3132
|
-
seenActions = new Set();
|
|
3131
|
+
maybeActionKey = null;
|
|
3133
3132
|
body.forEach(function (value, key) {
|
|
3134
3133
|
key.startsWith("$ACTION_")
|
|
3135
3134
|
? key.startsWith("$ACTION_REF_")
|
|
3136
|
-
?
|
|
3137
|
-
|
|
3138
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
3139
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
3140
|
-
(action = loadServerReference(serverManifest, value)))
|
|
3141
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
3142
|
-
!seenActions.has(key) &&
|
|
3143
|
-
(seenActions.add(key),
|
|
3144
|
-
(value = key.slice(11)),
|
|
3145
|
-
(action = loadServerReference(serverManifest, {
|
|
3146
|
-
id: value,
|
|
3147
|
-
bound: null
|
|
3148
|
-
})))
|
|
3135
|
+
? (maybeActionKey = key)
|
|
3136
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
3149
3137
|
: formData.append(key, value);
|
|
3150
3138
|
});
|
|
3151
|
-
|
|
3152
|
-
|
|
3153
|
-
|
|
3154
|
-
|
|
3155
|
-
|
|
3139
|
+
if (null === maybeActionKey) return null;
|
|
3140
|
+
var actionKey = maybeActionKey,
|
|
3141
|
+
action = null;
|
|
3142
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
3143
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
3144
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
3145
|
+
(action = loadServerReference(serverManifest, body));
|
|
3146
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
3147
|
+
(body = actionKey.slice(11)),
|
|
3148
|
+
(action = loadServerReference(serverManifest, { id: body, bound: null }));
|
|
3149
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
3150
|
+
return action.then(function (fn) {
|
|
3151
|
+
return fn.bind(null, formData);
|
|
3152
|
+
});
|
|
3156
3153
|
};
|
|
3157
3154
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
3158
3155
|
var keyPath = body.get("$ACTION_KEY");
|
|
3159
3156
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
3160
|
-
var
|
|
3157
|
+
var actionKey = null;
|
|
3161
3158
|
body.forEach(function (value, key) {
|
|
3162
|
-
key.startsWith("$ACTION_REF_") &&
|
|
3163
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
3164
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
3159
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
3165
3160
|
});
|
|
3166
|
-
if (null ===
|
|
3167
|
-
var
|
|
3168
|
-
|
|
3161
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
3162
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
3163
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
3164
|
+
var referenceId = body.id;
|
|
3165
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
3169
3166
|
return null === bound
|
|
3170
3167
|
? null
|
|
3171
3168
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -253,13 +253,13 @@
|
|
|
253
253
|
temporaryReferences.set(reference, id);
|
|
254
254
|
return reference;
|
|
255
255
|
}
|
|
256
|
-
function noop$
|
|
256
|
+
function noop$2() {}
|
|
257
257
|
function trackUsedThenable(thenableState, thenable, index) {
|
|
258
258
|
index = thenableState[index];
|
|
259
259
|
void 0 === index
|
|
260
260
|
? thenableState.push(thenable)
|
|
261
261
|
: index !== thenable &&
|
|
262
|
-
(thenable.then(noop$
|
|
262
|
+
(thenable.then(noop$2, noop$2), (thenable = index));
|
|
263
263
|
switch (thenable.status) {
|
|
264
264
|
case "fulfilled":
|
|
265
265
|
return thenable.value;
|
|
@@ -267,7 +267,7 @@
|
|
|
267
267
|
throw thenable.reason;
|
|
268
268
|
default:
|
|
269
269
|
"string" === typeof thenable.status
|
|
270
|
-
? thenable.then(noop$
|
|
270
|
+
? thenable.then(noop$2, noop$2)
|
|
271
271
|
: ((thenableState = thenable),
|
|
272
272
|
(thenableState.status = "pending"),
|
|
273
273
|
thenableState.then(
|
|
@@ -711,7 +711,7 @@
|
|
|
711
711
|
type = createTask(this, model, null, !1, abortSet, null, null, null);
|
|
712
712
|
pingedTasks.push(type);
|
|
713
713
|
}
|
|
714
|
-
function noop() {}
|
|
714
|
+
function noop$1() {}
|
|
715
715
|
function createRequest(
|
|
716
716
|
model,
|
|
717
717
|
bundlerConfig,
|
|
@@ -733,8 +733,8 @@
|
|
|
733
733
|
temporaryReferences,
|
|
734
734
|
environmentName,
|
|
735
735
|
filterStackFrame,
|
|
736
|
-
noop,
|
|
737
|
-
noop
|
|
736
|
+
noop$1,
|
|
737
|
+
noop$1
|
|
738
738
|
);
|
|
739
739
|
}
|
|
740
740
|
function createPrerenderRequest(
|
|
@@ -933,7 +933,7 @@
|
|
|
933
933
|
erroredTask(request, streamTask, reason),
|
|
934
934
|
enqueueFlush(request),
|
|
935
935
|
"function" === typeof iterator.throw &&
|
|
936
|
-
iterator.throw(reason).then(
|
|
936
|
+
iterator.throw(reason).then(noop$1, noop$1));
|
|
937
937
|
}
|
|
938
938
|
function abortIterable(reason) {
|
|
939
939
|
aborted ||
|
|
@@ -942,7 +942,7 @@
|
|
|
942
942
|
erroredTask(request, streamTask, reason),
|
|
943
943
|
enqueueFlush(request),
|
|
944
944
|
"function" === typeof iterator.throw &&
|
|
945
|
-
iterator.throw(reason).then(
|
|
945
|
+
iterator.throw(reason).then(noop$1, noop$1));
|
|
946
946
|
}
|
|
947
947
|
var isIterator = iterable === iterator,
|
|
948
948
|
streamTask = createTask(
|
|
@@ -3963,6 +3963,7 @@
|
|
|
3963
3963
|
if ("fulfilled" !== body.status) throw body.reason;
|
|
3964
3964
|
return body.value;
|
|
3965
3965
|
}
|
|
3966
|
+
function noop() {}
|
|
3966
3967
|
var ReactDOM = require("react-dom"),
|
|
3967
3968
|
React = require("react"),
|
|
3968
3969
|
REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element"),
|
|
@@ -4491,44 +4492,44 @@
|
|
|
4491
4492
|
};
|
|
4492
4493
|
exports.decodeAction = function (body, serverManifest) {
|
|
4493
4494
|
var formData = new FormData(),
|
|
4494
|
-
|
|
4495
|
-
seenActions = new Set();
|
|
4495
|
+
maybeActionKey = null;
|
|
4496
4496
|
body.forEach(function (value, key) {
|
|
4497
4497
|
key.startsWith("$ACTION_")
|
|
4498
4498
|
? key.startsWith("$ACTION_REF_")
|
|
4499
|
-
?
|
|
4500
|
-
|
|
4501
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
4502
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
4503
|
-
(action = loadServerReference(serverManifest, value)))
|
|
4504
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
4505
|
-
!seenActions.has(key) &&
|
|
4506
|
-
(seenActions.add(key),
|
|
4507
|
-
(value = key.slice(11)),
|
|
4508
|
-
(action = loadServerReference(serverManifest, {
|
|
4509
|
-
id: value,
|
|
4510
|
-
bound: null
|
|
4511
|
-
})))
|
|
4499
|
+
? (maybeActionKey = key)
|
|
4500
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
4512
4501
|
: formData.append(key, value);
|
|
4513
4502
|
});
|
|
4514
|
-
|
|
4515
|
-
|
|
4516
|
-
|
|
4517
|
-
|
|
4518
|
-
|
|
4503
|
+
if (null === maybeActionKey) return null;
|
|
4504
|
+
var actionKey = maybeActionKey,
|
|
4505
|
+
action = null;
|
|
4506
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
4507
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
4508
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
4509
|
+
(action = loadServerReference(serverManifest, body));
|
|
4510
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
4511
|
+
(body = actionKey.slice(11)),
|
|
4512
|
+
(action = loadServerReference(serverManifest, {
|
|
4513
|
+
id: body,
|
|
4514
|
+
bound: null
|
|
4515
|
+
}));
|
|
4516
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
4517
|
+
return action.then(function (fn) {
|
|
4518
|
+
return fn.bind(null, formData);
|
|
4519
|
+
});
|
|
4519
4520
|
};
|
|
4520
4521
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
4521
4522
|
var keyPath = body.get("$ACTION_KEY");
|
|
4522
4523
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
4523
|
-
var
|
|
4524
|
+
var actionKey = null;
|
|
4524
4525
|
body.forEach(function (value, key) {
|
|
4525
|
-
key.startsWith("$ACTION_REF_") &&
|
|
4526
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
4527
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
4526
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
4528
4527
|
});
|
|
4529
|
-
if (null ===
|
|
4530
|
-
var
|
|
4531
|
-
|
|
4528
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
4529
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
4530
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
4531
|
+
var referenceId = body.id;
|
|
4532
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
4532
4533
|
return null === bound
|
|
4533
4534
|
? null
|
|
4534
4535
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -4579,7 +4580,7 @@
|
|
|
4579
4580
|
function error(reason) {
|
|
4580
4581
|
reportGlobalError(response$jscomp$0, reason);
|
|
4581
4582
|
"function" === typeof iterator.throw &&
|
|
4582
|
-
iterator.throw(reason).then(
|
|
4583
|
+
iterator.throw(reason).then(noop, noop);
|
|
4583
4584
|
}
|
|
4584
4585
|
var iterator = iterable[ASYNC_ITERATOR](),
|
|
4585
4586
|
response$jscomp$0 = createResponse(
|
|
@@ -451,12 +451,12 @@ function createTemporaryReference(temporaryReferences, id) {
|
|
|
451
451
|
var SuspenseException = Error(
|
|
452
452
|
"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`."
|
|
453
453
|
);
|
|
454
|
-
function noop$
|
|
454
|
+
function noop$2() {}
|
|
455
455
|
function trackUsedThenable(thenableState, thenable, index) {
|
|
456
456
|
index = thenableState[index];
|
|
457
457
|
void 0 === index
|
|
458
458
|
? thenableState.push(thenable)
|
|
459
|
-
: index !== thenable && (thenable.then(noop$
|
|
459
|
+
: index !== thenable && (thenable.then(noop$2, noop$2), (thenable = index));
|
|
460
460
|
switch (thenable.status) {
|
|
461
461
|
case "fulfilled":
|
|
462
462
|
return thenable.value;
|
|
@@ -464,7 +464,7 @@ function trackUsedThenable(thenableState, thenable, index) {
|
|
|
464
464
|
throw thenable.reason;
|
|
465
465
|
default:
|
|
466
466
|
"string" === typeof thenable.status
|
|
467
|
-
? thenable.then(noop$
|
|
467
|
+
? thenable.then(noop$2, noop$2)
|
|
468
468
|
: ((thenableState = thenable),
|
|
469
469
|
(thenableState.status = "pending"),
|
|
470
470
|
thenableState.then(
|
|
@@ -769,7 +769,7 @@ function RequestInstance(
|
|
|
769
769
|
type = createTask(this, model, null, !1, filterStackFrame);
|
|
770
770
|
environmentName.push(type);
|
|
771
771
|
}
|
|
772
|
-
function noop() {}
|
|
772
|
+
function noop$1() {}
|
|
773
773
|
var currentRequest = null;
|
|
774
774
|
function resolveRequest() {
|
|
775
775
|
if (currentRequest) return currentRequest;
|
|
@@ -929,7 +929,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
929
929
|
erroredTask(request, streamTask, reason),
|
|
930
930
|
enqueueFlush(request),
|
|
931
931
|
"function" === typeof iterator.throw &&
|
|
932
|
-
iterator.throw(reason).then(
|
|
932
|
+
iterator.throw(reason).then(noop$1, noop$1));
|
|
933
933
|
}
|
|
934
934
|
function abortIterable(reason) {
|
|
935
935
|
aborted ||
|
|
@@ -938,7 +938,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
938
938
|
erroredTask(request, streamTask, reason),
|
|
939
939
|
enqueueFlush(request),
|
|
940
940
|
"function" === typeof iterator.throw &&
|
|
941
|
-
iterator.throw(reason).then(
|
|
941
|
+
iterator.throw(reason).then(noop$1, noop$1));
|
|
942
942
|
}
|
|
943
943
|
iterable = iterable === iterator;
|
|
944
944
|
var streamTask = createTask(
|
|
@@ -3138,6 +3138,7 @@ function decodeBoundActionMetaData(
|
|
|
3138
3138
|
if ("fulfilled" !== body.status) throw body.reason;
|
|
3139
3139
|
return body.value;
|
|
3140
3140
|
}
|
|
3141
|
+
function noop() {}
|
|
3141
3142
|
exports.createClientModuleProxy = function (moduleId) {
|
|
3142
3143
|
moduleId = registerClientReferenceImpl({}, moduleId, !1);
|
|
3143
3144
|
return new Proxy(moduleId, proxyHandlers$1);
|
|
@@ -3147,44 +3148,41 @@ exports.createTemporaryReferenceSet = function () {
|
|
|
3147
3148
|
};
|
|
3148
3149
|
exports.decodeAction = function (body, serverManifest) {
|
|
3149
3150
|
var formData = new FormData(),
|
|
3150
|
-
|
|
3151
|
-
seenActions = new Set();
|
|
3151
|
+
maybeActionKey = null;
|
|
3152
3152
|
body.forEach(function (value, key) {
|
|
3153
3153
|
key.startsWith("$ACTION_")
|
|
3154
3154
|
? key.startsWith("$ACTION_REF_")
|
|
3155
|
-
?
|
|
3156
|
-
|
|
3157
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
3158
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
3159
|
-
(action = loadServerReference(serverManifest, value)))
|
|
3160
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
3161
|
-
!seenActions.has(key) &&
|
|
3162
|
-
(seenActions.add(key),
|
|
3163
|
-
(value = key.slice(11)),
|
|
3164
|
-
(action = loadServerReference(serverManifest, {
|
|
3165
|
-
id: value,
|
|
3166
|
-
bound: null
|
|
3167
|
-
})))
|
|
3155
|
+
? (maybeActionKey = key)
|
|
3156
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
3168
3157
|
: formData.append(key, value);
|
|
3169
3158
|
});
|
|
3170
|
-
|
|
3171
|
-
|
|
3172
|
-
|
|
3173
|
-
|
|
3174
|
-
|
|
3159
|
+
if (null === maybeActionKey) return null;
|
|
3160
|
+
var actionKey = maybeActionKey,
|
|
3161
|
+
action = null;
|
|
3162
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
3163
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
3164
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
3165
|
+
(action = loadServerReference(serverManifest, body));
|
|
3166
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
3167
|
+
(body = actionKey.slice(11)),
|
|
3168
|
+
(action = loadServerReference(serverManifest, { id: body, bound: null }));
|
|
3169
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
3170
|
+
return action.then(function (fn) {
|
|
3171
|
+
return fn.bind(null, formData);
|
|
3172
|
+
});
|
|
3175
3173
|
};
|
|
3176
3174
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
3177
3175
|
var keyPath = body.get("$ACTION_KEY");
|
|
3178
3176
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
3179
|
-
var
|
|
3177
|
+
var actionKey = null;
|
|
3180
3178
|
body.forEach(function (value, key) {
|
|
3181
|
-
key.startsWith("$ACTION_REF_") &&
|
|
3182
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
3183
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
3179
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
3184
3180
|
});
|
|
3185
|
-
if (null ===
|
|
3186
|
-
var
|
|
3187
|
-
|
|
3181
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
3182
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
3183
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
3184
|
+
var referenceId = body.id;
|
|
3185
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
3188
3186
|
return null === bound
|
|
3189
3187
|
? null
|
|
3190
3188
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -3234,7 +3232,7 @@ exports.decodeReplyFromAsyncIterable = function (
|
|
|
3234
3232
|
function error(reason) {
|
|
3235
3233
|
reportGlobalError(response, reason);
|
|
3236
3234
|
"function" === typeof iterator.throw &&
|
|
3237
|
-
iterator.throw(reason).then(
|
|
3235
|
+
iterator.throw(reason).then(noop, noop);
|
|
3238
3236
|
}
|
|
3239
3237
|
var iterator = iterable[ASYNC_ITERATOR](),
|
|
3240
3238
|
response = createResponse(
|
|
@@ -3281,8 +3279,8 @@ exports.renderToReadableStream = function (model, turbopackMap, options) {
|
|
|
3281
3279
|
options ? options.temporaryReferences : void 0,
|
|
3282
3280
|
void 0,
|
|
3283
3281
|
void 0,
|
|
3284
|
-
noop,
|
|
3285
|
-
noop
|
|
3282
|
+
noop$1,
|
|
3283
|
+
noop$1
|
|
3286
3284
|
);
|
|
3287
3285
|
if (options && options.signal) {
|
|
3288
3286
|
var signal = options.signal;
|
|
@@ -954,7 +954,7 @@
|
|
|
954
954
|
erroredTask(request, streamTask, reason),
|
|
955
955
|
enqueueFlush(request),
|
|
956
956
|
"function" === typeof iterator.throw &&
|
|
957
|
-
iterator.throw(reason).then(
|
|
957
|
+
iterator.throw(reason).then(noop, noop));
|
|
958
958
|
}
|
|
959
959
|
function abortIterable(reason) {
|
|
960
960
|
aborted ||
|
|
@@ -963,7 +963,7 @@
|
|
|
963
963
|
erroredTask(request, streamTask, reason),
|
|
964
964
|
enqueueFlush(request),
|
|
965
965
|
"function" === typeof iterator.throw &&
|
|
966
|
-
iterator.throw(reason).then(
|
|
966
|
+
iterator.throw(reason).then(noop, noop));
|
|
967
967
|
}
|
|
968
968
|
var isIterator = iterable === iterator,
|
|
969
969
|
streamTask = createTask(
|
|
@@ -4487,44 +4487,44 @@
|
|
|
4487
4487
|
};
|
|
4488
4488
|
exports.decodeAction = function (body, serverManifest) {
|
|
4489
4489
|
var formData = new FormData(),
|
|
4490
|
-
|
|
4491
|
-
seenActions = new Set();
|
|
4490
|
+
maybeActionKey = null;
|
|
4492
4491
|
body.forEach(function (value, key) {
|
|
4493
4492
|
key.startsWith("$ACTION_")
|
|
4494
4493
|
? key.startsWith("$ACTION_REF_")
|
|
4495
|
-
?
|
|
4496
|
-
|
|
4497
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
4498
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
4499
|
-
(action = loadServerReference(serverManifest, value)))
|
|
4500
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
4501
|
-
!seenActions.has(key) &&
|
|
4502
|
-
(seenActions.add(key),
|
|
4503
|
-
(value = key.slice(11)),
|
|
4504
|
-
(action = loadServerReference(serverManifest, {
|
|
4505
|
-
id: value,
|
|
4506
|
-
bound: null
|
|
4507
|
-
})))
|
|
4494
|
+
? (maybeActionKey = key)
|
|
4495
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
4508
4496
|
: formData.append(key, value);
|
|
4509
4497
|
});
|
|
4510
|
-
|
|
4511
|
-
|
|
4512
|
-
|
|
4513
|
-
|
|
4514
|
-
|
|
4498
|
+
if (null === maybeActionKey) return null;
|
|
4499
|
+
var actionKey = maybeActionKey,
|
|
4500
|
+
action = null;
|
|
4501
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
4502
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
4503
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
4504
|
+
(action = loadServerReference(serverManifest, body));
|
|
4505
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
4506
|
+
(body = actionKey.slice(11)),
|
|
4507
|
+
(action = loadServerReference(serverManifest, {
|
|
4508
|
+
id: body,
|
|
4509
|
+
bound: null
|
|
4510
|
+
}));
|
|
4511
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
4512
|
+
return action.then(function (fn) {
|
|
4513
|
+
return fn.bind(null, formData);
|
|
4514
|
+
});
|
|
4515
4515
|
};
|
|
4516
4516
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
4517
4517
|
var keyPath = body.get("$ACTION_KEY");
|
|
4518
4518
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
4519
|
-
var
|
|
4519
|
+
var actionKey = null;
|
|
4520
4520
|
body.forEach(function (value, key) {
|
|
4521
|
-
key.startsWith("$ACTION_REF_") &&
|
|
4522
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
4523
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
4521
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
4524
4522
|
});
|
|
4525
|
-
if (null ===
|
|
4526
|
-
var
|
|
4527
|
-
|
|
4523
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
4524
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
4525
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
4526
|
+
var referenceId = body.id;
|
|
4527
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
4528
4528
|
return null === bound
|
|
4529
4529
|
? null
|
|
4530
4530
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -4552,20 +4552,58 @@
|
|
|
4552
4552
|
turbopackMap,
|
|
4553
4553
|
options
|
|
4554
4554
|
) {
|
|
4555
|
-
|
|
4555
|
+
function flush() {
|
|
4556
|
+
for (; null !== head; ) {
|
|
4557
|
+
var current = head;
|
|
4558
|
+
if (!current.complete) return;
|
|
4559
|
+
try {
|
|
4560
|
+
var response = response$jscomp$0,
|
|
4561
|
+
key = current.name,
|
|
4562
|
+
handle = current.file,
|
|
4563
|
+
blob = new Blob(handle.chunks, { type: handle.mime }),
|
|
4564
|
+
backingStore = response._formData;
|
|
4565
|
+
response = key;
|
|
4566
|
+
backingStore.data.append(response, blob, handle.filename);
|
|
4567
|
+
var keys = backingStore.keys;
|
|
4568
|
+
null === keys
|
|
4569
|
+
? ((backingStore.keys = Array.from(backingStore.data.keys())),
|
|
4570
|
+
(backingStore.keyPointer = 0))
|
|
4571
|
+
: keys.push(response);
|
|
4572
|
+
var queuedFields = current.queuedFields;
|
|
4573
|
+
if (null !== queuedFields)
|
|
4574
|
+
for (response = 0; response < queuedFields.length; response += 2)
|
|
4575
|
+
resolveField(
|
|
4576
|
+
response$jscomp$0,
|
|
4577
|
+
queuedFields[response],
|
|
4578
|
+
queuedFields[response + 1]
|
|
4579
|
+
);
|
|
4580
|
+
} catch (error) {
|
|
4581
|
+
busboyStream.destroy(error);
|
|
4582
|
+
return;
|
|
4583
|
+
}
|
|
4584
|
+
head = current.next;
|
|
4585
|
+
}
|
|
4586
|
+
tail = null;
|
|
4587
|
+
bodyFinished && !closed && ((closed = !0), close(response$jscomp$0));
|
|
4588
|
+
}
|
|
4589
|
+
var response$jscomp$0 = createResponse(
|
|
4556
4590
|
turbopackMap,
|
|
4557
4591
|
"",
|
|
4558
4592
|
options ? options.temporaryReferences : void 0,
|
|
4559
4593
|
void 0,
|
|
4560
4594
|
options ? options.arraySizeLimit : void 0
|
|
4561
4595
|
),
|
|
4562
|
-
|
|
4563
|
-
|
|
4596
|
+
head = null,
|
|
4597
|
+
tail = null,
|
|
4598
|
+
bodyFinished = !1,
|
|
4599
|
+
closed = !1;
|
|
4564
4600
|
busboyStream.on("field", function (name, value) {
|
|
4565
|
-
if (
|
|
4601
|
+
if (null !== tail)
|
|
4602
|
+
null === tail.queuedFields && (tail.queuedFields = []),
|
|
4603
|
+
tail.queuedFields.push(name, value);
|
|
4566
4604
|
else
|
|
4567
4605
|
try {
|
|
4568
|
-
resolveField(response, name, value);
|
|
4606
|
+
resolveField(response$jscomp$0, name, value);
|
|
4569
4607
|
} catch (error) {
|
|
4570
4608
|
busboyStream.destroy(error);
|
|
4571
4609
|
}
|
|
@@ -4580,46 +4618,45 @@
|
|
|
4580
4618
|
)
|
|
4581
4619
|
);
|
|
4582
4620
|
else {
|
|
4583
|
-
|
|
4584
|
-
|
|
4621
|
+
var file = { chunks: [], filename: filename, mime: mimeType },
|
|
4622
|
+
pendingFile = {
|
|
4623
|
+
name: name,
|
|
4624
|
+
file: file,
|
|
4625
|
+
complete: !1,
|
|
4626
|
+
queuedFields: null,
|
|
4627
|
+
next: null
|
|
4628
|
+
};
|
|
4629
|
+
null === tail ? (head = pendingFile) : (tail.next = pendingFile);
|
|
4630
|
+
tail = pendingFile;
|
|
4585
4631
|
value.on("data", function (chunk) {
|
|
4586
|
-
JSCompiler_object_inline_chunks_174.push(chunk);
|
|
4587
|
-
});
|
|
4588
|
-
value.on("end", function () {
|
|
4589
4632
|
try {
|
|
4590
|
-
|
|
4591
|
-
type: mimeType
|
|
4592
|
-
}),
|
|
4593
|
-
backingStore = response._formData;
|
|
4594
|
-
backingStore.data.append(name, blob, filename);
|
|
4595
|
-
var keys = backingStore.keys;
|
|
4596
|
-
null === keys
|
|
4597
|
-
? ((backingStore.keys = Array.from(backingStore.data.keys())),
|
|
4598
|
-
(backingStore.keyPointer = 0))
|
|
4599
|
-
: keys.push(name);
|
|
4600
|
-
pendingFiles--;
|
|
4601
|
-
if (0 === pendingFiles) {
|
|
4602
|
-
for (blob = 0; blob < queuedFields.length; blob += 2)
|
|
4603
|
-
resolveField(
|
|
4604
|
-
response,
|
|
4605
|
-
queuedFields[blob],
|
|
4606
|
-
queuedFields[blob + 1]
|
|
4607
|
-
);
|
|
4608
|
-
queuedFields.length = 0;
|
|
4609
|
-
}
|
|
4633
|
+
file.chunks.push(chunk);
|
|
4610
4634
|
} catch (error) {
|
|
4611
4635
|
busboyStream.destroy(error);
|
|
4612
4636
|
}
|
|
4613
4637
|
});
|
|
4638
|
+
value.on("error", function (error) {
|
|
4639
|
+
busboyStream.destroy(error);
|
|
4640
|
+
});
|
|
4641
|
+
value.on("end", function () {
|
|
4642
|
+
pendingFile.complete = !0;
|
|
4643
|
+
flush();
|
|
4644
|
+
});
|
|
4614
4645
|
}
|
|
4615
4646
|
});
|
|
4616
4647
|
busboyStream.on("finish", function () {
|
|
4617
|
-
|
|
4648
|
+
bodyFinished = !0;
|
|
4649
|
+
flush();
|
|
4650
|
+
closed ||
|
|
4651
|
+
reportGlobalError(
|
|
4652
|
+
response$jscomp$0,
|
|
4653
|
+
Error("Reply finished with incomplete file part.")
|
|
4654
|
+
);
|
|
4618
4655
|
});
|
|
4619
4656
|
busboyStream.on("error", function (err) {
|
|
4620
|
-
reportGlobalError(response, err);
|
|
4657
|
+
reportGlobalError(response$jscomp$0, err);
|
|
4621
4658
|
});
|
|
4622
|
-
return getChunk(response, 0);
|
|
4659
|
+
return getChunk(response$jscomp$0, 0);
|
|
4623
4660
|
};
|
|
4624
4661
|
exports.registerClientReference = function (
|
|
4625
4662
|
proxyImplementation,
|
|
@@ -946,7 +946,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
946
946
|
erroredTask(request, streamTask, reason),
|
|
947
947
|
enqueueFlush(request),
|
|
948
948
|
"function" === typeof iterator.throw &&
|
|
949
|
-
iterator.throw(reason).then(
|
|
949
|
+
iterator.throw(reason).then(noop, noop));
|
|
950
950
|
}
|
|
951
951
|
function abortIterable(reason) {
|
|
952
952
|
aborted ||
|
|
@@ -955,7 +955,7 @@ function serializeAsyncIterable(request, task, iterable, iterator) {
|
|
|
955
955
|
erroredTask(request, streamTask, reason),
|
|
956
956
|
enqueueFlush(request),
|
|
957
957
|
"function" === typeof iterator.throw &&
|
|
958
|
-
iterator.throw(reason).then(
|
|
958
|
+
iterator.throw(reason).then(noop, noop));
|
|
959
959
|
}
|
|
960
960
|
iterable = iterable === iterator;
|
|
961
961
|
var streamTask = createTask(
|
|
@@ -3203,44 +3203,41 @@ exports.createTemporaryReferenceSet = function () {
|
|
|
3203
3203
|
};
|
|
3204
3204
|
exports.decodeAction = function (body, serverManifest) {
|
|
3205
3205
|
var formData = new FormData(),
|
|
3206
|
-
|
|
3207
|
-
seenActions = new Set();
|
|
3206
|
+
maybeActionKey = null;
|
|
3208
3207
|
body.forEach(function (value, key) {
|
|
3209
3208
|
key.startsWith("$ACTION_")
|
|
3210
3209
|
? key.startsWith("$ACTION_REF_")
|
|
3211
|
-
?
|
|
3212
|
-
|
|
3213
|
-
(value = "$ACTION_" + key.slice(12) + ":"),
|
|
3214
|
-
(value = decodeBoundActionMetaData(body, serverManifest, value)),
|
|
3215
|
-
(action = loadServerReference(serverManifest, value)))
|
|
3216
|
-
: key.startsWith("$ACTION_ID_") &&
|
|
3217
|
-
!seenActions.has(key) &&
|
|
3218
|
-
(seenActions.add(key),
|
|
3219
|
-
(value = key.slice(11)),
|
|
3220
|
-
(action = loadServerReference(serverManifest, {
|
|
3221
|
-
id: value,
|
|
3222
|
-
bound: null
|
|
3223
|
-
})))
|
|
3210
|
+
? (maybeActionKey = key)
|
|
3211
|
+
: key.startsWith("$ACTION_ID_") && (maybeActionKey = key)
|
|
3224
3212
|
: formData.append(key, value);
|
|
3225
3213
|
});
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3214
|
+
if (null === maybeActionKey) return null;
|
|
3215
|
+
var actionKey = maybeActionKey,
|
|
3216
|
+
action = null;
|
|
3217
|
+
if (actionKey.startsWith("$ACTION_REF_"))
|
|
3218
|
+
(actionKey = "$ACTION_" + actionKey.slice(12) + ":"),
|
|
3219
|
+
(body = decodeBoundActionMetaData(body, serverManifest, actionKey)),
|
|
3220
|
+
(action = loadServerReference(serverManifest, body));
|
|
3221
|
+
else if (actionKey.startsWith("$ACTION_ID_"))
|
|
3222
|
+
(body = actionKey.slice(11)),
|
|
3223
|
+
(action = loadServerReference(serverManifest, { id: body, bound: null }));
|
|
3224
|
+
else throw Error("Cannot handle action key. This is a bug in React.");
|
|
3225
|
+
return action.then(function (fn) {
|
|
3226
|
+
return fn.bind(null, formData);
|
|
3227
|
+
});
|
|
3231
3228
|
};
|
|
3232
3229
|
exports.decodeFormState = function (actionResult, body, serverManifest) {
|
|
3233
3230
|
var keyPath = body.get("$ACTION_KEY");
|
|
3234
3231
|
if ("string" !== typeof keyPath) return Promise.resolve(null);
|
|
3235
|
-
var
|
|
3232
|
+
var actionKey = null;
|
|
3236
3233
|
body.forEach(function (value, key) {
|
|
3237
|
-
key.startsWith("$ACTION_REF_") &&
|
|
3238
|
-
((value = "$ACTION_" + key.slice(12) + ":"),
|
|
3239
|
-
(metaData = decodeBoundActionMetaData(body, serverManifest, value)));
|
|
3234
|
+
key.startsWith("$ACTION_REF_") && (actionKey = key);
|
|
3240
3235
|
});
|
|
3241
|
-
if (null ===
|
|
3242
|
-
var
|
|
3243
|
-
|
|
3236
|
+
if (null === actionKey) return Promise.resolve(null);
|
|
3237
|
+
var formFieldPrefix = "$ACTION_" + actionKey.slice(12) + ":";
|
|
3238
|
+
body = decodeBoundActionMetaData(body, serverManifest, formFieldPrefix);
|
|
3239
|
+
var referenceId = body.id;
|
|
3240
|
+
return Promise.resolve(body.bound).then(function (bound) {
|
|
3244
3241
|
return null === bound
|
|
3245
3242
|
? null
|
|
3246
3243
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
@@ -3264,6 +3261,43 @@ exports.decodeReply = function (body, turbopackMap, options) {
|
|
|
3264
3261
|
return turbopackMap;
|
|
3265
3262
|
};
|
|
3266
3263
|
exports.decodeReplyFromBusboy = function (busboyStream, turbopackMap, options) {
|
|
3264
|
+
function flush() {
|
|
3265
|
+
for (; null !== head; ) {
|
|
3266
|
+
var current = head;
|
|
3267
|
+
if (!current.complete) return;
|
|
3268
|
+
try {
|
|
3269
|
+
var key = current.name,
|
|
3270
|
+
handle = current.file,
|
|
3271
|
+
blob = new Blob(handle.chunks, { type: handle.mime }),
|
|
3272
|
+
backingStore = response._formData,
|
|
3273
|
+
key$jscomp$0 = key;
|
|
3274
|
+
backingStore.data.append(key$jscomp$0, blob, handle.filename);
|
|
3275
|
+
var keys = backingStore.keys;
|
|
3276
|
+
null === keys
|
|
3277
|
+
? ((backingStore.keys = Array.from(backingStore.data.keys())),
|
|
3278
|
+
(backingStore.keyPointer = 0))
|
|
3279
|
+
: keys.push(key$jscomp$0);
|
|
3280
|
+
var queuedFields = current.queuedFields;
|
|
3281
|
+
if (null !== queuedFields)
|
|
3282
|
+
for (
|
|
3283
|
+
key$jscomp$0 = 0;
|
|
3284
|
+
key$jscomp$0 < queuedFields.length;
|
|
3285
|
+
key$jscomp$0 += 2
|
|
3286
|
+
)
|
|
3287
|
+
resolveField(
|
|
3288
|
+
response,
|
|
3289
|
+
queuedFields[key$jscomp$0],
|
|
3290
|
+
queuedFields[key$jscomp$0 + 1]
|
|
3291
|
+
);
|
|
3292
|
+
} catch (error) {
|
|
3293
|
+
busboyStream.destroy(error);
|
|
3294
|
+
return;
|
|
3295
|
+
}
|
|
3296
|
+
head = current.next;
|
|
3297
|
+
}
|
|
3298
|
+
tail = null;
|
|
3299
|
+
bodyFinished && !closed && ((closed = !0), close(response));
|
|
3300
|
+
}
|
|
3267
3301
|
var response = createResponse(
|
|
3268
3302
|
turbopackMap,
|
|
3269
3303
|
"",
|
|
@@ -3271,10 +3305,14 @@ exports.decodeReplyFromBusboy = function (busboyStream, turbopackMap, options) {
|
|
|
3271
3305
|
void 0,
|
|
3272
3306
|
options ? options.arraySizeLimit : void 0
|
|
3273
3307
|
),
|
|
3274
|
-
|
|
3275
|
-
|
|
3308
|
+
head = null,
|
|
3309
|
+
tail = null,
|
|
3310
|
+
bodyFinished = !1,
|
|
3311
|
+
closed = !1;
|
|
3276
3312
|
busboyStream.on("field", function (name, value) {
|
|
3277
|
-
if (
|
|
3313
|
+
if (null !== tail)
|
|
3314
|
+
null === tail.queuedFields && (tail.queuedFields = []),
|
|
3315
|
+
tail.queuedFields.push(name, value);
|
|
3278
3316
|
else
|
|
3279
3317
|
try {
|
|
3280
3318
|
resolveField(response, name, value);
|
|
@@ -3292,41 +3330,40 @@ exports.decodeReplyFromBusboy = function (busboyStream, turbopackMap, options) {
|
|
|
3292
3330
|
)
|
|
3293
3331
|
);
|
|
3294
3332
|
else {
|
|
3295
|
-
|
|
3296
|
-
|
|
3333
|
+
var file = { chunks: [], filename: filename, mime: mimeType },
|
|
3334
|
+
pendingFile = {
|
|
3335
|
+
name: name,
|
|
3336
|
+
file: file,
|
|
3337
|
+
complete: !1,
|
|
3338
|
+
queuedFields: null,
|
|
3339
|
+
next: null
|
|
3340
|
+
};
|
|
3341
|
+
null === tail ? (head = pendingFile) : (tail.next = pendingFile);
|
|
3342
|
+
tail = pendingFile;
|
|
3297
3343
|
value.on("data", function (chunk) {
|
|
3298
|
-
JSCompiler_object_inline_chunks_254.push(chunk);
|
|
3299
|
-
});
|
|
3300
|
-
value.on("end", function () {
|
|
3301
3344
|
try {
|
|
3302
|
-
|
|
3303
|
-
type: mimeType
|
|
3304
|
-
}),
|
|
3305
|
-
backingStore = response._formData;
|
|
3306
|
-
backingStore.data.append(name, blob, filename);
|
|
3307
|
-
var keys = backingStore.keys;
|
|
3308
|
-
null === keys
|
|
3309
|
-
? ((backingStore.keys = Array.from(backingStore.data.keys())),
|
|
3310
|
-
(backingStore.keyPointer = 0))
|
|
3311
|
-
: keys.push(name);
|
|
3312
|
-
pendingFiles--;
|
|
3313
|
-
if (0 === pendingFiles) {
|
|
3314
|
-
for (blob = 0; blob < queuedFields.length; blob += 2)
|
|
3315
|
-
resolveField(
|
|
3316
|
-
response,
|
|
3317
|
-
queuedFields[blob],
|
|
3318
|
-
queuedFields[blob + 1]
|
|
3319
|
-
);
|
|
3320
|
-
queuedFields.length = 0;
|
|
3321
|
-
}
|
|
3345
|
+
file.chunks.push(chunk);
|
|
3322
3346
|
} catch (error) {
|
|
3323
3347
|
busboyStream.destroy(error);
|
|
3324
3348
|
}
|
|
3325
3349
|
});
|
|
3350
|
+
value.on("error", function (error) {
|
|
3351
|
+
busboyStream.destroy(error);
|
|
3352
|
+
});
|
|
3353
|
+
value.on("end", function () {
|
|
3354
|
+
pendingFile.complete = !0;
|
|
3355
|
+
flush();
|
|
3356
|
+
});
|
|
3326
3357
|
}
|
|
3327
3358
|
});
|
|
3328
3359
|
busboyStream.on("finish", function () {
|
|
3329
|
-
|
|
3360
|
+
bodyFinished = !0;
|
|
3361
|
+
flush();
|
|
3362
|
+
closed ||
|
|
3363
|
+
reportGlobalError(
|
|
3364
|
+
response,
|
|
3365
|
+
Error("Reply finished with incomplete file part.")
|
|
3366
|
+
);
|
|
3330
3367
|
});
|
|
3331
3368
|
busboyStream.on("error", function (err) {
|
|
3332
3369
|
reportGlobalError(response, err);
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-server-dom-turbopack",
|
|
3
3
|
"description": "React Server Components bindings for DOM using Turbopack. This is intended to be integrated into meta-frameworks. It is not intended to be imported directly.",
|
|
4
|
-
"version": "19.1.
|
|
4
|
+
"version": "19.1.9",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react"
|
|
7
7
|
],
|
|
8
8
|
"homepage": "https://react.dev/",
|
|
9
|
-
"bugs": "https://github.com/
|
|
9
|
+
"bugs": "https://github.com/react/react/issues",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"files": [
|
|
12
12
|
"LICENSE",
|
|
@@ -71,15 +71,15 @@
|
|
|
71
71
|
"main": "index.js",
|
|
72
72
|
"repository": {
|
|
73
73
|
"type": "git",
|
|
74
|
-
"url": "https://github.com/
|
|
74
|
+
"url": "https://github.com/react/react.git",
|
|
75
75
|
"directory": "packages/react-server-dom-turbopack"
|
|
76
76
|
},
|
|
77
77
|
"engines": {
|
|
78
78
|
"node": ">=0.10.0"
|
|
79
79
|
},
|
|
80
80
|
"peerDependencies": {
|
|
81
|
-
"react": "^19.1.
|
|
82
|
-
"react-dom": "^19.1.
|
|
81
|
+
"react": "^19.1.9",
|
|
82
|
+
"react-dom": "^19.1.9"
|
|
83
83
|
},
|
|
84
84
|
"dependencies": {
|
|
85
85
|
"acorn-loose": "^8.3.0",
|