1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 |
|
30 |
|
31 |
|
32 |
|
33 |
|
34 |
|
35 | "use strict";
|
36 | var React = require("react"),
|
37 | ReactDOM = require("react-dom");
|
38 | function formatProdErrorMessage(code) {
|
39 | var url = "https://react.dev/errors/" + code;
|
40 | if (1 < arguments.length) {
|
41 | url += "?args[]=" + encodeURIComponent(arguments[1]);
|
42 | for (var i = 2; i < arguments.length; i++)
|
43 | url += "&args[]=" + encodeURIComponent(arguments[i]);
|
44 | }
|
45 | return (
|
46 | "Minified React error #" +
|
47 | code +
|
48 | "; visit " +
|
49 | url +
|
50 | " for the full message or use the non-minified dev environment for full errors and additional helpful warnings."
|
51 | );
|
52 | }
|
53 | var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"),
|
54 | REACT_PORTAL_TYPE = Symbol.for("react.portal"),
|
55 | REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"),
|
56 | REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"),
|
57 | REACT_PROFILER_TYPE = Symbol.for("react.profiler"),
|
58 | REACT_PROVIDER_TYPE = Symbol.for("react.provider"),
|
59 | REACT_CONSUMER_TYPE = Symbol.for("react.consumer"),
|
60 | REACT_CONTEXT_TYPE = Symbol.for("react.context"),
|
61 | REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"),
|
62 | REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"),
|
63 | REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"),
|
64 | REACT_MEMO_TYPE = Symbol.for("react.memo"),
|
65 | REACT_LAZY_TYPE = Symbol.for("react.lazy"),
|
66 | REACT_SCOPE_TYPE = Symbol.for("react.scope"),
|
67 | REACT_DEBUG_TRACING_MODE_TYPE = Symbol.for("react.debug_trace_mode"),
|
68 | REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen"),
|
69 | REACT_LEGACY_HIDDEN_TYPE = Symbol.for("react.legacy_hidden"),
|
70 | MAYBE_ITERATOR_SYMBOL = Symbol.iterator,
|
71 | isArrayImpl = Array.isArray;
|
72 | function murmurhash3_32_gc(key, seed) {
|
73 | var remainder = key.length & 3;
|
74 | var bytes = key.length - remainder;
|
75 | var h1 = seed;
|
76 | for (seed = 0; seed < bytes; ) {
|
77 | var k1 =
|
78 | (key.charCodeAt(seed) & 255) |
|
79 | ((key.charCodeAt(++seed) & 255) << 8) |
|
80 | ((key.charCodeAt(++seed) & 255) << 16) |
|
81 | ((key.charCodeAt(++seed) & 255) << 24);
|
82 | ++seed;
|
83 | k1 =
|
84 | (3432918353 * (k1 & 65535) +
|
85 | (((3432918353 * (k1 >>> 16)) & 65535) << 16)) &
|
86 | 4294967295;
|
87 | k1 = (k1 << 15) | (k1 >>> 17);
|
88 | k1 =
|
89 | (461845907 * (k1 & 65535) + (((461845907 * (k1 >>> 16)) & 65535) << 16)) &
|
90 | 4294967295;
|
91 | h1 ^= k1;
|
92 | h1 = (h1 << 13) | (h1 >>> 19);
|
93 | h1 = (5 * (h1 & 65535) + (((5 * (h1 >>> 16)) & 65535) << 16)) & 4294967295;
|
94 | h1 = (h1 & 65535) + 27492 + ((((h1 >>> 16) + 58964) & 65535) << 16);
|
95 | }
|
96 | k1 = 0;
|
97 | switch (remainder) {
|
98 | case 3:
|
99 | k1 ^= (key.charCodeAt(seed + 2) & 255) << 16;
|
100 | case 2:
|
101 | k1 ^= (key.charCodeAt(seed + 1) & 255) << 8;
|
102 | case 1:
|
103 | (k1 ^= key.charCodeAt(seed) & 255),
|
104 | (k1 =
|
105 | (3432918353 * (k1 & 65535) +
|
106 | (((3432918353 * (k1 >>> 16)) & 65535) << 16)) &
|
107 | 4294967295),
|
108 | (k1 = (k1 << 15) | (k1 >>> 17)),
|
109 | (h1 ^=
|
110 | (461845907 * (k1 & 65535) +
|
111 | (((461845907 * (k1 >>> 16)) & 65535) << 16)) &
|
112 | 4294967295);
|
113 | }
|
114 | h1 ^= key.length;
|
115 | h1 ^= h1 >>> 16;
|
116 | h1 =
|
117 | (2246822507 * (h1 & 65535) + (((2246822507 * (h1 >>> 16)) & 65535) << 16)) &
|
118 | 4294967295;
|
119 | h1 ^= h1 >>> 13;
|
120 | h1 =
|
121 | (3266489909 * (h1 & 65535) + (((3266489909 * (h1 >>> 16)) & 65535) << 16)) &
|
122 | 4294967295;
|
123 | return (h1 ^ (h1 >>> 16)) >>> 0;
|
124 | }
|
125 | var assign = Object.assign,
|
126 | hasOwnProperty = Object.prototype.hasOwnProperty,
|
127 | VALID_ATTRIBUTE_NAME_REGEX = RegExp(
|
128 | "^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"
|
129 | ),
|
130 | illegalAttributeNameCache = {},
|
131 | validatedAttributeNameCache = {};
|
132 | function isAttributeNameSafe(attributeName) {
|
133 | if (hasOwnProperty.call(validatedAttributeNameCache, attributeName))
|
134 | return !0;
|
135 | if (hasOwnProperty.call(illegalAttributeNameCache, attributeName)) return !1;
|
136 | if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName))
|
137 | return (validatedAttributeNameCache[attributeName] = !0);
|
138 | illegalAttributeNameCache[attributeName] = !0;
|
139 | return !1;
|
140 | }
|
141 | var unitlessNumbers = new Set(
|
142 | "animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(
|
143 | " "
|
144 | )
|
145 | ),
|
146 | aliases = new Map([
|
147 | ["acceptCharset", "accept-charset"],
|
148 | ["htmlFor", "for"],
|
149 | ["httpEquiv", "http-equiv"],
|
150 | ["crossOrigin", "crossorigin"],
|
151 | ["accentHeight", "accent-height"],
|
152 | ["alignmentBaseline", "alignment-baseline"],
|
153 | ["arabicForm", "arabic-form"],
|
154 | ["baselineShift", "baseline-shift"],
|
155 | ["capHeight", "cap-height"],
|
156 | ["clipPath", "clip-path"],
|
157 | ["clipRule", "clip-rule"],
|
158 | ["colorInterpolation", "color-interpolation"],
|
159 | ["colorInterpolationFilters", "color-interpolation-filters"],
|
160 | ["colorProfile", "color-profile"],
|
161 | ["colorRendering", "color-rendering"],
|
162 | ["dominantBaseline", "dominant-baseline"],
|
163 | ["enableBackground", "enable-background"],
|
164 | ["fillOpacity", "fill-opacity"],
|
165 | ["fillRule", "fill-rule"],
|
166 | ["floodColor", "flood-color"],
|
167 | ["floodOpacity", "flood-opacity"],
|
168 | ["fontFamily", "font-family"],
|
169 | ["fontSize", "font-size"],
|
170 | ["fontSizeAdjust", "font-size-adjust"],
|
171 | ["fontStretch", "font-stretch"],
|
172 | ["fontStyle", "font-style"],
|
173 | ["fontVariant", "font-variant"],
|
174 | ["fontWeight", "font-weight"],
|
175 | ["glyphName", "glyph-name"],
|
176 | ["glyphOrientationHorizontal", "glyph-orientation-horizontal"],
|
177 | ["glyphOrientationVertical", "glyph-orientation-vertical"],
|
178 | ["horizAdvX", "horiz-adv-x"],
|
179 | ["horizOriginX", "horiz-origin-x"],
|
180 | ["imageRendering", "image-rendering"],
|
181 | ["letterSpacing", "letter-spacing"],
|
182 | ["lightingColor", "lighting-color"],
|
183 | ["markerEnd", "marker-end"],
|
184 | ["markerMid", "marker-mid"],
|
185 | ["markerStart", "marker-start"],
|
186 | ["overlinePosition", "overline-position"],
|
187 | ["overlineThickness", "overline-thickness"],
|
188 | ["paintOrder", "paint-order"],
|
189 | ["panose-1", "panose-1"],
|
190 | ["pointerEvents", "pointer-events"],
|
191 | ["renderingIntent", "rendering-intent"],
|
192 | ["shapeRendering", "shape-rendering"],
|
193 | ["stopColor", "stop-color"],
|
194 | ["stopOpacity", "stop-opacity"],
|
195 | ["strikethroughPosition", "strikethrough-position"],
|
196 | ["strikethroughThickness", "strikethrough-thickness"],
|
197 | ["strokeDasharray", "stroke-dasharray"],
|
198 | ["strokeDashoffset", "stroke-dashoffset"],
|
199 | ["strokeLinecap", "stroke-linecap"],
|
200 | ["strokeLinejoin", "stroke-linejoin"],
|
201 | ["strokeMiterlimit", "stroke-miterlimit"],
|
202 | ["strokeOpacity", "stroke-opacity"],
|
203 | ["strokeWidth", "stroke-width"],
|
204 | ["textAnchor", "text-anchor"],
|
205 | ["textDecoration", "text-decoration"],
|
206 | ["textRendering", "text-rendering"],
|
207 | ["transformOrigin", "transform-origin"],
|
208 | ["underlinePosition", "underline-position"],
|
209 | ["underlineThickness", "underline-thickness"],
|
210 | ["unicodeBidi", "unicode-bidi"],
|
211 | ["unicodeRange", "unicode-range"],
|
212 | ["unitsPerEm", "units-per-em"],
|
213 | ["vAlphabetic", "v-alphabetic"],
|
214 | ["vHanging", "v-hanging"],
|
215 | ["vIdeographic", "v-ideographic"],
|
216 | ["vMathematical", "v-mathematical"],
|
217 | ["vectorEffect", "vector-effect"],
|
218 | ["vertAdvY", "vert-adv-y"],
|
219 | ["vertOriginX", "vert-origin-x"],
|
220 | ["vertOriginY", "vert-origin-y"],
|
221 | ["wordSpacing", "word-spacing"],
|
222 | ["writingMode", "writing-mode"],
|
223 | ["xmlnsXlink", "xmlns:xlink"],
|
224 | ["xHeight", "x-height"]
|
225 | ]),
|
226 | matchHtmlRegExp = /["'&<>]/;
|
227 | function escapeTextForBrowser(text) {
|
228 | if (
|
229 | "boolean" === typeof text ||
|
230 | "number" === typeof text ||
|
231 | "bigint" === typeof text
|
232 | )
|
233 | return "" + text;
|
234 | text = "" + text;
|
235 | var match = matchHtmlRegExp.exec(text);
|
236 | if (match) {
|
237 | var html = "",
|
238 | index,
|
239 | lastIndex = 0;
|
240 | for (index = match.index; index < text.length; index++) {
|
241 | switch (text.charCodeAt(index)) {
|
242 | case 34:
|
243 | match = """;
|
244 | break;
|
245 | case 38:
|
246 | match = "&";
|
247 | break;
|
248 | case 39:
|
249 | match = "'";
|
250 | break;
|
251 | case 60:
|
252 | match = "<";
|
253 | break;
|
254 | case 62:
|
255 | match = ">";
|
256 | break;
|
257 | default:
|
258 | continue;
|
259 | }
|
260 | lastIndex !== index && (html += text.slice(lastIndex, index));
|
261 | lastIndex = index + 1;
|
262 | html += match;
|
263 | }
|
264 | text = lastIndex !== index ? html + text.slice(lastIndex, index) : html;
|
265 | }
|
266 | return text;
|
267 | }
|
268 | var uppercasePattern = /([A-Z])/g,
|
269 | msPattern = /^ms-/,
|
270 | isJavaScriptProtocol =
|
271 | /^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;
|
272 | function sanitizeURL(url) {
|
273 | return isJavaScriptProtocol.test("" + url)
|
274 | ? "javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')"
|
275 | : url;
|
276 | }
|
277 | var ReactSharedInternals =
|
278 | React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
|
279 | ReactDOMSharedInternals =
|
280 | ReactDOM.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
|
281 | sharedNotPendingObject = {
|
282 | pending: !1,
|
283 | data: null,
|
284 | method: null,
|
285 | action: null
|
286 | },
|
287 | previousDispatcher = ReactDOMSharedInternals.d;
|
288 | ReactDOMSharedInternals.d = {
|
289 | f: previousDispatcher.f,
|
290 | r: previousDispatcher.r,
|
291 | D: prefetchDNS,
|
292 | C: preconnect,
|
293 | L: preload,
|
294 | m: preloadModule,
|
295 | X: preinitScript,
|
296 | S: preinitStyle,
|
297 | M: preinitModuleScript
|
298 | };
|
299 | var PRELOAD_NO_CREDS = [],
|
300 | scriptRegex = /(<\/|<)(s)(cript)/gi;
|
301 | function scriptReplacer(match, prefix, s, suffix) {
|
302 | return "" + prefix + ("s" === s ? "\\u0073" : "\\u0053") + suffix;
|
303 | }
|
304 | function createResumableState(
|
305 | identifierPrefix,
|
306 | externalRuntimeConfig,
|
307 | bootstrapScriptContent,
|
308 | bootstrapScripts,
|
309 | bootstrapModules
|
310 | ) {
|
311 | return {
|
312 | idPrefix: void 0 === identifierPrefix ? "" : identifierPrefix,
|
313 | nextFormID: 0,
|
314 | streamingFormat: 0,
|
315 | bootstrapScriptContent: bootstrapScriptContent,
|
316 | bootstrapScripts: bootstrapScripts,
|
317 | bootstrapModules: bootstrapModules,
|
318 | instructions: 0,
|
319 | hasBody: !1,
|
320 | hasHtml: !1,
|
321 | unknownResources: {},
|
322 | dnsResources: {},
|
323 | connectResources: { default: {}, anonymous: {}, credentials: {} },
|
324 | imageResources: {},
|
325 | styleResources: {},
|
326 | scriptResources: {},
|
327 | moduleUnknownResources: {},
|
328 | moduleScriptResources: {}
|
329 | };
|
330 | }
|
331 | function createFormatContext(insertionMode, selectedValue, tagScope) {
|
332 | return {
|
333 | insertionMode: insertionMode,
|
334 | selectedValue: selectedValue,
|
335 | tagScope: tagScope
|
336 | };
|
337 | }
|
338 | function getChildFormatContext(parentContext, type, props) {
|
339 | switch (type) {
|
340 | case "noscript":
|
341 | return createFormatContext(2, null, parentContext.tagScope | 1);
|
342 | case "select":
|
343 | return createFormatContext(
|
344 | 2,
|
345 | null != props.value ? props.value : props.defaultValue,
|
346 | parentContext.tagScope
|
347 | );
|
348 | case "svg":
|
349 | return createFormatContext(3, null, parentContext.tagScope);
|
350 | case "picture":
|
351 | return createFormatContext(2, null, parentContext.tagScope | 2);
|
352 | case "math":
|
353 | return createFormatContext(4, null, parentContext.tagScope);
|
354 | case "foreignObject":
|
355 | return createFormatContext(2, null, parentContext.tagScope);
|
356 | case "table":
|
357 | return createFormatContext(5, null, parentContext.tagScope);
|
358 | case "thead":
|
359 | case "tbody":
|
360 | case "tfoot":
|
361 | return createFormatContext(6, null, parentContext.tagScope);
|
362 | case "colgroup":
|
363 | return createFormatContext(8, null, parentContext.tagScope);
|
364 | case "tr":
|
365 | return createFormatContext(7, null, parentContext.tagScope);
|
366 | }
|
367 | return 5 <= parentContext.insertionMode
|
368 | ? createFormatContext(2, null, parentContext.tagScope)
|
369 | : 0 === parentContext.insertionMode
|
370 | ? "html" === type
|
371 | ? createFormatContext(1, null, parentContext.tagScope)
|
372 | : createFormatContext(2, null, parentContext.tagScope)
|
373 | : 1 === parentContext.insertionMode
|
374 | ? createFormatContext(2, null, parentContext.tagScope)
|
375 | : parentContext;
|
376 | }
|
377 | var styleNameCache = new Map();
|
378 | function pushStyleAttribute(target, style) {
|
379 | if ("object" !== typeof style) throw Error(formatProdErrorMessage(62));
|
380 | var isFirst = !0,
|
381 | styleName;
|
382 | for (styleName in style)
|
383 | if (hasOwnProperty.call(style, styleName)) {
|
384 | var styleValue = style[styleName];
|
385 | if (
|
386 | null != styleValue &&
|
387 | "boolean" !== typeof styleValue &&
|
388 | "" !== styleValue
|
389 | ) {
|
390 | if (0 === styleName.indexOf("--")) {
|
391 | var nameChunk = escapeTextForBrowser(styleName);
|
392 | styleValue = escapeTextForBrowser(("" + styleValue).trim());
|
393 | } else
|
394 | (nameChunk = styleNameCache.get(styleName)),
|
395 | void 0 === nameChunk &&
|
396 | ((nameChunk = escapeTextForBrowser(
|
397 | styleName
|
398 | .replace(uppercasePattern, "-$1")
|
399 | .toLowerCase()
|
400 | .replace(msPattern, "-ms-")
|
401 | )),
|
402 | styleNameCache.set(styleName, nameChunk)),
|
403 | (styleValue =
|
404 | "number" === typeof styleValue
|
405 | ? 0 === styleValue || unitlessNumbers.has(styleName)
|
406 | ? "" + styleValue
|
407 | : styleValue + "px"
|
408 | : escapeTextForBrowser(("" + styleValue).trim()));
|
409 | isFirst
|
410 | ? ((isFirst = !1),
|
411 | target.push(' style="', nameChunk, ":", styleValue))
|
412 | : target.push(";", nameChunk, ":", styleValue);
|
413 | }
|
414 | }
|
415 | isFirst || target.push('"');
|
416 | }
|
417 | function pushBooleanAttribute(target, name, value) {
|
418 | value &&
|
419 | "function" !== typeof value &&
|
420 | "symbol" !== typeof value &&
|
421 | target.push(" ", name, '=""');
|
422 | }
|
423 | function pushStringAttribute(target, name, value) {
|
424 | "function" !== typeof value &&
|
425 | "symbol" !== typeof value &&
|
426 | "boolean" !== typeof value &&
|
427 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
428 | }
|
429 | var actionJavaScriptURL = escapeTextForBrowser(
|
430 | "javascript:throw new Error('React form unexpectedly submitted.')"
|
431 | );
|
432 | function pushAdditionalFormField(value, key) {
|
433 | this.push('<input type="hidden"');
|
434 | if ("string" !== typeof value) throw Error(formatProdErrorMessage(480));
|
435 | pushStringAttribute(this, "name", key);
|
436 | pushStringAttribute(this, "value", value);
|
437 | this.push("/>");
|
438 | }
|
439 | function getCustomFormFields(resumableState, formAction) {
|
440 | if ("function" === typeof formAction.$$FORM_ACTION) {
|
441 | var id = resumableState.nextFormID++;
|
442 | resumableState = resumableState.idPrefix + id;
|
443 | try {
|
444 | return formAction.$$FORM_ACTION(resumableState);
|
445 | } catch (x) {
|
446 | if ("object" === typeof x && null !== x && "function" === typeof x.then)
|
447 | throw x;
|
448 | }
|
449 | }
|
450 | return null;
|
451 | }
|
452 | function pushFormActionAttribute(
|
453 | target,
|
454 | resumableState,
|
455 | renderState,
|
456 | formAction,
|
457 | formEncType,
|
458 | formMethod,
|
459 | formTarget,
|
460 | name
|
461 | ) {
|
462 | var formData = null;
|
463 | if ("function" === typeof formAction) {
|
464 | var customFields = getCustomFormFields(resumableState, formAction);
|
465 | null !== customFields
|
466 | ? ((name = customFields.name),
|
467 | (formAction = customFields.action || ""),
|
468 | (formEncType = customFields.encType),
|
469 | (formMethod = customFields.method),
|
470 | (formTarget = customFields.target),
|
471 | (formData = customFields.data))
|
472 | : (target.push(" ", "formAction", '="', actionJavaScriptURL, '"'),
|
473 | (formTarget = formMethod = formEncType = formAction = name = null),
|
474 | injectFormReplayingRuntime(resumableState, renderState));
|
475 | }
|
476 | null != name && pushAttribute(target, "name", name);
|
477 | null != formAction && pushAttribute(target, "formAction", formAction);
|
478 | null != formEncType && pushAttribute(target, "formEncType", formEncType);
|
479 | null != formMethod && pushAttribute(target, "formMethod", formMethod);
|
480 | null != formTarget && pushAttribute(target, "formTarget", formTarget);
|
481 | return formData;
|
482 | }
|
483 | function pushAttribute(target, name, value) {
|
484 | switch (name) {
|
485 | case "className":
|
486 | pushStringAttribute(target, "class", value);
|
487 | break;
|
488 | case "tabIndex":
|
489 | pushStringAttribute(target, "tabindex", value);
|
490 | break;
|
491 | case "dir":
|
492 | case "role":
|
493 | case "viewBox":
|
494 | case "width":
|
495 | case "height":
|
496 | pushStringAttribute(target, name, value);
|
497 | break;
|
498 | case "style":
|
499 | pushStyleAttribute(target, value);
|
500 | break;
|
501 | case "src":
|
502 | case "href":
|
503 | if ("" === value) break;
|
504 | case "action":
|
505 | case "formAction":
|
506 | if (
|
507 | null == value ||
|
508 | "function" === typeof value ||
|
509 | "symbol" === typeof value ||
|
510 | "boolean" === typeof value
|
511 | )
|
512 | break;
|
513 | value = sanitizeURL("" + value);
|
514 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
515 | break;
|
516 | case "defaultValue":
|
517 | case "defaultChecked":
|
518 | case "innerHTML":
|
519 | case "suppressContentEditableWarning":
|
520 | case "suppressHydrationWarning":
|
521 | case "ref":
|
522 | break;
|
523 | case "autoFocus":
|
524 | case "multiple":
|
525 | case "muted":
|
526 | pushBooleanAttribute(target, name.toLowerCase(), value);
|
527 | break;
|
528 | case "xlinkHref":
|
529 | if (
|
530 | "function" === typeof value ||
|
531 | "symbol" === typeof value ||
|
532 | "boolean" === typeof value
|
533 | )
|
534 | break;
|
535 | value = sanitizeURL("" + value);
|
536 | target.push(" ", "xlink:href", '="', escapeTextForBrowser(value), '"');
|
537 | break;
|
538 | case "contentEditable":
|
539 | case "spellCheck":
|
540 | case "draggable":
|
541 | case "value":
|
542 | case "autoReverse":
|
543 | case "externalResourcesRequired":
|
544 | case "focusable":
|
545 | case "preserveAlpha":
|
546 | "function" !== typeof value &&
|
547 | "symbol" !== typeof value &&
|
548 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
549 | break;
|
550 | case "inert":
|
551 | case "allowFullScreen":
|
552 | case "async":
|
553 | case "autoPlay":
|
554 | case "controls":
|
555 | case "default":
|
556 | case "defer":
|
557 | case "disabled":
|
558 | case "disablePictureInPicture":
|
559 | case "disableRemotePlayback":
|
560 | case "formNoValidate":
|
561 | case "hidden":
|
562 | case "loop":
|
563 | case "noModule":
|
564 | case "noValidate":
|
565 | case "open":
|
566 | case "playsInline":
|
567 | case "readOnly":
|
568 | case "required":
|
569 | case "reversed":
|
570 | case "scoped":
|
571 | case "seamless":
|
572 | case "itemScope":
|
573 | value &&
|
574 | "function" !== typeof value &&
|
575 | "symbol" !== typeof value &&
|
576 | target.push(" ", name, '=""');
|
577 | break;
|
578 | case "capture":
|
579 | case "download":
|
580 | !0 === value
|
581 | ? target.push(" ", name, '=""')
|
582 | : !1 !== value &&
|
583 | "function" !== typeof value &&
|
584 | "symbol" !== typeof value &&
|
585 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
586 | break;
|
587 | case "cols":
|
588 | case "rows":
|
589 | case "size":
|
590 | case "span":
|
591 | "function" !== typeof value &&
|
592 | "symbol" !== typeof value &&
|
593 | !isNaN(value) &&
|
594 | 1 <= value &&
|
595 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
596 | break;
|
597 | case "rowSpan":
|
598 | case "start":
|
599 | "function" === typeof value ||
|
600 | "symbol" === typeof value ||
|
601 | isNaN(value) ||
|
602 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
603 | break;
|
604 | case "xlinkActuate":
|
605 | pushStringAttribute(target, "xlink:actuate", value);
|
606 | break;
|
607 | case "xlinkArcrole":
|
608 | pushStringAttribute(target, "xlink:arcrole", value);
|
609 | break;
|
610 | case "xlinkRole":
|
611 | pushStringAttribute(target, "xlink:role", value);
|
612 | break;
|
613 | case "xlinkShow":
|
614 | pushStringAttribute(target, "xlink:show", value);
|
615 | break;
|
616 | case "xlinkTitle":
|
617 | pushStringAttribute(target, "xlink:title", value);
|
618 | break;
|
619 | case "xlinkType":
|
620 | pushStringAttribute(target, "xlink:type", value);
|
621 | break;
|
622 | case "xmlBase":
|
623 | pushStringAttribute(target, "xml:base", value);
|
624 | break;
|
625 | case "xmlLang":
|
626 | pushStringAttribute(target, "xml:lang", value);
|
627 | break;
|
628 | case "xmlSpace":
|
629 | pushStringAttribute(target, "xml:space", value);
|
630 | break;
|
631 | default:
|
632 | if (
|
633 | !(2 < name.length) ||
|
634 | ("o" !== name[0] && "O" !== name[0]) ||
|
635 | ("n" !== name[1] && "N" !== name[1])
|
636 | )
|
637 | if (((name = aliases.get(name) || name), isAttributeNameSafe(name))) {
|
638 | switch (typeof value) {
|
639 | case "function":
|
640 | case "symbol":
|
641 | return;
|
642 | case "boolean":
|
643 | var prefix$8 = name.toLowerCase().slice(0, 5);
|
644 | if ("data-" !== prefix$8 && "aria-" !== prefix$8) return;
|
645 | }
|
646 | target.push(" ", name, '="', escapeTextForBrowser(value), '"');
|
647 | }
|
648 | }
|
649 | }
|
650 | function pushInnerHTML(target, innerHTML, children) {
|
651 | if (null != innerHTML) {
|
652 | if (null != children) throw Error(formatProdErrorMessage(60));
|
653 | if ("object" !== typeof innerHTML || !("__html" in innerHTML))
|
654 | throw Error(formatProdErrorMessage(61));
|
655 | innerHTML = innerHTML.__html;
|
656 | null !== innerHTML && void 0 !== innerHTML && target.push("" + innerHTML);
|
657 | }
|
658 | }
|
659 | function flattenOptionChildren(children) {
|
660 | var content = "";
|
661 | React.Children.forEach(children, function (child) {
|
662 | null != child && (content += child);
|
663 | });
|
664 | return content;
|
665 | }
|
666 | function injectFormReplayingRuntime(resumableState, renderState) {
|
667 | 0 === (resumableState.instructions & 16) &&
|
668 | ((resumableState.instructions |= 16),
|
669 | renderState.bootstrapChunks.unshift(
|
670 | renderState.startInlineScript,
|
671 | 'addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error(\'React form unexpectedly submitted.\')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});',
|
672 | "\x3c/script>"
|
673 | ));
|
674 | }
|
675 | function pushLinkImpl(target, props) {
|
676 | target.push(startChunkForTag("link"));
|
677 | for (var propKey in props)
|
678 | if (hasOwnProperty.call(props, propKey)) {
|
679 | var propValue = props[propKey];
|
680 | if (null != propValue)
|
681 | switch (propKey) {
|
682 | case "children":
|
683 | case "dangerouslySetInnerHTML":
|
684 | throw Error(formatProdErrorMessage(399, "link"));
|
685 | default:
|
686 | pushAttribute(target, propKey, propValue);
|
687 | }
|
688 | }
|
689 | target.push("/>");
|
690 | return null;
|
691 | }
|
692 | var styleRegex = /(<\/|<)(s)(tyle)/gi;
|
693 | function styleReplacer(match, prefix, s, suffix) {
|
694 | return "" + prefix + ("s" === s ? "\\73 " : "\\53 ") + suffix;
|
695 | }
|
696 | function pushSelfClosing(target, props, tag) {
|
697 | target.push(startChunkForTag(tag));
|
698 | for (var propKey in props)
|
699 | if (hasOwnProperty.call(props, propKey)) {
|
700 | var propValue = props[propKey];
|
701 | if (null != propValue)
|
702 | switch (propKey) {
|
703 | case "children":
|
704 | case "dangerouslySetInnerHTML":
|
705 | throw Error(formatProdErrorMessage(399, tag));
|
706 | default:
|
707 | pushAttribute(target, propKey, propValue);
|
708 | }
|
709 | }
|
710 | target.push("/>");
|
711 | return null;
|
712 | }
|
713 | function pushTitleImpl(target, props) {
|
714 | target.push(startChunkForTag("title"));
|
715 | var children = null,
|
716 | innerHTML = null,
|
717 | propKey;
|
718 | for (propKey in props)
|
719 | if (hasOwnProperty.call(props, propKey)) {
|
720 | var propValue = props[propKey];
|
721 | if (null != propValue)
|
722 | switch (propKey) {
|
723 | case "children":
|
724 | children = propValue;
|
725 | break;
|
726 | case "dangerouslySetInnerHTML":
|
727 | innerHTML = propValue;
|
728 | break;
|
729 | default:
|
730 | pushAttribute(target, propKey, propValue);
|
731 | }
|
732 | }
|
733 | target.push(">");
|
734 | props = Array.isArray(children)
|
735 | ? 2 > children.length
|
736 | ? children[0]
|
737 | : null
|
738 | : children;
|
739 | "function" !== typeof props &&
|
740 | "symbol" !== typeof props &&
|
741 | null !== props &&
|
742 | void 0 !== props &&
|
743 | target.push(escapeTextForBrowser("" + props));
|
744 | pushInnerHTML(target, innerHTML, children);
|
745 | target.push(endChunkForTag("title"));
|
746 | return null;
|
747 | }
|
748 | function pushScriptImpl(target, props) {
|
749 | target.push(startChunkForTag("script"));
|
750 | var children = null,
|
751 | innerHTML = null,
|
752 | propKey;
|
753 | for (propKey in props)
|
754 | if (hasOwnProperty.call(props, propKey)) {
|
755 | var propValue = props[propKey];
|
756 | if (null != propValue)
|
757 | switch (propKey) {
|
758 | case "children":
|
759 | children = propValue;
|
760 | break;
|
761 | case "dangerouslySetInnerHTML":
|
762 | innerHTML = propValue;
|
763 | break;
|
764 | default:
|
765 | pushAttribute(target, propKey, propValue);
|
766 | }
|
767 | }
|
768 | target.push(">");
|
769 | pushInnerHTML(target, innerHTML, children);
|
770 | "string" === typeof children &&
|
771 | target.push(("" + children).replace(scriptRegex, scriptReplacer));
|
772 | target.push(endChunkForTag("script"));
|
773 | return null;
|
774 | }
|
775 | function pushStartGenericElement(target, props, tag) {
|
776 | target.push(startChunkForTag(tag));
|
777 | var innerHTML = (tag = null),
|
778 | propKey;
|
779 | for (propKey in props)
|
780 | if (hasOwnProperty.call(props, propKey)) {
|
781 | var propValue = props[propKey];
|
782 | if (null != propValue)
|
783 | switch (propKey) {
|
784 | case "children":
|
785 | tag = propValue;
|
786 | break;
|
787 | case "dangerouslySetInnerHTML":
|
788 | innerHTML = propValue;
|
789 | break;
|
790 | default:
|
791 | pushAttribute(target, propKey, propValue);
|
792 | }
|
793 | }
|
794 | target.push(">");
|
795 | pushInnerHTML(target, innerHTML, tag);
|
796 | return "string" === typeof tag
|
797 | ? (target.push(escapeTextForBrowser(tag)), null)
|
798 | : tag;
|
799 | }
|
800 | var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,
|
801 | validatedTagCache = new Map();
|
802 | function startChunkForTag(tag) {
|
803 | var tagStartChunk = validatedTagCache.get(tag);
|
804 | if (void 0 === tagStartChunk) {
|
805 | if (!VALID_TAG_REGEX.test(tag))
|
806 | throw Error(formatProdErrorMessage(65, tag));
|
807 | tagStartChunk = "<" + tag;
|
808 | validatedTagCache.set(tag, tagStartChunk);
|
809 | }
|
810 | return tagStartChunk;
|
811 | }
|
812 | function pushStartInstance(
|
813 | target$jscomp$0,
|
814 | type,
|
815 | props,
|
816 | resumableState,
|
817 | renderState,
|
818 | hoistableState,
|
819 | formatContext,
|
820 | textEmbedded,
|
821 | isFallback
|
822 | ) {
|
823 | switch (type) {
|
824 | case "div":
|
825 | case "span":
|
826 | case "svg":
|
827 | case "path":
|
828 | break;
|
829 | case "a":
|
830 | target$jscomp$0.push(startChunkForTag("a"));
|
831 | var children = null,
|
832 | innerHTML = null,
|
833 | propKey;
|
834 | for (propKey in props)
|
835 | if (hasOwnProperty.call(props, propKey)) {
|
836 | var propValue = props[propKey];
|
837 | if (null != propValue)
|
838 | switch (propKey) {
|
839 | case "children":
|
840 | children = propValue;
|
841 | break;
|
842 | case "dangerouslySetInnerHTML":
|
843 | innerHTML = propValue;
|
844 | break;
|
845 | case "href":
|
846 | "" === propValue
|
847 | ? pushStringAttribute(target$jscomp$0, "href", "")
|
848 | : pushAttribute(target$jscomp$0, propKey, propValue);
|
849 | break;
|
850 | default:
|
851 | pushAttribute(target$jscomp$0, propKey, propValue);
|
852 | }
|
853 | }
|
854 | target$jscomp$0.push(">");
|
855 | pushInnerHTML(target$jscomp$0, innerHTML, children);
|
856 | if ("string" === typeof children) {
|
857 | target$jscomp$0.push(escapeTextForBrowser(children));
|
858 | var JSCompiler_inline_result = null;
|
859 | } else JSCompiler_inline_result = children;
|
860 | return JSCompiler_inline_result;
|
861 | case "g":
|
862 | case "p":
|
863 | case "li":
|
864 | break;
|
865 | case "select":
|
866 | target$jscomp$0.push(startChunkForTag("select"));
|
867 | var children$jscomp$0 = null,
|
868 | innerHTML$jscomp$0 = null,
|
869 | propKey$jscomp$0;
|
870 | for (propKey$jscomp$0 in props)
|
871 | if (hasOwnProperty.call(props, propKey$jscomp$0)) {
|
872 | var propValue$jscomp$0 = props[propKey$jscomp$0];
|
873 | if (null != propValue$jscomp$0)
|
874 | switch (propKey$jscomp$0) {
|
875 | case "children":
|
876 | children$jscomp$0 = propValue$jscomp$0;
|
877 | break;
|
878 | case "dangerouslySetInnerHTML":
|
879 | innerHTML$jscomp$0 = propValue$jscomp$0;
|
880 | break;
|
881 | case "defaultValue":
|
882 | case "value":
|
883 | break;
|
884 | default:
|
885 | pushAttribute(
|
886 | target$jscomp$0,
|
887 | propKey$jscomp$0,
|
888 | propValue$jscomp$0
|
889 | );
|
890 | }
|
891 | }
|
892 | target$jscomp$0.push(">");
|
893 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$0, children$jscomp$0);
|
894 | return children$jscomp$0;
|
895 | case "option":
|
896 | var selectedValue = formatContext.selectedValue;
|
897 | target$jscomp$0.push(startChunkForTag("option"));
|
898 | var children$jscomp$1 = null,
|
899 | value = null,
|
900 | selected = null,
|
901 | innerHTML$jscomp$1 = null,
|
902 | propKey$jscomp$1;
|
903 | for (propKey$jscomp$1 in props)
|
904 | if (hasOwnProperty.call(props, propKey$jscomp$1)) {
|
905 | var propValue$jscomp$1 = props[propKey$jscomp$1];
|
906 | if (null != propValue$jscomp$1)
|
907 | switch (propKey$jscomp$1) {
|
908 | case "children":
|
909 | children$jscomp$1 = propValue$jscomp$1;
|
910 | break;
|
911 | case "selected":
|
912 | selected = propValue$jscomp$1;
|
913 | break;
|
914 | case "dangerouslySetInnerHTML":
|
915 | innerHTML$jscomp$1 = propValue$jscomp$1;
|
916 | break;
|
917 | case "value":
|
918 | value = propValue$jscomp$1;
|
919 | default:
|
920 | pushAttribute(
|
921 | target$jscomp$0,
|
922 | propKey$jscomp$1,
|
923 | propValue$jscomp$1
|
924 | );
|
925 | }
|
926 | }
|
927 | if (null != selectedValue) {
|
928 | var stringValue =
|
929 | null !== value
|
930 | ? "" + value
|
931 | : flattenOptionChildren(children$jscomp$1);
|
932 | if (isArrayImpl(selectedValue))
|
933 | for (var i = 0; i < selectedValue.length; i++) {
|
934 | if ("" + selectedValue[i] === stringValue) {
|
935 | target$jscomp$0.push(' selected=""');
|
936 | break;
|
937 | }
|
938 | }
|
939 | else
|
940 | "" + selectedValue === stringValue &&
|
941 | target$jscomp$0.push(' selected=""');
|
942 | } else selected && target$jscomp$0.push(' selected=""');
|
943 | target$jscomp$0.push(">");
|
944 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$1, children$jscomp$1);
|
945 | return children$jscomp$1;
|
946 | case "textarea":
|
947 | target$jscomp$0.push(startChunkForTag("textarea"));
|
948 | var value$jscomp$0 = null,
|
949 | defaultValue = null,
|
950 | children$jscomp$2 = null,
|
951 | propKey$jscomp$2;
|
952 | for (propKey$jscomp$2 in props)
|
953 | if (hasOwnProperty.call(props, propKey$jscomp$2)) {
|
954 | var propValue$jscomp$2 = props[propKey$jscomp$2];
|
955 | if (null != propValue$jscomp$2)
|
956 | switch (propKey$jscomp$2) {
|
957 | case "children":
|
958 | children$jscomp$2 = propValue$jscomp$2;
|
959 | break;
|
960 | case "value":
|
961 | value$jscomp$0 = propValue$jscomp$2;
|
962 | break;
|
963 | case "defaultValue":
|
964 | defaultValue = propValue$jscomp$2;
|
965 | break;
|
966 | case "dangerouslySetInnerHTML":
|
967 | throw Error(formatProdErrorMessage(91));
|
968 | default:
|
969 | pushAttribute(
|
970 | target$jscomp$0,
|
971 | propKey$jscomp$2,
|
972 | propValue$jscomp$2
|
973 | );
|
974 | }
|
975 | }
|
976 | null === value$jscomp$0 &&
|
977 | null !== defaultValue &&
|
978 | (value$jscomp$0 = defaultValue);
|
979 | target$jscomp$0.push(">");
|
980 | if (null != children$jscomp$2) {
|
981 | if (null != value$jscomp$0) throw Error(formatProdErrorMessage(92));
|
982 | if (isArrayImpl(children$jscomp$2)) {
|
983 | if (1 < children$jscomp$2.length)
|
984 | throw Error(formatProdErrorMessage(93));
|
985 | value$jscomp$0 = "" + children$jscomp$2[0];
|
986 | }
|
987 | value$jscomp$0 = "" + children$jscomp$2;
|
988 | }
|
989 | "string" === typeof value$jscomp$0 &&
|
990 | "\n" === value$jscomp$0[0] &&
|
991 | target$jscomp$0.push("\n");
|
992 | null !== value$jscomp$0 &&
|
993 | target$jscomp$0.push(escapeTextForBrowser("" + value$jscomp$0));
|
994 | return null;
|
995 | case "input":
|
996 | target$jscomp$0.push(startChunkForTag("input"));
|
997 | var name = null,
|
998 | formAction = null,
|
999 | formEncType = null,
|
1000 | formMethod = null,
|
1001 | formTarget = null,
|
1002 | value$jscomp$1 = null,
|
1003 | defaultValue$jscomp$0 = null,
|
1004 | checked = null,
|
1005 | defaultChecked = null,
|
1006 | propKey$jscomp$3;
|
1007 | for (propKey$jscomp$3 in props)
|
1008 | if (hasOwnProperty.call(props, propKey$jscomp$3)) {
|
1009 | var propValue$jscomp$3 = props[propKey$jscomp$3];
|
1010 | if (null != propValue$jscomp$3)
|
1011 | switch (propKey$jscomp$3) {
|
1012 | case "children":
|
1013 | case "dangerouslySetInnerHTML":
|
1014 | throw Error(formatProdErrorMessage(399, "input"));
|
1015 | case "name":
|
1016 | name = propValue$jscomp$3;
|
1017 | break;
|
1018 | case "formAction":
|
1019 | formAction = propValue$jscomp$3;
|
1020 | break;
|
1021 | case "formEncType":
|
1022 | formEncType = propValue$jscomp$3;
|
1023 | break;
|
1024 | case "formMethod":
|
1025 | formMethod = propValue$jscomp$3;
|
1026 | break;
|
1027 | case "formTarget":
|
1028 | formTarget = propValue$jscomp$3;
|
1029 | break;
|
1030 | case "defaultChecked":
|
1031 | defaultChecked = propValue$jscomp$3;
|
1032 | break;
|
1033 | case "defaultValue":
|
1034 | defaultValue$jscomp$0 = propValue$jscomp$3;
|
1035 | break;
|
1036 | case "checked":
|
1037 | checked = propValue$jscomp$3;
|
1038 | break;
|
1039 | case "value":
|
1040 | value$jscomp$1 = propValue$jscomp$3;
|
1041 | break;
|
1042 | default:
|
1043 | pushAttribute(
|
1044 | target$jscomp$0,
|
1045 | propKey$jscomp$3,
|
1046 | propValue$jscomp$3
|
1047 | );
|
1048 | }
|
1049 | }
|
1050 | var formData = pushFormActionAttribute(
|
1051 | target$jscomp$0,
|
1052 | resumableState,
|
1053 | renderState,
|
1054 | formAction,
|
1055 | formEncType,
|
1056 | formMethod,
|
1057 | formTarget,
|
1058 | name
|
1059 | );
|
1060 | null !== checked
|
1061 | ? pushBooleanAttribute(target$jscomp$0, "checked", checked)
|
1062 | : null !== defaultChecked &&
|
1063 | pushBooleanAttribute(target$jscomp$0, "checked", defaultChecked);
|
1064 | null !== value$jscomp$1
|
1065 | ? pushAttribute(target$jscomp$0, "value", value$jscomp$1)
|
1066 | : null !== defaultValue$jscomp$0 &&
|
1067 | pushAttribute(target$jscomp$0, "value", defaultValue$jscomp$0);
|
1068 | target$jscomp$0.push("/>");
|
1069 | null != formData &&
|
1070 | formData.forEach(pushAdditionalFormField, target$jscomp$0);
|
1071 | return null;
|
1072 | case "button":
|
1073 | target$jscomp$0.push(startChunkForTag("button"));
|
1074 | var children$jscomp$3 = null,
|
1075 | innerHTML$jscomp$2 = null,
|
1076 | name$jscomp$0 = null,
|
1077 | formAction$jscomp$0 = null,
|
1078 | formEncType$jscomp$0 = null,
|
1079 | formMethod$jscomp$0 = null,
|
1080 | formTarget$jscomp$0 = null,
|
1081 | propKey$jscomp$4;
|
1082 | for (propKey$jscomp$4 in props)
|
1083 | if (hasOwnProperty.call(props, propKey$jscomp$4)) {
|
1084 | var propValue$jscomp$4 = props[propKey$jscomp$4];
|
1085 | if (null != propValue$jscomp$4)
|
1086 | switch (propKey$jscomp$4) {
|
1087 | case "children":
|
1088 | children$jscomp$3 = propValue$jscomp$4;
|
1089 | break;
|
1090 | case "dangerouslySetInnerHTML":
|
1091 | innerHTML$jscomp$2 = propValue$jscomp$4;
|
1092 | break;
|
1093 | case "name":
|
1094 | name$jscomp$0 = propValue$jscomp$4;
|
1095 | break;
|
1096 | case "formAction":
|
1097 | formAction$jscomp$0 = propValue$jscomp$4;
|
1098 | break;
|
1099 | case "formEncType":
|
1100 | formEncType$jscomp$0 = propValue$jscomp$4;
|
1101 | break;
|
1102 | case "formMethod":
|
1103 | formMethod$jscomp$0 = propValue$jscomp$4;
|
1104 | break;
|
1105 | case "formTarget":
|
1106 | formTarget$jscomp$0 = propValue$jscomp$4;
|
1107 | break;
|
1108 | default:
|
1109 | pushAttribute(
|
1110 | target$jscomp$0,
|
1111 | propKey$jscomp$4,
|
1112 | propValue$jscomp$4
|
1113 | );
|
1114 | }
|
1115 | }
|
1116 | var formData$jscomp$0 = pushFormActionAttribute(
|
1117 | target$jscomp$0,
|
1118 | resumableState,
|
1119 | renderState,
|
1120 | formAction$jscomp$0,
|
1121 | formEncType$jscomp$0,
|
1122 | formMethod$jscomp$0,
|
1123 | formTarget$jscomp$0,
|
1124 | name$jscomp$0
|
1125 | );
|
1126 | target$jscomp$0.push(">");
|
1127 | null != formData$jscomp$0 &&
|
1128 | formData$jscomp$0.forEach(pushAdditionalFormField, target$jscomp$0);
|
1129 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$2, children$jscomp$3);
|
1130 | if ("string" === typeof children$jscomp$3) {
|
1131 | target$jscomp$0.push(escapeTextForBrowser(children$jscomp$3));
|
1132 | var JSCompiler_inline_result$jscomp$0 = null;
|
1133 | } else JSCompiler_inline_result$jscomp$0 = children$jscomp$3;
|
1134 | return JSCompiler_inline_result$jscomp$0;
|
1135 | case "form":
|
1136 | target$jscomp$0.push(startChunkForTag("form"));
|
1137 | var children$jscomp$4 = null,
|
1138 | innerHTML$jscomp$3 = null,
|
1139 | formAction$jscomp$1 = null,
|
1140 | formEncType$jscomp$1 = null,
|
1141 | formMethod$jscomp$1 = null,
|
1142 | formTarget$jscomp$1 = null,
|
1143 | propKey$jscomp$5;
|
1144 | for (propKey$jscomp$5 in props)
|
1145 | if (hasOwnProperty.call(props, propKey$jscomp$5)) {
|
1146 | var propValue$jscomp$5 = props[propKey$jscomp$5];
|
1147 | if (null != propValue$jscomp$5)
|
1148 | switch (propKey$jscomp$5) {
|
1149 | case "children":
|
1150 | children$jscomp$4 = propValue$jscomp$5;
|
1151 | break;
|
1152 | case "dangerouslySetInnerHTML":
|
1153 | innerHTML$jscomp$3 = propValue$jscomp$5;
|
1154 | break;
|
1155 | case "action":
|
1156 | formAction$jscomp$1 = propValue$jscomp$5;
|
1157 | break;
|
1158 | case "encType":
|
1159 | formEncType$jscomp$1 = propValue$jscomp$5;
|
1160 | break;
|
1161 | case "method":
|
1162 | formMethod$jscomp$1 = propValue$jscomp$5;
|
1163 | break;
|
1164 | case "target":
|
1165 | formTarget$jscomp$1 = propValue$jscomp$5;
|
1166 | break;
|
1167 | default:
|
1168 | pushAttribute(
|
1169 | target$jscomp$0,
|
1170 | propKey$jscomp$5,
|
1171 | propValue$jscomp$5
|
1172 | );
|
1173 | }
|
1174 | }
|
1175 | var formData$jscomp$1 = null,
|
1176 | formActionName = null;
|
1177 | if ("function" === typeof formAction$jscomp$1) {
|
1178 | var customFields = getCustomFormFields(
|
1179 | resumableState,
|
1180 | formAction$jscomp$1
|
1181 | );
|
1182 | null !== customFields
|
1183 | ? ((formAction$jscomp$1 = customFields.action || ""),
|
1184 | (formEncType$jscomp$1 = customFields.encType),
|
1185 | (formMethod$jscomp$1 = customFields.method),
|
1186 | (formTarget$jscomp$1 = customFields.target),
|
1187 | (formData$jscomp$1 = customFields.data),
|
1188 | (formActionName = customFields.name))
|
1189 | : (target$jscomp$0.push(
|
1190 | " ",
|
1191 | "action",
|
1192 | '="',
|
1193 | actionJavaScriptURL,
|
1194 | '"'
|
1195 | ),
|
1196 | (formTarget$jscomp$1 =
|
1197 | formMethod$jscomp$1 =
|
1198 | formEncType$jscomp$1 =
|
1199 | formAction$jscomp$1 =
|
1200 | null),
|
1201 | injectFormReplayingRuntime(resumableState, renderState));
|
1202 | }
|
1203 | null != formAction$jscomp$1 &&
|
1204 | pushAttribute(target$jscomp$0, "action", formAction$jscomp$1);
|
1205 | null != formEncType$jscomp$1 &&
|
1206 | pushAttribute(target$jscomp$0, "encType", formEncType$jscomp$1);
|
1207 | null != formMethod$jscomp$1 &&
|
1208 | pushAttribute(target$jscomp$0, "method", formMethod$jscomp$1);
|
1209 | null != formTarget$jscomp$1 &&
|
1210 | pushAttribute(target$jscomp$0, "target", formTarget$jscomp$1);
|
1211 | target$jscomp$0.push(">");
|
1212 | null !== formActionName &&
|
1213 | (target$jscomp$0.push('<input type="hidden"'),
|
1214 | pushStringAttribute(target$jscomp$0, "name", formActionName),
|
1215 | target$jscomp$0.push("/>"),
|
1216 | null != formData$jscomp$1 &&
|
1217 | formData$jscomp$1.forEach(pushAdditionalFormField, target$jscomp$0));
|
1218 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$3, children$jscomp$4);
|
1219 | if ("string" === typeof children$jscomp$4) {
|
1220 | target$jscomp$0.push(escapeTextForBrowser(children$jscomp$4));
|
1221 | var JSCompiler_inline_result$jscomp$1 = null;
|
1222 | } else JSCompiler_inline_result$jscomp$1 = children$jscomp$4;
|
1223 | return JSCompiler_inline_result$jscomp$1;
|
1224 | case "menuitem":
|
1225 | target$jscomp$0.push(startChunkForTag("menuitem"));
|
1226 | for (var propKey$jscomp$6 in props)
|
1227 | if (hasOwnProperty.call(props, propKey$jscomp$6)) {
|
1228 | var propValue$jscomp$6 = props[propKey$jscomp$6];
|
1229 | if (null != propValue$jscomp$6)
|
1230 | switch (propKey$jscomp$6) {
|
1231 | case "children":
|
1232 | case "dangerouslySetInnerHTML":
|
1233 | throw Error(formatProdErrorMessage(400));
|
1234 | default:
|
1235 | pushAttribute(
|
1236 | target$jscomp$0,
|
1237 | propKey$jscomp$6,
|
1238 | propValue$jscomp$6
|
1239 | );
|
1240 | }
|
1241 | }
|
1242 | target$jscomp$0.push(">");
|
1243 | return null;
|
1244 | case "title":
|
1245 | if (
|
1246 | 3 === formatContext.insertionMode ||
|
1247 | formatContext.tagScope & 1 ||
|
1248 | null != props.itemProp
|
1249 | )
|
1250 | var JSCompiler_inline_result$jscomp$2 = pushTitleImpl(
|
1251 | target$jscomp$0,
|
1252 | props
|
1253 | );
|
1254 | else
|
1255 | isFallback
|
1256 | ? (JSCompiler_inline_result$jscomp$2 = null)
|
1257 | : (pushTitleImpl(renderState.hoistableChunks, props),
|
1258 | (JSCompiler_inline_result$jscomp$2 = void 0));
|
1259 | return JSCompiler_inline_result$jscomp$2;
|
1260 | case "link":
|
1261 | var rel = props.rel,
|
1262 | href = props.href,
|
1263 | precedence = props.precedence;
|
1264 | if (
|
1265 | 3 === formatContext.insertionMode ||
|
1266 | formatContext.tagScope & 1 ||
|
1267 | null != props.itemProp ||
|
1268 | "string" !== typeof rel ||
|
1269 | "string" !== typeof href ||
|
1270 | "" === href
|
1271 | ) {
|
1272 | pushLinkImpl(target$jscomp$0, props);
|
1273 | var JSCompiler_inline_result$jscomp$3 = null;
|
1274 | } else if ("stylesheet" === props.rel)
|
1275 | if (
|
1276 | "string" !== typeof precedence ||
|
1277 | null != props.disabled ||
|
1278 | props.onLoad ||
|
1279 | props.onError
|
1280 | )
|
1281 | JSCompiler_inline_result$jscomp$3 = pushLinkImpl(
|
1282 | target$jscomp$0,
|
1283 | props
|
1284 | );
|
1285 | else {
|
1286 | var styleQueue = renderState.styles.get(precedence),
|
1287 | resourceState = resumableState.styleResources.hasOwnProperty(href)
|
1288 | ? resumableState.styleResources[href]
|
1289 | : void 0;
|
1290 | if (null !== resourceState) {
|
1291 | resumableState.styleResources[href] = null;
|
1292 | styleQueue ||
|
1293 | ((styleQueue = {
|
1294 | precedence: escapeTextForBrowser(precedence),
|
1295 | rules: [],
|
1296 | hrefs: [],
|
1297 | sheets: new Map()
|
1298 | }),
|
1299 | renderState.styles.set(precedence, styleQueue));
|
1300 | var resource = {
|
1301 | state: 0,
|
1302 | props: assign({}, props, {
|
1303 | "data-precedence": props.precedence,
|
1304 | precedence: null
|
1305 | })
|
1306 | };
|
1307 | if (resourceState) {
|
1308 | 2 === resourceState.length &&
|
1309 | adoptPreloadCredentials(resource.props, resourceState);
|
1310 | var preloadResource = renderState.preloads.stylesheets.get(href);
|
1311 | preloadResource && 0 < preloadResource.length
|
1312 | ? (preloadResource.length = 0)
|
1313 | : (resource.state = 1);
|
1314 | }
|
1315 | styleQueue.sheets.set(href, resource);
|
1316 | hoistableState && hoistableState.stylesheets.add(resource);
|
1317 | } else if (styleQueue) {
|
1318 | var resource$9 = styleQueue.sheets.get(href);
|
1319 | resource$9 &&
|
1320 | hoistableState &&
|
1321 | hoistableState.stylesheets.add(resource$9);
|
1322 | }
|
1323 | textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
|
1324 | JSCompiler_inline_result$jscomp$3 = null;
|
1325 | }
|
1326 | else
|
1327 | props.onLoad || props.onError
|
1328 | ? (JSCompiler_inline_result$jscomp$3 = pushLinkImpl(
|
1329 | target$jscomp$0,
|
1330 | props
|
1331 | ))
|
1332 | : (textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e"),
|
1333 | (JSCompiler_inline_result$jscomp$3 = isFallback
|
1334 | ? null
|
1335 | : pushLinkImpl(renderState.hoistableChunks, props)));
|
1336 | return JSCompiler_inline_result$jscomp$3;
|
1337 | case "script":
|
1338 | var asyncProp = props.async;
|
1339 | if (
|
1340 | "string" !== typeof props.src ||
|
1341 | !props.src ||
|
1342 | !asyncProp ||
|
1343 | "function" === typeof asyncProp ||
|
1344 | "symbol" === typeof asyncProp ||
|
1345 | props.onLoad ||
|
1346 | props.onError ||
|
1347 | 3 === formatContext.insertionMode ||
|
1348 | formatContext.tagScope & 1 ||
|
1349 | null != props.itemProp
|
1350 | )
|
1351 | var JSCompiler_inline_result$jscomp$4 = pushScriptImpl(
|
1352 | target$jscomp$0,
|
1353 | props
|
1354 | );
|
1355 | else {
|
1356 | var key = props.src;
|
1357 | if ("module" === props.type) {
|
1358 | var resources = resumableState.moduleScriptResources;
|
1359 | var preloads = renderState.preloads.moduleScripts;
|
1360 | } else
|
1361 | (resources = resumableState.scriptResources),
|
1362 | (preloads = renderState.preloads.scripts);
|
1363 | var resourceState$jscomp$0 = resources.hasOwnProperty(key)
|
1364 | ? resources[key]
|
1365 | : void 0;
|
1366 | if (null !== resourceState$jscomp$0) {
|
1367 | resources[key] = null;
|
1368 | var scriptProps = props;
|
1369 | if (resourceState$jscomp$0) {
|
1370 | 2 === resourceState$jscomp$0.length &&
|
1371 | ((scriptProps = assign({}, props)),
|
1372 | adoptPreloadCredentials(scriptProps, resourceState$jscomp$0));
|
1373 | var preloadResource$jscomp$0 = preloads.get(key);
|
1374 | preloadResource$jscomp$0 && (preloadResource$jscomp$0.length = 0);
|
1375 | }
|
1376 | var resource$jscomp$0 = [];
|
1377 | renderState.scripts.add(resource$jscomp$0);
|
1378 | pushScriptImpl(resource$jscomp$0, scriptProps);
|
1379 | }
|
1380 | textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
|
1381 | JSCompiler_inline_result$jscomp$4 = null;
|
1382 | }
|
1383 | return JSCompiler_inline_result$jscomp$4;
|
1384 | case "style":
|
1385 | var precedence$jscomp$0 = props.precedence,
|
1386 | href$jscomp$0 = props.href;
|
1387 | if (
|
1388 | 3 === formatContext.insertionMode ||
|
1389 | formatContext.tagScope & 1 ||
|
1390 | null != props.itemProp ||
|
1391 | "string" !== typeof precedence$jscomp$0 ||
|
1392 | "string" !== typeof href$jscomp$0 ||
|
1393 | "" === href$jscomp$0
|
1394 | ) {
|
1395 | target$jscomp$0.push(startChunkForTag("style"));
|
1396 | var children$jscomp$5 = null,
|
1397 | innerHTML$jscomp$4 = null,
|
1398 | propKey$jscomp$7;
|
1399 | for (propKey$jscomp$7 in props)
|
1400 | if (hasOwnProperty.call(props, propKey$jscomp$7)) {
|
1401 | var propValue$jscomp$7 = props[propKey$jscomp$7];
|
1402 | if (null != propValue$jscomp$7)
|
1403 | switch (propKey$jscomp$7) {
|
1404 | case "children":
|
1405 | children$jscomp$5 = propValue$jscomp$7;
|
1406 | break;
|
1407 | case "dangerouslySetInnerHTML":
|
1408 | innerHTML$jscomp$4 = propValue$jscomp$7;
|
1409 | break;
|
1410 | default:
|
1411 | pushAttribute(
|
1412 | target$jscomp$0,
|
1413 | propKey$jscomp$7,
|
1414 | propValue$jscomp$7
|
1415 | );
|
1416 | }
|
1417 | }
|
1418 | target$jscomp$0.push(">");
|
1419 | var child = Array.isArray(children$jscomp$5)
|
1420 | ? 2 > children$jscomp$5.length
|
1421 | ? children$jscomp$5[0]
|
1422 | : null
|
1423 | : children$jscomp$5;
|
1424 | "function" !== typeof child &&
|
1425 | "symbol" !== typeof child &&
|
1426 | null !== child &&
|
1427 | void 0 !== child &&
|
1428 | target$jscomp$0.push(("" + child).replace(styleRegex, styleReplacer));
|
1429 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$4, children$jscomp$5);
|
1430 | target$jscomp$0.push(endChunkForTag("style"));
|
1431 | var JSCompiler_inline_result$jscomp$5 = null;
|
1432 | } else {
|
1433 | var styleQueue$jscomp$0 = renderState.styles.get(precedence$jscomp$0);
|
1434 | if (
|
1435 | null !==
|
1436 | (resumableState.styleResources.hasOwnProperty(href$jscomp$0)
|
1437 | ? resumableState.styleResources[href$jscomp$0]
|
1438 | : void 0)
|
1439 | ) {
|
1440 | resumableState.styleResources[href$jscomp$0] = null;
|
1441 | styleQueue$jscomp$0
|
1442 | ? styleQueue$jscomp$0.hrefs.push(
|
1443 | escapeTextForBrowser(href$jscomp$0)
|
1444 | )
|
1445 | : ((styleQueue$jscomp$0 = {
|
1446 | precedence: escapeTextForBrowser(precedence$jscomp$0),
|
1447 | rules: [],
|
1448 | hrefs: [escapeTextForBrowser(href$jscomp$0)],
|
1449 | sheets: new Map()
|
1450 | }),
|
1451 | renderState.styles.set(precedence$jscomp$0, styleQueue$jscomp$0));
|
1452 | var target = styleQueue$jscomp$0.rules,
|
1453 | children$jscomp$6 = null,
|
1454 | innerHTML$jscomp$5 = null,
|
1455 | propKey$jscomp$8;
|
1456 | for (propKey$jscomp$8 in props)
|
1457 | if (hasOwnProperty.call(props, propKey$jscomp$8)) {
|
1458 | var propValue$jscomp$8 = props[propKey$jscomp$8];
|
1459 | if (null != propValue$jscomp$8)
|
1460 | switch (propKey$jscomp$8) {
|
1461 | case "children":
|
1462 | children$jscomp$6 = propValue$jscomp$8;
|
1463 | break;
|
1464 | case "dangerouslySetInnerHTML":
|
1465 | innerHTML$jscomp$5 = propValue$jscomp$8;
|
1466 | }
|
1467 | }
|
1468 | var child$jscomp$0 = Array.isArray(children$jscomp$6)
|
1469 | ? 2 > children$jscomp$6.length
|
1470 | ? children$jscomp$6[0]
|
1471 | : null
|
1472 | : children$jscomp$6;
|
1473 | "function" !== typeof child$jscomp$0 &&
|
1474 | "symbol" !== typeof child$jscomp$0 &&
|
1475 | null !== child$jscomp$0 &&
|
1476 | void 0 !== child$jscomp$0 &&
|
1477 | target.push(
|
1478 | ("" + child$jscomp$0).replace(styleRegex, styleReplacer)
|
1479 | );
|
1480 | pushInnerHTML(target, innerHTML$jscomp$5, children$jscomp$6);
|
1481 | }
|
1482 | styleQueue$jscomp$0 &&
|
1483 | hoistableState &&
|
1484 | hoistableState.styles.add(styleQueue$jscomp$0);
|
1485 | textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e");
|
1486 | JSCompiler_inline_result$jscomp$5 = void 0;
|
1487 | }
|
1488 | return JSCompiler_inline_result$jscomp$5;
|
1489 | case "meta":
|
1490 | if (
|
1491 | 3 === formatContext.insertionMode ||
|
1492 | formatContext.tagScope & 1 ||
|
1493 | null != props.itemProp
|
1494 | )
|
1495 | var JSCompiler_inline_result$jscomp$6 = pushSelfClosing(
|
1496 | target$jscomp$0,
|
1497 | props,
|
1498 | "meta"
|
1499 | );
|
1500 | else
|
1501 | textEmbedded && target$jscomp$0.push("\x3c!-- --\x3e"),
|
1502 | (JSCompiler_inline_result$jscomp$6 = isFallback
|
1503 | ? null
|
1504 | : "string" === typeof props.charSet
|
1505 | ? pushSelfClosing(renderState.charsetChunks, props, "meta")
|
1506 | : "viewport" === props.name
|
1507 | ? pushSelfClosing(renderState.viewportChunks, props, "meta")
|
1508 | : pushSelfClosing(renderState.hoistableChunks, props, "meta"));
|
1509 | return JSCompiler_inline_result$jscomp$6;
|
1510 | case "listing":
|
1511 | case "pre":
|
1512 | target$jscomp$0.push(startChunkForTag(type));
|
1513 | var children$jscomp$7 = null,
|
1514 | innerHTML$jscomp$6 = null,
|
1515 | propKey$jscomp$9;
|
1516 | for (propKey$jscomp$9 in props)
|
1517 | if (hasOwnProperty.call(props, propKey$jscomp$9)) {
|
1518 | var propValue$jscomp$9 = props[propKey$jscomp$9];
|
1519 | if (null != propValue$jscomp$9)
|
1520 | switch (propKey$jscomp$9) {
|
1521 | case "children":
|
1522 | children$jscomp$7 = propValue$jscomp$9;
|
1523 | break;
|
1524 | case "dangerouslySetInnerHTML":
|
1525 | innerHTML$jscomp$6 = propValue$jscomp$9;
|
1526 | break;
|
1527 | default:
|
1528 | pushAttribute(
|
1529 | target$jscomp$0,
|
1530 | propKey$jscomp$9,
|
1531 | propValue$jscomp$9
|
1532 | );
|
1533 | }
|
1534 | }
|
1535 | target$jscomp$0.push(">");
|
1536 | if (null != innerHTML$jscomp$6) {
|
1537 | if (null != children$jscomp$7) throw Error(formatProdErrorMessage(60));
|
1538 | if (
|
1539 | "object" !== typeof innerHTML$jscomp$6 ||
|
1540 | !("__html" in innerHTML$jscomp$6)
|
1541 | )
|
1542 | throw Error(formatProdErrorMessage(61));
|
1543 | var html = innerHTML$jscomp$6.__html;
|
1544 | null !== html &&
|
1545 | void 0 !== html &&
|
1546 | ("string" === typeof html && 0 < html.length && "\n" === html[0]
|
1547 | ? target$jscomp$0.push("\n", html)
|
1548 | : target$jscomp$0.push("" + html));
|
1549 | }
|
1550 | "string" === typeof children$jscomp$7 &&
|
1551 | "\n" === children$jscomp$7[0] &&
|
1552 | target$jscomp$0.push("\n");
|
1553 | return children$jscomp$7;
|
1554 | case "img":
|
1555 | var src = props.src,
|
1556 | srcSet = props.srcSet;
|
1557 | if (
|
1558 | !(
|
1559 | "lazy" === props.loading ||
|
1560 | (!src && !srcSet) ||
|
1561 | ("string" !== typeof src && null != src) ||
|
1562 | ("string" !== typeof srcSet && null != srcSet)
|
1563 | ) &&
|
1564 | "low" !== props.fetchPriority &&
|
1565 | !1 === !!(formatContext.tagScope & 3) &&
|
1566 | ("string" !== typeof src ||
|
1567 | ":" !== src[4] ||
|
1568 | ("d" !== src[0] && "D" !== src[0]) ||
|
1569 | ("a" !== src[1] && "A" !== src[1]) ||
|
1570 | ("t" !== src[2] && "T" !== src[2]) ||
|
1571 | ("a" !== src[3] && "A" !== src[3])) &&
|
1572 | ("string" !== typeof srcSet ||
|
1573 | ":" !== srcSet[4] ||
|
1574 | ("d" !== srcSet[0] && "D" !== srcSet[0]) ||
|
1575 | ("a" !== srcSet[1] && "A" !== srcSet[1]) ||
|
1576 | ("t" !== srcSet[2] && "T" !== srcSet[2]) ||
|
1577 | ("a" !== srcSet[3] && "A" !== srcSet[3]))
|
1578 | ) {
|
1579 | var sizes = "string" === typeof props.sizes ? props.sizes : void 0,
|
1580 | key$jscomp$0 = srcSet ? srcSet + "\n" + (sizes || "") : src,
|
1581 | promotablePreloads = renderState.preloads.images,
|
1582 | resource$jscomp$1 = promotablePreloads.get(key$jscomp$0);
|
1583 | if (resource$jscomp$1) {
|
1584 | if (
|
1585 | "high" === props.fetchPriority ||
|
1586 | 10 > renderState.highImagePreloads.size
|
1587 | )
|
1588 | promotablePreloads.delete(key$jscomp$0),
|
1589 | renderState.highImagePreloads.add(resource$jscomp$1);
|
1590 | } else if (
|
1591 | !resumableState.imageResources.hasOwnProperty(key$jscomp$0)
|
1592 | ) {
|
1593 | resumableState.imageResources[key$jscomp$0] = PRELOAD_NO_CREDS;
|
1594 | var input = props.crossOrigin;
|
1595 | var JSCompiler_inline_result$jscomp$7 =
|
1596 | "string" === typeof input
|
1597 | ? "use-credentials" === input
|
1598 | ? input
|
1599 | : ""
|
1600 | : void 0;
|
1601 | var headers = renderState.headers,
|
1602 | header;
|
1603 | headers &&
|
1604 | 0 < headers.remainingCapacity &&
|
1605 | ("high" === props.fetchPriority ||
|
1606 | 500 > headers.highImagePreloads.length) &&
|
1607 | ((header = getPreloadAsHeader(src, "image", {
|
1608 | imageSrcSet: props.srcSet,
|
1609 | imageSizes: props.sizes,
|
1610 | crossOrigin: JSCompiler_inline_result$jscomp$7,
|
1611 | integrity: props.integrity,
|
1612 | nonce: props.nonce,
|
1613 | type: props.type,
|
1614 | fetchPriority: props.fetchPriority,
|
1615 | referrerPolicy: props.refererPolicy
|
1616 | })),
|
1617 | 2 <= (headers.remainingCapacity -= header.length))
|
1618 | ? ((renderState.resets.image[key$jscomp$0] = PRELOAD_NO_CREDS),
|
1619 | headers.highImagePreloads && (headers.highImagePreloads += ", "),
|
1620 | (headers.highImagePreloads += header))
|
1621 | : ((resource$jscomp$1 = []),
|
1622 | pushLinkImpl(resource$jscomp$1, {
|
1623 | rel: "preload",
|
1624 | as: "image",
|
1625 | href: srcSet ? void 0 : src,
|
1626 | imageSrcSet: srcSet,
|
1627 | imageSizes: sizes,
|
1628 | crossOrigin: JSCompiler_inline_result$jscomp$7,
|
1629 | integrity: props.integrity,
|
1630 | type: props.type,
|
1631 | fetchPriority: props.fetchPriority,
|
1632 | referrerPolicy: props.referrerPolicy
|
1633 | }),
|
1634 | "high" === props.fetchPriority ||
|
1635 | 10 > renderState.highImagePreloads.size
|
1636 | ? renderState.highImagePreloads.add(resource$jscomp$1)
|
1637 | : (renderState.bulkPreloads.add(resource$jscomp$1),
|
1638 | promotablePreloads.set(key$jscomp$0, resource$jscomp$1)));
|
1639 | }
|
1640 | }
|
1641 | return pushSelfClosing(target$jscomp$0, props, "img");
|
1642 | case "base":
|
1643 | case "area":
|
1644 | case "br":
|
1645 | case "col":
|
1646 | case "embed":
|
1647 | case "hr":
|
1648 | case "keygen":
|
1649 | case "param":
|
1650 | case "source":
|
1651 | case "track":
|
1652 | case "wbr":
|
1653 | return pushSelfClosing(target$jscomp$0, props, type);
|
1654 | case "annotation-xml":
|
1655 | case "color-profile":
|
1656 | case "font-face":
|
1657 | case "font-face-src":
|
1658 | case "font-face-uri":
|
1659 | case "font-face-format":
|
1660 | case "font-face-name":
|
1661 | case "missing-glyph":
|
1662 | break;
|
1663 | case "head":
|
1664 | if (2 > formatContext.insertionMode && null === renderState.headChunks) {
|
1665 | renderState.headChunks = [];
|
1666 | var JSCompiler_inline_result$jscomp$8 = pushStartGenericElement(
|
1667 | renderState.headChunks,
|
1668 | props,
|
1669 | "head"
|
1670 | );
|
1671 | } else
|
1672 | JSCompiler_inline_result$jscomp$8 = pushStartGenericElement(
|
1673 | target$jscomp$0,
|
1674 | props,
|
1675 | "head"
|
1676 | );
|
1677 | return JSCompiler_inline_result$jscomp$8;
|
1678 | case "html":
|
1679 | if (
|
1680 | 0 === formatContext.insertionMode &&
|
1681 | null === renderState.htmlChunks
|
1682 | ) {
|
1683 | renderState.htmlChunks = [""];
|
1684 | var JSCompiler_inline_result$jscomp$9 = pushStartGenericElement(
|
1685 | renderState.htmlChunks,
|
1686 | props,
|
1687 | "html"
|
1688 | );
|
1689 | } else
|
1690 | JSCompiler_inline_result$jscomp$9 = pushStartGenericElement(
|
1691 | target$jscomp$0,
|
1692 | props,
|
1693 | "html"
|
1694 | );
|
1695 | return JSCompiler_inline_result$jscomp$9;
|
1696 | default:
|
1697 | if (-1 !== type.indexOf("-")) {
|
1698 | target$jscomp$0.push(startChunkForTag(type));
|
1699 | var children$jscomp$8 = null,
|
1700 | innerHTML$jscomp$7 = null,
|
1701 | propKey$jscomp$10;
|
1702 | for (propKey$jscomp$10 in props)
|
1703 | if (hasOwnProperty.call(props, propKey$jscomp$10)) {
|
1704 | var propValue$jscomp$10 = props[propKey$jscomp$10];
|
1705 | if (null != propValue$jscomp$10) {
|
1706 | var attributeName = propKey$jscomp$10;
|
1707 | switch (propKey$jscomp$10) {
|
1708 | case "children":
|
1709 | children$jscomp$8 = propValue$jscomp$10;
|
1710 | break;
|
1711 | case "dangerouslySetInnerHTML":
|
1712 | innerHTML$jscomp$7 = propValue$jscomp$10;
|
1713 | break;
|
1714 | case "style":
|
1715 | pushStyleAttribute(target$jscomp$0, propValue$jscomp$10);
|
1716 | break;
|
1717 | case "suppressContentEditableWarning":
|
1718 | case "suppressHydrationWarning":
|
1719 | case "ref":
|
1720 | break;
|
1721 | case "className":
|
1722 | attributeName = "class";
|
1723 | default:
|
1724 | if (
|
1725 | isAttributeNameSafe(propKey$jscomp$10) &&
|
1726 | "function" !== typeof propValue$jscomp$10 &&
|
1727 | "symbol" !== typeof propValue$jscomp$10 &&
|
1728 | !1 !== propValue$jscomp$10
|
1729 | ) {
|
1730 | if (!0 === propValue$jscomp$10) propValue$jscomp$10 = "";
|
1731 | else if ("object" === typeof propValue$jscomp$10) continue;
|
1732 | target$jscomp$0.push(
|
1733 | " ",
|
1734 | attributeName,
|
1735 | '="',
|
1736 | escapeTextForBrowser(propValue$jscomp$10),
|
1737 | '"'
|
1738 | );
|
1739 | }
|
1740 | }
|
1741 | }
|
1742 | }
|
1743 | target$jscomp$0.push(">");
|
1744 | pushInnerHTML(target$jscomp$0, innerHTML$jscomp$7, children$jscomp$8);
|
1745 | return children$jscomp$8;
|
1746 | }
|
1747 | }
|
1748 | return pushStartGenericElement(target$jscomp$0, props, type);
|
1749 | }
|
1750 | var endTagCache = new Map();
|
1751 | function endChunkForTag(tag) {
|
1752 | var chunk = endTagCache.get(tag);
|
1753 | void 0 === chunk && ((chunk = "</" + tag + ">"), endTagCache.set(tag, chunk));
|
1754 | return chunk;
|
1755 | }
|
1756 | function writeBootstrap(destination, renderState) {
|
1757 | renderState = renderState.bootstrapChunks;
|
1758 | for (var i = 0; i < renderState.length - 1; i++)
|
1759 | destination.push(renderState[i]);
|
1760 | return i < renderState.length
|
1761 | ? ((i = renderState[i]), (renderState.length = 0), destination.push(i))
|
1762 | : !0;
|
1763 | }
|
1764 | function writeStartPendingSuspenseBoundary(destination, renderState, id) {
|
1765 | destination.push('\x3c!--$?--\x3e<template id="');
|
1766 | if (null === id) throw Error(formatProdErrorMessage(395));
|
1767 | destination.push(renderState.boundaryPrefix);
|
1768 | renderState = id.toString(16);
|
1769 | destination.push(renderState);
|
1770 | return destination.push('"></template>');
|
1771 | }
|
1772 | function writeStartSegment(destination, renderState, formatContext, id) {
|
1773 | switch (formatContext.insertionMode) {
|
1774 | case 0:
|
1775 | case 1:
|
1776 | case 2:
|
1777 | return (
|
1778 | destination.push('<div hidden id="'),
|
1779 | destination.push(renderState.segmentPrefix),
|
1780 | (renderState = id.toString(16)),
|
1781 | destination.push(renderState),
|
1782 | destination.push('">')
|
1783 | );
|
1784 | case 3:
|
1785 | return (
|
1786 | destination.push('<svg aria-hidden="true" style="display:none" id="'),
|
1787 | destination.push(renderState.segmentPrefix),
|
1788 | (renderState = id.toString(16)),
|
1789 | destination.push(renderState),
|
1790 | destination.push('">')
|
1791 | );
|
1792 | case 4:
|
1793 | return (
|
1794 | destination.push('<math aria-hidden="true" style="display:none" id="'),
|
1795 | destination.push(renderState.segmentPrefix),
|
1796 | (renderState = id.toString(16)),
|
1797 | destination.push(renderState),
|
1798 | destination.push('">')
|
1799 | );
|
1800 | case 5:
|
1801 | return (
|
1802 | destination.push('<table hidden id="'),
|
1803 | destination.push(renderState.segmentPrefix),
|
1804 | (renderState = id.toString(16)),
|
1805 | destination.push(renderState),
|
1806 | destination.push('">')
|
1807 | );
|
1808 | case 6:
|
1809 | return (
|
1810 | destination.push('<table hidden><tbody id="'),
|
1811 | destination.push(renderState.segmentPrefix),
|
1812 | (renderState = id.toString(16)),
|
1813 | destination.push(renderState),
|
1814 | destination.push('">')
|
1815 | );
|
1816 | case 7:
|
1817 | return (
|
1818 | destination.push('<table hidden><tr id="'),
|
1819 | destination.push(renderState.segmentPrefix),
|
1820 | (renderState = id.toString(16)),
|
1821 | destination.push(renderState),
|
1822 | destination.push('">')
|
1823 | );
|
1824 | case 8:
|
1825 | return (
|
1826 | destination.push('<table hidden><colgroup id="'),
|
1827 | destination.push(renderState.segmentPrefix),
|
1828 | (renderState = id.toString(16)),
|
1829 | destination.push(renderState),
|
1830 | destination.push('">')
|
1831 | );
|
1832 | default:
|
1833 | throw Error(formatProdErrorMessage(397));
|
1834 | }
|
1835 | }
|
1836 | function writeEndSegment(destination, formatContext) {
|
1837 | switch (formatContext.insertionMode) {
|
1838 | case 0:
|
1839 | case 1:
|
1840 | case 2:
|
1841 | return destination.push("</div>");
|
1842 | case 3:
|
1843 | return destination.push("</svg>");
|
1844 | case 4:
|
1845 | return destination.push("</math>");
|
1846 | case 5:
|
1847 | return destination.push("</table>");
|
1848 | case 6:
|
1849 | return destination.push("</tbody></table>");
|
1850 | case 7:
|
1851 | return destination.push("</tr></table>");
|
1852 | case 8:
|
1853 | return destination.push("</colgroup></table>");
|
1854 | default:
|
1855 | throw Error(formatProdErrorMessage(397));
|
1856 | }
|
1857 | }
|
1858 | var regexForJSStringsInInstructionScripts = /[<\u2028\u2029]/g;
|
1859 | function escapeJSStringsForInstructionScripts(input) {
|
1860 | return JSON.stringify(input).replace(
|
1861 | regexForJSStringsInInstructionScripts,
|
1862 | function (match) {
|
1863 | switch (match) {
|
1864 | case "<":
|
1865 | return "\\u003c";
|
1866 | case "\u2028":
|
1867 | return "\\u2028";
|
1868 | case "\u2029":
|
1869 | return "\\u2029";
|
1870 | default:
|
1871 | throw Error(
|
1872 | "escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React"
|
1873 | );
|
1874 | }
|
1875 | }
|
1876 | );
|
1877 | }
|
1878 | var regexForJSStringsInScripts = /[&><\u2028\u2029]/g;
|
1879 | function escapeJSObjectForInstructionScripts(input) {
|
1880 | return JSON.stringify(input).replace(
|
1881 | regexForJSStringsInScripts,
|
1882 | function (match) {
|
1883 | switch (match) {
|
1884 | case "&":
|
1885 | return "\\u0026";
|
1886 | case ">":
|
1887 | return "\\u003e";
|
1888 | case "<":
|
1889 | return "\\u003c";
|
1890 | case "\u2028":
|
1891 | return "\\u2028";
|
1892 | case "\u2029":
|
1893 | return "\\u2029";
|
1894 | default:
|
1895 | throw Error(
|
1896 | "escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React"
|
1897 | );
|
1898 | }
|
1899 | }
|
1900 | );
|
1901 | }
|
1902 | var currentlyRenderingBoundaryHasStylesToHoist = !1,
|
1903 | destinationHasCapacity = !0;
|
1904 | function flushStyleTagsLateForBoundary(styleQueue) {
|
1905 | var rules = styleQueue.rules,
|
1906 | hrefs = styleQueue.hrefs,
|
1907 | i = 0;
|
1908 | if (hrefs.length) {
|
1909 | this.push('<style media="not all" data-precedence="');
|
1910 | this.push(styleQueue.precedence);
|
1911 | for (this.push('" data-href="'); i < hrefs.length - 1; i++)
|
1912 | this.push(hrefs[i]), this.push(" ");
|
1913 | this.push(hrefs[i]);
|
1914 | this.push('">');
|
1915 | for (i = 0; i < rules.length; i++) this.push(rules[i]);
|
1916 | destinationHasCapacity = this.push("</style>");
|
1917 | currentlyRenderingBoundaryHasStylesToHoist = !0;
|
1918 | rules.length = 0;
|
1919 | hrefs.length = 0;
|
1920 | }
|
1921 | }
|
1922 | function hasStylesToHoist(stylesheet) {
|
1923 | return 2 !== stylesheet.state
|
1924 | ? (currentlyRenderingBoundaryHasStylesToHoist = !0)
|
1925 | : !1;
|
1926 | }
|
1927 | function writeHoistablesForBoundary(destination, hoistableState, renderState) {
|
1928 | currentlyRenderingBoundaryHasStylesToHoist = !1;
|
1929 | destinationHasCapacity = !0;
|
1930 | hoistableState.styles.forEach(flushStyleTagsLateForBoundary, destination);
|
1931 | hoistableState.stylesheets.forEach(hasStylesToHoist);
|
1932 | currentlyRenderingBoundaryHasStylesToHoist &&
|
1933 | (renderState.stylesToHoist = !0);
|
1934 | return destinationHasCapacity;
|
1935 | }
|
1936 | function flushResource(resource) {
|
1937 | for (var i = 0; i < resource.length; i++) this.push(resource[i]);
|
1938 | resource.length = 0;
|
1939 | }
|
1940 | var stylesheetFlushingQueue = [];
|
1941 | function flushStyleInPreamble(stylesheet) {
|
1942 | pushLinkImpl(stylesheetFlushingQueue, stylesheet.props);
|
1943 | for (var i = 0; i < stylesheetFlushingQueue.length; i++)
|
1944 | this.push(stylesheetFlushingQueue[i]);
|
1945 | stylesheetFlushingQueue.length = 0;
|
1946 | stylesheet.state = 2;
|
1947 | }
|
1948 | function flushStylesInPreamble(styleQueue) {
|
1949 | var hasStylesheets = 0 < styleQueue.sheets.size;
|
1950 | styleQueue.sheets.forEach(flushStyleInPreamble, this);
|
1951 | styleQueue.sheets.clear();
|
1952 | var rules = styleQueue.rules,
|
1953 | hrefs = styleQueue.hrefs;
|
1954 | if (!hasStylesheets || hrefs.length) {
|
1955 | this.push('<style data-precedence="');
|
1956 | this.push(styleQueue.precedence);
|
1957 | styleQueue = 0;
|
1958 | if (hrefs.length) {
|
1959 | for (
|
1960 | this.push('" data-href="');
|
1961 | styleQueue < hrefs.length - 1;
|
1962 | styleQueue++
|
1963 | )
|
1964 | this.push(hrefs[styleQueue]), this.push(" ");
|
1965 | this.push(hrefs[styleQueue]);
|
1966 | }
|
1967 | this.push('">');
|
1968 | for (styleQueue = 0; styleQueue < rules.length; styleQueue++)
|
1969 | this.push(rules[styleQueue]);
|
1970 | this.push("</style>");
|
1971 | rules.length = 0;
|
1972 | hrefs.length = 0;
|
1973 | }
|
1974 | }
|
1975 | function preloadLateStyle(stylesheet) {
|
1976 | if (0 === stylesheet.state) {
|
1977 | stylesheet.state = 1;
|
1978 | var props = stylesheet.props;
|
1979 | pushLinkImpl(stylesheetFlushingQueue, {
|
1980 | rel: "preload",
|
1981 | as: "style",
|
1982 | href: stylesheet.props.href,
|
1983 | crossOrigin: props.crossOrigin,
|
1984 | fetchPriority: props.fetchPriority,
|
1985 | integrity: props.integrity,
|
1986 | media: props.media,
|
1987 | hrefLang: props.hrefLang,
|
1988 | referrerPolicy: props.referrerPolicy
|
1989 | });
|
1990 | for (
|
1991 | stylesheet = 0;
|
1992 | stylesheet < stylesheetFlushingQueue.length;
|
1993 | stylesheet++
|
1994 | )
|
1995 | this.push(stylesheetFlushingQueue[stylesheet]);
|
1996 | stylesheetFlushingQueue.length = 0;
|
1997 | }
|
1998 | }
|
1999 | function preloadLateStyles(styleQueue) {
|
2000 | styleQueue.sheets.forEach(preloadLateStyle, this);
|
2001 | styleQueue.sheets.clear();
|
2002 | }
|
2003 | function writeStyleResourceDependenciesInJS(destination, hoistableState) {
|
2004 | destination.push("[");
|
2005 | var nextArrayOpenBrackChunk = "[";
|
2006 | hoistableState.stylesheets.forEach(function (resource) {
|
2007 | if (2 !== resource.state)
|
2008 | if (3 === resource.state)
|
2009 | destination.push(nextArrayOpenBrackChunk),
|
2010 | (resource = escapeJSObjectForInstructionScripts(
|
2011 | "" + resource.props.href
|
2012 | )),
|
2013 | destination.push(resource),
|
2014 | destination.push("]"),
|
2015 | (nextArrayOpenBrackChunk = ",[");
|
2016 | else {
|
2017 | destination.push(nextArrayOpenBrackChunk);
|
2018 | var precedence = resource.props["data-precedence"],
|
2019 | props = resource.props,
|
2020 | coercedHref = sanitizeURL("" + resource.props.href);
|
2021 | coercedHref = escapeJSObjectForInstructionScripts(coercedHref);
|
2022 | destination.push(coercedHref);
|
2023 | precedence = "" + precedence;
|
2024 | destination.push(",");
|
2025 | precedence = escapeJSObjectForInstructionScripts(precedence);
|
2026 | destination.push(precedence);
|
2027 | for (var propKey in props)
|
2028 | if (
|
2029 | hasOwnProperty.call(props, propKey) &&
|
2030 | ((precedence = props[propKey]), null != precedence)
|
2031 | )
|
2032 | switch (propKey) {
|
2033 | case "href":
|
2034 | case "rel":
|
2035 | case "precedence":
|
2036 | case "data-precedence":
|
2037 | break;
|
2038 | case "children":
|
2039 | case "dangerouslySetInnerHTML":
|
2040 | throw Error(formatProdErrorMessage(399, "link"));
|
2041 | default:
|
2042 | writeStyleResourceAttributeInJS(
|
2043 | destination,
|
2044 | propKey,
|
2045 | precedence
|
2046 | );
|
2047 | }
|
2048 | destination.push("]");
|
2049 | nextArrayOpenBrackChunk = ",[";
|
2050 | resource.state = 3;
|
2051 | }
|
2052 | });
|
2053 | destination.push("]");
|
2054 | }
|
2055 | function writeStyleResourceAttributeInJS(destination, name, value) {
|
2056 | var attributeName = name.toLowerCase();
|
2057 | switch (typeof value) {
|
2058 | case "function":
|
2059 | case "symbol":
|
2060 | return;
|
2061 | }
|
2062 | switch (name) {
|
2063 | case "innerHTML":
|
2064 | case "dangerouslySetInnerHTML":
|
2065 | case "suppressContentEditableWarning":
|
2066 | case "suppressHydrationWarning":
|
2067 | case "style":
|
2068 | case "ref":
|
2069 | return;
|
2070 | case "className":
|
2071 | attributeName = "class";
|
2072 | name = "" + value;
|
2073 | break;
|
2074 | case "hidden":
|
2075 | if (!1 === value) return;
|
2076 | name = "";
|
2077 | break;
|
2078 | case "src":
|
2079 | case "href":
|
2080 | value = sanitizeURL(value);
|
2081 | name = "" + value;
|
2082 | break;
|
2083 | default:
|
2084 | if (
|
2085 | (2 < name.length &&
|
2086 | ("o" === name[0] || "O" === name[0]) &&
|
2087 | ("n" === name[1] || "N" === name[1])) ||
|
2088 | !isAttributeNameSafe(name)
|
2089 | )
|
2090 | return;
|
2091 | name = "" + value;
|
2092 | }
|
2093 | destination.push(",");
|
2094 | attributeName = escapeJSObjectForInstructionScripts(attributeName);
|
2095 | destination.push(attributeName);
|
2096 | destination.push(",");
|
2097 | attributeName = escapeJSObjectForInstructionScripts(name);
|
2098 | destination.push(attributeName);
|
2099 | }
|
2100 | function createHoistableState() {
|
2101 | return { styles: new Set(), stylesheets: new Set() };
|
2102 | }
|
2103 | function prefetchDNS(href) {
|
2104 | var request = currentRequest ? currentRequest : null;
|
2105 | if (request) {
|
2106 | var resumableState = request.resumableState,
|
2107 | renderState = request.renderState;
|
2108 | if ("string" === typeof href && href) {
|
2109 | if (!resumableState.dnsResources.hasOwnProperty(href)) {
|
2110 | resumableState.dnsResources[href] = null;
|
2111 | resumableState = renderState.headers;
|
2112 | var header, JSCompiler_temp;
|
2113 | if (
|
2114 | (JSCompiler_temp =
|
2115 | resumableState && 0 < resumableState.remainingCapacity)
|
2116 | )
|
2117 | JSCompiler_temp =
|
2118 | ((header =
|
2119 | "<" +
|
2120 | ("" + href).replace(
|
2121 | regexForHrefInLinkHeaderURLContext,
|
2122 | escapeHrefForLinkHeaderURLContextReplacer
|
2123 | ) +
|
2124 | ">; rel=dns-prefetch"),
|
2125 | 2 <= (resumableState.remainingCapacity -= header.length));
|
2126 | JSCompiler_temp
|
2127 | ? ((renderState.resets.dns[href] = null),
|
2128 | resumableState.preconnects && (resumableState.preconnects += ", "),
|
2129 | (resumableState.preconnects += header))
|
2130 | : ((header = []),
|
2131 | pushLinkImpl(header, { href: href, rel: "dns-prefetch" }),
|
2132 | renderState.preconnects.add(header));
|
2133 | }
|
2134 | enqueueFlush(request);
|
2135 | }
|
2136 | } else previousDispatcher.D(href);
|
2137 | }
|
2138 | function preconnect(href, crossOrigin) {
|
2139 | var request = currentRequest ? currentRequest : null;
|
2140 | if (request) {
|
2141 | var resumableState = request.resumableState,
|
2142 | renderState = request.renderState;
|
2143 | if ("string" === typeof href && href) {
|
2144 | var bucket =
|
2145 | "use-credentials" === crossOrigin
|
2146 | ? "credentials"
|
2147 | : "string" === typeof crossOrigin
|
2148 | ? "anonymous"
|
2149 | : "default";
|
2150 | if (!resumableState.connectResources[bucket].hasOwnProperty(href)) {
|
2151 | resumableState.connectResources[bucket][href] = null;
|
2152 | resumableState = renderState.headers;
|
2153 | var header, JSCompiler_temp;
|
2154 | if (
|
2155 | (JSCompiler_temp =
|
2156 | resumableState && 0 < resumableState.remainingCapacity)
|
2157 | ) {
|
2158 | JSCompiler_temp =
|
2159 | "<" +
|
2160 | ("" + href).replace(
|
2161 | regexForHrefInLinkHeaderURLContext,
|
2162 | escapeHrefForLinkHeaderURLContextReplacer
|
2163 | ) +
|
2164 | ">; rel=preconnect";
|
2165 | if ("string" === typeof crossOrigin) {
|
2166 | var escapedCrossOrigin = ("" + crossOrigin).replace(
|
2167 | regexForLinkHeaderQuotedParamValueContext,
|
2168 | escapeStringForLinkHeaderQuotedParamValueContextReplacer
|
2169 | );
|
2170 | JSCompiler_temp += '; crossorigin="' + escapedCrossOrigin + '"';
|
2171 | }
|
2172 | JSCompiler_temp =
|
2173 | ((header = JSCompiler_temp),
|
2174 | 2 <= (resumableState.remainingCapacity -= header.length));
|
2175 | }
|
2176 | JSCompiler_temp
|
2177 | ? ((renderState.resets.connect[bucket][href] = null),
|
2178 | resumableState.preconnects && (resumableState.preconnects += ", "),
|
2179 | (resumableState.preconnects += header))
|
2180 | : ((bucket = []),
|
2181 | pushLinkImpl(bucket, {
|
2182 | rel: "preconnect",
|
2183 | href: href,
|
2184 | crossOrigin: crossOrigin
|
2185 | }),
|
2186 | renderState.preconnects.add(bucket));
|
2187 | }
|
2188 | enqueueFlush(request);
|
2189 | }
|
2190 | } else previousDispatcher.C(href, crossOrigin);
|
2191 | }
|
2192 | function preload(href, as, options) {
|
2193 | var request = currentRequest ? currentRequest : null;
|
2194 | if (request) {
|
2195 | var resumableState = request.resumableState,
|
2196 | renderState = request.renderState;
|
2197 | if (as && href) {
|
2198 | switch (as) {
|
2199 | case "image":
|
2200 | if (options) {
|
2201 | var imageSrcSet = options.imageSrcSet;
|
2202 | var imageSizes = options.imageSizes;
|
2203 | var fetchPriority = options.fetchPriority;
|
2204 | }
|
2205 | var key = imageSrcSet
|
2206 | ? imageSrcSet + "\n" + (imageSizes || "")
|
2207 | : href;
|
2208 | if (resumableState.imageResources.hasOwnProperty(key)) return;
|
2209 | resumableState.imageResources[key] = PRELOAD_NO_CREDS;
|
2210 | resumableState = renderState.headers;
|
2211 | var header;
|
2212 | resumableState &&
|
2213 | 0 < resumableState.remainingCapacity &&
|
2214 | "high" === fetchPriority &&
|
2215 | ((header = getPreloadAsHeader(href, as, options)),
|
2216 | 2 <= (resumableState.remainingCapacity -= header.length))
|
2217 | ? ((renderState.resets.image[key] = PRELOAD_NO_CREDS),
|
2218 | resumableState.highImagePreloads &&
|
2219 | (resumableState.highImagePreloads += ", "),
|
2220 | (resumableState.highImagePreloads += header))
|
2221 | : ((resumableState = []),
|
2222 | pushLinkImpl(
|
2223 | resumableState,
|
2224 | assign(
|
2225 | { rel: "preload", href: imageSrcSet ? void 0 : href, as: as },
|
2226 | options
|
2227 | )
|
2228 | ),
|
2229 | "high" === fetchPriority
|
2230 | ? renderState.highImagePreloads.add(resumableState)
|
2231 | : (renderState.bulkPreloads.add(resumableState),
|
2232 | renderState.preloads.images.set(key, resumableState)));
|
2233 | break;
|
2234 | case "style":
|
2235 | if (resumableState.styleResources.hasOwnProperty(href)) return;
|
2236 | imageSrcSet = [];
|
2237 | pushLinkImpl(
|
2238 | imageSrcSet,
|
2239 | assign({ rel: "preload", href: href, as: as }, options)
|
2240 | );
|
2241 | resumableState.styleResources[href] =
|
2242 | !options ||
|
2243 | ("string" !== typeof options.crossOrigin &&
|
2244 | "string" !== typeof options.integrity)
|
2245 | ? PRELOAD_NO_CREDS
|
2246 | : [options.crossOrigin, options.integrity];
|
2247 | renderState.preloads.stylesheets.set(href, imageSrcSet);
|
2248 | renderState.bulkPreloads.add(imageSrcSet);
|
2249 | break;
|
2250 | case "script":
|
2251 | if (resumableState.scriptResources.hasOwnProperty(href)) return;
|
2252 | imageSrcSet = [];
|
2253 | renderState.preloads.scripts.set(href, imageSrcSet);
|
2254 | renderState.bulkPreloads.add(imageSrcSet);
|
2255 | pushLinkImpl(
|
2256 | imageSrcSet,
|
2257 | assign({ rel: "preload", href: href, as: as }, options)
|
2258 | );
|
2259 | resumableState.scriptResources[href] =
|
2260 | !options ||
|
2261 | ("string" !== typeof options.crossOrigin &&
|
2262 | "string" !== typeof options.integrity)
|
2263 | ? PRELOAD_NO_CREDS
|
2264 | : [options.crossOrigin, options.integrity];
|
2265 | break;
|
2266 | default:
|
2267 | if (resumableState.unknownResources.hasOwnProperty(as)) {
|
2268 | if (
|
2269 | ((imageSrcSet = resumableState.unknownResources[as]),
|
2270 | imageSrcSet.hasOwnProperty(href))
|
2271 | )
|
2272 | return;
|
2273 | } else
|
2274 | (imageSrcSet = {}),
|
2275 | (resumableState.unknownResources[as] = imageSrcSet);
|
2276 | imageSrcSet[href] = PRELOAD_NO_CREDS;
|
2277 | if (
|
2278 | (resumableState = renderState.headers) &&
|
2279 | 0 < resumableState.remainingCapacity &&
|
2280 | "font" === as &&
|
2281 | ((key = getPreloadAsHeader(href, as, options)),
|
2282 | 2 <= (resumableState.remainingCapacity -= key.length))
|
2283 | )
|
2284 | (renderState.resets.font[href] = PRELOAD_NO_CREDS),
|
2285 | resumableState.fontPreloads &&
|
2286 | (resumableState.fontPreloads += ", "),
|
2287 | (resumableState.fontPreloads += key);
|
2288 | else
|
2289 | switch (
|
2290 | ((resumableState = []),
|
2291 | (href = assign({ rel: "preload", href: href, as: as }, options)),
|
2292 | pushLinkImpl(resumableState, href),
|
2293 | as)
|
2294 | ) {
|
2295 | case "font":
|
2296 | renderState.fontPreloads.add(resumableState);
|
2297 | break;
|
2298 | default:
|
2299 | renderState.bulkPreloads.add(resumableState);
|
2300 | }
|
2301 | }
|
2302 | enqueueFlush(request);
|
2303 | }
|
2304 | } else previousDispatcher.L(href, as, options);
|
2305 | }
|
2306 | function preloadModule(href, options) {
|
2307 | var request = currentRequest ? currentRequest : null;
|
2308 | if (request) {
|
2309 | var resumableState = request.resumableState,
|
2310 | renderState = request.renderState;
|
2311 | if (href) {
|
2312 | var as =
|
2313 | options && "string" === typeof options.as ? options.as : "script";
|
2314 | switch (as) {
|
2315 | case "script":
|
2316 | if (resumableState.moduleScriptResources.hasOwnProperty(href)) return;
|
2317 | as = [];
|
2318 | resumableState.moduleScriptResources[href] =
|
2319 | !options ||
|
2320 | ("string" !== typeof options.crossOrigin &&
|
2321 | "string" !== typeof options.integrity)
|
2322 | ? PRELOAD_NO_CREDS
|
2323 | : [options.crossOrigin, options.integrity];
|
2324 | renderState.preloads.moduleScripts.set(href, as);
|
2325 | break;
|
2326 | default:
|
2327 | if (resumableState.moduleUnknownResources.hasOwnProperty(as)) {
|
2328 | var resources = resumableState.unknownResources[as];
|
2329 | if (resources.hasOwnProperty(href)) return;
|
2330 | } else
|
2331 | (resources = {}),
|
2332 | (resumableState.moduleUnknownResources[as] = resources);
|
2333 | as = [];
|
2334 | resources[href] = PRELOAD_NO_CREDS;
|
2335 | }
|
2336 | pushLinkImpl(as, assign({ rel: "modulepreload", href: href }, options));
|
2337 | renderState.bulkPreloads.add(as);
|
2338 | enqueueFlush(request);
|
2339 | }
|
2340 | } else previousDispatcher.m(href, options);
|
2341 | }
|
2342 | function preinitStyle(href, precedence, options) {
|
2343 | var request = currentRequest ? currentRequest : null;
|
2344 | if (request) {
|
2345 | var resumableState = request.resumableState,
|
2346 | renderState = request.renderState;
|
2347 | if (href) {
|
2348 | precedence = precedence || "default";
|
2349 | var styleQueue = renderState.styles.get(precedence),
|
2350 | resourceState = resumableState.styleResources.hasOwnProperty(href)
|
2351 | ? resumableState.styleResources[href]
|
2352 | : void 0;
|
2353 | null !== resourceState &&
|
2354 | ((resumableState.styleResources[href] = null),
|
2355 | styleQueue ||
|
2356 | ((styleQueue = {
|
2357 | precedence: escapeTextForBrowser(precedence),
|
2358 | rules: [],
|
2359 | hrefs: [],
|
2360 | sheets: new Map()
|
2361 | }),
|
2362 | renderState.styles.set(precedence, styleQueue)),
|
2363 | (precedence = {
|
2364 | state: 0,
|
2365 | props: assign(
|
2366 | { rel: "stylesheet", href: href, "data-precedence": precedence },
|
2367 | options
|
2368 | )
|
2369 | }),
|
2370 | resourceState &&
|
2371 | (2 === resourceState.length &&
|
2372 | adoptPreloadCredentials(precedence.props, resourceState),
|
2373 | (renderState = renderState.preloads.stylesheets.get(href)) &&
|
2374 | 0 < renderState.length
|
2375 | ? (renderState.length = 0)
|
2376 | : (precedence.state = 1)),
|
2377 | styleQueue.sheets.set(href, precedence),
|
2378 | enqueueFlush(request));
|
2379 | }
|
2380 | } else previousDispatcher.S(href, precedence, options);
|
2381 | }
|
2382 | function preinitScript(src, options) {
|
2383 | var request = currentRequest ? currentRequest : null;
|
2384 | if (request) {
|
2385 | var resumableState = request.resumableState,
|
2386 | renderState = request.renderState;
|
2387 | if (src) {
|
2388 | var resourceState = resumableState.scriptResources.hasOwnProperty(src)
|
2389 | ? resumableState.scriptResources[src]
|
2390 | : void 0;
|
2391 | null !== resourceState &&
|
2392 | ((resumableState.scriptResources[src] = null),
|
2393 | (options = assign({ src: src, async: !0 }, options)),
|
2394 | resourceState &&
|
2395 | (2 === resourceState.length &&
|
2396 | adoptPreloadCredentials(options, resourceState),
|
2397 | (src = renderState.preloads.scripts.get(src))) &&
|
2398 | (src.length = 0),
|
2399 | (src = []),
|
2400 | renderState.scripts.add(src),
|
2401 | pushScriptImpl(src, options),
|
2402 | enqueueFlush(request));
|
2403 | }
|
2404 | } else previousDispatcher.X(src, options);
|
2405 | }
|
2406 | function preinitModuleScript(src, options) {
|
2407 | var request = currentRequest ? currentRequest : null;
|
2408 | if (request) {
|
2409 | var resumableState = request.resumableState,
|
2410 | renderState = request.renderState;
|
2411 | if (src) {
|
2412 | var resourceState = resumableState.moduleScriptResources.hasOwnProperty(
|
2413 | src
|
2414 | )
|
2415 | ? resumableState.moduleScriptResources[src]
|
2416 | : void 0;
|
2417 | null !== resourceState &&
|
2418 | ((resumableState.moduleScriptResources[src] = null),
|
2419 | (options = assign({ src: src, type: "module", async: !0 }, options)),
|
2420 | resourceState &&
|
2421 | (2 === resourceState.length &&
|
2422 | adoptPreloadCredentials(options, resourceState),
|
2423 | (src = renderState.preloads.moduleScripts.get(src))) &&
|
2424 | (src.length = 0),
|
2425 | (src = []),
|
2426 | renderState.scripts.add(src),
|
2427 | pushScriptImpl(src, options),
|
2428 | enqueueFlush(request));
|
2429 | }
|
2430 | } else previousDispatcher.M(src, options);
|
2431 | }
|
2432 | function adoptPreloadCredentials(target, preloadState) {
|
2433 | null == target.crossOrigin && (target.crossOrigin = preloadState[0]);
|
2434 | null == target.integrity && (target.integrity = preloadState[1]);
|
2435 | }
|
2436 | function getPreloadAsHeader(href, as, params) {
|
2437 | href = ("" + href).replace(
|
2438 | regexForHrefInLinkHeaderURLContext,
|
2439 | escapeHrefForLinkHeaderURLContextReplacer
|
2440 | );
|
2441 | as = ("" + as).replace(
|
2442 | regexForLinkHeaderQuotedParamValueContext,
|
2443 | escapeStringForLinkHeaderQuotedParamValueContextReplacer
|
2444 | );
|
2445 | as = "<" + href + '>; rel=preload; as="' + as + '"';
|
2446 | for (var paramName in params)
|
2447 | hasOwnProperty.call(params, paramName) &&
|
2448 | ((href = params[paramName]),
|
2449 | "string" === typeof href &&
|
2450 | (as +=
|
2451 | "; " +
|
2452 | paramName.toLowerCase() +
|
2453 | '="' +
|
2454 | ("" + href).replace(
|
2455 | regexForLinkHeaderQuotedParamValueContext,
|
2456 | escapeStringForLinkHeaderQuotedParamValueContextReplacer
|
2457 | ) +
|
2458 | '"'));
|
2459 | return as;
|
2460 | }
|
2461 | var regexForHrefInLinkHeaderURLContext = /[<>\r\n]/g;
|
2462 | function escapeHrefForLinkHeaderURLContextReplacer(match) {
|
2463 | switch (match) {
|
2464 | case "<":
|
2465 | return "%3C";
|
2466 | case ">":
|
2467 | return "%3E";
|
2468 | case "\n":
|
2469 | return "%0A";
|
2470 | case "\r":
|
2471 | return "%0D";
|
2472 | default:
|
2473 | throw Error(
|
2474 | "escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React"
|
2475 | );
|
2476 | }
|
2477 | }
|
2478 | var regexForLinkHeaderQuotedParamValueContext = /["';,\r\n]/g;
|
2479 | function escapeStringForLinkHeaderQuotedParamValueContextReplacer(match) {
|
2480 | switch (match) {
|
2481 | case '"':
|
2482 | return "%22";
|
2483 | case "'":
|
2484 | return "%27";
|
2485 | case ";":
|
2486 | return "%3B";
|
2487 | case ",":
|
2488 | return "%2C";
|
2489 | case "\n":
|
2490 | return "%0A";
|
2491 | case "\r":
|
2492 | return "%0D";
|
2493 | default:
|
2494 | throw Error(
|
2495 | "escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React"
|
2496 | );
|
2497 | }
|
2498 | }
|
2499 | function hoistStyleQueueDependency(styleQueue) {
|
2500 | this.styles.add(styleQueue);
|
2501 | }
|
2502 | function hoistStylesheetDependency(stylesheet) {
|
2503 | this.stylesheets.add(stylesheet);
|
2504 | }
|
2505 | function createRenderState(resumableState, generateStaticMarkup) {
|
2506 | var idPrefix = resumableState.idPrefix,
|
2507 | bootstrapChunks = [],
|
2508 | bootstrapScriptContent = resumableState.bootstrapScriptContent,
|
2509 | bootstrapScripts = resumableState.bootstrapScripts,
|
2510 | bootstrapModules = resumableState.bootstrapModules;
|
2511 | void 0 !== bootstrapScriptContent &&
|
2512 | bootstrapChunks.push(
|
2513 | "<script>",
|
2514 | ("" + bootstrapScriptContent).replace(scriptRegex, scriptReplacer),
|
2515 | "\x3c/script>"
|
2516 | );
|
2517 | bootstrapScriptContent = idPrefix + "P:";
|
2518 | var JSCompiler_object_inline_segmentPrefix_1483 = idPrefix + "S:";
|
2519 | idPrefix += "B:";
|
2520 | var JSCompiler_object_inline_preconnects_1497 = new Set(),
|
2521 | JSCompiler_object_inline_fontPreloads_1498 = new Set(),
|
2522 | JSCompiler_object_inline_highImagePreloads_1499 = new Set(),
|
2523 | JSCompiler_object_inline_styles_1500 = new Map(),
|
2524 | JSCompiler_object_inline_bootstrapScripts_1501 = new Set(),
|
2525 | JSCompiler_object_inline_scripts_1502 = new Set(),
|
2526 | JSCompiler_object_inline_bulkPreloads_1503 = new Set(),
|
2527 | JSCompiler_object_inline_preloads_1504 = {
|
2528 | images: new Map(),
|
2529 | stylesheets: new Map(),
|
2530 | scripts: new Map(),
|
2531 | moduleScripts: new Map()
|
2532 | };
|
2533 | if (void 0 !== bootstrapScripts)
|
2534 | for (var i = 0; i < bootstrapScripts.length; i++) {
|
2535 | var scriptConfig = bootstrapScripts[i],
|
2536 | src,
|
2537 | crossOrigin = void 0,
|
2538 | integrity = void 0,
|
2539 | props = {
|
2540 | rel: "preload",
|
2541 | as: "script",
|
2542 | fetchPriority: "low",
|
2543 | nonce: void 0
|
2544 | };
|
2545 | "string" === typeof scriptConfig
|
2546 | ? (props.href = src = scriptConfig)
|
2547 | : ((props.href = src = scriptConfig.src),
|
2548 | (props.integrity = integrity =
|
2549 | "string" === typeof scriptConfig.integrity
|
2550 | ? scriptConfig.integrity
|
2551 | : void 0),
|
2552 | (props.crossOrigin = crossOrigin =
|
2553 | "string" === typeof scriptConfig || null == scriptConfig.crossOrigin
|
2554 | ? void 0
|
2555 | : "use-credentials" === scriptConfig.crossOrigin
|
2556 | ? "use-credentials"
|
2557 | : ""));
|
2558 | scriptConfig = resumableState;
|
2559 | var href = src;
|
2560 | scriptConfig.scriptResources[href] = null;
|
2561 | scriptConfig.moduleScriptResources[href] = null;
|
2562 | scriptConfig = [];
|
2563 | pushLinkImpl(scriptConfig, props);
|
2564 | JSCompiler_object_inline_bootstrapScripts_1501.add(scriptConfig);
|
2565 | bootstrapChunks.push('<script src="', escapeTextForBrowser(src));
|
2566 | "string" === typeof integrity &&
|
2567 | bootstrapChunks.push('" integrity="', escapeTextForBrowser(integrity));
|
2568 | "string" === typeof crossOrigin &&
|
2569 | bootstrapChunks.push(
|
2570 | '" crossorigin="',
|
2571 | escapeTextForBrowser(crossOrigin)
|
2572 | );
|
2573 | bootstrapChunks.push('" async="">\x3c/script>');
|
2574 | }
|
2575 | if (void 0 !== bootstrapModules)
|
2576 | for (
|
2577 | bootstrapScripts = 0;
|
2578 | bootstrapScripts < bootstrapModules.length;
|
2579 | bootstrapScripts++
|
2580 | )
|
2581 | (props = bootstrapModules[bootstrapScripts]),
|
2582 | (crossOrigin = src = void 0),
|
2583 | (integrity = {
|
2584 | rel: "modulepreload",
|
2585 | fetchPriority: "low",
|
2586 | nonce: void 0
|
2587 | }),
|
2588 | "string" === typeof props
|
2589 | ? (integrity.href = i = props)
|
2590 | : ((integrity.href = i = props.src),
|
2591 | (integrity.integrity = crossOrigin =
|
2592 | "string" === typeof props.integrity ? props.integrity : void 0),
|
2593 | (integrity.crossOrigin = src =
|
2594 | "string" === typeof props || null == props.crossOrigin
|
2595 | ? void 0
|
2596 | : "use-credentials" === props.crossOrigin
|
2597 | ? "use-credentials"
|
2598 | : "")),
|
2599 | (props = resumableState),
|
2600 | (scriptConfig = i),
|
2601 | (props.scriptResources[scriptConfig] = null),
|
2602 | (props.moduleScriptResources[scriptConfig] = null),
|
2603 | (props = []),
|
2604 | pushLinkImpl(props, integrity),
|
2605 | JSCompiler_object_inline_bootstrapScripts_1501.add(props),
|
2606 | bootstrapChunks.push(
|
2607 | '<script type="module" src="',
|
2608 | escapeTextForBrowser(i)
|
2609 | ),
|
2610 | "string" === typeof crossOrigin &&
|
2611 | bootstrapChunks.push(
|
2612 | '" integrity="',
|
2613 | escapeTextForBrowser(crossOrigin)
|
2614 | ),
|
2615 | "string" === typeof src &&
|
2616 | bootstrapChunks.push('" crossorigin="', escapeTextForBrowser(src)),
|
2617 | bootstrapChunks.push('" async="">\x3c/script>');
|
2618 | return {
|
2619 | placeholderPrefix: bootstrapScriptContent,
|
2620 | segmentPrefix: JSCompiler_object_inline_segmentPrefix_1483,
|
2621 | boundaryPrefix: idPrefix,
|
2622 | startInlineScript: "<script>",
|
2623 | htmlChunks: null,
|
2624 | headChunks: null,
|
2625 | externalRuntimeScript: null,
|
2626 | bootstrapChunks: bootstrapChunks,
|
2627 | importMapChunks: [],
|
2628 | onHeaders: void 0,
|
2629 | headers: null,
|
2630 | resets: {
|
2631 | font: {},
|
2632 | dns: {},
|
2633 | connect: { default: {}, anonymous: {}, credentials: {} },
|
2634 | image: {},
|
2635 | style: {}
|
2636 | },
|
2637 | charsetChunks: [],
|
2638 | viewportChunks: [],
|
2639 | hoistableChunks: [],
|
2640 | preconnects: JSCompiler_object_inline_preconnects_1497,
|
2641 | fontPreloads: JSCompiler_object_inline_fontPreloads_1498,
|
2642 | highImagePreloads: JSCompiler_object_inline_highImagePreloads_1499,
|
2643 | styles: JSCompiler_object_inline_styles_1500,
|
2644 | bootstrapScripts: JSCompiler_object_inline_bootstrapScripts_1501,
|
2645 | scripts: JSCompiler_object_inline_scripts_1502,
|
2646 | bulkPreloads: JSCompiler_object_inline_bulkPreloads_1503,
|
2647 | preloads: JSCompiler_object_inline_preloads_1504,
|
2648 | stylesToHoist: !1,
|
2649 | generateStaticMarkup: generateStaticMarkup
|
2650 | };
|
2651 | }
|
2652 | function pushTextInstance(target, text, renderState, textEmbedded) {
|
2653 | if (renderState.generateStaticMarkup)
|
2654 | return target.push(escapeTextForBrowser(text)), !1;
|
2655 | "" === text
|
2656 | ? (target = textEmbedded)
|
2657 | : (textEmbedded && target.push("\x3c!-- --\x3e"),
|
2658 | target.push(escapeTextForBrowser(text)),
|
2659 | (target = !0));
|
2660 | return target;
|
2661 | }
|
2662 | var REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference");
|
2663 | function getComponentNameFromType(type) {
|
2664 | if (null == type) return null;
|
2665 | if ("function" === typeof type)
|
2666 | return type.$$typeof === REACT_CLIENT_REFERENCE
|
2667 | ? null
|
2668 | : type.displayName || type.name || null;
|
2669 | if ("string" === typeof type) return type;
|
2670 | switch (type) {
|
2671 | case REACT_FRAGMENT_TYPE:
|
2672 | return "Fragment";
|
2673 | case REACT_PORTAL_TYPE:
|
2674 | return "Portal";
|
2675 | case REACT_PROFILER_TYPE:
|
2676 | return "Profiler";
|
2677 | case REACT_STRICT_MODE_TYPE:
|
2678 | return "StrictMode";
|
2679 | case REACT_SUSPENSE_TYPE:
|
2680 | return "Suspense";
|
2681 | case REACT_SUSPENSE_LIST_TYPE:
|
2682 | return "SuspenseList";
|
2683 | }
|
2684 | if ("object" === typeof type)
|
2685 | switch (type.$$typeof) {
|
2686 | case REACT_CONTEXT_TYPE:
|
2687 | return (type.displayName || "Context") + ".Provider";
|
2688 | case REACT_CONSUMER_TYPE:
|
2689 | return (type._context.displayName || "Context") + ".Consumer";
|
2690 | case REACT_FORWARD_REF_TYPE:
|
2691 | var innerType = type.render;
|
2692 | type = type.displayName;
|
2693 | type ||
|
2694 | ((type = innerType.displayName || innerType.name || ""),
|
2695 | (type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef"));
|
2696 | return type;
|
2697 | case REACT_MEMO_TYPE:
|
2698 | return (
|
2699 | (innerType = type.displayName || null),
|
2700 | null !== innerType
|
2701 | ? innerType
|
2702 | : getComponentNameFromType(type.type) || "Memo"
|
2703 | );
|
2704 | case REACT_LAZY_TYPE:
|
2705 | innerType = type._payload;
|
2706 | type = type._init;
|
2707 | try {
|
2708 | return getComponentNameFromType(type(innerType));
|
2709 | } catch (x) {}
|
2710 | }
|
2711 | return null;
|
2712 | }
|
2713 | var emptyContextObject = {},
|
2714 | currentActiveSnapshot = null;
|
2715 | function popToNearestCommonAncestor(prev, next) {
|
2716 | if (prev !== next) {
|
2717 | prev.context._currentValue2 = prev.parentValue;
|
2718 | prev = prev.parent;
|
2719 | var parentNext = next.parent;
|
2720 | if (null === prev) {
|
2721 | if (null !== parentNext) throw Error(formatProdErrorMessage(401));
|
2722 | } else {
|
2723 | if (null === parentNext) throw Error(formatProdErrorMessage(401));
|
2724 | popToNearestCommonAncestor(prev, parentNext);
|
2725 | }
|
2726 | next.context._currentValue2 = next.value;
|
2727 | }
|
2728 | }
|
2729 | function popAllPrevious(prev) {
|
2730 | prev.context._currentValue2 = prev.parentValue;
|
2731 | prev = prev.parent;
|
2732 | null !== prev && popAllPrevious(prev);
|
2733 | }
|
2734 | function pushAllNext(next) {
|
2735 | var parentNext = next.parent;
|
2736 | null !== parentNext && pushAllNext(parentNext);
|
2737 | next.context._currentValue2 = next.value;
|
2738 | }
|
2739 | function popPreviousToCommonLevel(prev, next) {
|
2740 | prev.context._currentValue2 = prev.parentValue;
|
2741 | prev = prev.parent;
|
2742 | if (null === prev) throw Error(formatProdErrorMessage(402));
|
2743 | prev.depth === next.depth
|
2744 | ? popToNearestCommonAncestor(prev, next)
|
2745 | : popPreviousToCommonLevel(prev, next);
|
2746 | }
|
2747 | function popNextToCommonLevel(prev, next) {
|
2748 | var parentNext = next.parent;
|
2749 | if (null === parentNext) throw Error(formatProdErrorMessage(402));
|
2750 | prev.depth === parentNext.depth
|
2751 | ? popToNearestCommonAncestor(prev, parentNext)
|
2752 | : popNextToCommonLevel(prev, parentNext);
|
2753 | next.context._currentValue2 = next.value;
|
2754 | }
|
2755 | function switchContext(newSnapshot) {
|
2756 | var prev = currentActiveSnapshot;
|
2757 | prev !== newSnapshot &&
|
2758 | (null === prev
|
2759 | ? pushAllNext(newSnapshot)
|
2760 | : null === newSnapshot
|
2761 | ? popAllPrevious(prev)
|
2762 | : prev.depth === newSnapshot.depth
|
2763 | ? popToNearestCommonAncestor(prev, newSnapshot)
|
2764 | : prev.depth > newSnapshot.depth
|
2765 | ? popPreviousToCommonLevel(prev, newSnapshot)
|
2766 | : popNextToCommonLevel(prev, newSnapshot),
|
2767 | (currentActiveSnapshot = newSnapshot));
|
2768 | }
|
2769 | var classComponentUpdater = {
|
2770 | isMounted: function () {
|
2771 | return !1;
|
2772 | },
|
2773 | enqueueSetState: function (inst, payload) {
|
2774 | inst = inst._reactInternals;
|
2775 | null !== inst.queue && inst.queue.push(payload);
|
2776 | },
|
2777 | enqueueReplaceState: function (inst, payload) {
|
2778 | inst = inst._reactInternals;
|
2779 | inst.replace = !0;
|
2780 | inst.queue = [payload];
|
2781 | },
|
2782 | enqueueForceUpdate: function () {}
|
2783 | },
|
2784 | emptyTreeContext = { id: 1, overflow: "" };
|
2785 | function pushTreeContext(baseContext, totalChildren, index) {
|
2786 | var baseIdWithLeadingBit = baseContext.id;
|
2787 | baseContext = baseContext.overflow;
|
2788 | var baseLength = 32 - clz32(baseIdWithLeadingBit) - 1;
|
2789 | baseIdWithLeadingBit &= ~(1 << baseLength);
|
2790 | index += 1;
|
2791 | var length = 32 - clz32(totalChildren) + baseLength;
|
2792 | if (30 < length) {
|
2793 | var numberOfOverflowBits = baseLength - (baseLength % 5);
|
2794 | length = (
|
2795 | baseIdWithLeadingBit &
|
2796 | ((1 << numberOfOverflowBits) - 1)
|
2797 | ).toString(32);
|
2798 | baseIdWithLeadingBit >>= numberOfOverflowBits;
|
2799 | baseLength -= numberOfOverflowBits;
|
2800 | return {
|
2801 | id:
|
2802 | (1 << (32 - clz32(totalChildren) + baseLength)) |
|
2803 | (index << baseLength) |
|
2804 | baseIdWithLeadingBit,
|
2805 | overflow: length + baseContext
|
2806 | };
|
2807 | }
|
2808 | return {
|
2809 | id: (1 << length) | (index << baseLength) | baseIdWithLeadingBit,
|
2810 | overflow: baseContext
|
2811 | };
|
2812 | }
|
2813 | var clz32 = Math.clz32 ? Math.clz32 : clz32Fallback,
|
2814 | log = Math.log,
|
2815 | LN2 = Math.LN2;
|
2816 | function clz32Fallback(x) {
|
2817 | x >>>= 0;
|
2818 | return 0 === x ? 32 : (31 - ((log(x) / LN2) | 0)) | 0;
|
2819 | }
|
2820 | var SuspenseException = Error(formatProdErrorMessage(460));
|
2821 | function noop$2() {}
|
2822 | function trackUsedThenable(thenableState, thenable, index) {
|
2823 | index = thenableState[index];
|
2824 | void 0 === index
|
2825 | ? thenableState.push(thenable)
|
2826 | : index !== thenable && (thenable.then(noop$2, noop$2), (thenable = index));
|
2827 | switch (thenable.status) {
|
2828 | case "fulfilled":
|
2829 | return thenable.value;
|
2830 | case "rejected":
|
2831 | throw thenable.reason;
|
2832 | default:
|
2833 | "string" === typeof thenable.status
|
2834 | ? thenable.then(noop$2, noop$2)
|
2835 | : ((thenableState = thenable),
|
2836 | (thenableState.status = "pending"),
|
2837 | thenableState.then(
|
2838 | function (fulfilledValue) {
|
2839 | if ("pending" === thenable.status) {
|
2840 | var fulfilledThenable = thenable;
|
2841 | fulfilledThenable.status = "fulfilled";
|
2842 | fulfilledThenable.value = fulfilledValue;
|
2843 | }
|
2844 | },
|
2845 | function (error) {
|
2846 | if ("pending" === thenable.status) {
|
2847 | var rejectedThenable = thenable;
|
2848 | rejectedThenable.status = "rejected";
|
2849 | rejectedThenable.reason = error;
|
2850 | }
|
2851 | }
|
2852 | ));
|
2853 | switch (thenable.status) {
|
2854 | case "fulfilled":
|
2855 | return thenable.value;
|
2856 | case "rejected":
|
2857 | throw thenable.reason;
|
2858 | }
|
2859 | suspendedThenable = thenable;
|
2860 | throw SuspenseException;
|
2861 | }
|
2862 | }
|
2863 | var suspendedThenable = null;
|
2864 | function getSuspendedThenable() {
|
2865 | if (null === suspendedThenable) throw Error(formatProdErrorMessage(459));
|
2866 | var thenable = suspendedThenable;
|
2867 | suspendedThenable = null;
|
2868 | return thenable;
|
2869 | }
|
2870 | function is(x, y) {
|
2871 | return (x === y && (0 !== x || 1 / x === 1 / y)) || (x !== x && y !== y);
|
2872 | }
|
2873 | var objectIs = "function" === typeof Object.is ? Object.is : is,
|
2874 | currentlyRenderingComponent = null,
|
2875 | currentlyRenderingTask = null,
|
2876 | currentlyRenderingRequest = null,
|
2877 | currentlyRenderingKeyPath = null,
|
2878 | firstWorkInProgressHook = null,
|
2879 | workInProgressHook = null,
|
2880 | isReRender = !1,
|
2881 | didScheduleRenderPhaseUpdate = !1,
|
2882 | localIdCounter = 0,
|
2883 | actionStateCounter = 0,
|
2884 | actionStateMatchingIndex = -1,
|
2885 | thenableIndexCounter = 0,
|
2886 | thenableState = null,
|
2887 | renderPhaseUpdates = null,
|
2888 | numberOfReRenders = 0;
|
2889 | function resolveCurrentlyRenderingComponent() {
|
2890 | if (null === currentlyRenderingComponent)
|
2891 | throw Error(formatProdErrorMessage(321));
|
2892 | return currentlyRenderingComponent;
|
2893 | }
|
2894 | function createHook() {
|
2895 | if (0 < numberOfReRenders) throw Error(formatProdErrorMessage(312));
|
2896 | return { memoizedState: null, queue: null, next: null };
|
2897 | }
|
2898 | function createWorkInProgressHook() {
|
2899 | null === workInProgressHook
|
2900 | ? null === firstWorkInProgressHook
|
2901 | ? ((isReRender = !1),
|
2902 | (firstWorkInProgressHook = workInProgressHook = createHook()))
|
2903 | : ((isReRender = !0), (workInProgressHook = firstWorkInProgressHook))
|
2904 | : null === workInProgressHook.next
|
2905 | ? ((isReRender = !1),
|
2906 | (workInProgressHook = workInProgressHook.next = createHook()))
|
2907 | : ((isReRender = !0), (workInProgressHook = workInProgressHook.next));
|
2908 | return workInProgressHook;
|
2909 | }
|
2910 | function getThenableStateAfterSuspending() {
|
2911 | var state = thenableState;
|
2912 | thenableState = null;
|
2913 | return state;
|
2914 | }
|
2915 | function resetHooksState() {
|
2916 | currentlyRenderingKeyPath =
|
2917 | currentlyRenderingRequest =
|
2918 | currentlyRenderingTask =
|
2919 | currentlyRenderingComponent =
|
2920 | null;
|
2921 | didScheduleRenderPhaseUpdate = !1;
|
2922 | firstWorkInProgressHook = null;
|
2923 | numberOfReRenders = 0;
|
2924 | workInProgressHook = renderPhaseUpdates = null;
|
2925 | }
|
2926 | function basicStateReducer(state, action) {
|
2927 | return "function" === typeof action ? action(state) : action;
|
2928 | }
|
2929 | function useReducer(reducer, initialArg, init) {
|
2930 | currentlyRenderingComponent = resolveCurrentlyRenderingComponent();
|
2931 | workInProgressHook = createWorkInProgressHook();
|
2932 | if (isReRender) {
|
2933 | var queue = workInProgressHook.queue;
|
2934 | initialArg = queue.dispatch;
|
2935 | if (
|
2936 | null !== renderPhaseUpdates &&
|
2937 | ((init = renderPhaseUpdates.get(queue)), void 0 !== init)
|
2938 | ) {
|
2939 | renderPhaseUpdates.delete(queue);
|
2940 | queue = workInProgressHook.memoizedState;
|
2941 | do (queue = reducer(queue, init.action)), (init = init.next);
|
2942 | while (null !== init);
|
2943 | workInProgressHook.memoizedState = queue;
|
2944 | return [queue, initialArg];
|
2945 | }
|
2946 | return [workInProgressHook.memoizedState, initialArg];
|
2947 | }
|
2948 | reducer =
|
2949 | reducer === basicStateReducer
|
2950 | ? "function" === typeof initialArg
|
2951 | ? initialArg()
|
2952 | : initialArg
|
2953 | : void 0 !== init
|
2954 | ? init(initialArg)
|
2955 | : initialArg;
|
2956 | workInProgressHook.memoizedState = reducer;
|
2957 | reducer = workInProgressHook.queue = { last: null, dispatch: null };
|
2958 | reducer = reducer.dispatch = dispatchAction.bind(
|
2959 | null,
|
2960 | currentlyRenderingComponent,
|
2961 | reducer
|
2962 | );
|
2963 | return [workInProgressHook.memoizedState, reducer];
|
2964 | }
|
2965 | function useMemo(nextCreate, deps) {
|
2966 | currentlyRenderingComponent = resolveCurrentlyRenderingComponent();
|
2967 | workInProgressHook = createWorkInProgressHook();
|
2968 | deps = void 0 === deps ? null : deps;
|
2969 | if (null !== workInProgressHook) {
|
2970 | var prevState = workInProgressHook.memoizedState;
|
2971 | if (null !== prevState && null !== deps) {
|
2972 | var prevDeps = prevState[1];
|
2973 | a: if (null === prevDeps) prevDeps = !1;
|
2974 | else {
|
2975 | for (var i = 0; i < prevDeps.length && i < deps.length; i++)
|
2976 | if (!objectIs(deps[i], prevDeps[i])) {
|
2977 | prevDeps = !1;
|
2978 | break a;
|
2979 | }
|
2980 | prevDeps = !0;
|
2981 | }
|
2982 | if (prevDeps) return prevState[0];
|
2983 | }
|
2984 | }
|
2985 | nextCreate = nextCreate();
|
2986 | workInProgressHook.memoizedState = [nextCreate, deps];
|
2987 | return nextCreate;
|
2988 | }
|
2989 | function dispatchAction(componentIdentity, queue, action) {
|
2990 | if (25 <= numberOfReRenders) throw Error(formatProdErrorMessage(301));
|
2991 | if (componentIdentity === currentlyRenderingComponent)
|
2992 | if (
|
2993 | ((didScheduleRenderPhaseUpdate = !0),
|
2994 | (componentIdentity = { action: action, next: null }),
|
2995 | null === renderPhaseUpdates && (renderPhaseUpdates = new Map()),
|
2996 | (action = renderPhaseUpdates.get(queue)),
|
2997 | void 0 === action)
|
2998 | )
|
2999 | renderPhaseUpdates.set(queue, componentIdentity);
|
3000 | else {
|
3001 | for (queue = action; null !== queue.next; ) queue = queue.next;
|
3002 | queue.next = componentIdentity;
|
3003 | }
|
3004 | }
|
3005 | function unsupportedStartTransition() {
|
3006 | throw Error(formatProdErrorMessage(394));
|
3007 | }
|
3008 | function unsupportedSetOptimisticState() {
|
3009 | throw Error(formatProdErrorMessage(479));
|
3010 | }
|
3011 | function useActionState(action, initialState, permalink) {
|
3012 | resolveCurrentlyRenderingComponent();
|
3013 | var actionStateHookIndex = actionStateCounter++,
|
3014 | request = currentlyRenderingRequest;
|
3015 | if ("function" === typeof action.$$FORM_ACTION) {
|
3016 | var nextPostbackStateKey = null,
|
3017 | componentKeyPath = currentlyRenderingKeyPath;
|
3018 | request = request.formState;
|
3019 | var isSignatureEqual = action.$$IS_SIGNATURE_EQUAL;
|
3020 | if (null !== request && "function" === typeof isSignatureEqual) {
|
3021 | var postbackKey = request[1];
|
3022 | isSignatureEqual.call(action, request[2], request[3]) &&
|
3023 | ((nextPostbackStateKey =
|
3024 | void 0 !== permalink
|
3025 | ? "p" + permalink
|
3026 | : "k" +
|
3027 | murmurhash3_32_gc(
|
3028 | JSON.stringify([componentKeyPath, null, actionStateHookIndex]),
|
3029 | 0
|
3030 | )),
|
3031 | postbackKey === nextPostbackStateKey &&
|
3032 | ((actionStateMatchingIndex = actionStateHookIndex),
|
3033 | (initialState = request[0])));
|
3034 | }
|
3035 | var boundAction = action.bind(null, initialState);
|
3036 | action = function (payload) {
|
3037 | boundAction(payload);
|
3038 | };
|
3039 | "function" === typeof boundAction.$$FORM_ACTION &&
|
3040 | (action.$$FORM_ACTION = function (prefix) {
|
3041 | prefix = boundAction.$$FORM_ACTION(prefix);
|
3042 | void 0 !== permalink &&
|
3043 | ((permalink += ""), (prefix.action = permalink));
|
3044 | var formData = prefix.data;
|
3045 | formData &&
|
3046 | (null === nextPostbackStateKey &&
|
3047 | (nextPostbackStateKey =
|
3048 | void 0 !== permalink
|
3049 | ? "p" + permalink
|
3050 | : "k" +
|
3051 | murmurhash3_32_gc(
|
3052 | JSON.stringify([
|
3053 | componentKeyPath,
|
3054 | null,
|
3055 | actionStateHookIndex
|
3056 | ]),
|
3057 | 0
|
3058 | )),
|
3059 | formData.append("$ACTION_KEY", nextPostbackStateKey));
|
3060 | return prefix;
|
3061 | });
|
3062 | return [initialState, action, !1];
|
3063 | }
|
3064 | var boundAction$22 = action.bind(null, initialState);
|
3065 | return [
|
3066 | initialState,
|
3067 | function (payload) {
|
3068 | boundAction$22(payload);
|
3069 | },
|
3070 | !1
|
3071 | ];
|
3072 | }
|
3073 | function unwrapThenable(thenable) {
|
3074 | var index = thenableIndexCounter;
|
3075 | thenableIndexCounter += 1;
|
3076 | null === thenableState && (thenableState = []);
|
3077 | return trackUsedThenable(thenableState, thenable, index);
|
3078 | }
|
3079 | function unsupportedRefresh() {
|
3080 | throw Error(formatProdErrorMessage(393));
|
3081 | }
|
3082 | function noop$1() {}
|
3083 | var HooksDispatcher = {
|
3084 | readContext: function (context) {
|
3085 | return context._currentValue2;
|
3086 | },
|
3087 | use: function (usable) {
|
3088 | if (null !== usable && "object" === typeof usable) {
|
3089 | if ("function" === typeof usable.then) return unwrapThenable(usable);
|
3090 | if (usable.$$typeof === REACT_CONTEXT_TYPE) return usable._currentValue2;
|
3091 | }
|
3092 | throw Error(formatProdErrorMessage(438, String(usable)));
|
3093 | },
|
3094 | useContext: function (context) {
|
3095 | resolveCurrentlyRenderingComponent();
|
3096 | return context._currentValue2;
|
3097 | },
|
3098 | useMemo: useMemo,
|
3099 | useReducer: useReducer,
|
3100 | useRef: function (initialValue) {
|
3101 | currentlyRenderingComponent = resolveCurrentlyRenderingComponent();
|
3102 | workInProgressHook = createWorkInProgressHook();
|
3103 | var previousRef = workInProgressHook.memoizedState;
|
3104 | return null === previousRef
|
3105 | ? ((initialValue = { current: initialValue }),
|
3106 | (workInProgressHook.memoizedState = initialValue))
|
3107 | : previousRef;
|
3108 | },
|
3109 | useState: function (initialState) {
|
3110 | return useReducer(basicStateReducer, initialState);
|
3111 | },
|
3112 | useInsertionEffect: noop$1,
|
3113 | useLayoutEffect: noop$1,
|
3114 | useCallback: function (callback, deps) {
|
3115 | return useMemo(function () {
|
3116 | return callback;
|
3117 | }, deps);
|
3118 | },
|
3119 | useImperativeHandle: noop$1,
|
3120 | useEffect: noop$1,
|
3121 | useDebugValue: noop$1,
|
3122 | useDeferredValue: function (value, initialValue) {
|
3123 | resolveCurrentlyRenderingComponent();
|
3124 | return void 0 !== initialValue ? initialValue : value;
|
3125 | },
|
3126 | useTransition: function () {
|
3127 | resolveCurrentlyRenderingComponent();
|
3128 | return [!1, unsupportedStartTransition];
|
3129 | },
|
3130 | useId: function () {
|
3131 | var JSCompiler_inline_result = currentlyRenderingTask.treeContext;
|
3132 | var overflow = JSCompiler_inline_result.overflow;
|
3133 | JSCompiler_inline_result = JSCompiler_inline_result.id;
|
3134 | JSCompiler_inline_result =
|
3135 | (
|
3136 | JSCompiler_inline_result &
|
3137 | ~(1 << (32 - clz32(JSCompiler_inline_result) - 1))
|
3138 | ).toString(32) + overflow;
|
3139 | var resumableState = currentResumableState;
|
3140 | if (null === resumableState) throw Error(formatProdErrorMessage(404));
|
3141 | overflow = localIdCounter++;
|
3142 | JSCompiler_inline_result =
|
3143 | ":" + resumableState.idPrefix + "R" + JSCompiler_inline_result;
|
3144 | 0 < overflow && (JSCompiler_inline_result += "H" + overflow.toString(32));
|
3145 | return JSCompiler_inline_result + ":";
|
3146 | },
|
3147 | useSyncExternalStore: function (subscribe, getSnapshot, getServerSnapshot) {
|
3148 | if (void 0 === getServerSnapshot) throw Error(formatProdErrorMessage(407));
|
3149 | return getServerSnapshot();
|
3150 | },
|
3151 | useCacheRefresh: function () {
|
3152 | return unsupportedRefresh;
|
3153 | },
|
3154 | useHostTransitionStatus: function () {
|
3155 | resolveCurrentlyRenderingComponent();
|
3156 | return sharedNotPendingObject;
|
3157 | },
|
3158 | useOptimistic: function (passthrough) {
|
3159 | resolveCurrentlyRenderingComponent();
|
3160 | return [passthrough, unsupportedSetOptimisticState];
|
3161 | }
|
3162 | };
|
3163 | HooksDispatcher.useFormState = useActionState;
|
3164 | HooksDispatcher.useActionState = useActionState;
|
3165 | var currentResumableState = null,
|
3166 | DefaultAsyncDispatcher = {
|
3167 | getCacheForType: function () {
|
3168 | throw Error(formatProdErrorMessage(248));
|
3169 | }
|
3170 | },
|
3171 | prefix;
|
3172 | function describeBuiltInComponentFrame(name) {
|
3173 | if (void 0 === prefix)
|
3174 | try {
|
3175 | throw Error();
|
3176 | } catch (x) {
|
3177 | var match = x.stack.trim().match(/\n( *(at )?)/);
|
3178 | prefix = (match && match[1]) || "";
|
3179 | }
|
3180 | return "\n" + prefix + name;
|
3181 | }
|
3182 | var reentry = !1;
|
3183 | function describeNativeComponentFrame(fn, construct) {
|
3184 | if (!fn || reentry) return "";
|
3185 | reentry = !0;
|
3186 | var previousPrepareStackTrace = Error.prepareStackTrace;
|
3187 | Error.prepareStackTrace = void 0;
|
3188 | var RunInRootFrame = {
|
3189 | DetermineComponentFrameRoot: function () {
|
3190 | try {
|
3191 | if (construct) {
|
3192 | var Fake = function () {
|
3193 | throw Error();
|
3194 | };
|
3195 | Object.defineProperty(Fake.prototype, "props", {
|
3196 | set: function () {
|
3197 | throw Error();
|
3198 | }
|
3199 | });
|
3200 | if ("object" === typeof Reflect && Reflect.construct) {
|
3201 | try {
|
3202 | Reflect.construct(Fake, []);
|
3203 | } catch (x) {
|
3204 | var control = x;
|
3205 | }
|
3206 | Reflect.construct(fn, [], Fake);
|
3207 | } else {
|
3208 | try {
|
3209 | Fake.call();
|
3210 | } catch (x$24) {
|
3211 | control = x$24;
|
3212 | }
|
3213 | fn.call(Fake.prototype);
|
3214 | }
|
3215 | } else {
|
3216 | try {
|
3217 | throw Error();
|
3218 | } catch (x$25) {
|
3219 | control = x$25;
|
3220 | }
|
3221 | (Fake = fn()) &&
|
3222 | "function" === typeof Fake.catch &&
|
3223 | Fake.catch(function () {});
|
3224 | }
|
3225 | } catch (sample) {
|
3226 | if (sample && control && "string" === typeof sample.stack)
|
3227 | return [sample.stack, control.stack];
|
3228 | }
|
3229 | return [null, null];
|
3230 | }
|
3231 | };
|
3232 | RunInRootFrame.DetermineComponentFrameRoot.displayName =
|
3233 | "DetermineComponentFrameRoot";
|
3234 | var namePropDescriptor = Object.getOwnPropertyDescriptor(
|
3235 | RunInRootFrame.DetermineComponentFrameRoot,
|
3236 | "name"
|
3237 | );
|
3238 | namePropDescriptor &&
|
3239 | namePropDescriptor.configurable &&
|
3240 | Object.defineProperty(RunInRootFrame.DetermineComponentFrameRoot, "name", {
|
3241 | value: "DetermineComponentFrameRoot"
|
3242 | });
|
3243 | try {
|
3244 | var _RunInRootFrame$Deter = RunInRootFrame.DetermineComponentFrameRoot(),
|
3245 | sampleStack = _RunInRootFrame$Deter[0],
|
3246 | controlStack = _RunInRootFrame$Deter[1];
|
3247 | if (sampleStack && controlStack) {
|
3248 | var sampleLines = sampleStack.split("\n"),
|
3249 | controlLines = controlStack.split("\n");
|
3250 | for (
|
3251 | namePropDescriptor = RunInRootFrame = 0;
|
3252 | RunInRootFrame < sampleLines.length &&
|
3253 | !sampleLines[RunInRootFrame].includes("DetermineComponentFrameRoot");
|
3254 |
|
3255 | )
|
3256 | RunInRootFrame++;
|
3257 | for (
|
3258 | ;
|
3259 | namePropDescriptor < controlLines.length &&
|
3260 | !controlLines[namePropDescriptor].includes(
|
3261 | "DetermineComponentFrameRoot"
|
3262 | );
|
3263 |
|
3264 | )
|
3265 | namePropDescriptor++;
|
3266 | if (
|
3267 | RunInRootFrame === sampleLines.length ||
|
3268 | namePropDescriptor === controlLines.length
|
3269 | )
|
3270 | for (
|
3271 | RunInRootFrame = sampleLines.length - 1,
|
3272 | namePropDescriptor = controlLines.length - 1;
|
3273 | 1 <= RunInRootFrame &&
|
3274 | 0 <= namePropDescriptor &&
|
3275 | sampleLines[RunInRootFrame] !== controlLines[namePropDescriptor];
|
3276 |
|
3277 | )
|
3278 | namePropDescriptor--;
|
3279 | for (
|
3280 | ;
|
3281 | 1 <= RunInRootFrame && 0 <= namePropDescriptor;
|
3282 | RunInRootFrame--, namePropDescriptor--
|
3283 | )
|
3284 | if (sampleLines[RunInRootFrame] !== controlLines[namePropDescriptor]) {
|
3285 | if (1 !== RunInRootFrame || 1 !== namePropDescriptor) {
|
3286 | do
|
3287 | if (
|
3288 | (RunInRootFrame--,
|
3289 | namePropDescriptor--,
|
3290 | 0 > namePropDescriptor ||
|
3291 | sampleLines[RunInRootFrame] !==
|
3292 | controlLines[namePropDescriptor])
|
3293 | ) {
|
3294 | var frame =
|
3295 | "\n" +
|
3296 | sampleLines[RunInRootFrame].replace(" at new ", " at ");
|
3297 | fn.displayName &&
|
3298 | frame.includes("<anonymous>") &&
|
3299 | (frame = frame.replace("<anonymous>", fn.displayName));
|
3300 | return frame;
|
3301 | }
|
3302 | while (1 <= RunInRootFrame && 0 <= namePropDescriptor);
|
3303 | }
|
3304 | break;
|
3305 | }
|
3306 | }
|
3307 | } finally {
|
3308 | (reentry = !1), (Error.prepareStackTrace = previousPrepareStackTrace);
|
3309 | }
|
3310 | return (previousPrepareStackTrace = fn ? fn.displayName || fn.name : "")
|
3311 | ? describeBuiltInComponentFrame(previousPrepareStackTrace)
|
3312 | : "";
|
3313 | }
|
3314 | function defaultErrorHandler(error) {
|
3315 | console.error(error);
|
3316 | return null;
|
3317 | }
|
3318 | function noop() {}
|
3319 | function createRequest(
|
3320 | children,
|
3321 | resumableState,
|
3322 | renderState,
|
3323 | rootFormatContext,
|
3324 | progressiveChunkSize,
|
3325 | onError,
|
3326 | onAllReady,
|
3327 | onShellReady,
|
3328 | onShellError,
|
3329 | onFatalError,
|
3330 | onPostpone,
|
3331 | formState
|
3332 | ) {
|
3333 | var pingedTasks = [],
|
3334 | abortSet = new Set();
|
3335 | resumableState = {
|
3336 | destination: null,
|
3337 | flushScheduled: !1,
|
3338 | resumableState: resumableState,
|
3339 | renderState: renderState,
|
3340 | rootFormatContext: rootFormatContext,
|
3341 | progressiveChunkSize:
|
3342 | void 0 === progressiveChunkSize ? 12800 : progressiveChunkSize,
|
3343 | status: 0,
|
3344 | fatalError: null,
|
3345 | nextSegmentId: 0,
|
3346 | allPendingTasks: 0,
|
3347 | pendingRootTasks: 0,
|
3348 | completedRootSegment: null,
|
3349 | abortableTasks: abortSet,
|
3350 | pingedTasks: pingedTasks,
|
3351 | clientRenderedBoundaries: [],
|
3352 | completedBoundaries: [],
|
3353 | partialBoundaries: [],
|
3354 | trackedPostpones: null,
|
3355 | onError: void 0 === onError ? defaultErrorHandler : onError,
|
3356 | onPostpone: void 0 === onPostpone ? noop : onPostpone,
|
3357 | onAllReady: void 0 === onAllReady ? noop : onAllReady,
|
3358 | onShellReady: void 0 === onShellReady ? noop : onShellReady,
|
3359 | onShellError: void 0 === onShellError ? noop : onShellError,
|
3360 | onFatalError: void 0 === onFatalError ? noop : onFatalError,
|
3361 | formState: void 0 === formState ? null : formState
|
3362 | };
|
3363 | renderState = createPendingSegment(
|
3364 | resumableState,
|
3365 | 0,
|
3366 | null,
|
3367 | rootFormatContext,
|
3368 | !1,
|
3369 | !1
|
3370 | );
|
3371 | renderState.parentFlushed = !0;
|
3372 | children = createRenderTask(
|
3373 | resumableState,
|
3374 | null,
|
3375 | children,
|
3376 | -1,
|
3377 | null,
|
3378 | renderState,
|
3379 | null,
|
3380 | abortSet,
|
3381 | null,
|
3382 | rootFormatContext,
|
3383 | emptyContextObject,
|
3384 | null,
|
3385 | emptyTreeContext,
|
3386 | null,
|
3387 | !1
|
3388 | );
|
3389 | pingedTasks.push(children);
|
3390 | return resumableState;
|
3391 | }
|
3392 | var currentRequest = null;
|
3393 | function pingTask(request, task) {
|
3394 | request.pingedTasks.push(task);
|
3395 | 1 === request.pingedTasks.length &&
|
3396 | ((request.flushScheduled = null !== request.destination),
|
3397 | performWork(request));
|
3398 | }
|
3399 | function createSuspenseBoundary(request, fallbackAbortableTasks) {
|
3400 | return {
|
3401 | status: 0,
|
3402 | rootSegmentID: -1,
|
3403 | parentFlushed: !1,
|
3404 | pendingTasks: 0,
|
3405 | completedSegments: [],
|
3406 | byteSize: 0,
|
3407 | fallbackAbortableTasks: fallbackAbortableTasks,
|
3408 | errorDigest: null,
|
3409 | contentState: createHoistableState(),
|
3410 | fallbackState: createHoistableState(),
|
3411 | trackedContentKeyPath: null,
|
3412 | trackedFallbackNode: null
|
3413 | };
|
3414 | }
|
3415 | function createRenderTask(
|
3416 | request,
|
3417 | thenableState,
|
3418 | node,
|
3419 | childIndex,
|
3420 | blockedBoundary,
|
3421 | blockedSegment,
|
3422 | hoistableState,
|
3423 | abortSet,
|
3424 | keyPath,
|
3425 | formatContext,
|
3426 | legacyContext,
|
3427 | context,
|
3428 | treeContext,
|
3429 | componentStack,
|
3430 | isFallback
|
3431 | ) {
|
3432 | request.allPendingTasks++;
|
3433 | null === blockedBoundary
|
3434 | ? request.pendingRootTasks++
|
3435 | : blockedBoundary.pendingTasks++;
|
3436 | var task = {
|
3437 | replay: null,
|
3438 | node: node,
|
3439 | childIndex: childIndex,
|
3440 | ping: function () {
|
3441 | return pingTask(request, task);
|
3442 | },
|
3443 | blockedBoundary: blockedBoundary,
|
3444 | blockedSegment: blockedSegment,
|
3445 | hoistableState: hoistableState,
|
3446 | abortSet: abortSet,
|
3447 | keyPath: keyPath,
|
3448 | formatContext: formatContext,
|
3449 | legacyContext: legacyContext,
|
3450 | context: context,
|
3451 | treeContext: treeContext,
|
3452 | componentStack: componentStack,
|
3453 | thenableState: thenableState,
|
3454 | isFallback: isFallback
|
3455 | };
|
3456 | abortSet.add(task);
|
3457 | return task;
|
3458 | }
|
3459 | function createReplayTask(
|
3460 | request,
|
3461 | thenableState,
|
3462 | replay,
|
3463 | node,
|
3464 | childIndex,
|
3465 | blockedBoundary,
|
3466 | hoistableState,
|
3467 | abortSet,
|
3468 | keyPath,
|
3469 | formatContext,
|
3470 | legacyContext,
|
3471 | context,
|
3472 | treeContext,
|
3473 | componentStack,
|
3474 | isFallback
|
3475 | ) {
|
3476 | request.allPendingTasks++;
|
3477 | null === blockedBoundary
|
3478 | ? request.pendingRootTasks++
|
3479 | : blockedBoundary.pendingTasks++;
|
3480 | replay.pendingTasks++;
|
3481 | var task = {
|
3482 | replay: replay,
|
3483 | node: node,
|
3484 | childIndex: childIndex,
|
3485 | ping: function () {
|
3486 | return pingTask(request, task);
|
3487 | },
|
3488 | blockedBoundary: blockedBoundary,
|
3489 | blockedSegment: null,
|
3490 | hoistableState: hoistableState,
|
3491 | abortSet: abortSet,
|
3492 | keyPath: keyPath,
|
3493 | formatContext: formatContext,
|
3494 | legacyContext: legacyContext,
|
3495 | context: context,
|
3496 | treeContext: treeContext,
|
3497 | componentStack: componentStack,
|
3498 | thenableState: thenableState,
|
3499 | isFallback: isFallback
|
3500 | };
|
3501 | abortSet.add(task);
|
3502 | return task;
|
3503 | }
|
3504 | function createPendingSegment(
|
3505 | request,
|
3506 | index,
|
3507 | boundary,
|
3508 | parentFormatContext,
|
3509 | lastPushedText,
|
3510 | textEmbedded
|
3511 | ) {
|
3512 | return {
|
3513 | status: 0,
|
3514 | id: -1,
|
3515 | index: index,
|
3516 | parentFlushed: !1,
|
3517 | chunks: [],
|
3518 | children: [],
|
3519 | parentFormatContext: parentFormatContext,
|
3520 | boundary: boundary,
|
3521 | lastPushedText: lastPushedText,
|
3522 | textEmbedded: textEmbedded
|
3523 | };
|
3524 | }
|
3525 | function createBuiltInComponentStack(task, type) {
|
3526 | return { tag: 0, parent: task.componentStack, type: type };
|
3527 | }
|
3528 | function getThrownInfo(request, node) {
|
3529 | if (node && null !== request.trackedPostpones) {
|
3530 | try {
|
3531 | request = "";
|
3532 | do {
|
3533 | switch (node.tag) {
|
3534 | case 0:
|
3535 | request += describeBuiltInComponentFrame(node.type);
|
3536 | break;
|
3537 | case 1:
|
3538 | request += describeNativeComponentFrame(node.type, !1);
|
3539 | break;
|
3540 | case 2:
|
3541 | request += describeNativeComponentFrame(node.type, !0);
|
3542 | }
|
3543 | node = node.parent;
|
3544 | } while (node);
|
3545 | var JSCompiler_temp = request;
|
3546 | } catch (x) {
|
3547 | JSCompiler_temp =
|
3548 | "\nError generating stack: " + x.message + "\n" + x.stack;
|
3549 | }
|
3550 | JSCompiler_temp = { componentStack: JSCompiler_temp };
|
3551 | } else JSCompiler_temp = {};
|
3552 | return JSCompiler_temp;
|
3553 | }
|
3554 | function logRecoverableError(request, error, errorInfo) {
|
3555 | request = request.onError(error, errorInfo);
|
3556 | if (null == request || "string" === typeof request) return request;
|
3557 | }
|
3558 | function fatalError(request, error) {
|
3559 | var onShellError = request.onShellError;
|
3560 | onShellError(error);
|
3561 | onShellError = request.onFatalError;
|
3562 | onShellError(error);
|
3563 | null !== request.destination
|
3564 | ? ((request.status = 2), request.destination.destroy(error))
|
3565 | : ((request.status = 1), (request.fatalError = error));
|
3566 | }
|
3567 | function renderWithHooks(request, task, keyPath, Component, props, secondArg) {
|
3568 | var prevThenableState = task.thenableState;
|
3569 | task.thenableState = null;
|
3570 | currentlyRenderingComponent = {};
|
3571 | currentlyRenderingTask = task;
|
3572 | currentlyRenderingRequest = request;
|
3573 | currentlyRenderingKeyPath = keyPath;
|
3574 | actionStateCounter = localIdCounter = 0;
|
3575 | actionStateMatchingIndex = -1;
|
3576 | thenableIndexCounter = 0;
|
3577 | thenableState = prevThenableState;
|
3578 | for (request = Component(props, secondArg); didScheduleRenderPhaseUpdate; )
|
3579 | (didScheduleRenderPhaseUpdate = !1),
|
3580 | (actionStateCounter = localIdCounter = 0),
|
3581 | (actionStateMatchingIndex = -1),
|
3582 | (thenableIndexCounter = 0),
|
3583 | (numberOfReRenders += 1),
|
3584 | (workInProgressHook = null),
|
3585 | (request = Component(props, secondArg));
|
3586 | resetHooksState();
|
3587 | return request;
|
3588 | }
|
3589 | function finishFunctionComponent(
|
3590 | request,
|
3591 | task,
|
3592 | keyPath,
|
3593 | children,
|
3594 | hasId,
|
3595 | actionStateCount,
|
3596 | actionStateMatchingIndex
|
3597 | ) {
|
3598 | var didEmitActionStateMarkers = !1;
|
3599 | if (0 !== actionStateCount && null !== request.formState) {
|
3600 | var segment = task.blockedSegment;
|
3601 | if (null !== segment) {
|
3602 | didEmitActionStateMarkers = !0;
|
3603 | segment = segment.chunks;
|
3604 | for (var i = 0; i < actionStateCount; i++)
|
3605 | i === actionStateMatchingIndex
|
3606 | ? segment.push("\x3c!--F!--\x3e")
|
3607 | : segment.push("\x3c!--F--\x3e");
|
3608 | }
|
3609 | }
|
3610 | actionStateCount = task.keyPath;
|
3611 | task.keyPath = keyPath;
|
3612 | hasId
|
3613 | ? ((keyPath = task.treeContext),
|
3614 | (task.treeContext = pushTreeContext(keyPath, 1, 0)),
|
3615 | renderNode(request, task, children, -1),
|
3616 | (task.treeContext = keyPath))
|
3617 | : didEmitActionStateMarkers
|
3618 | ? renderNode(request, task, children, -1)
|
3619 | : renderNodeDestructive(request, task, children, -1);
|
3620 | task.keyPath = actionStateCount;
|
3621 | }
|
3622 | function renderElement(request, task, keyPath, type, props, ref) {
|
3623 | if ("function" === typeof type)
|
3624 | if (type.prototype && type.prototype.isReactComponent) {
|
3625 | var JSCompiler_inline_result = props;
|
3626 | if ("ref" in props) {
|
3627 | JSCompiler_inline_result = {};
|
3628 | for (var propName in props)
|
3629 | "ref" !== propName &&
|
3630 | (JSCompiler_inline_result[propName] = props[propName]);
|
3631 | }
|
3632 | var defaultProps = type.defaultProps;
|
3633 | if (defaultProps) {
|
3634 | JSCompiler_inline_result === props &&
|
3635 | (JSCompiler_inline_result = assign(
|
3636 | {},
|
3637 | JSCompiler_inline_result,
|
3638 | props
|
3639 | ));
|
3640 | for (var propName$31 in defaultProps)
|
3641 | void 0 === JSCompiler_inline_result[propName$31] &&
|
3642 | (JSCompiler_inline_result[propName$31] = defaultProps[propName$31]);
|
3643 | }
|
3644 | props = task.componentStack;
|
3645 | task.componentStack = { tag: 2, parent: task.componentStack, type: type };
|
3646 | defaultProps = emptyContextObject;
|
3647 | ref = type.contextType;
|
3648 | "object" === typeof ref &&
|
3649 | null !== ref &&
|
3650 | (defaultProps = ref._currentValue2);
|
3651 | defaultProps = new type(JSCompiler_inline_result, defaultProps);
|
3652 | propName$31 = void 0 !== defaultProps.state ? defaultProps.state : null;
|
3653 | defaultProps.updater = classComponentUpdater;
|
3654 | defaultProps.props = JSCompiler_inline_result;
|
3655 | defaultProps.state = propName$31;
|
3656 | ref = { queue: [], replace: !1 };
|
3657 | defaultProps._reactInternals = ref;
|
3658 | var contextType = type.contextType;
|
3659 | defaultProps.context =
|
3660 | "object" === typeof contextType && null !== contextType
|
3661 | ? contextType._currentValue2
|
3662 | : emptyContextObject;
|
3663 | contextType = type.getDerivedStateFromProps;
|
3664 | "function" === typeof contextType &&
|
3665 | ((contextType = contextType(JSCompiler_inline_result, propName$31)),
|
3666 | (propName$31 =
|
3667 | null === contextType || void 0 === contextType
|
3668 | ? propName$31
|
3669 | : assign({}, propName$31, contextType)),
|
3670 | (defaultProps.state = propName$31));
|
3671 | if (
|
3672 | "function" !== typeof type.getDerivedStateFromProps &&
|
3673 | "function" !== typeof defaultProps.getSnapshotBeforeUpdate &&
|
3674 | ("function" === typeof defaultProps.UNSAFE_componentWillMount ||
|
3675 | "function" === typeof defaultProps.componentWillMount)
|
3676 | )
|
3677 | if (
|
3678 | ((type = defaultProps.state),
|
3679 | "function" === typeof defaultProps.componentWillMount &&
|
3680 | defaultProps.componentWillMount(),
|
3681 | "function" === typeof defaultProps.UNSAFE_componentWillMount &&
|
3682 | defaultProps.UNSAFE_componentWillMount(),
|
3683 | type !== defaultProps.state &&
|
3684 | classComponentUpdater.enqueueReplaceState(
|
3685 | defaultProps,
|
3686 | defaultProps.state,
|
3687 | null
|
3688 | ),
|
3689 | null !== ref.queue && 0 < ref.queue.length)
|
3690 | )
|
3691 | if (
|
3692 | ((type = ref.queue),
|
3693 | (contextType = ref.replace),
|
3694 | (ref.queue = null),
|
3695 | (ref.replace = !1),
|
3696 | contextType && 1 === type.length)
|
3697 | )
|
3698 | defaultProps.state = type[0];
|
3699 | else {
|
3700 | ref = contextType ? type[0] : defaultProps.state;
|
3701 | propName$31 = !0;
|
3702 | for (
|
3703 | contextType = contextType ? 1 : 0;
|
3704 | contextType < type.length;
|
3705 | contextType++
|
3706 | )
|
3707 | (propName = type[contextType]),
|
3708 | (propName =
|
3709 | "function" === typeof propName
|
3710 | ? propName.call(
|
3711 | defaultProps,
|
3712 | ref,
|
3713 | JSCompiler_inline_result,
|
3714 | void 0
|
3715 | )
|
3716 | : propName),
|
3717 | null != propName &&
|
3718 | (propName$31
|
3719 | ? ((propName$31 = !1), (ref = assign({}, ref, propName)))
|
3720 | : assign(ref, propName));
|
3721 | defaultProps.state = ref;
|
3722 | }
|
3723 | else ref.queue = null;
|
3724 | type = defaultProps.render();
|
3725 | JSCompiler_inline_result = task.keyPath;
|
3726 | task.keyPath = keyPath;
|
3727 | renderNodeDestructive(request, task, type, -1);
|
3728 | task.keyPath = JSCompiler_inline_result;
|
3729 | task.componentStack = props;
|
3730 | } else
|
3731 | (JSCompiler_inline_result = task.componentStack),
|
3732 | (task.componentStack = {
|
3733 | tag: 1,
|
3734 | parent: task.componentStack,
|
3735 | type: type
|
3736 | }),
|
3737 | (type = renderWithHooks(request, task, keyPath, type, props, void 0)),
|
3738 | finishFunctionComponent(
|
3739 | request,
|
3740 | task,
|
3741 | keyPath,
|
3742 | type,
|
3743 | 0 !== localIdCounter,
|
3744 | actionStateCounter,
|
3745 | actionStateMatchingIndex
|
3746 | ),
|
3747 | (task.componentStack = JSCompiler_inline_result);
|
3748 | else if ("string" === typeof type) {
|
3749 | JSCompiler_inline_result = task.componentStack;
|
3750 | task.componentStack = createBuiltInComponentStack(task, type);
|
3751 | defaultProps = task.blockedSegment;
|
3752 | if (null === defaultProps)
|
3753 | (defaultProps = props.children),
|
3754 | (ref = task.formatContext),
|
3755 | (propName$31 = task.keyPath),
|
3756 | (task.formatContext = getChildFormatContext(ref, type, props)),
|
3757 | (task.keyPath = keyPath),
|
3758 | renderNode(request, task, defaultProps, -1),
|
3759 | (task.formatContext = ref),
|
3760 | (task.keyPath = propName$31);
|
3761 | else {
|
3762 | propName$31 = pushStartInstance(
|
3763 | defaultProps.chunks,
|
3764 | type,
|
3765 | props,
|
3766 | request.resumableState,
|
3767 | request.renderState,
|
3768 | task.hoistableState,
|
3769 | task.formatContext,
|
3770 | defaultProps.lastPushedText,
|
3771 | task.isFallback
|
3772 | );
|
3773 | defaultProps.lastPushedText = !1;
|
3774 | ref = task.formatContext;
|
3775 | contextType = task.keyPath;
|
3776 | task.formatContext = getChildFormatContext(ref, type, props);
|
3777 | task.keyPath = keyPath;
|
3778 | renderNode(request, task, propName$31, -1);
|
3779 | task.formatContext = ref;
|
3780 | task.keyPath = contextType;
|
3781 | a: {
|
3782 | keyPath = defaultProps.chunks;
|
3783 | request = request.resumableState;
|
3784 | switch (type) {
|
3785 | case "title":
|
3786 | case "style":
|
3787 | case "script":
|
3788 | case "area":
|
3789 | case "base":
|
3790 | case "br":
|
3791 | case "col":
|
3792 | case "embed":
|
3793 | case "hr":
|
3794 | case "img":
|
3795 | case "input":
|
3796 | case "keygen":
|
3797 | case "link":
|
3798 | case "meta":
|
3799 | case "param":
|
3800 | case "source":
|
3801 | case "track":
|
3802 | case "wbr":
|
3803 | break a;
|
3804 | case "body":
|
3805 | if (1 >= ref.insertionMode) {
|
3806 | request.hasBody = !0;
|
3807 | break a;
|
3808 | }
|
3809 | break;
|
3810 | case "html":
|
3811 | if (0 === ref.insertionMode) {
|
3812 | request.hasHtml = !0;
|
3813 | break a;
|
3814 | }
|
3815 | }
|
3816 | keyPath.push(endChunkForTag(type));
|
3817 | }
|
3818 | defaultProps.lastPushedText = !1;
|
3819 | }
|
3820 | task.componentStack = JSCompiler_inline_result;
|
3821 | } else {
|
3822 | switch (type) {
|
3823 | case REACT_LEGACY_HIDDEN_TYPE:
|
3824 | case REACT_DEBUG_TRACING_MODE_TYPE:
|
3825 | case REACT_STRICT_MODE_TYPE:
|
3826 | case REACT_PROFILER_TYPE:
|
3827 | case REACT_FRAGMENT_TYPE:
|
3828 | type = task.keyPath;
|
3829 | task.keyPath = keyPath;
|
3830 | renderNodeDestructive(request, task, props.children, -1);
|
3831 | task.keyPath = type;
|
3832 | return;
|
3833 | case REACT_OFFSCREEN_TYPE:
|
3834 | "hidden" !== props.mode &&
|
3835 | ((type = task.keyPath),
|
3836 | (task.keyPath = keyPath),
|
3837 | renderNodeDestructive(request, task, props.children, -1),
|
3838 | (task.keyPath = type));
|
3839 | return;
|
3840 | case REACT_SUSPENSE_LIST_TYPE:
|
3841 | type = task.componentStack;
|
3842 | task.componentStack = createBuiltInComponentStack(task, "SuspenseList");
|
3843 | JSCompiler_inline_result = task.keyPath;
|
3844 | task.keyPath = keyPath;
|
3845 | renderNodeDestructive(request, task, props.children, -1);
|
3846 | task.keyPath = JSCompiler_inline_result;
|
3847 | task.componentStack = type;
|
3848 | return;
|
3849 | case REACT_SCOPE_TYPE:
|
3850 | throw Error(formatProdErrorMessage(343));
|
3851 | case REACT_SUSPENSE_TYPE:
|
3852 | a: if (null !== task.replay) {
|
3853 | type = task.keyPath;
|
3854 | task.keyPath = keyPath;
|
3855 | keyPath = props.children;
|
3856 | try {
|
3857 | renderNode(request, task, keyPath, -1);
|
3858 | } finally {
|
3859 | task.keyPath = type;
|
3860 | }
|
3861 | } else {
|
3862 | var previousComponentStack = task.componentStack;
|
3863 | type = task.componentStack = createBuiltInComponentStack(
|
3864 | task,
|
3865 | "Suspense"
|
3866 | );
|
3867 | var prevKeyPath = task.keyPath;
|
3868 | ref = task.blockedBoundary;
|
3869 | var parentHoistableState = task.hoistableState,
|
3870 | parentSegment = task.blockedSegment;
|
3871 | propName$31 = props.fallback;
|
3872 | var content = props.children;
|
3873 | props = new Set();
|
3874 | contextType = createSuspenseBoundary(request, props);
|
3875 | null !== request.trackedPostpones &&
|
3876 | (contextType.trackedContentKeyPath = keyPath);
|
3877 | propName = createPendingSegment(
|
3878 | request,
|
3879 | parentSegment.chunks.length,
|
3880 | contextType,
|
3881 | task.formatContext,
|
3882 | !1,
|
3883 | !1
|
3884 | );
|
3885 | parentSegment.children.push(propName);
|
3886 | parentSegment.lastPushedText = !1;
|
3887 | var contentRootSegment = createPendingSegment(
|
3888 | request,
|
3889 | 0,
|
3890 | null,
|
3891 | task.formatContext,
|
3892 | !1,
|
3893 | !1
|
3894 | );
|
3895 | contentRootSegment.parentFlushed = !0;
|
3896 | task.blockedBoundary = contextType;
|
3897 | task.hoistableState = contextType.contentState;
|
3898 | task.blockedSegment = contentRootSegment;
|
3899 | task.keyPath = keyPath;
|
3900 | try {
|
3901 | if (
|
3902 | (renderNode(request, task, content, -1),
|
3903 | request.renderState.generateStaticMarkup ||
|
3904 | (contentRootSegment.lastPushedText &&
|
3905 | contentRootSegment.textEmbedded &&
|
3906 | contentRootSegment.chunks.push("\x3c!-- --\x3e")),
|
3907 | (contentRootSegment.status = 1),
|
3908 | queueCompletedSegment(contextType, contentRootSegment),
|
3909 | 0 === contextType.pendingTasks && 0 === contextType.status)
|
3910 | ) {
|
3911 | contextType.status = 1;
|
3912 | task.componentStack = previousComponentStack;
|
3913 | break a;
|
3914 | }
|
3915 | } catch (error) {
|
3916 | (contentRootSegment.status = 4),
|
3917 | (contextType.status = 4),
|
3918 | (JSCompiler_inline_result = getThrownInfo(
|
3919 | request,
|
3920 | task.componentStack
|
3921 | )),
|
3922 | (defaultProps = logRecoverableError(
|
3923 | request,
|
3924 | error,
|
3925 | JSCompiler_inline_result
|
3926 | )),
|
3927 | (contextType.errorDigest = defaultProps),
|
3928 | untrackBoundary(request, contextType);
|
3929 | } finally {
|
3930 | (task.blockedBoundary = ref),
|
3931 | (task.hoistableState = parentHoistableState),
|
3932 | (task.blockedSegment = parentSegment),
|
3933 | (task.keyPath = prevKeyPath),
|
3934 | (task.componentStack = previousComponentStack);
|
3935 | }
|
3936 | JSCompiler_inline_result = [
|
3937 | keyPath[0],
|
3938 | "Suspense Fallback",
|
3939 | keyPath[2]
|
3940 | ];
|
3941 | defaultProps = request.trackedPostpones;
|
3942 | null !== defaultProps &&
|
3943 | ((previousComponentStack = [
|
3944 | JSCompiler_inline_result[1],
|
3945 | JSCompiler_inline_result[2],
|
3946 | [],
|
3947 | null
|
3948 | ]),
|
3949 | defaultProps.workingMap.set(
|
3950 | JSCompiler_inline_result,
|
3951 | previousComponentStack
|
3952 | ),
|
3953 | 5 === contextType.status
|
3954 | ? (defaultProps.workingMap.get(keyPath)[4] =
|
3955 | previousComponentStack)
|
3956 | : (contextType.trackedFallbackNode = previousComponentStack));
|
3957 | task = createRenderTask(
|
3958 | request,
|
3959 | null,
|
3960 | propName$31,
|
3961 | -1,
|
3962 | ref,
|
3963 | propName,
|
3964 | contextType.fallbackState,
|
3965 | props,
|
3966 | JSCompiler_inline_result,
|
3967 | task.formatContext,
|
3968 | task.legacyContext,
|
3969 | task.context,
|
3970 | task.treeContext,
|
3971 | type,
|
3972 | !0
|
3973 | );
|
3974 | request.pingedTasks.push(task);
|
3975 | }
|
3976 | return;
|
3977 | }
|
3978 | if ("object" === typeof type && null !== type)
|
3979 | switch (type.$$typeof) {
|
3980 | case REACT_FORWARD_REF_TYPE:
|
3981 | JSCompiler_inline_result = task.componentStack;
|
3982 | task.componentStack = {
|
3983 | tag: 1,
|
3984 | parent: task.componentStack,
|
3985 | type: type.render
|
3986 | };
|
3987 | if ("ref" in props)
|
3988 | for (contextType in ((defaultProps = {}), props))
|
3989 | "ref" !== contextType &&
|
3990 | (defaultProps[contextType] = props[contextType]);
|
3991 | else defaultProps = props;
|
3992 | type = renderWithHooks(
|
3993 | request,
|
3994 | task,
|
3995 | keyPath,
|
3996 | type.render,
|
3997 | defaultProps,
|
3998 | ref
|
3999 | );
|
4000 | finishFunctionComponent(
|
4001 | request,
|
4002 | task,
|
4003 | keyPath,
|
4004 | type,
|
4005 | 0 !== localIdCounter,
|
4006 | actionStateCounter,
|
4007 | actionStateMatchingIndex
|
4008 | );
|
4009 | task.componentStack = JSCompiler_inline_result;
|
4010 | return;
|
4011 | case REACT_MEMO_TYPE:
|
4012 | renderElement(request, task, keyPath, type.type, props, ref);
|
4013 | return;
|
4014 | case REACT_PROVIDER_TYPE:
|
4015 | case REACT_CONTEXT_TYPE:
|
4016 | defaultProps = props.children;
|
4017 | JSCompiler_inline_result = task.keyPath;
|
4018 | props = props.value;
|
4019 | ref = type._currentValue2;
|
4020 | type._currentValue2 = props;
|
4021 | propName$31 = currentActiveSnapshot;
|
4022 | currentActiveSnapshot = type = {
|
4023 | parent: propName$31,
|
4024 | depth: null === propName$31 ? 0 : propName$31.depth + 1,
|
4025 | context: type,
|
4026 | parentValue: ref,
|
4027 | value: props
|
4028 | };
|
4029 | task.context = type;
|
4030 | task.keyPath = keyPath;
|
4031 | renderNodeDestructive(request, task, defaultProps, -1);
|
4032 | request = currentActiveSnapshot;
|
4033 | if (null === request) throw Error(formatProdErrorMessage(403));
|
4034 | request.context._currentValue2 = request.parentValue;
|
4035 | request = currentActiveSnapshot = request.parent;
|
4036 | task.context = request;
|
4037 | task.keyPath = JSCompiler_inline_result;
|
4038 | return;
|
4039 | case REACT_CONSUMER_TYPE:
|
4040 | props = props.children;
|
4041 | type = props(type._context._currentValue2);
|
4042 | props = task.keyPath;
|
4043 | task.keyPath = keyPath;
|
4044 | renderNodeDestructive(request, task, type, -1);
|
4045 | task.keyPath = props;
|
4046 | return;
|
4047 | case REACT_LAZY_TYPE:
|
4048 | JSCompiler_inline_result = task.componentStack;
|
4049 | task.componentStack = createBuiltInComponentStack(task, "Lazy");
|
4050 | defaultProps = type._init;
|
4051 | type = defaultProps(type._payload);
|
4052 | renderElement(request, task, keyPath, type, props, void 0);
|
4053 | task.componentStack = JSCompiler_inline_result;
|
4054 | return;
|
4055 | }
|
4056 | throw Error(
|
4057 | formatProdErrorMessage(130, null == type ? type : typeof type, "")
|
4058 | );
|
4059 | }
|
4060 | }
|
4061 | function resumeNode(request, task, segmentId, node, childIndex) {
|
4062 | var prevReplay = task.replay,
|
4063 | blockedBoundary = task.blockedBoundary,
|
4064 | resumedSegment = createPendingSegment(
|
4065 | request,
|
4066 | 0,
|
4067 | null,
|
4068 | task.formatContext,
|
4069 | !1,
|
4070 | !1
|
4071 | );
|
4072 | resumedSegment.id = segmentId;
|
4073 | resumedSegment.parentFlushed = !0;
|
4074 | try {
|
4075 | (task.replay = null),
|
4076 | (task.blockedSegment = resumedSegment),
|
4077 | renderNode(request, task, node, childIndex),
|
4078 | (resumedSegment.status = 1),
|
4079 | null === blockedBoundary
|
4080 | ? (request.completedRootSegment = resumedSegment)
|
4081 | : (queueCompletedSegment(blockedBoundary, resumedSegment),
|
4082 | blockedBoundary.parentFlushed &&
|
4083 | request.partialBoundaries.push(blockedBoundary));
|
4084 | } finally {
|
4085 | (task.replay = prevReplay), (task.blockedSegment = null);
|
4086 | }
|
4087 | }
|
4088 | function renderNodeDestructive(request, task, node$jscomp$0, childIndex) {
|
4089 | if (null !== task.replay && "number" === typeof task.replay.slots)
|
4090 | resumeNode(request, task, task.replay.slots, node$jscomp$0, childIndex);
|
4091 | else if (
|
4092 | ((task.node = node$jscomp$0),
|
4093 | (task.childIndex = childIndex),
|
4094 | null !== node$jscomp$0)
|
4095 | ) {
|
4096 | if ("object" === typeof node$jscomp$0) {
|
4097 | switch (node$jscomp$0.$$typeof) {
|
4098 | case REACT_ELEMENT_TYPE:
|
4099 | var type = node$jscomp$0.type,
|
4100 | key = node$jscomp$0.key,
|
4101 | props = node$jscomp$0.props;
|
4102 | node$jscomp$0 = props.ref;
|
4103 | var ref = void 0 !== node$jscomp$0 ? node$jscomp$0 : null;
|
4104 | var name = getComponentNameFromType(type),
|
4105 | keyOrIndex =
|
4106 | null == key ? (-1 === childIndex ? 0 : childIndex) : key;
|
4107 | key = [task.keyPath, name, keyOrIndex];
|
4108 | if (null !== task.replay)
|
4109 | a: {
|
4110 | var replay = task.replay;
|
4111 | childIndex = replay.nodes;
|
4112 | for (
|
4113 | node$jscomp$0 = 0;
|
4114 | node$jscomp$0 < childIndex.length;
|
4115 | node$jscomp$0++
|
4116 | ) {
|
4117 | var node = childIndex[node$jscomp$0];
|
4118 | if (keyOrIndex === node[1]) {
|
4119 | if (4 === node.length) {
|
4120 | if (null !== name && name !== node[0])
|
4121 | throw Error(formatProdErrorMessage(490, node[0], name));
|
4122 | var childNodes = node[2];
|
4123 | name = node[3];
|
4124 | keyOrIndex = task.node;
|
4125 | task.replay = {
|
4126 | nodes: childNodes,
|
4127 | slots: name,
|
4128 | pendingTasks: 1
|
4129 | };
|
4130 | try {
|
4131 | renderElement(request, task, key, type, props, ref);
|
4132 | if (
|
4133 | 1 === task.replay.pendingTasks &&
|
4134 | 0 < task.replay.nodes.length
|
4135 | )
|
4136 | throw Error(formatProdErrorMessage(488));
|
4137 | task.replay.pendingTasks--;
|
4138 | } catch (x) {
|
4139 | if (
|
4140 | "object" === typeof x &&
|
4141 | null !== x &&
|
4142 | (x === SuspenseException ||
|
4143 | "function" === typeof x.then)
|
4144 | )
|
4145 | throw (
|
4146 | (task.node === keyOrIndex && (task.replay = replay),
|
4147 | x)
|
4148 | );
|
4149 | task.replay.pendingTasks--;
|
4150 | props = getThrownInfo(request, task.componentStack);
|
4151 | key = request;
|
4152 | request = task.blockedBoundary;
|
4153 | type = x;
|
4154 | props = logRecoverableError(key, type, props);
|
4155 | abortRemainingReplayNodes(
|
4156 | key,
|
4157 | request,
|
4158 | childNodes,
|
4159 | name,
|
4160 | type,
|
4161 | props
|
4162 | );
|
4163 | }
|
4164 | task.replay = replay;
|
4165 | } else {
|
4166 | if (type !== REACT_SUSPENSE_TYPE)
|
4167 | throw Error(
|
4168 | formatProdErrorMessage(
|
4169 | 490,
|
4170 | "Suspense",
|
4171 | getComponentNameFromType(type) || "Unknown"
|
4172 | )
|
4173 | );
|
4174 | b: {
|
4175 | replay = void 0;
|
4176 | type = node[5];
|
4177 | ref = node[2];
|
4178 | name = node[3];
|
4179 | keyOrIndex = null === node[4] ? [] : node[4][2];
|
4180 | node = null === node[4] ? null : node[4][3];
|
4181 | var previousComponentStack = task.componentStack,
|
4182 | suspenseComponentStack = (task.componentStack =
|
4183 | createBuiltInComponentStack(task, "Suspense")),
|
4184 | prevKeyPath = task.keyPath,
|
4185 | previousReplaySet = task.replay,
|
4186 | parentBoundary = task.blockedBoundary,
|
4187 | parentHoistableState = task.hoistableState,
|
4188 | content = props.children;
|
4189 | props = props.fallback;
|
4190 | var fallbackAbortSet = new Set(),
|
4191 | resumedBoundary = createSuspenseBoundary(
|
4192 | request,
|
4193 | fallbackAbortSet
|
4194 | );
|
4195 | resumedBoundary.parentFlushed = !0;
|
4196 | resumedBoundary.rootSegmentID = type;
|
4197 | task.blockedBoundary = resumedBoundary;
|
4198 | task.hoistableState = resumedBoundary.contentState;
|
4199 | task.replay = {
|
4200 | nodes: ref,
|
4201 | slots: name,
|
4202 | pendingTasks: 1
|
4203 | };
|
4204 | try {
|
4205 | renderNode(request, task, content, -1);
|
4206 | if (
|
4207 | 1 === task.replay.pendingTasks &&
|
4208 | 0 < task.replay.nodes.length
|
4209 | )
|
4210 | throw Error(formatProdErrorMessage(488));
|
4211 | task.replay.pendingTasks--;
|
4212 | if (
|
4213 | 0 === resumedBoundary.pendingTasks &&
|
4214 | 0 === resumedBoundary.status
|
4215 | ) {
|
4216 | resumedBoundary.status = 1;
|
4217 | request.completedBoundaries.push(resumedBoundary);
|
4218 | break b;
|
4219 | }
|
4220 | } catch (error) {
|
4221 | (resumedBoundary.status = 4),
|
4222 | (childNodes = getThrownInfo(
|
4223 | request,
|
4224 | task.componentStack
|
4225 | )),
|
4226 | (replay = logRecoverableError(
|
4227 | request,
|
4228 | error,
|
4229 | childNodes
|
4230 | )),
|
4231 | (resumedBoundary.errorDigest = replay),
|
4232 | task.replay.pendingTasks--,
|
4233 | request.clientRenderedBoundaries.push(
|
4234 | resumedBoundary
|
4235 | );
|
4236 | } finally {
|
4237 | (task.blockedBoundary = parentBoundary),
|
4238 | (task.hoistableState = parentHoistableState),
|
4239 | (task.replay = previousReplaySet),
|
4240 | (task.keyPath = prevKeyPath),
|
4241 | (task.componentStack = previousComponentStack);
|
4242 | }
|
4243 | task = createReplayTask(
|
4244 | request,
|
4245 | null,
|
4246 | { nodes: keyOrIndex, slots: node, pendingTasks: 0 },
|
4247 | props,
|
4248 | -1,
|
4249 | parentBoundary,
|
4250 | resumedBoundary.fallbackState,
|
4251 | fallbackAbortSet,
|
4252 | [key[0], "Suspense Fallback", key[2]],
|
4253 | task.formatContext,
|
4254 | task.legacyContext,
|
4255 | task.context,
|
4256 | task.treeContext,
|
4257 | suspenseComponentStack,
|
4258 | !0
|
4259 | );
|
4260 | request.pingedTasks.push(task);
|
4261 | }
|
4262 | }
|
4263 | childIndex.splice(node$jscomp$0, 1);
|
4264 | break a;
|
4265 | }
|
4266 | }
|
4267 | }
|
4268 | else renderElement(request, task, key, type, props, ref);
|
4269 | return;
|
4270 | case REACT_PORTAL_TYPE:
|
4271 | throw Error(formatProdErrorMessage(257));
|
4272 | case REACT_LAZY_TYPE:
|
4273 | childNodes = task.componentStack;
|
4274 | task.componentStack = createBuiltInComponentStack(task, "Lazy");
|
4275 | props = node$jscomp$0._init;
|
4276 | node$jscomp$0 = props(node$jscomp$0._payload);
|
4277 | task.componentStack = childNodes;
|
4278 | renderNodeDestructive(request, task, node$jscomp$0, childIndex);
|
4279 | return;
|
4280 | }
|
4281 | if (isArrayImpl(node$jscomp$0)) {
|
4282 | renderChildrenArray(request, task, node$jscomp$0, childIndex);
|
4283 | return;
|
4284 | }
|
4285 | null === node$jscomp$0 || "object" !== typeof node$jscomp$0
|
4286 | ? (childNodes = null)
|
4287 | : ((childNodes =
|
4288 | (MAYBE_ITERATOR_SYMBOL && node$jscomp$0[MAYBE_ITERATOR_SYMBOL]) ||
|
4289 | node$jscomp$0["@@iterator"]),
|
4290 | (childNodes = "function" === typeof childNodes ? childNodes : null));
|
4291 | if (childNodes && (childNodes = childNodes.call(node$jscomp$0))) {
|
4292 | node$jscomp$0 = childNodes.next();
|
4293 | if (!node$jscomp$0.done) {
|
4294 | props = [];
|
4295 | do
|
4296 | props.push(node$jscomp$0.value),
|
4297 | (node$jscomp$0 = childNodes.next());
|
4298 | while (!node$jscomp$0.done);
|
4299 | renderChildrenArray(request, task, props, childIndex);
|
4300 | }
|
4301 | return;
|
4302 | }
|
4303 | if ("function" === typeof node$jscomp$0.then)
|
4304 | return (
|
4305 | (task.thenableState = null),
|
4306 | renderNodeDestructive(
|
4307 | request,
|
4308 | task,
|
4309 | unwrapThenable(node$jscomp$0),
|
4310 | childIndex
|
4311 | )
|
4312 | );
|
4313 | if (node$jscomp$0.$$typeof === REACT_CONTEXT_TYPE)
|
4314 | return renderNodeDestructive(
|
4315 | request,
|
4316 | task,
|
4317 | node$jscomp$0._currentValue2,
|
4318 | childIndex
|
4319 | );
|
4320 | childIndex = Object.prototype.toString.call(node$jscomp$0);
|
4321 | throw Error(
|
4322 | formatProdErrorMessage(
|
4323 | 31,
|
4324 | "[object Object]" === childIndex
|
4325 | ? "object with keys {" + Object.keys(node$jscomp$0).join(", ") + "}"
|
4326 | : childIndex
|
4327 | )
|
4328 | );
|
4329 | }
|
4330 | if ("string" === typeof node$jscomp$0)
|
4331 | (childIndex = task.blockedSegment),
|
4332 | null !== childIndex &&
|
4333 | (childIndex.lastPushedText = pushTextInstance(
|
4334 | childIndex.chunks,
|
4335 | node$jscomp$0,
|
4336 | request.renderState,
|
4337 | childIndex.lastPushedText
|
4338 | ));
|
4339 | else if (
|
4340 | "number" === typeof node$jscomp$0 ||
|
4341 | "bigint" === typeof node$jscomp$0
|
4342 | )
|
4343 | (childIndex = task.blockedSegment),
|
4344 | null !== childIndex &&
|
4345 | (childIndex.lastPushedText = pushTextInstance(
|
4346 | childIndex.chunks,
|
4347 | "" + node$jscomp$0,
|
4348 | request.renderState,
|
4349 | childIndex.lastPushedText
|
4350 | ));
|
4351 | }
|
4352 | }
|
4353 | function renderChildrenArray(request, task, children, childIndex) {
|
4354 | var prevKeyPath = task.keyPath;
|
4355 | if (
|
4356 | -1 !== childIndex &&
|
4357 | ((task.keyPath = [task.keyPath, "Fragment", childIndex]),
|
4358 | null !== task.replay)
|
4359 | ) {
|
4360 | for (
|
4361 | var replay = task.replay, replayNodes = replay.nodes, j = 0;
|
4362 | j < replayNodes.length;
|
4363 | j++
|
4364 | ) {
|
4365 | var node = replayNodes[j];
|
4366 | if (node[1] === childIndex) {
|
4367 | childIndex = node[2];
|
4368 | node = node[3];
|
4369 | task.replay = { nodes: childIndex, slots: node, pendingTasks: 1 };
|
4370 | try {
|
4371 | renderChildrenArray(request, task, children, -1);
|
4372 | if (1 === task.replay.pendingTasks && 0 < task.replay.nodes.length)
|
4373 | throw Error(formatProdErrorMessage(488));
|
4374 | task.replay.pendingTasks--;
|
4375 | } catch (x) {
|
4376 | if (
|
4377 | "object" === typeof x &&
|
4378 | null !== x &&
|
4379 | (x === SuspenseException || "function" === typeof x.then)
|
4380 | )
|
4381 | throw x;
|
4382 | task.replay.pendingTasks--;
|
4383 | children = getThrownInfo(request, task.componentStack);
|
4384 | var boundary = task.blockedBoundary,
|
4385 | error = x;
|
4386 | children = logRecoverableError(request, error, children);
|
4387 | abortRemainingReplayNodes(
|
4388 | request,
|
4389 | boundary,
|
4390 | childIndex,
|
4391 | node,
|
4392 | error,
|
4393 | children
|
4394 | );
|
4395 | }
|
4396 | task.replay = replay;
|
4397 | replayNodes.splice(j, 1);
|
4398 | break;
|
4399 | }
|
4400 | }
|
4401 | task.keyPath = prevKeyPath;
|
4402 | return;
|
4403 | }
|
4404 | replay = task.treeContext;
|
4405 | replayNodes = children.length;
|
4406 | if (
|
4407 | null !== task.replay &&
|
4408 | ((j = task.replay.slots), null !== j && "object" === typeof j)
|
4409 | ) {
|
4410 | for (childIndex = 0; childIndex < replayNodes; childIndex++)
|
4411 | (node = children[childIndex]),
|
4412 | (task.treeContext = pushTreeContext(replay, replayNodes, childIndex)),
|
4413 | (boundary = j[childIndex]),
|
4414 | "number" === typeof boundary
|
4415 | ? (resumeNode(request, task, boundary, node, childIndex),
|
4416 | delete j[childIndex])
|
4417 | : renderNode(request, task, node, childIndex);
|
4418 | task.treeContext = replay;
|
4419 | task.keyPath = prevKeyPath;
|
4420 | return;
|
4421 | }
|
4422 | for (j = 0; j < replayNodes; j++)
|
4423 | (childIndex = children[j]),
|
4424 | (task.treeContext = pushTreeContext(replay, replayNodes, j)),
|
4425 | renderNode(request, task, childIndex, j);
|
4426 | task.treeContext = replay;
|
4427 | task.keyPath = prevKeyPath;
|
4428 | }
|
4429 | function untrackBoundary(request, boundary) {
|
4430 | request = request.trackedPostpones;
|
4431 | null !== request &&
|
4432 | ((boundary = boundary.trackedContentKeyPath),
|
4433 | null !== boundary &&
|
4434 | ((boundary = request.workingMap.get(boundary)),
|
4435 | void 0 !== boundary &&
|
4436 | ((boundary.length = 4), (boundary[2] = []), (boundary[3] = null))));
|
4437 | }
|
4438 | function renderNode(request, task, node, childIndex) {
|
4439 | var previousFormatContext = task.formatContext,
|
4440 | previousLegacyContext = task.legacyContext,
|
4441 | previousContext = task.context,
|
4442 | previousKeyPath = task.keyPath,
|
4443 | previousTreeContext = task.treeContext,
|
4444 | previousComponentStack = task.componentStack,
|
4445 | segment = task.blockedSegment;
|
4446 | if (null === segment)
|
4447 | try {
|
4448 | return renderNodeDestructive(request, task, node, childIndex);
|
4449 | } catch (thrownValue) {
|
4450 | if (
|
4451 | (resetHooksState(),
|
4452 | (node =
|
4453 | thrownValue === SuspenseException
|
4454 | ? getSuspendedThenable()
|
4455 | : thrownValue),
|
4456 | "object" === typeof node &&
|
4457 | null !== node &&
|
4458 | "function" === typeof node.then)
|
4459 | ) {
|
4460 | childIndex = getThenableStateAfterSuspending();
|
4461 | request = createReplayTask(
|
4462 | request,
|
4463 | childIndex,
|
4464 | task.replay,
|
4465 | task.node,
|
4466 | task.childIndex,
|
4467 | task.blockedBoundary,
|
4468 | task.hoistableState,
|
4469 | task.abortSet,
|
4470 | task.keyPath,
|
4471 | task.formatContext,
|
4472 | task.legacyContext,
|
4473 | task.context,
|
4474 | task.treeContext,
|
4475 | null !== task.componentStack ? task.componentStack.parent : null,
|
4476 | task.isFallback
|
4477 | ).ping;
|
4478 | node.then(request, request);
|
4479 | task.formatContext = previousFormatContext;
|
4480 | task.legacyContext = previousLegacyContext;
|
4481 | task.context = previousContext;
|
4482 | task.keyPath = previousKeyPath;
|
4483 | task.treeContext = previousTreeContext;
|
4484 | task.componentStack = previousComponentStack;
|
4485 | switchContext(previousContext);
|
4486 | return;
|
4487 | }
|
4488 | }
|
4489 | else {
|
4490 | var childrenLength = segment.children.length,
|
4491 | chunkLength = segment.chunks.length;
|
4492 | try {
|
4493 | return renderNodeDestructive(request, task, node, childIndex);
|
4494 | } catch (thrownValue$40) {
|
4495 | if (
|
4496 | (resetHooksState(),
|
4497 | (segment.children.length = childrenLength),
|
4498 | (segment.chunks.length = chunkLength),
|
4499 | (node =
|
4500 | thrownValue$40 === SuspenseException
|
4501 | ? getSuspendedThenable()
|
4502 | : thrownValue$40),
|
4503 | "object" === typeof node &&
|
4504 | null !== node &&
|
4505 | "function" === typeof node.then)
|
4506 | ) {
|
4507 | childIndex = getThenableStateAfterSuspending();
|
4508 | segment = task.blockedSegment;
|
4509 | childrenLength = createPendingSegment(
|
4510 | request,
|
4511 | segment.chunks.length,
|
4512 | null,
|
4513 | task.formatContext,
|
4514 | segment.lastPushedText,
|
4515 | !0
|
4516 | );
|
4517 | segment.children.push(childrenLength);
|
4518 | segment.lastPushedText = !1;
|
4519 | request = createRenderTask(
|
4520 | request,
|
4521 | childIndex,
|
4522 | task.node,
|
4523 | task.childIndex,
|
4524 | task.blockedBoundary,
|
4525 | childrenLength,
|
4526 | task.hoistableState,
|
4527 | task.abortSet,
|
4528 | task.keyPath,
|
4529 | task.formatContext,
|
4530 | task.legacyContext,
|
4531 | task.context,
|
4532 | task.treeContext,
|
4533 | null !== task.componentStack ? task.componentStack.parent : null,
|
4534 | task.isFallback
|
4535 | ).ping;
|
4536 | node.then(request, request);
|
4537 | task.formatContext = previousFormatContext;
|
4538 | task.legacyContext = previousLegacyContext;
|
4539 | task.context = previousContext;
|
4540 | task.keyPath = previousKeyPath;
|
4541 | task.treeContext = previousTreeContext;
|
4542 | task.componentStack = previousComponentStack;
|
4543 | switchContext(previousContext);
|
4544 | return;
|
4545 | }
|
4546 | }
|
4547 | }
|
4548 | task.formatContext = previousFormatContext;
|
4549 | task.legacyContext = previousLegacyContext;
|
4550 | task.context = previousContext;
|
4551 | task.keyPath = previousKeyPath;
|
4552 | task.treeContext = previousTreeContext;
|
4553 | switchContext(previousContext);
|
4554 | throw node;
|
4555 | }
|
4556 | function abortTaskSoft(task) {
|
4557 | var boundary = task.blockedBoundary;
|
4558 | task = task.blockedSegment;
|
4559 | null !== task && ((task.status = 3), finishedTask(this, boundary, task));
|
4560 | }
|
4561 | function abortRemainingReplayNodes(
|
4562 | request$jscomp$0,
|
4563 | boundary,
|
4564 | nodes,
|
4565 | slots,
|
4566 | error,
|
4567 | errorDigest$jscomp$0
|
4568 | ) {
|
4569 | for (var i = 0; i < nodes.length; i++) {
|
4570 | var node = nodes[i];
|
4571 | if (4 === node.length)
|
4572 | abortRemainingReplayNodes(
|
4573 | request$jscomp$0,
|
4574 | boundary,
|
4575 | node[2],
|
4576 | node[3],
|
4577 | error,
|
4578 | errorDigest$jscomp$0
|
4579 | );
|
4580 | else {
|
4581 | node = node[5];
|
4582 | var request = request$jscomp$0,
|
4583 | errorDigest = errorDigest$jscomp$0,
|
4584 | resumedBoundary = createSuspenseBoundary(request, new Set());
|
4585 | resumedBoundary.parentFlushed = !0;
|
4586 | resumedBoundary.rootSegmentID = node;
|
4587 | resumedBoundary.status = 4;
|
4588 | resumedBoundary.errorDigest = errorDigest;
|
4589 | resumedBoundary.parentFlushed &&
|
4590 | request.clientRenderedBoundaries.push(resumedBoundary);
|
4591 | }
|
4592 | }
|
4593 | nodes.length = 0;
|
4594 | if (null !== slots) {
|
4595 | if (null === boundary) throw Error(formatProdErrorMessage(487));
|
4596 | 4 !== boundary.status &&
|
4597 | ((boundary.status = 4),
|
4598 | (boundary.errorDigest = errorDigest$jscomp$0),
|
4599 | boundary.parentFlushed &&
|
4600 | request$jscomp$0.clientRenderedBoundaries.push(boundary));
|
4601 | if ("object" === typeof slots) for (var index in slots) delete slots[index];
|
4602 | }
|
4603 | }
|
4604 | function abortTask(task, request, error) {
|
4605 | var boundary = task.blockedBoundary,
|
4606 | segment = task.blockedSegment;
|
4607 | null !== segment && (segment.status = 3);
|
4608 | if (null === boundary) {
|
4609 | if (((boundary = {}), 1 !== request.status && 2 !== request.status)) {
|
4610 | task = task.replay;
|
4611 | if (null === task) {
|
4612 | logRecoverableError(request, error, boundary);
|
4613 | fatalError(request, error);
|
4614 | return;
|
4615 | }
|
4616 | task.pendingTasks--;
|
4617 | 0 === task.pendingTasks &&
|
4618 | 0 < task.nodes.length &&
|
4619 | ((boundary = logRecoverableError(request, error, boundary)),
|
4620 | abortRemainingReplayNodes(
|
4621 | request,
|
4622 | null,
|
4623 | task.nodes,
|
4624 | task.slots,
|
4625 | error,
|
4626 | boundary
|
4627 | ));
|
4628 | request.pendingRootTasks--;
|
4629 | 0 === request.pendingRootTasks && completeShell(request);
|
4630 | }
|
4631 | } else
|
4632 | boundary.pendingTasks--,
|
4633 | 4 !== boundary.status &&
|
4634 | ((boundary.status = 4),
|
4635 | (task = getThrownInfo(request, task.componentStack)),
|
4636 | (task = logRecoverableError(request, error, task)),
|
4637 | (boundary.errorDigest = task),
|
4638 | untrackBoundary(request, boundary),
|
4639 | boundary.parentFlushed &&
|
4640 | request.clientRenderedBoundaries.push(boundary)),
|
4641 | boundary.fallbackAbortableTasks.forEach(function (fallbackTask) {
|
4642 | return abortTask(fallbackTask, request, error);
|
4643 | }),
|
4644 | boundary.fallbackAbortableTasks.clear();
|
4645 | request.allPendingTasks--;
|
4646 | 0 === request.allPendingTasks && completeAll(request);
|
4647 | }
|
4648 | function safelyEmitEarlyPreloads(request, shellComplete) {
|
4649 | try {
|
4650 | var renderState = request.renderState,
|
4651 | onHeaders = renderState.onHeaders;
|
4652 | if (onHeaders) {
|
4653 | var headers = renderState.headers;
|
4654 | if (headers) {
|
4655 | renderState.headers = null;
|
4656 | var linkHeader = headers.preconnects;
|
4657 | headers.fontPreloads &&
|
4658 | (linkHeader && (linkHeader += ", "),
|
4659 | (linkHeader += headers.fontPreloads));
|
4660 | headers.highImagePreloads &&
|
4661 | (linkHeader && (linkHeader += ", "),
|
4662 | (linkHeader += headers.highImagePreloads));
|
4663 | if (!shellComplete) {
|
4664 | var queueIter = renderState.styles.values(),
|
4665 | queueStep = queueIter.next();
|
4666 | b: for (
|
4667 | ;
|
4668 | 0 < headers.remainingCapacity && !queueStep.done;
|
4669 | queueStep = queueIter.next()
|
4670 | )
|
4671 | for (
|
4672 | var sheetIter = queueStep.value.sheets.values(),
|
4673 | sheetStep = sheetIter.next();
|
4674 | 0 < headers.remainingCapacity && !sheetStep.done;
|
4675 | sheetStep = sheetIter.next()
|
4676 | ) {
|
4677 | var sheet = sheetStep.value,
|
4678 | props = sheet.props,
|
4679 | key = props.href,
|
4680 | props$jscomp$0 = sheet.props,
|
4681 | header = getPreloadAsHeader(props$jscomp$0.href, "style", {
|
4682 | crossOrigin: props$jscomp$0.crossOrigin,
|
4683 | integrity: props$jscomp$0.integrity,
|
4684 | nonce: props$jscomp$0.nonce,
|
4685 | type: props$jscomp$0.type,
|
4686 | fetchPriority: props$jscomp$0.fetchPriority,
|
4687 | referrerPolicy: props$jscomp$0.referrerPolicy,
|
4688 | media: props$jscomp$0.media
|
4689 | });
|
4690 | if (2 <= (headers.remainingCapacity -= header.length))
|
4691 | (renderState.resets.style[key] = PRELOAD_NO_CREDS),
|
4692 | linkHeader && (linkHeader += ", "),
|
4693 | (linkHeader += header),
|
4694 | (renderState.resets.style[key] =
|
4695 | "string" === typeof props.crossOrigin ||
|
4696 | "string" === typeof props.integrity
|
4697 | ? [props.crossOrigin, props.integrity]
|
4698 | : PRELOAD_NO_CREDS);
|
4699 | else break b;
|
4700 | }
|
4701 | }
|
4702 | linkHeader ? onHeaders({ Link: linkHeader }) : onHeaders({});
|
4703 | }
|
4704 | }
|
4705 | } catch (error) {
|
4706 | logRecoverableError(request, error, {});
|
4707 | }
|
4708 | }
|
4709 | function completeShell(request) {
|
4710 | null === request.trackedPostpones && safelyEmitEarlyPreloads(request, !0);
|
4711 | request.onShellError = noop;
|
4712 | request = request.onShellReady;
|
4713 | request();
|
4714 | }
|
4715 | function completeAll(request) {
|
4716 | safelyEmitEarlyPreloads(
|
4717 | request,
|
4718 | null === request.trackedPostpones
|
4719 | ? !0
|
4720 | : null === request.completedRootSegment ||
|
4721 | 5 !== request.completedRootSegment.status
|
4722 | );
|
4723 | request = request.onAllReady;
|
4724 | request();
|
4725 | }
|
4726 | function queueCompletedSegment(boundary, segment) {
|
4727 | if (
|
4728 | 0 === segment.chunks.length &&
|
4729 | 1 === segment.children.length &&
|
4730 | null === segment.children[0].boundary &&
|
4731 | -1 === segment.children[0].id
|
4732 | ) {
|
4733 | var childSegment = segment.children[0];
|
4734 | childSegment.id = segment.id;
|
4735 | childSegment.parentFlushed = !0;
|
4736 | 1 === childSegment.status && queueCompletedSegment(boundary, childSegment);
|
4737 | } else boundary.completedSegments.push(segment);
|
4738 | }
|
4739 | function finishedTask(request, boundary, segment) {
|
4740 | if (null === boundary) {
|
4741 | if (null !== segment && segment.parentFlushed) {
|
4742 | if (null !== request.completedRootSegment)
|
4743 | throw Error(formatProdErrorMessage(389));
|
4744 | request.completedRootSegment = segment;
|
4745 | }
|
4746 | request.pendingRootTasks--;
|
4747 | 0 === request.pendingRootTasks && completeShell(request);
|
4748 | } else
|
4749 | boundary.pendingTasks--,
|
4750 | 4 !== boundary.status &&
|
4751 | (0 === boundary.pendingTasks
|
4752 | ? (0 === boundary.status && (boundary.status = 1),
|
4753 | null !== segment &&
|
4754 | segment.parentFlushed &&
|
4755 | 1 === segment.status &&
|
4756 | queueCompletedSegment(boundary, segment),
|
4757 | boundary.parentFlushed &&
|
4758 | request.completedBoundaries.push(boundary),
|
4759 | 1 === boundary.status &&
|
4760 | (boundary.fallbackAbortableTasks.forEach(abortTaskSoft, request),
|
4761 | boundary.fallbackAbortableTasks.clear()))
|
4762 | : null !== segment &&
|
4763 | segment.parentFlushed &&
|
4764 | 1 === segment.status &&
|
4765 | (queueCompletedSegment(boundary, segment),
|
4766 | 1 === boundary.completedSegments.length &&
|
4767 | boundary.parentFlushed &&
|
4768 | request.partialBoundaries.push(boundary)));
|
4769 | request.allPendingTasks--;
|
4770 | 0 === request.allPendingTasks && completeAll(request);
|
4771 | }
|
4772 | function performWork(request$jscomp$2) {
|
4773 | if (2 !== request$jscomp$2.status) {
|
4774 | var prevContext = currentActiveSnapshot,
|
4775 | prevDispatcher = ReactSharedInternals.H;
|
4776 | ReactSharedInternals.H = HooksDispatcher;
|
4777 | var prevAsyncDispatcher = ReactSharedInternals.A;
|
4778 | ReactSharedInternals.A = DefaultAsyncDispatcher;
|
4779 | var prevRequest = currentRequest;
|
4780 | currentRequest = request$jscomp$2;
|
4781 | var prevResumableState = currentResumableState;
|
4782 | currentResumableState = request$jscomp$2.resumableState;
|
4783 | try {
|
4784 | var pingedTasks = request$jscomp$2.pingedTasks,
|
4785 | i;
|
4786 | for (i = 0; i < pingedTasks.length; i++) {
|
4787 | var task = pingedTasks[i],
|
4788 | request = request$jscomp$2,
|
4789 | segment = task.blockedSegment;
|
4790 | if (null === segment) {
|
4791 | var request$jscomp$0 = request;
|
4792 | if (0 !== task.replay.pendingTasks) {
|
4793 | switchContext(task.context);
|
4794 | try {
|
4795 | renderNodeDestructive(
|
4796 | request$jscomp$0,
|
4797 | task,
|
4798 | task.node,
|
4799 | task.childIndex
|
4800 | );
|
4801 | if (
|
4802 | 1 === task.replay.pendingTasks &&
|
4803 | 0 < task.replay.nodes.length
|
4804 | )
|
4805 | throw Error(formatProdErrorMessage(488));
|
4806 | task.replay.pendingTasks--;
|
4807 | task.abortSet.delete(task);
|
4808 | finishedTask(request$jscomp$0, task.blockedBoundary, null);
|
4809 | } catch (thrownValue) {
|
4810 | resetHooksState();
|
4811 | var x =
|
4812 | thrownValue === SuspenseException
|
4813 | ? getSuspendedThenable()
|
4814 | : thrownValue;
|
4815 | if (
|
4816 | "object" === typeof x &&
|
4817 | null !== x &&
|
4818 | "function" === typeof x.then
|
4819 | ) {
|
4820 | var ping = task.ping;
|
4821 | x.then(ping, ping);
|
4822 | task.thenableState = getThenableStateAfterSuspending();
|
4823 | null !== task.componentStack &&
|
4824 | (task.componentStack = task.componentStack.parent);
|
4825 | } else {
|
4826 | task.replay.pendingTasks--;
|
4827 | task.abortSet.delete(task);
|
4828 | var errorInfo = getThrownInfo(
|
4829 | request$jscomp$0,
|
4830 | task.componentStack
|
4831 | );
|
4832 | request = void 0;
|
4833 | var request$jscomp$1 = request$jscomp$0,
|
4834 | boundary = task.blockedBoundary,
|
4835 | error$jscomp$0 = x,
|
4836 | replayNodes = task.replay.nodes,
|
4837 | resumeSlots = task.replay.slots;
|
4838 | request = logRecoverableError(
|
4839 | request$jscomp$1,
|
4840 | error$jscomp$0,
|
4841 | errorInfo
|
4842 | );
|
4843 | abortRemainingReplayNodes(
|
4844 | request$jscomp$1,
|
4845 | boundary,
|
4846 | replayNodes,
|
4847 | resumeSlots,
|
4848 | error$jscomp$0,
|
4849 | request
|
4850 | );
|
4851 | request$jscomp$0.pendingRootTasks--;
|
4852 | 0 === request$jscomp$0.pendingRootTasks &&
|
4853 | completeShell(request$jscomp$0);
|
4854 | request$jscomp$0.allPendingTasks--;
|
4855 | 0 === request$jscomp$0.allPendingTasks &&
|
4856 | completeAll(request$jscomp$0);
|
4857 | }
|
4858 | } finally {
|
4859 | }
|
4860 | }
|
4861 | } else if (
|
4862 | ((request$jscomp$0 = void 0),
|
4863 | (request$jscomp$1 = segment),
|
4864 | 0 === request$jscomp$1.status)
|
4865 | ) {
|
4866 | switchContext(task.context);
|
4867 | var childrenLength = request$jscomp$1.children.length,
|
4868 | chunkLength = request$jscomp$1.chunks.length;
|
4869 | try {
|
4870 | renderNodeDestructive(request, task, task.node, task.childIndex),
|
4871 | request.renderState.generateStaticMarkup ||
|
4872 | (request$jscomp$1.lastPushedText &&
|
4873 | request$jscomp$1.textEmbedded &&
|
4874 | request$jscomp$1.chunks.push("\x3c!-- --\x3e")),
|
4875 | task.abortSet.delete(task),
|
4876 | (request$jscomp$1.status = 1),
|
4877 | finishedTask(request, task.blockedBoundary, request$jscomp$1);
|
4878 | } catch (thrownValue) {
|
4879 | resetHooksState();
|
4880 | request$jscomp$1.children.length = childrenLength;
|
4881 | request$jscomp$1.chunks.length = chunkLength;
|
4882 | var x$jscomp$0 =
|
4883 | thrownValue === SuspenseException
|
4884 | ? getSuspendedThenable()
|
4885 | : thrownValue;
|
4886 | if (
|
4887 | "object" === typeof x$jscomp$0 &&
|
4888 | null !== x$jscomp$0 &&
|
4889 | "function" === typeof x$jscomp$0.then
|
4890 | ) {
|
4891 | var ping$jscomp$0 = task.ping;
|
4892 | x$jscomp$0.then(ping$jscomp$0, ping$jscomp$0);
|
4893 | task.thenableState = getThenableStateAfterSuspending();
|
4894 | null !== task.componentStack &&
|
4895 | (task.componentStack = task.componentStack.parent);
|
4896 | } else {
|
4897 | var errorInfo$jscomp$0 = getThrownInfo(
|
4898 | request,
|
4899 | task.componentStack
|
4900 | );
|
4901 | task.abortSet.delete(task);
|
4902 | request$jscomp$1.status = 4;
|
4903 | var boundary$jscomp$0 = task.blockedBoundary;
|
4904 | request$jscomp$0 = logRecoverableError(
|
4905 | request,
|
4906 | x$jscomp$0,
|
4907 | errorInfo$jscomp$0
|
4908 | );
|
4909 | null === boundary$jscomp$0
|
4910 | ? fatalError(request, x$jscomp$0)
|
4911 | : (boundary$jscomp$0.pendingTasks--,
|
4912 | 4 !== boundary$jscomp$0.status &&
|
4913 | ((boundary$jscomp$0.status = 4),
|
4914 | (boundary$jscomp$0.errorDigest = request$jscomp$0),
|
4915 | untrackBoundary(request, boundary$jscomp$0),
|
4916 | boundary$jscomp$0.parentFlushed &&
|
4917 | request.clientRenderedBoundaries.push(
|
4918 | boundary$jscomp$0
|
4919 | )));
|
4920 | request.allPendingTasks--;
|
4921 | 0 === request.allPendingTasks && completeAll(request);
|
4922 | }
|
4923 | } finally {
|
4924 | }
|
4925 | }
|
4926 | }
|
4927 | pingedTasks.splice(0, i);
|
4928 | null !== request$jscomp$2.destination &&
|
4929 | flushCompletedQueues(request$jscomp$2, request$jscomp$2.destination);
|
4930 | } catch (error) {
|
4931 | logRecoverableError(request$jscomp$2, error, {}),
|
4932 | fatalError(request$jscomp$2, error);
|
4933 | } finally {
|
4934 | (currentResumableState = prevResumableState),
|
4935 | (ReactSharedInternals.H = prevDispatcher),
|
4936 | (ReactSharedInternals.A = prevAsyncDispatcher),
|
4937 | prevDispatcher === HooksDispatcher && switchContext(prevContext),
|
4938 | (currentRequest = prevRequest);
|
4939 | }
|
4940 | }
|
4941 | }
|
4942 | function flushSubtree(request, destination, segment, hoistableState) {
|
4943 | segment.parentFlushed = !0;
|
4944 | switch (segment.status) {
|
4945 | case 0:
|
4946 | segment.id = request.nextSegmentId++;
|
4947 | case 5:
|
4948 | return (
|
4949 | (hoistableState = segment.id),
|
4950 | (segment.lastPushedText = !1),
|
4951 | (segment.textEmbedded = !1),
|
4952 | (request = request.renderState),
|
4953 | destination.push('<template id="'),
|
4954 | destination.push(request.placeholderPrefix),
|
4955 | (request = hoistableState.toString(16)),
|
4956 | destination.push(request),
|
4957 | destination.push('"></template>')
|
4958 | );
|
4959 | case 1:
|
4960 | segment.status = 2;
|
4961 | var r = !0,
|
4962 | chunks = segment.chunks,
|
4963 | chunkIdx = 0;
|
4964 | segment = segment.children;
|
4965 | for (var childIdx = 0; childIdx < segment.length; childIdx++) {
|
4966 | for (r = segment[childIdx]; chunkIdx < r.index; chunkIdx++)
|
4967 | destination.push(chunks[chunkIdx]);
|
4968 | r = flushSegment(request, destination, r, hoistableState);
|
4969 | }
|
4970 | for (; chunkIdx < chunks.length - 1; chunkIdx++)
|
4971 | destination.push(chunks[chunkIdx]);
|
4972 | chunkIdx < chunks.length && (r = destination.push(chunks[chunkIdx]));
|
4973 | return r;
|
4974 | default:
|
4975 | throw Error(formatProdErrorMessage(390));
|
4976 | }
|
4977 | }
|
4978 | function flushSegment(request, destination, segment, hoistableState) {
|
4979 | var boundary = segment.boundary;
|
4980 | if (null === boundary)
|
4981 | return flushSubtree(request, destination, segment, hoistableState);
|
4982 | boundary.parentFlushed = !0;
|
4983 | if (4 === boundary.status)
|
4984 | return (
|
4985 | request.renderState.generateStaticMarkup ||
|
4986 | ((boundary = boundary.errorDigest),
|
4987 | destination.push("\x3c!--$!--\x3e"),
|
4988 | destination.push("<template"),
|
4989 | boundary &&
|
4990 | (destination.push(' data-dgst="'),
|
4991 | (boundary = escapeTextForBrowser(boundary)),
|
4992 | destination.push(boundary),
|
4993 | destination.push('"')),
|
4994 | destination.push("></template>")),
|
4995 | flushSubtree(request, destination, segment, hoistableState),
|
4996 | (request = request.renderState.generateStaticMarkup
|
4997 | ? !0
|
4998 | : destination.push("\x3c!--/$--\x3e")),
|
4999 | request
|
5000 | );
|
5001 | if (1 !== boundary.status)
|
5002 | return (
|
5003 | 0 === boundary.status &&
|
5004 | (boundary.rootSegmentID = request.nextSegmentId++),
|
5005 | 0 < boundary.completedSegments.length &&
|
5006 | request.partialBoundaries.push(boundary),
|
5007 | writeStartPendingSuspenseBoundary(
|
5008 | destination,
|
5009 | request.renderState,
|
5010 | boundary.rootSegmentID
|
5011 | ),
|
5012 | hoistableState &&
|
5013 | ((boundary = boundary.fallbackState),
|
5014 | boundary.styles.forEach(hoistStyleQueueDependency, hoistableState),
|
5015 | boundary.stylesheets.forEach(
|
5016 | hoistStylesheetDependency,
|
5017 | hoistableState
|
5018 | )),
|
5019 | flushSubtree(request, destination, segment, hoistableState),
|
5020 | destination.push("\x3c!--/$--\x3e")
|
5021 | );
|
5022 | if (boundary.byteSize > request.progressiveChunkSize)
|
5023 | return (
|
5024 | (boundary.rootSegmentID = request.nextSegmentId++),
|
5025 | request.completedBoundaries.push(boundary),
|
5026 | writeStartPendingSuspenseBoundary(
|
5027 | destination,
|
5028 | request.renderState,
|
5029 | boundary.rootSegmentID
|
5030 | ),
|
5031 | flushSubtree(request, destination, segment, hoistableState),
|
5032 | destination.push("\x3c!--/$--\x3e")
|
5033 | );
|
5034 | hoistableState &&
|
5035 | ((segment = boundary.contentState),
|
5036 | segment.styles.forEach(hoistStyleQueueDependency, hoistableState),
|
5037 | segment.stylesheets.forEach(hoistStylesheetDependency, hoistableState));
|
5038 | request.renderState.generateStaticMarkup ||
|
5039 | destination.push("\x3c!--$--\x3e");
|
5040 | segment = boundary.completedSegments;
|
5041 | if (1 !== segment.length) throw Error(formatProdErrorMessage(391));
|
5042 | flushSegment(request, destination, segment[0], hoistableState);
|
5043 | request = request.renderState.generateStaticMarkup
|
5044 | ? !0
|
5045 | : destination.push("\x3c!--/$--\x3e");
|
5046 | return request;
|
5047 | }
|
5048 | function flushSegmentContainer(request, destination, segment, hoistableState) {
|
5049 | writeStartSegment(
|
5050 | destination,
|
5051 | request.renderState,
|
5052 | segment.parentFormatContext,
|
5053 | segment.id
|
5054 | );
|
5055 | flushSegment(request, destination, segment, hoistableState);
|
5056 | return writeEndSegment(destination, segment.parentFormatContext);
|
5057 | }
|
5058 | function flushCompletedBoundary(request, destination, boundary) {
|
5059 | for (
|
5060 | var completedSegments = boundary.completedSegments, i = 0;
|
5061 | i < completedSegments.length;
|
5062 | i++
|
5063 | )
|
5064 | flushPartiallyCompletedSegment(
|
5065 | request,
|
5066 | destination,
|
5067 | boundary,
|
5068 | completedSegments[i]
|
5069 | );
|
5070 | completedSegments.length = 0;
|
5071 | writeHoistablesForBoundary(
|
5072 | destination,
|
5073 | boundary.contentState,
|
5074 | request.renderState
|
5075 | );
|
5076 | completedSegments = request.resumableState;
|
5077 | request = request.renderState;
|
5078 | i = boundary.rootSegmentID;
|
5079 | boundary = boundary.contentState;
|
5080 | var requiresStyleInsertion = request.stylesToHoist;
|
5081 | request.stylesToHoist = !1;
|
5082 | destination.push(request.startInlineScript);
|
5083 | requiresStyleInsertion
|
5084 | ? 0 === (completedSegments.instructions & 2)
|
5085 | ? ((completedSegments.instructions |= 10),
|
5086 | destination.push(
|
5087 | '$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RM=new Map;\n$RR=function(r,t,w){for(var u=$RC,n=$RM,p=new Map,q=document,g,b,h=q.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&n.set(b.getAttribute("href"),b),p.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var f=w[b++];if(!f){k=!1;b=0;continue}var c=!1,m=0;var d=f[m++];if(a=n.get(d)){var e=a._p;c=!0}else{a=q.createElement("link");a.href=d;a.rel="stylesheet";for(a.dataset.precedence=\nl=f[m++];e=f[m++];)a.setAttribute(e,f[m++]);e=a._p=new Promise(function(x,y){a.onload=x;a.onerror=y});n.set(d,a)}d=a.getAttribute("media");!e||"l"===e.s||d&&!matchMedia(d).matches||h.push(e);if(c)continue}else{a=v[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=p.get(l)||g;c===g&&(g=a);p.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=q.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(u.bind(null,r,t,""),u.bind(null,r,t,"Resource failed to load"))};$RR("'
|
5088 | ))
|
5089 | : 0 === (completedSegments.instructions & 8)
|
5090 | ? ((completedSegments.instructions |= 8),
|
5091 | destination.push(
|
5092 | '$RM=new Map;\n$RR=function(r,t,w){for(var u=$RC,n=$RM,p=new Map,q=document,g,b,h=q.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&n.set(b.getAttribute("href"),b),p.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var f=w[b++];if(!f){k=!1;b=0;continue}var c=!1,m=0;var d=f[m++];if(a=n.get(d)){var e=a._p;c=!0}else{a=q.createElement("link");a.href=d;a.rel="stylesheet";for(a.dataset.precedence=\nl=f[m++];e=f[m++];)a.setAttribute(e,f[m++]);e=a._p=new Promise(function(x,y){a.onload=x;a.onerror=y});n.set(d,a)}d=a.getAttribute("media");!e||"l"===e.s||d&&!matchMedia(d).matches||h.push(e);if(c)continue}else{a=v[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=p.get(l)||g;c===g&&(g=a);p.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=q.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(u.bind(null,r,t,""),u.bind(null,r,t,"Resource failed to load"))};$RR("'
|
5093 | ))
|
5094 | : destination.push('$RR("')
|
5095 | : 0 === (completedSegments.instructions & 2)
|
5096 | ? ((completedSegments.instructions |= 2),
|
5097 | destination.push(
|
5098 | '$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RC("'
|
5099 | ))
|
5100 | : destination.push('$RC("');
|
5101 | completedSegments = i.toString(16);
|
5102 | destination.push(request.boundaryPrefix);
|
5103 | destination.push(completedSegments);
|
5104 | destination.push('","');
|
5105 | destination.push(request.segmentPrefix);
|
5106 | destination.push(completedSegments);
|
5107 | requiresStyleInsertion
|
5108 | ? (destination.push('",'),
|
5109 | writeStyleResourceDependenciesInJS(destination, boundary))
|
5110 | : destination.push('"');
|
5111 | boundary = destination.push(")\x3c/script>");
|
5112 | return writeBootstrap(destination, request) && boundary;
|
5113 | }
|
5114 | function flushPartiallyCompletedSegment(
|
5115 | request,
|
5116 | destination,
|
5117 | boundary,
|
5118 | segment
|
5119 | ) {
|
5120 | if (2 === segment.status) return !0;
|
5121 | var hoistableState = boundary.contentState,
|
5122 | segmentID = segment.id;
|
5123 | if (-1 === segmentID) {
|
5124 | if (-1 === (segment.id = boundary.rootSegmentID))
|
5125 | throw Error(formatProdErrorMessage(392));
|
5126 | return flushSegmentContainer(request, destination, segment, hoistableState);
|
5127 | }
|
5128 | if (segmentID === boundary.rootSegmentID)
|
5129 | return flushSegmentContainer(request, destination, segment, hoistableState);
|
5130 | flushSegmentContainer(request, destination, segment, hoistableState);
|
5131 | boundary = request.resumableState;
|
5132 | request = request.renderState;
|
5133 | destination.push(request.startInlineScript);
|
5134 | 0 === (boundary.instructions & 1)
|
5135 | ? ((boundary.instructions |= 1),
|
5136 | destination.push(
|
5137 | '$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'
|
5138 | ))
|
5139 | : destination.push('$RS("');
|
5140 | destination.push(request.segmentPrefix);
|
5141 | segmentID = segmentID.toString(16);
|
5142 | destination.push(segmentID);
|
5143 | destination.push('","');
|
5144 | destination.push(request.placeholderPrefix);
|
5145 | destination.push(segmentID);
|
5146 | destination = destination.push('")\x3c/script>');
|
5147 | return destination;
|
5148 | }
|
5149 | function flushCompletedQueues(request, destination) {
|
5150 | try {
|
5151 | if (!(0 < request.pendingRootTasks)) {
|
5152 | var i,
|
5153 | completedRootSegment = request.completedRootSegment;
|
5154 | if (null !== completedRootSegment) {
|
5155 | if (5 === completedRootSegment.status) return;
|
5156 | var renderState = request.renderState,
|
5157 | htmlChunks = renderState.htmlChunks,
|
5158 | headChunks = renderState.headChunks,
|
5159 | i$jscomp$0;
|
5160 | if (htmlChunks) {
|
5161 | for (i$jscomp$0 = 0; i$jscomp$0 < htmlChunks.length; i$jscomp$0++)
|
5162 | destination.push(htmlChunks[i$jscomp$0]);
|
5163 | if (headChunks)
|
5164 | for (i$jscomp$0 = 0; i$jscomp$0 < headChunks.length; i$jscomp$0++)
|
5165 | destination.push(headChunks[i$jscomp$0]);
|
5166 | else {
|
5167 | var chunk = startChunkForTag("head");
|
5168 | destination.push(chunk);
|
5169 | destination.push(">");
|
5170 | }
|
5171 | } else if (headChunks)
|
5172 | for (i$jscomp$0 = 0; i$jscomp$0 < headChunks.length; i$jscomp$0++)
|
5173 | destination.push(headChunks[i$jscomp$0]);
|
5174 | var charsetChunks = renderState.charsetChunks;
|
5175 | for (i$jscomp$0 = 0; i$jscomp$0 < charsetChunks.length; i$jscomp$0++)
|
5176 | destination.push(charsetChunks[i$jscomp$0]);
|
5177 | charsetChunks.length = 0;
|
5178 | renderState.preconnects.forEach(flushResource, destination);
|
5179 | renderState.preconnects.clear();
|
5180 | var viewportChunks = renderState.viewportChunks;
|
5181 | for (i$jscomp$0 = 0; i$jscomp$0 < viewportChunks.length; i$jscomp$0++)
|
5182 | destination.push(viewportChunks[i$jscomp$0]);
|
5183 | viewportChunks.length = 0;
|
5184 | renderState.fontPreloads.forEach(flushResource, destination);
|
5185 | renderState.fontPreloads.clear();
|
5186 | renderState.highImagePreloads.forEach(flushResource, destination);
|
5187 | renderState.highImagePreloads.clear();
|
5188 | renderState.styles.forEach(flushStylesInPreamble, destination);
|
5189 | var importMapChunks = renderState.importMapChunks;
|
5190 | for (i$jscomp$0 = 0; i$jscomp$0 < importMapChunks.length; i$jscomp$0++)
|
5191 | destination.push(importMapChunks[i$jscomp$0]);
|
5192 | importMapChunks.length = 0;
|
5193 | renderState.bootstrapScripts.forEach(flushResource, destination);
|
5194 | renderState.scripts.forEach(flushResource, destination);
|
5195 | renderState.scripts.clear();
|
5196 | renderState.bulkPreloads.forEach(flushResource, destination);
|
5197 | renderState.bulkPreloads.clear();
|
5198 | var hoistableChunks = renderState.hoistableChunks;
|
5199 | for (i$jscomp$0 = 0; i$jscomp$0 < hoistableChunks.length; i$jscomp$0++)
|
5200 | destination.push(hoistableChunks[i$jscomp$0]);
|
5201 | hoistableChunks.length = 0;
|
5202 | if (htmlChunks && null === headChunks) {
|
5203 | var chunk$jscomp$0 = endChunkForTag("head");
|
5204 | destination.push(chunk$jscomp$0);
|
5205 | }
|
5206 | flushSegment(request, destination, completedRootSegment, null);
|
5207 | request.completedRootSegment = null;
|
5208 | writeBootstrap(destination, request.renderState);
|
5209 | }
|
5210 | var renderState$jscomp$0 = request.renderState;
|
5211 | completedRootSegment = 0;
|
5212 | var viewportChunks$jscomp$0 = renderState$jscomp$0.viewportChunks;
|
5213 | for (
|
5214 | completedRootSegment = 0;
|
5215 | completedRootSegment < viewportChunks$jscomp$0.length;
|
5216 | completedRootSegment++
|
5217 | )
|
5218 | destination.push(viewportChunks$jscomp$0[completedRootSegment]);
|
5219 | viewportChunks$jscomp$0.length = 0;
|
5220 | renderState$jscomp$0.preconnects.forEach(flushResource, destination);
|
5221 | renderState$jscomp$0.preconnects.clear();
|
5222 | renderState$jscomp$0.fontPreloads.forEach(flushResource, destination);
|
5223 | renderState$jscomp$0.fontPreloads.clear();
|
5224 | renderState$jscomp$0.highImagePreloads.forEach(
|
5225 | flushResource,
|
5226 | destination
|
5227 | );
|
5228 | renderState$jscomp$0.highImagePreloads.clear();
|
5229 | renderState$jscomp$0.styles.forEach(preloadLateStyles, destination);
|
5230 | renderState$jscomp$0.scripts.forEach(flushResource, destination);
|
5231 | renderState$jscomp$0.scripts.clear();
|
5232 | renderState$jscomp$0.bulkPreloads.forEach(flushResource, destination);
|
5233 | renderState$jscomp$0.bulkPreloads.clear();
|
5234 | var hoistableChunks$jscomp$0 = renderState$jscomp$0.hoistableChunks;
|
5235 | for (
|
5236 | completedRootSegment = 0;
|
5237 | completedRootSegment < hoistableChunks$jscomp$0.length;
|
5238 | completedRootSegment++
|
5239 | )
|
5240 | destination.push(hoistableChunks$jscomp$0[completedRootSegment]);
|
5241 | hoistableChunks$jscomp$0.length = 0;
|
5242 | var clientRenderedBoundaries = request.clientRenderedBoundaries;
|
5243 | for (i = 0; i < clientRenderedBoundaries.length; i++) {
|
5244 | var boundary = clientRenderedBoundaries[i];
|
5245 | renderState$jscomp$0 = destination;
|
5246 | var resumableState = request.resumableState,
|
5247 | renderState$jscomp$1 = request.renderState,
|
5248 | id = boundary.rootSegmentID,
|
5249 | errorDigest = boundary.errorDigest;
|
5250 | renderState$jscomp$0.push(renderState$jscomp$1.startInlineScript);
|
5251 | 0 === (resumableState.instructions & 4)
|
5252 | ? ((resumableState.instructions |= 4),
|
5253 | renderState$jscomp$0.push(
|
5254 | '$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'
|
5255 | ))
|
5256 | : renderState$jscomp$0.push('$RX("');
|
5257 | renderState$jscomp$0.push(renderState$jscomp$1.boundaryPrefix);
|
5258 | var chunk$jscomp$1 = id.toString(16);
|
5259 | renderState$jscomp$0.push(chunk$jscomp$1);
|
5260 | renderState$jscomp$0.push('"');
|
5261 | if (errorDigest) {
|
5262 | renderState$jscomp$0.push(",");
|
5263 | var chunk$jscomp$2 = escapeJSStringsForInstructionScripts(
|
5264 | errorDigest || ""
|
5265 | );
|
5266 | renderState$jscomp$0.push(chunk$jscomp$2);
|
5267 | }
|
5268 | var JSCompiler_inline_result =
|
5269 | renderState$jscomp$0.push(")\x3c/script>");
|
5270 | if (!JSCompiler_inline_result) {
|
5271 | request.destination = null;
|
5272 | i++;
|
5273 | clientRenderedBoundaries.splice(0, i);
|
5274 | return;
|
5275 | }
|
5276 | }
|
5277 | clientRenderedBoundaries.splice(0, i);
|
5278 | var completedBoundaries = request.completedBoundaries;
|
5279 | for (i = 0; i < completedBoundaries.length; i++)
|
5280 | if (
|
5281 | !flushCompletedBoundary(request, destination, completedBoundaries[i])
|
5282 | ) {
|
5283 | request.destination = null;
|
5284 | i++;
|
5285 | completedBoundaries.splice(0, i);
|
5286 | return;
|
5287 | }
|
5288 | completedBoundaries.splice(0, i);
|
5289 | var partialBoundaries = request.partialBoundaries;
|
5290 | for (i = 0; i < partialBoundaries.length; i++) {
|
5291 | var boundary$44 = partialBoundaries[i];
|
5292 | a: {
|
5293 | clientRenderedBoundaries = request;
|
5294 | boundary = destination;
|
5295 | var completedSegments = boundary$44.completedSegments;
|
5296 | for (
|
5297 | JSCompiler_inline_result = 0;
|
5298 | JSCompiler_inline_result < completedSegments.length;
|
5299 | JSCompiler_inline_result++
|
5300 | )
|
5301 | if (
|
5302 | !flushPartiallyCompletedSegment(
|
5303 | clientRenderedBoundaries,
|
5304 | boundary,
|
5305 | boundary$44,
|
5306 | completedSegments[JSCompiler_inline_result]
|
5307 | )
|
5308 | ) {
|
5309 | JSCompiler_inline_result++;
|
5310 | completedSegments.splice(0, JSCompiler_inline_result);
|
5311 | var JSCompiler_inline_result$jscomp$0 = !1;
|
5312 | break a;
|
5313 | }
|
5314 | completedSegments.splice(0, JSCompiler_inline_result);
|
5315 | JSCompiler_inline_result$jscomp$0 = writeHoistablesForBoundary(
|
5316 | boundary,
|
5317 | boundary$44.contentState,
|
5318 | clientRenderedBoundaries.renderState
|
5319 | );
|
5320 | }
|
5321 | if (!JSCompiler_inline_result$jscomp$0) {
|
5322 | request.destination = null;
|
5323 | i++;
|
5324 | partialBoundaries.splice(0, i);
|
5325 | return;
|
5326 | }
|
5327 | }
|
5328 | partialBoundaries.splice(0, i);
|
5329 | var largeBoundaries = request.completedBoundaries;
|
5330 | for (i = 0; i < largeBoundaries.length; i++)
|
5331 | if (!flushCompletedBoundary(request, destination, largeBoundaries[i])) {
|
5332 | request.destination = null;
|
5333 | i++;
|
5334 | largeBoundaries.splice(0, i);
|
5335 | return;
|
5336 | }
|
5337 | largeBoundaries.splice(0, i);
|
5338 | }
|
5339 | } finally {
|
5340 | 0 === request.allPendingTasks &&
|
5341 | 0 === request.pingedTasks.length &&
|
5342 | 0 === request.clientRenderedBoundaries.length &&
|
5343 | 0 === request.completedBoundaries.length &&
|
5344 | ((request.flushScheduled = !1),
|
5345 | (i = request.resumableState),
|
5346 | i.hasBody &&
|
5347 | ((partialBoundaries = endChunkForTag("body")),
|
5348 | destination.push(partialBoundaries)),
|
5349 | i.hasHtml && ((i = endChunkForTag("html")), destination.push(i)),
|
5350 | destination.push(null),
|
5351 | (request.destination = null));
|
5352 | }
|
5353 | }
|
5354 | function enqueueFlush(request) {
|
5355 | if (
|
5356 | !1 === request.flushScheduled &&
|
5357 | 0 === request.pingedTasks.length &&
|
5358 | null !== request.destination
|
5359 | ) {
|
5360 | request.flushScheduled = !0;
|
5361 | var destination = request.destination;
|
5362 | destination
|
5363 | ? flushCompletedQueues(request, destination)
|
5364 | : (request.flushScheduled = !1);
|
5365 | }
|
5366 | }
|
5367 | function startFlowing(request, destination) {
|
5368 | if (1 === request.status)
|
5369 | (request.status = 2), destination.destroy(request.fatalError);
|
5370 | else if (2 !== request.status && null === request.destination) {
|
5371 | request.destination = destination;
|
5372 | try {
|
5373 | flushCompletedQueues(request, destination);
|
5374 | } catch (error) {
|
5375 | logRecoverableError(request, error, {}), fatalError(request, error);
|
5376 | }
|
5377 | }
|
5378 | }
|
5379 | function abort(request, reason) {
|
5380 | try {
|
5381 | var abortableTasks = request.abortableTasks;
|
5382 | if (0 < abortableTasks.size) {
|
5383 | var error =
|
5384 | void 0 === reason ? Error(formatProdErrorMessage(432)) : reason;
|
5385 | abortableTasks.forEach(function (task) {
|
5386 | return abortTask(task, request, error);
|
5387 | });
|
5388 | abortableTasks.clear();
|
5389 | }
|
5390 | null !== request.destination &&
|
5391 | flushCompletedQueues(request, request.destination);
|
5392 | } catch (error$46) {
|
5393 | logRecoverableError(request, error$46, {}), fatalError(request, error$46);
|
5394 | }
|
5395 | }
|
5396 | function onError() {}
|
5397 | function renderToStringImpl(
|
5398 | children,
|
5399 | options,
|
5400 | generateStaticMarkup,
|
5401 | abortReason
|
5402 | ) {
|
5403 | var didFatal = !1,
|
5404 | fatalError = null,
|
5405 | result = "",
|
5406 | readyToStream = !1;
|
5407 | options = createResumableState(options ? options.identifierPrefix : void 0);
|
5408 | children = createRequest(
|
5409 | children,
|
5410 | options,
|
5411 | createRenderState(options, generateStaticMarkup),
|
5412 | createFormatContext(0, null, 0),
|
5413 | Infinity,
|
5414 | onError,
|
5415 | void 0,
|
5416 | function () {
|
5417 | readyToStream = !0;
|
5418 | },
|
5419 | void 0,
|
5420 | void 0,
|
5421 | void 0
|
5422 | );
|
5423 | children.flushScheduled = null !== children.destination;
|
5424 | performWork(children);
|
5425 | null === children.trackedPostpones &&
|
5426 | safelyEmitEarlyPreloads(children, 0 === children.pendingRootTasks);
|
5427 | abort(children, abortReason);
|
5428 | startFlowing(children, {
|
5429 | push: function (chunk) {
|
5430 | null !== chunk && (result += chunk);
|
5431 | return !0;
|
5432 | },
|
5433 | destroy: function (error) {
|
5434 | didFatal = !0;
|
5435 | fatalError = error;
|
5436 | }
|
5437 | });
|
5438 | if (didFatal && fatalError !== abortReason) throw fatalError;
|
5439 | if (!readyToStream) throw Error(formatProdErrorMessage(426));
|
5440 | return result;
|
5441 | }
|
5442 | exports.renderToStaticMarkup = function (children, options) {
|
5443 | return renderToStringImpl(
|
5444 | children,
|
5445 | options,
|
5446 | !0,
|
5447 | 'The server used "renderToStaticMarkup" which does not support Suspense. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
|
5448 | );
|
5449 | };
|
5450 | exports.renderToString = function (children, options) {
|
5451 | return renderToStringImpl(
|
5452 | children,
|
5453 | options,
|
5454 | !1,
|
5455 | 'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
|
5456 | );
|
5457 | };
|
5458 | exports.version = "19.0.0-beta-4508873393-20240430";
|