react-server-dom-rspack 0.0.1-alpha.8 → 0.0.1-beta.0
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/LICENSE +1 -1
- package/README.md +3 -1
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js → cjs/react-server-dom-rspack-client.browser.development.js} +372 -203
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.production.js → cjs/react-server-dom-rspack-client.browser.production.js} +133 -83
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js → cjs/react-server-dom-rspack-client.edge.development.js} +304 -160
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.js → cjs/react-server-dom-rspack-client.edge.production.js} +119 -79
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js → cjs/react-server-dom-rspack-client.node.development.js} +326 -191
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.js → cjs/react-server-dom-rspack-client.node.production.js} +127 -95
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.development.js → cjs/react-server-dom-rspack-server.browser.development.js} +263 -297
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.production.js → cjs/react-server-dom-rspack-server.browser.production.js} +170 -224
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.development.js → cjs/react-server-dom-rspack-server.edge.development.js} +283 -309
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.production.js → cjs/react-server-dom-rspack-server.edge.production.js} +186 -231
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.development.js → cjs/react-server-dom-rspack-server.node.development.js} +543 -522
- package/{vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.production.js → cjs/react-server-dom-rspack-server.node.production.js} +197 -243
- package/client.browser.js +7 -0
- package/client.edge.js +7 -0
- package/client.node.js +7 -0
- package/{vendor/react-server-dom-webpack/index.js → index.js} +1 -1
- package/package.json +66 -128
- package/plugin.js +3 -0
- package/server.browser.js +24 -0
- package/server.edge.js +25 -0
- package/{vendor/react-server-dom-webpack/server.node.js → server.node.js} +10 -3
- package/static.browser.js +10 -0
- package/static.edge.js +10 -0
- package/{vendor/react-server-dom-webpack/static.node.js → static.node.js} +2 -2
- package/dist/client.browser.d.ts +0 -23
- package/dist/client.browser.js +0 -41
- package/dist/client.d.ts +0 -1
- package/dist/client.edge.d.ts +0 -28
- package/dist/client.edge.js +0 -27
- package/dist/client.js +0 -1
- package/dist/client.node.d.ts +0 -11
- package/dist/client.node.js +0 -10
- package/dist/index.d.ts +0 -0
- package/dist/index.js +0 -2
- package/dist/server.browser.d.ts +0 -30
- package/dist/server.browser.js +0 -68
- package/dist/server.d.ts +0 -0
- package/dist/server.edge.d.ts +0 -32
- package/dist/server.edge.js +0 -71
- package/dist/server.js +0 -3
- package/dist/server.node.d.ts +0 -33
- package/dist/server.node.js +0 -75
- package/dist/types.d.ts +0 -45
- package/dist/types.js +0 -1
- package/vendor/react-server-dom-webpack/LICENSE +0 -21
- package/vendor/react-server-dom-webpack/README.md +0 -5
- package/vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-node-register.js +0 -69
- package/vendor/react-server-dom-webpack/cjs/react-server-dom-webpack-plugin.js +0 -404
- package/vendor/react-server-dom-webpack/client.browser.js +0 -7
- package/vendor/react-server-dom-webpack/client.edge.js +0 -7
- package/vendor/react-server-dom-webpack/client.node.js +0 -7
- package/vendor/react-server-dom-webpack/esm/react-server-dom-webpack-node-loader.production.js +0 -515
- package/vendor/react-server-dom-webpack/node-register.js +0 -3
- package/vendor/react-server-dom-webpack/package.json +0 -96
- package/vendor/react-server-dom-webpack/plugin.js +0 -3
- package/vendor/react-server-dom-webpack/server.browser.js +0 -17
- package/vendor/react-server-dom-webpack/server.edge.js +0 -18
- package/vendor/react-server-dom-webpack/static.browser.js +0 -10
- package/vendor/react-server-dom-webpack/static.edge.js +0 -10
- /package/{vendor/react-server-dom-webpack/client.js → client.js} +0 -0
- /package/{vendor/react-server-dom-webpack/esm → esm}/package.json +0 -0
- /package/{vendor/react-server-dom-webpack/server.js → server.js} +0 -0
- /package/{vendor/react-server-dom-webpack/static.js → static.js} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license React
|
|
3
|
-
* react-server-dom-
|
|
3
|
+
* react-server-dom-rspack-server.browser.development.js
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
6
6
|
*
|
|
@@ -12,6 +12,57 @@
|
|
|
12
12
|
"production" !== process.env.NODE_ENV &&
|
|
13
13
|
(function () {
|
|
14
14
|
function voidHandler() {}
|
|
15
|
+
function isClientReference(reference) {
|
|
16
|
+
return reference.$$typeof === CLIENT_REFERENCE_TAG$1;
|
|
17
|
+
}
|
|
18
|
+
function bind() {
|
|
19
|
+
var newFn = FunctionBind.apply(this, arguments);
|
|
20
|
+
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
|
21
|
+
null != arguments[0] &&
|
|
22
|
+
console.error(
|
|
23
|
+
'Cannot bind "this" of a Server Action. Pass null or undefined as the first argument to .bind().'
|
|
24
|
+
);
|
|
25
|
+
var args = ArraySlice.call(arguments, 1),
|
|
26
|
+
$$typeof = { value: SERVER_REFERENCE_TAG },
|
|
27
|
+
$$id = { value: this.$$id };
|
|
28
|
+
args = { value: this.$$bound ? this.$$bound.concat(args) : args };
|
|
29
|
+
return Object.defineProperties(newFn, {
|
|
30
|
+
$$typeof: $$typeof,
|
|
31
|
+
$$id: $$id,
|
|
32
|
+
$$bound: args,
|
|
33
|
+
$$location: { value: this.$$location, configurable: !0 },
|
|
34
|
+
bind: { value: bind, configurable: !0 }
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
return newFn;
|
|
38
|
+
}
|
|
39
|
+
function resolveClientReferenceMetadata(config, clientReference) {
|
|
40
|
+
var modulePath = clientReference.$$id,
|
|
41
|
+
name = "",
|
|
42
|
+
resolvedModuleData = config[modulePath];
|
|
43
|
+
if (resolvedModuleData) name = resolvedModuleData.name;
|
|
44
|
+
else {
|
|
45
|
+
var idx = modulePath.lastIndexOf("#");
|
|
46
|
+
-1 !== idx &&
|
|
47
|
+
((name = modulePath.slice(idx + 1)),
|
|
48
|
+
(resolvedModuleData = config[modulePath.slice(0, idx)]));
|
|
49
|
+
if (!resolvedModuleData)
|
|
50
|
+
throw Error(
|
|
51
|
+
'Could not find the module "' +
|
|
52
|
+
modulePath +
|
|
53
|
+
'" in the React Client Manifest. This is probably a bug in the React Server Components bundler.'
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
if (!0 === resolvedModuleData.async && !0 === clientReference.$$async)
|
|
57
|
+
throw Error(
|
|
58
|
+
'The module "' +
|
|
59
|
+
modulePath +
|
|
60
|
+
'" is marked as an async ESM module but was loaded as a CJS proxy. This is probably a bug in the React Server Components bundler.'
|
|
61
|
+
);
|
|
62
|
+
return !0 === resolvedModuleData.async || !0 === clientReference.$$async
|
|
63
|
+
? [resolvedModuleData.id, resolvedModuleData.chunks, name, 1]
|
|
64
|
+
: [resolvedModuleData.id, resolvedModuleData.chunks, name];
|
|
65
|
+
}
|
|
15
66
|
function _defineProperty(obj, key, value) {
|
|
16
67
|
a: if ("object" == typeof key && key) {
|
|
17
68
|
var e = key[Symbol.toPrimitive];
|
|
@@ -90,141 +141,6 @@
|
|
|
90
141
|
? destination.error(error)
|
|
91
142
|
: destination.close();
|
|
92
143
|
}
|
|
93
|
-
function isClientReference(reference) {
|
|
94
|
-
return reference.$$typeof === CLIENT_REFERENCE_TAG$1;
|
|
95
|
-
}
|
|
96
|
-
function registerClientReferenceImpl(proxyImplementation, id, async) {
|
|
97
|
-
return Object.defineProperties(proxyImplementation, {
|
|
98
|
-
$$typeof: { value: CLIENT_REFERENCE_TAG$1 },
|
|
99
|
-
$$id: { value: id },
|
|
100
|
-
$$async: { value: async }
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
function bind() {
|
|
104
|
-
var newFn = FunctionBind.apply(this, arguments);
|
|
105
|
-
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
|
106
|
-
null != arguments[0] &&
|
|
107
|
-
console.error(
|
|
108
|
-
'Cannot bind "this" of a Server Action. Pass null or undefined as the first argument to .bind().'
|
|
109
|
-
);
|
|
110
|
-
var args = ArraySlice.call(arguments, 1),
|
|
111
|
-
$$typeof = { value: SERVER_REFERENCE_TAG },
|
|
112
|
-
$$id = { value: this.$$id };
|
|
113
|
-
args = { value: this.$$bound ? this.$$bound.concat(args) : args };
|
|
114
|
-
return Object.defineProperties(newFn, {
|
|
115
|
-
$$typeof: $$typeof,
|
|
116
|
-
$$id: $$id,
|
|
117
|
-
$$bound: args,
|
|
118
|
-
$$location: { value: this.$$location, configurable: !0 },
|
|
119
|
-
bind: { value: bind, configurable: !0 }
|
|
120
|
-
});
|
|
121
|
-
}
|
|
122
|
-
return newFn;
|
|
123
|
-
}
|
|
124
|
-
function getReference(target, name) {
|
|
125
|
-
switch (name) {
|
|
126
|
-
case "$$typeof":
|
|
127
|
-
return target.$$typeof;
|
|
128
|
-
case "$$id":
|
|
129
|
-
return target.$$id;
|
|
130
|
-
case "$$async":
|
|
131
|
-
return target.$$async;
|
|
132
|
-
case "name":
|
|
133
|
-
return target.name;
|
|
134
|
-
case "defaultProps":
|
|
135
|
-
return;
|
|
136
|
-
case "_debugInfo":
|
|
137
|
-
return;
|
|
138
|
-
case "toJSON":
|
|
139
|
-
return;
|
|
140
|
-
case Symbol.toPrimitive:
|
|
141
|
-
return Object.prototype[Symbol.toPrimitive];
|
|
142
|
-
case Symbol.toStringTag:
|
|
143
|
-
return Object.prototype[Symbol.toStringTag];
|
|
144
|
-
case "__esModule":
|
|
145
|
-
var moduleId = target.$$id;
|
|
146
|
-
target.default = registerClientReferenceImpl(
|
|
147
|
-
function () {
|
|
148
|
-
throw Error(
|
|
149
|
-
"Attempted to call the default export of " +
|
|
150
|
-
moduleId +
|
|
151
|
-
" from the server but it's on the client. It's not possible to invoke a client function from the server, it can only be rendered as a Component or passed to props of a Client Component."
|
|
152
|
-
);
|
|
153
|
-
},
|
|
154
|
-
target.$$id + "#",
|
|
155
|
-
target.$$async
|
|
156
|
-
);
|
|
157
|
-
return !0;
|
|
158
|
-
case "then":
|
|
159
|
-
if (target.then) return target.then;
|
|
160
|
-
if (target.$$async) return;
|
|
161
|
-
var clientReference = registerClientReferenceImpl(
|
|
162
|
-
{},
|
|
163
|
-
target.$$id,
|
|
164
|
-
!0
|
|
165
|
-
),
|
|
166
|
-
proxy = new Proxy(clientReference, proxyHandlers$1);
|
|
167
|
-
target.status = "fulfilled";
|
|
168
|
-
target.value = proxy;
|
|
169
|
-
return (target.then = registerClientReferenceImpl(
|
|
170
|
-
function (resolve) {
|
|
171
|
-
return Promise.resolve(resolve(proxy));
|
|
172
|
-
},
|
|
173
|
-
target.$$id + "#then",
|
|
174
|
-
!1
|
|
175
|
-
));
|
|
176
|
-
}
|
|
177
|
-
if ("symbol" === typeof name)
|
|
178
|
-
throw Error(
|
|
179
|
-
"Cannot read Symbol exports. Only named exports are supported on a client module imported on the server."
|
|
180
|
-
);
|
|
181
|
-
clientReference = target[name];
|
|
182
|
-
clientReference ||
|
|
183
|
-
((clientReference = registerClientReferenceImpl(
|
|
184
|
-
function () {
|
|
185
|
-
throw Error(
|
|
186
|
-
"Attempted to call " +
|
|
187
|
-
String(name) +
|
|
188
|
-
"() from the server but " +
|
|
189
|
-
String(name) +
|
|
190
|
-
" is on the client. It's not possible to invoke a client function from the server, it can only be rendered as a Component or passed to props of a Client Component."
|
|
191
|
-
);
|
|
192
|
-
},
|
|
193
|
-
target.$$id + "#" + name,
|
|
194
|
-
target.$$async
|
|
195
|
-
)),
|
|
196
|
-
Object.defineProperty(clientReference, "name", { value: name }),
|
|
197
|
-
(clientReference = target[name] =
|
|
198
|
-
new Proxy(clientReference, deepProxyHandlers)));
|
|
199
|
-
return clientReference;
|
|
200
|
-
}
|
|
201
|
-
function resolveClientReferenceMetadata(config, clientReference) {
|
|
202
|
-
var modulePath = clientReference.$$id,
|
|
203
|
-
name = "",
|
|
204
|
-
resolvedModuleData = config[modulePath];
|
|
205
|
-
if (resolvedModuleData) name = resolvedModuleData.name;
|
|
206
|
-
else {
|
|
207
|
-
var idx = modulePath.lastIndexOf("#");
|
|
208
|
-
-1 !== idx &&
|
|
209
|
-
((name = modulePath.slice(idx + 1)),
|
|
210
|
-
(resolvedModuleData = config[modulePath.slice(0, idx)]));
|
|
211
|
-
if (!resolvedModuleData)
|
|
212
|
-
throw Error(
|
|
213
|
-
'Could not find the module "' +
|
|
214
|
-
modulePath +
|
|
215
|
-
'" in the React Client Manifest. This is probably a bug in the React Server Components bundler.'
|
|
216
|
-
);
|
|
217
|
-
}
|
|
218
|
-
if (!0 === resolvedModuleData.async && !0 === clientReference.$$async)
|
|
219
|
-
throw Error(
|
|
220
|
-
'The module "' +
|
|
221
|
-
modulePath +
|
|
222
|
-
'" is marked as an async ESM module but was loaded as a CJS proxy. This is probably a bug in the React Server Components bundler.'
|
|
223
|
-
);
|
|
224
|
-
return !0 === resolvedModuleData.async || !0 === clientReference.$$async
|
|
225
|
-
? [resolvedModuleData.id, resolvedModuleData.chunks, name, 1]
|
|
226
|
-
: [resolvedModuleData.id, resolvedModuleData.chunks, name];
|
|
227
|
-
}
|
|
228
144
|
function preload(href, as, options) {
|
|
229
145
|
if ("string" === typeof href) {
|
|
230
146
|
var request = resolveRequest();
|
|
@@ -355,7 +271,7 @@
|
|
|
355
271
|
});
|
|
356
272
|
break;
|
|
357
273
|
case "stylesheet":
|
|
358
|
-
preload(srcSet, "
|
|
274
|
+
preload(srcSet, "style", {
|
|
359
275
|
crossOrigin: props.crossOrigin,
|
|
360
276
|
integrity: props.integrity,
|
|
361
277
|
nonce: props.nonce,
|
|
@@ -668,6 +584,8 @@
|
|
|
668
584
|
return "Suspense";
|
|
669
585
|
case REACT_SUSPENSE_LIST_TYPE:
|
|
670
586
|
return "SuspenseList";
|
|
587
|
+
case REACT_VIEW_TRANSITION_TYPE:
|
|
588
|
+
return "ViewTransition";
|
|
671
589
|
}
|
|
672
590
|
if ("object" === typeof type)
|
|
673
591
|
switch (type.$$typeof) {
|
|
@@ -976,7 +894,6 @@
|
|
|
976
894
|
model,
|
|
977
895
|
bundlerConfig,
|
|
978
896
|
onError,
|
|
979
|
-
onPostpone,
|
|
980
897
|
onAllReady,
|
|
981
898
|
onFatalError,
|
|
982
899
|
identifierPrefix,
|
|
@@ -1021,8 +938,6 @@
|
|
|
1021
938
|
this.identifierCount = 1;
|
|
1022
939
|
this.taintCleanupQueue = [];
|
|
1023
940
|
this.onError = void 0 === onError ? defaultErrorHandler : onError;
|
|
1024
|
-
this.onPostpone =
|
|
1025
|
-
void 0 === onPostpone ? defaultPostponeHandler : onPostpone;
|
|
1026
941
|
this.onAllReady = onAllReady;
|
|
1027
942
|
this.onFatalError = onFatalError;
|
|
1028
943
|
this.pendingDebugChunks = 0;
|
|
@@ -1069,7 +984,6 @@
|
|
|
1069
984
|
bundlerConfig,
|
|
1070
985
|
onError,
|
|
1071
986
|
identifierPrefix,
|
|
1072
|
-
onPostpone,
|
|
1073
987
|
temporaryReferences,
|
|
1074
988
|
environmentName,
|
|
1075
989
|
filterStackFrame,
|
|
@@ -1081,7 +995,6 @@
|
|
|
1081
995
|
model,
|
|
1082
996
|
bundlerConfig,
|
|
1083
997
|
onError,
|
|
1084
|
-
onPostpone,
|
|
1085
998
|
noop,
|
|
1086
999
|
noop,
|
|
1087
1000
|
identifierPrefix,
|
|
@@ -1098,7 +1011,6 @@
|
|
|
1098
1011
|
onFatalError,
|
|
1099
1012
|
onError,
|
|
1100
1013
|
identifierPrefix,
|
|
1101
|
-
onPostpone,
|
|
1102
1014
|
temporaryReferences,
|
|
1103
1015
|
environmentName,
|
|
1104
1016
|
filterStackFrame,
|
|
@@ -1110,7 +1022,6 @@
|
|
|
1110
1022
|
model,
|
|
1111
1023
|
bundlerConfig,
|
|
1112
1024
|
onError,
|
|
1113
|
-
onPostpone,
|
|
1114
1025
|
onAllReady,
|
|
1115
1026
|
onFatalError,
|
|
1116
1027
|
identifierPrefix,
|
|
@@ -1156,7 +1067,23 @@
|
|
|
1156
1067
|
((cancelled = !0),
|
|
1157
1068
|
request.status === ABORTING
|
|
1158
1069
|
? emitDebugHaltChunk(request, id)
|
|
1159
|
-
:
|
|
1070
|
+
: (isArrayImpl(value) && 200 < value.length) ||
|
|
1071
|
+
((value instanceof ArrayBuffer ||
|
|
1072
|
+
value instanceof Int8Array ||
|
|
1073
|
+
value instanceof Uint8Array ||
|
|
1074
|
+
value instanceof Uint8ClampedArray ||
|
|
1075
|
+
value instanceof Int16Array ||
|
|
1076
|
+
value instanceof Uint16Array ||
|
|
1077
|
+
value instanceof Int32Array ||
|
|
1078
|
+
value instanceof Uint32Array ||
|
|
1079
|
+
value instanceof Float32Array ||
|
|
1080
|
+
value instanceof Float64Array ||
|
|
1081
|
+
value instanceof BigInt64Array ||
|
|
1082
|
+
value instanceof BigUint64Array ||
|
|
1083
|
+
value instanceof DataView) &&
|
|
1084
|
+
1e3 < value.byteLength)
|
|
1085
|
+
? emitDebugHaltChunk(request, id)
|
|
1086
|
+
: emitOutlinedDebugModelChunk(request, id, counter, value),
|
|
1160
1087
|
enqueueFlush(request));
|
|
1161
1088
|
},
|
|
1162
1089
|
function (reason) {
|
|
@@ -1288,9 +1215,17 @@
|
|
|
1288
1215
|
callOnAllReadyIfReady(request);
|
|
1289
1216
|
else
|
|
1290
1217
|
try {
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1218
|
+
request.pendingChunks++,
|
|
1219
|
+
(streamTask.model = entry.value),
|
|
1220
|
+
isByteStream
|
|
1221
|
+
? emitTypedArrayChunk(
|
|
1222
|
+
request,
|
|
1223
|
+
streamTask.id,
|
|
1224
|
+
"b",
|
|
1225
|
+
streamTask.model,
|
|
1226
|
+
!1
|
|
1227
|
+
)
|
|
1228
|
+
: tryStreamTask(request, streamTask),
|
|
1294
1229
|
enqueueFlush(request),
|
|
1295
1230
|
reader.read().then(progress, error);
|
|
1296
1231
|
} catch (x$0) {
|
|
@@ -1327,7 +1262,8 @@
|
|
|
1327
1262
|
} catch (x) {
|
|
1328
1263
|
supportsBYOB = !1;
|
|
1329
1264
|
}
|
|
1330
|
-
var
|
|
1265
|
+
var isByteStream = supportsBYOB,
|
|
1266
|
+
reader = stream.getReader(),
|
|
1331
1267
|
streamTask = createTask(
|
|
1332
1268
|
request,
|
|
1333
1269
|
task.model,
|
|
@@ -1342,7 +1278,7 @@
|
|
|
1342
1278
|
);
|
|
1343
1279
|
request.pendingChunks++;
|
|
1344
1280
|
task =
|
|
1345
|
-
streamTask.id.toString(16) + ":" + (
|
|
1281
|
+
streamTask.id.toString(16) + ":" + (isByteStream ? "r" : "R") + "\n";
|
|
1346
1282
|
request.completedRegularChunks.push(stringToChunk(task));
|
|
1347
1283
|
request.cacheController.signal.addEventListener("abort", abortStream);
|
|
1348
1284
|
reader.read().then(progress, error);
|
|
@@ -1650,7 +1586,12 @@
|
|
|
1650
1586
|
Component = task.keyPath;
|
|
1651
1587
|
componentDebugInfo = task.implicitSlot;
|
|
1652
1588
|
null !== key
|
|
1653
|
-
? (task.keyPath =
|
|
1589
|
+
? (task.keyPath =
|
|
1590
|
+
key === REACT_OPTIMISTIC_KEY || Component === REACT_OPTIMISTIC_KEY
|
|
1591
|
+
? REACT_OPTIMISTIC_KEY
|
|
1592
|
+
: null === Component
|
|
1593
|
+
? key
|
|
1594
|
+
: Component + "," + key)
|
|
1654
1595
|
: null === Component && (task.implicitSlot = !0);
|
|
1655
1596
|
request = renderModelDestructive(request, task, emptyRoot, "", props);
|
|
1656
1597
|
task.keyPath = Component;
|
|
@@ -1866,7 +1807,13 @@
|
|
|
1866
1807
|
validated
|
|
1867
1808
|
);
|
|
1868
1809
|
ref = task.keyPath;
|
|
1869
|
-
null === key
|
|
1810
|
+
null === key
|
|
1811
|
+
? (key = ref)
|
|
1812
|
+
: null !== ref &&
|
|
1813
|
+
(key =
|
|
1814
|
+
ref === REACT_OPTIMISTIC_KEY || key === REACT_OPTIMISTIC_KEY
|
|
1815
|
+
? REACT_OPTIMISTIC_KEY
|
|
1816
|
+
: ref + "," + key);
|
|
1870
1817
|
newFormatContext = null;
|
|
1871
1818
|
ref = task.debugOwner;
|
|
1872
1819
|
null !== ref && outlineComponentInfo(request, ref);
|
|
@@ -2154,6 +2101,8 @@
|
|
|
2154
2101
|
return serializeByValueID(bufferId);
|
|
2155
2102
|
}
|
|
2156
2103
|
function serializeDebugTypedArray(request, tag, typedArray) {
|
|
2104
|
+
if (1e3 < typedArray.byteLength && !doNotLimit.has(typedArray))
|
|
2105
|
+
return serializeDeferredObject(request, typedArray);
|
|
2157
2106
|
request.pendingDebugChunks++;
|
|
2158
2107
|
var bufferId = request.nextChunkId++;
|
|
2159
2108
|
emitTypedArrayChunk(request, bufferId, tag, typedArray, !0);
|
|
@@ -2361,7 +2310,9 @@
|
|
|
2361
2310
|
void 0 === value._debugTask
|
|
2362
2311
|
) {
|
|
2363
2312
|
var key = "";
|
|
2364
|
-
null !== value.key &&
|
|
2313
|
+
null !== value.key &&
|
|
2314
|
+
value.key !== REACT_OPTIMISTIC_KEY &&
|
|
2315
|
+
(key = ' key="' + value.key + '"');
|
|
2365
2316
|
console.error(
|
|
2366
2317
|
"Attempted to render <%s%s> without development properties. This is not supported. It can happen if:\n- The element is created with a production version of React but rendered in development.\n- The element was cloned with a custom function instead of `React.cloneElement`.\nThe props of this element may help locate this element: %o",
|
|
2367
2318
|
value.type,
|
|
@@ -2517,7 +2468,7 @@
|
|
|
2517
2468
|
if (value instanceof Date) return "$D" + value.toJSON();
|
|
2518
2469
|
elementReference = getPrototypeOf(value);
|
|
2519
2470
|
if (
|
|
2520
|
-
elementReference !== ObjectPrototype &&
|
|
2471
|
+
elementReference !== ObjectPrototype$1 &&
|
|
2521
2472
|
(null === elementReference ||
|
|
2522
2473
|
null !== getPrototypeOf(elementReference))
|
|
2523
2474
|
)
|
|
@@ -2756,12 +2707,15 @@
|
|
|
2756
2707
|
function emitDebugChunk(request, id, debugInfo) {
|
|
2757
2708
|
var json = serializeDebugModel(request, 500, debugInfo);
|
|
2758
2709
|
null !== request.debugDestination
|
|
2759
|
-
?
|
|
2760
|
-
(
|
|
2761
|
-
|
|
2762
|
-
request.
|
|
2763
|
-
|
|
2764
|
-
|
|
2710
|
+
? '"' === json[0] && "$" === json[1]
|
|
2711
|
+
? ((id = id.toString(16) + ":D" + json + "\n"),
|
|
2712
|
+
request.completedRegularChunks.push(stringToChunk(id)))
|
|
2713
|
+
: ((debugInfo = request.nextChunkId++),
|
|
2714
|
+
(json = debugInfo.toString(16) + ":" + json + "\n"),
|
|
2715
|
+
request.pendingDebugChunks++,
|
|
2716
|
+
request.completedDebugChunks.push(stringToChunk(json)),
|
|
2717
|
+
(id = id.toString(16) + ':D"$' + debugInfo.toString(16) + '"\n'),
|
|
2718
|
+
request.completedRegularChunks.push(stringToChunk(id)))
|
|
2765
2719
|
: ((id = id.toString(16) + ":D" + json + "\n"),
|
|
2766
2720
|
request.completedRegularChunks.push(stringToChunk(id)));
|
|
2767
2721
|
}
|
|
@@ -3001,7 +2955,11 @@
|
|
|
3001
2955
|
}
|
|
3002
2956
|
if ("function" === typeof value.then)
|
|
3003
2957
|
return serializeDebugThenable(request, counter, value);
|
|
3004
|
-
if (isArrayImpl(value))
|
|
2958
|
+
if (isArrayImpl(value))
|
|
2959
|
+
return 200 < value.length && !doNotLimit.has(value)
|
|
2960
|
+
? serializeDeferredObject(request, value)
|
|
2961
|
+
: value;
|
|
2962
|
+
if (value instanceof Date) return "$D" + value.toJSON();
|
|
3005
2963
|
if (value instanceof Map) {
|
|
3006
2964
|
value = Array.from(value);
|
|
3007
2965
|
counter.objectLimit++;
|
|
@@ -3088,7 +3046,7 @@
|
|
|
3088
3046
|
return serializeDebugBlob(request, value);
|
|
3089
3047
|
if (getIteratorFn(value)) return Array.from(value);
|
|
3090
3048
|
request = getPrototypeOf(value);
|
|
3091
|
-
if (request !== ObjectPrototype && null !== request) {
|
|
3049
|
+
if (request !== ObjectPrototype$1 && null !== request) {
|
|
3092
3050
|
counter = Object.create(null);
|
|
3093
3051
|
for (env in value)
|
|
3094
3052
|
if (hasOwnProperty.call(value, env) || isGetter(request, env))
|
|
@@ -3104,11 +3062,6 @@
|
|
|
3104
3062
|
return value;
|
|
3105
3063
|
}
|
|
3106
3064
|
if ("string" === typeof value) {
|
|
3107
|
-
if (
|
|
3108
|
-
"Z" === value[value.length - 1] &&
|
|
3109
|
-
parent[parentPropertyName] instanceof Date
|
|
3110
|
-
)
|
|
3111
|
-
return "$D" + value;
|
|
3112
3065
|
if (1024 <= value.length) {
|
|
3113
3066
|
if (0 >= counter.objectLimit)
|
|
3114
3067
|
return serializeDeferredObject(request, value);
|
|
@@ -3170,19 +3123,17 @@
|
|
|
3170
3123
|
}
|
|
3171
3124
|
return "bigint" === typeof value
|
|
3172
3125
|
? "$n" + value.toString(10)
|
|
3173
|
-
:
|
|
3174
|
-
? "$D" + value.toJSON()
|
|
3175
|
-
: "unknown type " + typeof value;
|
|
3126
|
+
: "unknown type " + typeof value;
|
|
3176
3127
|
}
|
|
3177
3128
|
function serializeDebugModel(request, objectLimit, model) {
|
|
3178
|
-
function replacer(parentPropertyName
|
|
3129
|
+
function replacer(parentPropertyName) {
|
|
3179
3130
|
try {
|
|
3180
3131
|
return renderDebugModel(
|
|
3181
3132
|
request,
|
|
3182
3133
|
counter,
|
|
3183
3134
|
this,
|
|
3184
3135
|
parentPropertyName,
|
|
3185
|
-
|
|
3136
|
+
this[parentPropertyName]
|
|
3186
3137
|
);
|
|
3187
3138
|
} catch (x) {
|
|
3188
3139
|
return (
|
|
@@ -3206,14 +3157,14 @@
|
|
|
3206
3157
|
}
|
|
3207
3158
|
}
|
|
3208
3159
|
function emitOutlinedDebugModelChunk(request, id, counter, model) {
|
|
3209
|
-
function replacer(parentPropertyName
|
|
3160
|
+
function replacer(parentPropertyName) {
|
|
3210
3161
|
try {
|
|
3211
3162
|
return renderDebugModel(
|
|
3212
3163
|
request,
|
|
3213
3164
|
counter,
|
|
3214
3165
|
this,
|
|
3215
3166
|
parentPropertyName,
|
|
3216
|
-
|
|
3167
|
+
this[parentPropertyName]
|
|
3217
3168
|
);
|
|
3218
3169
|
} catch (x) {
|
|
3219
3170
|
return (
|
|
@@ -3280,10 +3231,11 @@
|
|
|
3280
3231
|
parseStackTrace(ioInfo$jscomp$0.debugStack, 1)
|
|
3281
3232
|
)
|
|
3282
3233
|
: ioInfo$jscomp$0.stack;
|
|
3234
|
+
var env = ioInfo$jscomp$0.env;
|
|
3235
|
+
null == env && (env = (0, request.environmentName)());
|
|
3283
3236
|
var request$jscomp$0 = request,
|
|
3284
3237
|
id$jscomp$1 = id$jscomp$0,
|
|
3285
3238
|
value = ioInfo$jscomp$0.value,
|
|
3286
|
-
env = ioInfo$jscomp$0.env,
|
|
3287
3239
|
objectLimit = 10;
|
|
3288
3240
|
debugStack && (objectLimit += debugStack.length);
|
|
3289
3241
|
var debugIOInfo = {
|
|
@@ -3295,12 +3247,12 @@
|
|
|
3295
3247
|
null != debugStack && (debugIOInfo.stack = debugStack);
|
|
3296
3248
|
null != owner && (debugIOInfo.owner = owner);
|
|
3297
3249
|
void 0 !== value && (debugIOInfo.value = value);
|
|
3298
|
-
|
|
3250
|
+
env = serializeDebugModel(
|
|
3299
3251
|
request$jscomp$0,
|
|
3300
3252
|
objectLimit,
|
|
3301
3253
|
debugIOInfo
|
|
3302
3254
|
);
|
|
3303
|
-
id$jscomp$1 = id$jscomp$1.toString(16) + ":J" +
|
|
3255
|
+
id$jscomp$1 = id$jscomp$1.toString(16) + ":J" + env + "\n";
|
|
3304
3256
|
id$jscomp$1 = stringToChunk(id$jscomp$1);
|
|
3305
3257
|
request$jscomp$0.completedDebugChunks.push(id$jscomp$1);
|
|
3306
3258
|
request.writtenDebugObjects.set(
|
|
@@ -3318,7 +3270,10 @@
|
|
|
3318
3270
|
)
|
|
3319
3271
|
: info.stack;
|
|
3320
3272
|
ioInfo = { awaited: ioInfo };
|
|
3321
|
-
|
|
3273
|
+
ioInfo.env =
|
|
3274
|
+
null != info.env
|
|
3275
|
+
? info.env
|
|
3276
|
+
: (0, request$jscomp$1.environmentName)();
|
|
3322
3277
|
null != info.owner && (ioInfo.owner = info.owner);
|
|
3323
3278
|
null != request && (ioInfo.stack = request);
|
|
3324
3279
|
request$jscomp$1.pendingChunks++;
|
|
@@ -3755,15 +3710,15 @@
|
|
|
3755
3710
|
)
|
|
3756
3711
|
: reason,
|
|
3757
3712
|
digest = logRecoverableError(request, error, null),
|
|
3758
|
-
|
|
3759
|
-
request.fatalError =
|
|
3713
|
+
errorId = request.nextChunkId++;
|
|
3714
|
+
request.fatalError = errorId;
|
|
3760
3715
|
request.pendingChunks++;
|
|
3761
|
-
emitErrorChunk(request,
|
|
3716
|
+
emitErrorChunk(request, errorId, digest, error, !1, null);
|
|
3762
3717
|
abortableTasks.forEach(function (task) {
|
|
3763
|
-
return abortTask(task, request,
|
|
3718
|
+
return abortTask(task, request, errorId);
|
|
3764
3719
|
});
|
|
3765
3720
|
scheduleWork(function () {
|
|
3766
|
-
return finishAbort(request, abortableTasks,
|
|
3721
|
+
return finishAbort(request, abortableTasks, errorId);
|
|
3767
3722
|
});
|
|
3768
3723
|
}
|
|
3769
3724
|
else {
|
|
@@ -3835,11 +3790,16 @@
|
|
|
3835
3790
|
i < chunks.length;
|
|
3836
3791
|
|
|
3837
3792
|
) {
|
|
3838
|
-
var chunkId = chunks[i++]
|
|
3839
|
-
|
|
3840
|
-
|
|
3841
|
-
|
|
3842
|
-
|
|
3793
|
+
var chunkId = chunks[i++],
|
|
3794
|
+
chunkFilename = chunks[i++],
|
|
3795
|
+
entry = chunkCache.get(chunkId);
|
|
3796
|
+
void 0 === entry
|
|
3797
|
+
? ((chunkFilename = loadChunk(chunkId, chunkFilename)),
|
|
3798
|
+
promises.push(chunkFilename),
|
|
3799
|
+
(entry = chunkCache.set.bind(chunkCache, chunkId, null)),
|
|
3800
|
+
chunkFilename.then(entry, ignoreReject),
|
|
3801
|
+
chunkCache.set(chunkId, chunkFilename))
|
|
3802
|
+
: null !== entry && promises.push(entry);
|
|
3843
3803
|
}
|
|
3844
3804
|
return 4 === metadata.length
|
|
3845
3805
|
? 0 === promises.length
|
|
@@ -4203,8 +4163,10 @@
|
|
|
4203
4163
|
var name = path[i];
|
|
4204
4164
|
if (
|
|
4205
4165
|
"object" !== typeof value ||
|
|
4206
|
-
|
|
4207
|
-
value
|
|
4166
|
+
null === value ||
|
|
4167
|
+
(getPrototypeOf(value) !== ObjectPrototype &&
|
|
4168
|
+
getPrototypeOf(value) !== ArrayPrototype) ||
|
|
4169
|
+
!hasOwnProperty.call(value, name)
|
|
4208
4170
|
)
|
|
4209
4171
|
throw Error("Invalid reference.");
|
|
4210
4172
|
value = value[name];
|
|
@@ -4252,8 +4214,10 @@
|
|
|
4252
4214
|
var name = reference[i];
|
|
4253
4215
|
if (
|
|
4254
4216
|
"object" !== typeof id ||
|
|
4255
|
-
|
|
4256
|
-
id
|
|
4217
|
+
null === id ||
|
|
4218
|
+
(getPrototypeOf(id) !== ObjectPrototype &&
|
|
4219
|
+
getPrototypeOf(id) !== ArrayPrototype) ||
|
|
4220
|
+
!hasOwnProperty.call(id, name)
|
|
4257
4221
|
)
|
|
4258
4222
|
throw Error("Invalid reference.");
|
|
4259
4223
|
id = id[name];
|
|
@@ -4825,6 +4789,34 @@
|
|
|
4825
4789
|
}
|
|
4826
4790
|
var ReactDOM = require("react-dom"),
|
|
4827
4791
|
React = require("react"),
|
|
4792
|
+
assign = Object.assign,
|
|
4793
|
+
CLIENT_REFERENCE_TAG$1 = Symbol.for("react.client.reference"),
|
|
4794
|
+
SERVER_REFERENCE_TAG = Symbol.for("react.server.reference"),
|
|
4795
|
+
FunctionBind = Function.prototype.bind,
|
|
4796
|
+
ArraySlice = Array.prototype.slice,
|
|
4797
|
+
serverReferenceToString = {
|
|
4798
|
+
value: function () {
|
|
4799
|
+
return "function () { [omitted code] }";
|
|
4800
|
+
},
|
|
4801
|
+
configurable: !0,
|
|
4802
|
+
writable: !0
|
|
4803
|
+
},
|
|
4804
|
+
currentStrategy = {
|
|
4805
|
+
encrypt: function (_actionId) {
|
|
4806
|
+
for (
|
|
4807
|
+
var _len = arguments.length,
|
|
4808
|
+
args = Array(1 < _len ? _len - 1 : 0),
|
|
4809
|
+
_key = 1;
|
|
4810
|
+
_key < _len;
|
|
4811
|
+
_key++
|
|
4812
|
+
)
|
|
4813
|
+
args[_key - 1] = arguments[_key];
|
|
4814
|
+
return Promise.resolve(args);
|
|
4815
|
+
},
|
|
4816
|
+
decrypt: function (_actionId, payloadPromise) {
|
|
4817
|
+
return payloadPromise;
|
|
4818
|
+
}
|
|
4819
|
+
},
|
|
4828
4820
|
channel = new MessageChannel(),
|
|
4829
4821
|
taskQueue = [];
|
|
4830
4822
|
channel.port1.onmessage = function () {
|
|
@@ -4843,83 +4835,6 @@
|
|
|
4843
4835
|
currentView = null,
|
|
4844
4836
|
writtenBytes = 0,
|
|
4845
4837
|
textEncoder = new TextEncoder(),
|
|
4846
|
-
CLIENT_REFERENCE_TAG$1 = Symbol.for("react.client.reference"),
|
|
4847
|
-
SERVER_REFERENCE_TAG = Symbol.for("react.server.reference"),
|
|
4848
|
-
FunctionBind = Function.prototype.bind,
|
|
4849
|
-
ArraySlice = Array.prototype.slice,
|
|
4850
|
-
serverReferenceToString = {
|
|
4851
|
-
value: function () {
|
|
4852
|
-
return "function () { [omitted code] }";
|
|
4853
|
-
},
|
|
4854
|
-
configurable: !0,
|
|
4855
|
-
writable: !0
|
|
4856
|
-
},
|
|
4857
|
-
PROMISE_PROTOTYPE = Promise.prototype,
|
|
4858
|
-
deepProxyHandlers = {
|
|
4859
|
-
get: function (target, name) {
|
|
4860
|
-
switch (name) {
|
|
4861
|
-
case "$$typeof":
|
|
4862
|
-
return target.$$typeof;
|
|
4863
|
-
case "$$id":
|
|
4864
|
-
return target.$$id;
|
|
4865
|
-
case "$$async":
|
|
4866
|
-
return target.$$async;
|
|
4867
|
-
case "name":
|
|
4868
|
-
return target.name;
|
|
4869
|
-
case "displayName":
|
|
4870
|
-
return;
|
|
4871
|
-
case "defaultProps":
|
|
4872
|
-
return;
|
|
4873
|
-
case "_debugInfo":
|
|
4874
|
-
return;
|
|
4875
|
-
case "toJSON":
|
|
4876
|
-
return;
|
|
4877
|
-
case Symbol.toPrimitive:
|
|
4878
|
-
return Object.prototype[Symbol.toPrimitive];
|
|
4879
|
-
case Symbol.toStringTag:
|
|
4880
|
-
return Object.prototype[Symbol.toStringTag];
|
|
4881
|
-
case "Provider":
|
|
4882
|
-
throw Error(
|
|
4883
|
-
"Cannot render a Client Context Provider on the Server. Instead, you can export a Client Component wrapper that itself renders a Client Context Provider."
|
|
4884
|
-
);
|
|
4885
|
-
case "then":
|
|
4886
|
-
throw Error(
|
|
4887
|
-
"Cannot await or return from a thenable. You cannot await a client module from a server component."
|
|
4888
|
-
);
|
|
4889
|
-
}
|
|
4890
|
-
throw Error(
|
|
4891
|
-
"Cannot access " +
|
|
4892
|
-
(String(target.name) + "." + String(name)) +
|
|
4893
|
-
" on the server. You cannot dot into a client module from a server component. You can only pass the imported name through."
|
|
4894
|
-
);
|
|
4895
|
-
},
|
|
4896
|
-
set: function () {
|
|
4897
|
-
throw Error("Cannot assign to a client module from a server module.");
|
|
4898
|
-
}
|
|
4899
|
-
},
|
|
4900
|
-
proxyHandlers$1 = {
|
|
4901
|
-
get: function (target, name) {
|
|
4902
|
-
return getReference(target, name);
|
|
4903
|
-
},
|
|
4904
|
-
getOwnPropertyDescriptor: function (target, name) {
|
|
4905
|
-
var descriptor = Object.getOwnPropertyDescriptor(target, name);
|
|
4906
|
-
descriptor ||
|
|
4907
|
-
((descriptor = {
|
|
4908
|
-
value: getReference(target, name),
|
|
4909
|
-
writable: !1,
|
|
4910
|
-
configurable: !1,
|
|
4911
|
-
enumerable: !1
|
|
4912
|
-
}),
|
|
4913
|
-
Object.defineProperty(target, name, descriptor));
|
|
4914
|
-
return descriptor;
|
|
4915
|
-
},
|
|
4916
|
-
getPrototypeOf: function () {
|
|
4917
|
-
return PROMISE_PROTOTYPE;
|
|
4918
|
-
},
|
|
4919
|
-
set: function () {
|
|
4920
|
-
throw Error("Cannot assign to a client module from a server module.");
|
|
4921
|
-
}
|
|
4922
|
-
},
|
|
4923
4838
|
ReactDOMSharedInternals =
|
|
4924
4839
|
ReactDOM.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
|
|
4925
4840
|
previousDispatcher = ReactDOMSharedInternals.d;
|
|
@@ -5062,10 +4977,11 @@
|
|
|
5062
4977
|
REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"),
|
|
5063
4978
|
REACT_MEMO_TYPE = Symbol.for("react.memo"),
|
|
5064
4979
|
REACT_LAZY_TYPE = Symbol.for("react.lazy"),
|
|
5065
|
-
REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel")
|
|
5066
|
-
|
|
5067
|
-
|
|
4980
|
+
REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel"),
|
|
4981
|
+
REACT_VIEW_TRANSITION_TYPE = Symbol.for("react.view_transition"),
|
|
4982
|
+
MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
|
|
5068
4983
|
ASYNC_ITERATOR = Symbol.asyncIterator,
|
|
4984
|
+
REACT_OPTIMISTIC_KEY = Symbol.for("react.optimistic_key"),
|
|
5069
4985
|
SuspenseException = Error(
|
|
5070
4986
|
"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`."
|
|
5071
4987
|
),
|
|
@@ -5238,11 +5154,10 @@
|
|
|
5238
5154
|
patchConsole(console, "table"),
|
|
5239
5155
|
patchConsole(console, "trace"),
|
|
5240
5156
|
patchConsole(console, "warn"));
|
|
5241
|
-
var ObjectPrototype = Object.prototype,
|
|
5157
|
+
var ObjectPrototype$1 = Object.prototype,
|
|
5242
5158
|
stringify = JSON.stringify,
|
|
5243
5159
|
ABORTING = 12,
|
|
5244
5160
|
CLOSED = 14,
|
|
5245
|
-
defaultPostponeHandler = noop,
|
|
5246
5161
|
currentRequest = null,
|
|
5247
5162
|
canEmitDebugInfo = !1,
|
|
5248
5163
|
serializedSize = 0,
|
|
@@ -5253,13 +5168,14 @@
|
|
|
5253
5168
|
debugNoOutline = null,
|
|
5254
5169
|
emptyRoot = {},
|
|
5255
5170
|
decoderOptions = { stream: !0 },
|
|
5171
|
+
chunkCache = new Map(),
|
|
5256
5172
|
chunkMap = new Map(),
|
|
5257
|
-
|
|
5173
|
+
rspackGetChunkFilename = __webpack_require__.u;
|
|
5258
5174
|
__webpack_require__.u = function (chunkId) {
|
|
5259
5175
|
var flightChunk = chunkMap.get(chunkId);
|
|
5260
5176
|
return void 0 !== flightChunk
|
|
5261
5177
|
? flightChunk
|
|
5262
|
-
:
|
|
5178
|
+
: rspackGetChunkFilename(chunkId);
|
|
5263
5179
|
};
|
|
5264
5180
|
var RESPONSE_SYMBOL = Symbol();
|
|
5265
5181
|
ReactPromise.prototype = Object.create(Promise.prototype);
|
|
@@ -5272,16 +5188,23 @@
|
|
|
5272
5188
|
case "fulfilled":
|
|
5273
5189
|
if ("function" === typeof resolve) {
|
|
5274
5190
|
for (
|
|
5275
|
-
var inspectedValue = this.value,
|
|
5191
|
+
var inspectedValue = this.value,
|
|
5192
|
+
cycleProtection = 0,
|
|
5193
|
+
visited = new Set();
|
|
5276
5194
|
inspectedValue instanceof ReactPromise;
|
|
5277
5195
|
|
|
5278
5196
|
) {
|
|
5279
5197
|
cycleProtection++;
|
|
5280
|
-
if (
|
|
5198
|
+
if (
|
|
5199
|
+
inspectedValue === this ||
|
|
5200
|
+
visited.has(inspectedValue) ||
|
|
5201
|
+
1e3 < cycleProtection
|
|
5202
|
+
) {
|
|
5281
5203
|
"function" === typeof reject &&
|
|
5282
5204
|
reject(Error("Cannot have cyclic thenables."));
|
|
5283
5205
|
return;
|
|
5284
5206
|
}
|
|
5207
|
+
visited.add(inspectedValue);
|
|
5285
5208
|
if ("fulfilled" === inspectedValue.status)
|
|
5286
5209
|
inspectedValue = inspectedValue.value;
|
|
5287
5210
|
else break;
|
|
@@ -5302,10 +5225,20 @@
|
|
|
5302
5225
|
"function" === typeof reject && reject(this.reason);
|
|
5303
5226
|
}
|
|
5304
5227
|
};
|
|
5305
|
-
var
|
|
5306
|
-
|
|
5307
|
-
|
|
5308
|
-
|
|
5228
|
+
var ObjectPrototype = Object.prototype,
|
|
5229
|
+
ArrayPrototype = Array.prototype,
|
|
5230
|
+
initializingHandler = null;
|
|
5231
|
+
exports.createServerEntry = function (value, resource) {
|
|
5232
|
+
var entryJsFiles = __rspack_rsc_manifest__.entryJsFiles || [],
|
|
5233
|
+
entryCssFiles = __rspack_rsc_manifest__.entryCssFiles[resource] || [];
|
|
5234
|
+
("function" === typeof value ||
|
|
5235
|
+
("object" === typeof value && null !== value)) &&
|
|
5236
|
+
assign(value, {
|
|
5237
|
+
resource: resource,
|
|
5238
|
+
entryJsFiles: entryJsFiles,
|
|
5239
|
+
entryCssFiles: entryCssFiles
|
|
5240
|
+
});
|
|
5241
|
+
return value;
|
|
5309
5242
|
};
|
|
5310
5243
|
exports.createTemporaryReferenceSet = function () {
|
|
5311
5244
|
return new WeakMap();
|
|
@@ -5351,27 +5284,59 @@
|
|
|
5351
5284
|
: [actionResult, keyPath, referenceId, bound.length - 1];
|
|
5352
5285
|
});
|
|
5353
5286
|
};
|
|
5354
|
-
exports.decodeReply = function (body,
|
|
5287
|
+
exports.decodeReply = function (body, options) {
|
|
5355
5288
|
if ("string" === typeof body) {
|
|
5356
5289
|
var form = new FormData();
|
|
5357
5290
|
form.append("0", body);
|
|
5358
5291
|
body = form;
|
|
5359
5292
|
}
|
|
5360
5293
|
body = createResponse(
|
|
5361
|
-
|
|
5294
|
+
__rspack_rsc_manifest__.serverManifest,
|
|
5362
5295
|
"",
|
|
5363
5296
|
options ? options.temporaryReferences : void 0,
|
|
5364
5297
|
body
|
|
5365
5298
|
);
|
|
5366
|
-
|
|
5299
|
+
options = getChunk(body, 0);
|
|
5367
5300
|
close(body);
|
|
5368
|
-
return
|
|
5301
|
+
return options;
|
|
5302
|
+
};
|
|
5303
|
+
exports.decryptServerActionBoundArgs = function (
|
|
5304
|
+
actionId,
|
|
5305
|
+
encryptedPromise
|
|
5306
|
+
) {
|
|
5307
|
+
return currentStrategy.decrypt(actionId, encryptedPromise);
|
|
5308
|
+
};
|
|
5309
|
+
exports.encryptServerActionBoundArgs = function (actionId) {
|
|
5310
|
+
for (
|
|
5311
|
+
var _currentStrategy,
|
|
5312
|
+
_len2 = arguments.length,
|
|
5313
|
+
args = Array(1 < _len2 ? _len2 - 1 : 0),
|
|
5314
|
+
_key2 = 1;
|
|
5315
|
+
_key2 < _len2;
|
|
5316
|
+
_key2++
|
|
5317
|
+
)
|
|
5318
|
+
args[_key2 - 1] = arguments[_key2];
|
|
5319
|
+
return (_currentStrategy = currentStrategy).encrypt.apply(
|
|
5320
|
+
_currentStrategy,
|
|
5321
|
+
[actionId].concat(args)
|
|
5322
|
+
);
|
|
5323
|
+
};
|
|
5324
|
+
exports.ensureServerActions = function (actions) {
|
|
5325
|
+
for (var i = 0; i < actions.length; i++) {
|
|
5326
|
+
var action = actions[i];
|
|
5327
|
+
if ("function" !== typeof action)
|
|
5328
|
+
throw Error(
|
|
5329
|
+
'A "use server" file can only export async functions, found ' +
|
|
5330
|
+
typeof action +
|
|
5331
|
+
"."
|
|
5332
|
+
);
|
|
5333
|
+
}
|
|
5369
5334
|
};
|
|
5370
|
-
exports.prerender = function (model,
|
|
5335
|
+
exports.prerender = function (model, options) {
|
|
5371
5336
|
return new Promise(function (resolve, reject) {
|
|
5372
5337
|
var request = createPrerenderRequest(
|
|
5373
5338
|
model,
|
|
5374
|
-
|
|
5339
|
+
__rspack_rsc_manifest__.clientManifest,
|
|
5375
5340
|
function () {
|
|
5376
5341
|
var stream = new ReadableStream(
|
|
5377
5342
|
{
|
|
@@ -5391,7 +5356,6 @@
|
|
|
5391
5356
|
reject,
|
|
5392
5357
|
options ? options.onError : void 0,
|
|
5393
5358
|
options ? options.identifierPrefix : void 0,
|
|
5394
|
-
options ? options.onPostpone : void 0,
|
|
5395
5359
|
options ? options.temporaryReferences : void 0,
|
|
5396
5360
|
options ? options.environmentName : void 0,
|
|
5397
5361
|
options ? options.filterStackFrame : void 0,
|
|
@@ -5416,11 +5380,11 @@
|
|
|
5416
5380
|
id,
|
|
5417
5381
|
exportName
|
|
5418
5382
|
) {
|
|
5419
|
-
return
|
|
5420
|
-
|
|
5421
|
-
id + "#" + exportName,
|
|
5422
|
-
!1
|
|
5423
|
-
);
|
|
5383
|
+
return Object.defineProperties(proxyImplementation, {
|
|
5384
|
+
$$typeof: { value: CLIENT_REFERENCE_TAG$1 },
|
|
5385
|
+
$$id: { value: id + "#" + exportName },
|
|
5386
|
+
$$async: { value: !1 }
|
|
5387
|
+
});
|
|
5424
5388
|
};
|
|
5425
5389
|
exports.registerServerReference = function (reference, id, exportName) {
|
|
5426
5390
|
return Object.defineProperties(reference, {
|
|
@@ -5435,7 +5399,7 @@
|
|
|
5435
5399
|
toString: serverReferenceToString
|
|
5436
5400
|
});
|
|
5437
5401
|
};
|
|
5438
|
-
exports.renderToReadableStream = function (model,
|
|
5402
|
+
exports.renderToReadableStream = function (model, options) {
|
|
5439
5403
|
var debugChannelReadable =
|
|
5440
5404
|
options && options.debugChannel
|
|
5441
5405
|
? options.debugChannel.readable
|
|
@@ -5446,10 +5410,9 @@
|
|
|
5446
5410
|
: void 0,
|
|
5447
5411
|
request = createRequest(
|
|
5448
5412
|
model,
|
|
5449
|
-
|
|
5413
|
+
__rspack_rsc_manifest__.clientManifest,
|
|
5450
5414
|
options ? options.onError : void 0,
|
|
5451
5415
|
options ? options.identifierPrefix : void 0,
|
|
5452
|
-
options ? options.onPostpone : void 0,
|
|
5453
5416
|
options ? options.temporaryReferences : void 0,
|
|
5454
5417
|
options ? options.environmentName : void 0,
|
|
5455
5418
|
options ? options.filterStackFrame : void 0,
|
|
@@ -5512,4 +5475,7 @@
|
|
|
5512
5475
|
{ highWaterMark: 0 }
|
|
5513
5476
|
);
|
|
5514
5477
|
};
|
|
5478
|
+
exports.setServerActionBoundArgsEncryption = function (strategy) {
|
|
5479
|
+
currentStrategy = strategy;
|
|
5480
|
+
};
|
|
5515
5481
|
})();
|