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bC,SAAU,CACd,EAGA,GAAeJ,E","sources":["webpack://next/./dist/compiled/@edge-runtime/cookies/index.js","webpack://next/./dist/compiled/cookie/index.js","webpack://next/./dist/compiled/fresh/index.js","webpack://next/./dist/compiled/react-is/cjs/react-is.development.js","webpack://next/./dist/compiled/react-is/index.js","webpack://next/./dist/compiled/strip-ansi/index.js","webpack://next/./dist/esm/lib/picocolors.js","webpack://next/./dist/esm/build/output/log.js","webpack://next/./dist/esm/lib/constants.js","webpack://next/./dist/esm/lib/non-nullable.js","webpack://next/./dist/esm/server/api-utils/index.js","webpack://next/./dist/esm/server/api-utils/node/try-get-preview-data.js","webpack://next/external node-commonjs \"crypto\"","webpack://next/./dist/esm/server/crypto-utils.js","webpack://next/./dist/esm/server/font-utils.js","webpack://next/./dist/esm/server/node-polyfill-web-streams.js","webpack://next/./dist/esm/server/optimize-amp.js","webpack://next/./dist/esm/server/post-process.js","webpack://next/./dist/esm/server/web/spec-extension/adapters/headers.js","webpack://next/./dist/esm/server/web/spec-extension/adapters/reflect.js","webpack://next/./dist/esm/shared/lib/constants.js","webpack://next/./dist/esm/shared/lib/modern-browserslist-target.js","webpack://next/external commonjs2 \"critters\"","webpack://next/external commonjs2 \"next/dist/compiled/@ampproject/toolbox-optimizer\"","webpack://next/external commonjs2 \"next/dist/compiled/@edge-runtime/ponyfill\"","webpack://next/external commonjs2 \"next/dist/compiled/@next/react-dev-overlay/dist/middleware\"","webpack://next/external commonjs2 \"next/dist/compiled/jsonwebtoken\"","webpack://next/external commonjs2 \"next/dist/compiled/node-html-parser\"","webpack://next/external commonjs2 \"next/dist/server/capsize-font-metrics.json\"","webpack://next/external node-commonjs \"https\"","webpack://next/external node-commonjs \"path\"","webpack://next/external node-commonjs \"stream/web\"","webpack://next/webpack/bootstrap","webpack://next/webpack/runtime/compat get default export","webpack://next/webpack/runtime/define property getters","webpack://next/webpack/runtime/hasOwnProperty shorthand","webpack://next/webpack/runtime/make namespace object","webpack://next/./dist/esm/server/render.js","webpack://next/./dist/esm/server/lib/trace/constants.js","webpack://next/./dist/esm/shared/lib/app-router-context.shared-runtime.js","webpack://next/./dist/esm/server/future/route-modules/route-module.js","webpack://next/external commonjs2 \"react\"","webpack://next/external commonjs2 \"react-dom/server.browser\"","webpack://next/external commonjs2 \"styled-jsx\"","webpack://next/./dist/esm/shared/lib/is-plain-object.js","webpack://next/./dist/esm/lib/is-serializable-props.js","webpack://next/./dist/esm/shared/lib/amp-context.shared-runtime.js","webpack://next/./dist/esm/shared/lib/head-manager-context.shared-runtime.js","webpack://next/./dist/esm/shared/lib/loadable-context.shared-runtime.js","webpack://next/./dist/esm/shared/lib/loadable.shared-runtime.js","webpack://next/./dist/esm/shared/lib/router-context.shared-runtime.js","webpack://next/./dist/esm/shared/lib/router/utils/is-dynamic.js","webpack://next/./dist/esm/shared/lib/utils.js","webpack://next/./dist/esm/shared/lib/html-context.shared-runtime.js","webpack://next/./dist/esm/server/request-meta.js","webpack://next/./dist/esm/lib/redirect-status.js","webpack://next/./dist/esm/server/pipe-readable.js","webpack://next/./dist/esm/server/render-result.js","webpack://next/external commonjs \"next/dist/server/lib/trace/tracer\"","webpack://next/./dist/esm/server/stream-utils/encode-decode.js","webpack://next/./dist/esm/server/stream-utils/node-web-streams-helper.js","webpack://next/./dist/esm/shared/lib/image-config-context.shared-runtime.js","webpack://next/./dist/esm/shared/lib/image-config.js","webpack://next/./dist/esm/server/internal-utils.js","webpack://next/./dist/esm/client/components/app-router-headers.js","webpack://next/./dist/esm/shared/lib/hooks-client-context.shared-runtime.js","webpack://next/./dist/esm/server/future/helpers/interception-routes.js","webpack://next/./dist/esm/shared/lib/escape-regexp.js","webpack://next/./dist/esm/shared/lib/router/utils/route-regex.js","webpack://next/./dist/esm/shared/lib/router/adapters.js","webpack://next/./dist/esm/server/api-utils/get-cookie-parser.js","webpack://next/./dist/esm/server/send-payload/revalidate-headers.js","webpack://next/./dist/esm/shared/lib/amp-mode.js","webpack://next/./dist/esm/shared/lib/head.js","webpack://next/./dist/esm/shared/lib/router/utils/as-path-to-search-params.js","webpack://next/./dist/esm/shared/lib/router/utils/remove-trailing-slash.js","webpack://next/./dist/esm/lib/is-error.js","webpack://next/./dist/esm/shared/lib/page-path/denormalize-page-path.js","webpack://next/./dist/esm/shared/lib/page-path/normalize-path-sep.js","webpack://next/./dist/esm/shared/lib/page-path/normalize-page-path.js","webpack://next/./dist/esm/shared/lib/page-path/ensure-leading-slash.js","webpack://next/./dist/esm/shared/lib/server-inserted-html.shared-runtime.js","webpack://next/./dist/esm/server/future/route-modules/pages/module.js"],"sourcesContent":["\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\n\n// src/index.ts\nvar src_exports = {};\n__export(src_exports, {\n RequestCookies: () => RequestCookies,\n ResponseCookies: () => ResponseCookies,\n parseCookie: () => parseCookie,\n parseSetCookie: () => parseSetCookie,\n stringifyCookie: () => stringifyCookie\n});\nmodule.exports = __toCommonJS(src_exports);\n\n// src/serialize.ts\nfunction stringifyCookie(c) {\n var _a;\n const attrs = [\n \"path\" in c && c.path && `Path=${c.path}`,\n \"expires\" in c && (c.expires || c.expires === 0) && `Expires=${(typeof c.expires === \"number\" ? new Date(c.expires) : c.expires).toUTCString()}`,\n \"maxAge\" in c && typeof c.maxAge === \"number\" && `Max-Age=${c.maxAge}`,\n \"domain\" in c && c.domain && `Domain=${c.domain}`,\n \"secure\" in c && c.secure && \"Secure\",\n \"httpOnly\" in c && c.httpOnly && \"HttpOnly\",\n \"sameSite\" in c && c.sameSite && `SameSite=${c.sameSite}`,\n \"priority\" in c && c.priority && `Priority=${c.priority}`\n ].filter(Boolean);\n return `${c.name}=${encodeURIComponent((_a = c.value) != null ? _a : \"\")}; ${attrs.join(\"; \")}`;\n}\nfunction parseCookie(cookie) {\n const map = /* @__PURE__ */ new Map();\n for (const pair of cookie.split(/; */)) {\n if (!pair)\n continue;\n const splitAt = pair.indexOf(\"=\");\n if (splitAt === -1) {\n map.set(pair, \"true\");\n continue;\n }\n const [key, value] = [pair.slice(0, splitAt), pair.slice(splitAt + 1)];\n try {\n map.set(key, decodeURIComponent(value != null ? value : \"true\"));\n } catch {\n }\n }\n return map;\n}\nfunction parseSetCookie(setCookie) {\n if (!setCookie) {\n return void 0;\n }\n const [[name, value], ...attributes] = parseCookie(setCookie);\n const {\n domain,\n expires,\n httponly,\n maxage,\n path,\n samesite,\n secure,\n priority\n } = Object.fromEntries(\n attributes.map(([key, value2]) => [key.toLowerCase(), value2])\n );\n const cookie = {\n name,\n value: decodeURIComponent(value),\n domain,\n ...expires && { expires: new Date(expires) },\n ...httponly && { httpOnly: true },\n ...typeof maxage === \"string\" && { maxAge: Number(maxage) },\n path,\n ...samesite && { sameSite: parseSameSite(samesite) },\n ...secure && { secure: true },\n ...priority && { priority: parsePriority(priority) }\n };\n return compact(cookie);\n}\nfunction compact(t) {\n const newT = {};\n for (const key in t) {\n if (t[key]) {\n newT[key] = t[key];\n }\n }\n return newT;\n}\nvar SAME_SITE = [\"strict\", \"lax\", \"none\"];\nfunction parseSameSite(string) {\n string = string.toLowerCase();\n return SAME_SITE.includes(string) ? string : void 0;\n}\nvar PRIORITY = [\"low\", \"medium\", \"high\"];\nfunction parsePriority(string) {\n string = string.toLowerCase();\n return PRIORITY.includes(string) ? string : void 0;\n}\nfunction splitCookiesString(cookiesString) {\n if (!cookiesString)\n return [];\n var cookiesStrings = [];\n var pos = 0;\n var start;\n var ch;\n var lastComma;\n var nextStart;\n var cookiesSeparatorFound;\n function skipWhitespace() {\n while (pos < cookiesString.length && /\\s/.test(cookiesString.charAt(pos))) {\n pos += 1;\n }\n return pos < cookiesString.length;\n }\n function notSpecialChar() {\n ch = cookiesString.charAt(pos);\n return ch !== \"=\" && ch !== \";\" && ch !== \",\";\n }\n while (pos < cookiesString.length) {\n start = pos;\n cookiesSeparatorFound = false;\n while (skipWhitespace()) {\n ch = cookiesString.charAt(pos);\n if (ch === \",\") {\n lastComma = pos;\n pos += 1;\n skipWhitespace();\n nextStart = pos;\n while (pos < cookiesString.length && notSpecialChar()) {\n pos += 1;\n }\n if (pos < cookiesString.length && cookiesString.charAt(pos) === \"=\") {\n cookiesSeparatorFound = true;\n pos = nextStart;\n cookiesStrings.push(cookiesString.substring(start, lastComma));\n start = pos;\n } else {\n pos = lastComma + 1;\n }\n } else {\n pos += 1;\n }\n }\n if (!cookiesSeparatorFound || pos >= cookiesString.length) {\n cookiesStrings.push(cookiesString.substring(start, cookiesString.length));\n }\n }\n return cookiesStrings;\n}\n\n// src/request-cookies.ts\nvar RequestCookies = class {\n constructor(requestHeaders) {\n /** @internal */\n this._parsed = /* @__PURE__ */ new Map();\n this._headers = requestHeaders;\n const header = requestHeaders.get(\"cookie\");\n if (header) {\n const parsed = parseCookie(header);\n for (const [name, value] of parsed) {\n this._parsed.set(name, { name, value });\n }\n }\n }\n [Symbol.iterator]() {\n return this._parsed[Symbol.iterator]();\n }\n /**\n * The amount of cookies received from the client\n */\n get size() {\n return this._parsed.size;\n }\n get(...args) {\n const name = typeof args[0] === \"string\" ? args[0] : args[0].name;\n return this._parsed.get(name);\n }\n getAll(...args) {\n var _a;\n const all = Array.from(this._parsed);\n if (!args.length) {\n return all.map(([_, value]) => value);\n }\n const name = typeof args[0] === \"string\" ? args[0] : (_a = args[0]) == null ? void 0 : _a.name;\n return all.filter(([n]) => n === name).map(([_, value]) => value);\n }\n has(name) {\n return this._parsed.has(name);\n }\n set(...args) {\n const [name, value] = args.length === 1 ? [args[0].name, args[0].value] : args;\n const map = this._parsed;\n map.set(name, { name, value });\n this._headers.set(\n \"cookie\",\n Array.from(map).map(([_, value2]) => stringifyCookie(value2)).join(\"; \")\n );\n return this;\n }\n /**\n * Delete the cookies matching the passed name or names in the request.\n */\n delete(names) {\n const map = this._parsed;\n const result = !Array.isArray(names) ? map.delete(names) : names.map((name) => map.delete(name));\n this._headers.set(\n \"cookie\",\n Array.from(map).map(([_, value]) => stringifyCookie(value)).join(\"; \")\n );\n return result;\n }\n /**\n * Delete all the cookies in the cookies in the request.\n */\n clear() {\n this.delete(Array.from(this._parsed.keys()));\n return this;\n }\n /**\n * Format the cookies in the request as a string for logging\n */\n [Symbol.for(\"edge-runtime.inspect.custom\")]() {\n return `RequestCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`;\n }\n toString() {\n return [...this._parsed.values()].map((v) => `${v.name}=${encodeURIComponent(v.value)}`).join(\"; \");\n }\n};\n\n// src/response-cookies.ts\nvar ResponseCookies = class {\n constructor(responseHeaders) {\n /** @internal */\n this._parsed = /* @__PURE__ */ new Map();\n var _a, _b, _c;\n this._headers = responseHeaders;\n const setCookie = (_c = (_b = (_a = responseHeaders.getSetCookie) == null ? void 0 : _a.call(responseHeaders)) != null ? _b : responseHeaders.get(\"set-cookie\")) != null ? _c : [];\n const cookieStrings = Array.isArray(setCookie) ? setCookie : splitCookiesString(setCookie);\n for (const cookieString of cookieStrings) {\n const parsed = parseSetCookie(cookieString);\n if (parsed)\n this._parsed.set(parsed.name, parsed);\n }\n }\n /**\n * {@link https://wicg.github.io/cookie-store/#CookieStore-get CookieStore#get} without the Promise.\n */\n get(...args) {\n const key = typeof args[0] === \"string\" ? args[0] : args[0].name;\n return this._parsed.get(key);\n }\n /**\n * {@link https://wicg.github.io/cookie-store/#CookieStore-getAll CookieStore#getAll} without the Promise.\n */\n getAll(...args) {\n var _a;\n const all = Array.from(this._parsed.values());\n if (!args.length) {\n return all;\n }\n const key = typeof args[0] === \"string\" ? args[0] : (_a = args[0]) == null ? void 0 : _a.name;\n return all.filter((c) => c.name === key);\n }\n has(name) {\n return this._parsed.has(name);\n }\n /**\n * {@link https://wicg.github.io/cookie-store/#CookieStore-set CookieStore#set} without the Promise.\n */\n set(...args) {\n const [name, value, cookie] = args.length === 1 ? [args[0].name, args[0].value, args[0]] : args;\n const map = this._parsed;\n map.set(name, normalizeCookie({ name, value, ...cookie }));\n replace(map, this._headers);\n return this;\n }\n /**\n * {@link https://wicg.github.io/cookie-store/#CookieStore-delete CookieStore#delete} without the Promise.\n */\n delete(...args) {\n const [name, path, domain] = typeof args[0] === \"string\" ? [args[0]] : [args[0].name, args[0].path, args[0].domain];\n return this.set({ name, path, domain, value: \"\", expires: /* @__PURE__ */ new Date(0) });\n }\n [Symbol.for(\"edge-runtime.inspect.custom\")]() {\n return `ResponseCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`;\n }\n toString() {\n return [...this._parsed.values()].map(stringifyCookie).join(\"; \");\n }\n};\nfunction replace(bag, headers) {\n headers.delete(\"set-cookie\");\n for (const [, value] of bag) {\n const serialized = stringifyCookie(value);\n headers.append(\"set-cookie\", serialized);\n }\n}\nfunction normalizeCookie(cookie = { name: \"\", value: \"\" }) {\n if (typeof cookie.expires === \"number\") {\n cookie.expires = new Date(cookie.expires);\n }\n if (cookie.maxAge) {\n cookie.expires = new Date(Date.now() + cookie.maxAge * 1e3);\n }\n if (cookie.path === null || cookie.path === void 0) {\n cookie.path = \"/\";\n }\n return cookie;\n}\n// Annotate the CommonJS export names for ESM import in node:\n0 && (module.exports = {\n RequestCookies,\n ResponseCookies,\n parseCookie,\n parseSetCookie,\n stringifyCookie\n});\n","(()=>{\"use strict\";if(typeof __nccwpck_require__!==\"undefined\")__nccwpck_require__.ab=__dirname+\"/\";var e={};(()=>{var r=e;\n/*!\n * cookie\n * Copyright(c) 2012-2014 Roman Shtylman\n * Copyright(c) 2015 Douglas Christopher Wilson\n * MIT Licensed\n */r.parse=parse;r.serialize=serialize;var i=decodeURIComponent;var t=encodeURIComponent;var a=/; */;var n=/^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;function parse(e,r){if(typeof e!==\"string\"){throw new TypeError(\"argument str must be a string\")}var t={};var n=r||{};var o=e.split(a);var s=n.decode||i;for(var p=0;p{\"use strict\";var e={695:e=>{\n/*!\n * fresh\n * Copyright(c) 2012 TJ Holowaychuk\n * Copyright(c) 2016-2017 Douglas Christopher Wilson\n * MIT Licensed\n */\nvar r=/(?:^|,)\\s*?no-cache\\s*?(?:,|$)/;e.exports=fresh;function fresh(e,a){var t=e[\"if-modified-since\"];var s=e[\"if-none-match\"];if(!t&&!s){return false}var i=e[\"cache-control\"];if(i&&r.test(i)){return false}if(s&&s!==\"*\"){var f=a[\"etag\"];if(!f){return false}var n=true;var u=parseTokenList(s);for(var _=0;_{\"use strict\";var e={511:e=>{e.exports=({onlyFirst:e=false}={})=>{const r=[\"[\\\\u001B\\\\u009B][[\\\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\\\d\\\\/#&.:=?%@~_]+)*|[a-zA-Z\\\\d]+(?:;[-a-zA-Z\\\\d\\\\/#&.:=?%@~_]*)*)?\\\\u0007)\",\"(?:(?:\\\\d{1,4}(?:;\\\\d{0,4})*)?[\\\\dA-PR-TZcf-ntqry=><~]))\"].join(\"|\");return new RegExp(r,e?undefined:\"g\")}},532:(e,r,_)=>{const t=_(511);e.exports=e=>typeof e===\"string\"?e.replace(t(),\"\"):e}};var r={};function __nccwpck_require__(_){var t=r[_];if(t!==undefined){return t.exports}var a=r[_]={exports:{}};var n=true;try{e[_](a,a.exports,__nccwpck_require__);n=false}finally{if(n)delete r[_]}return a.exports}if(typeof __nccwpck_require__!==\"undefined\")__nccwpck_require__.ab=__dirname+\"/\";var _=__nccwpck_require__(532);module.exports=_})();","// ISC License\n// Copyright (c) 2021 Alexey Raspopov, Kostiantyn Denysov, Anton Verinov\n// Permission to use, copy, modify, and/or distribute this software for any\n// purpose with or without fee is hereby granted, provided that the above\n// copyright notice and this permission notice appear in all copies.\n// THE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES\n// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF\n// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR\n// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES\n// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN\n// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF\n// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.\n//\n// https://github.com/alexeyraspopov/picocolors/blob/b6261487e7b81aaab2440e397a356732cad9e342/picocolors.js#L1\nvar _globalThis;\nconst { env, stdout } = ((_globalThis = globalThis) == null ? void 0 : _globalThis.process) ?? {};\nconst enabled = env && !env.NO_COLOR && (env.FORCE_COLOR || (stdout == null ? void 0 : stdout.isTTY) && !env.CI && env.TERM !== \"dumb\");\nconst replaceClose = (str, close, replace, index)=>{\n const start = str.substring(0, index) + replace;\n const end = str.substring(index + close.length);\n const nextIndex = end.indexOf(close);\n return ~nextIndex ? start + replaceClose(end, close, replace, nextIndex) : start + end;\n};\nconst formatter = (open, close, replace = open)=>(input)=>{\n const string = \"\" + input;\n const index = string.indexOf(close, open.length);\n return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;\n };\nexport const reset = enabled ? (s)=>`\\x1b[0m${s}\\x1b[0m` : String;\nexport const bold = enabled ? formatter(\"\\x1b[1m\", \"\\x1b[22m\", \"\\x1b[22m\\x1b[1m\") : String;\nexport const dim = enabled ? formatter(\"\\x1b[2m\", \"\\x1b[22m\", \"\\x1b[22m\\x1b[2m\") : String;\nexport const italic = enabled ? formatter(\"\\x1b[3m\", \"\\x1b[23m\") : String;\nexport const underline = enabled ? formatter(\"\\x1b[4m\", \"\\x1b[24m\") : String;\nexport const inverse = enabled ? formatter(\"\\x1b[7m\", \"\\x1b[27m\") : String;\nexport const hidden = enabled ? formatter(\"\\x1b[8m\", \"\\x1b[28m\") : String;\nexport const strikethrough = enabled ? formatter(\"\\x1b[9m\", \"\\x1b[29m\") : String;\nexport const black = enabled ? formatter(\"\\x1b[30m\", \"\\x1b[39m\") : String;\nexport const red = enabled ? formatter(\"\\x1b[31m\", \"\\x1b[39m\") : String;\nexport const green = enabled ? formatter(\"\\x1b[32m\", \"\\x1b[39m\") : String;\nexport const yellow = enabled ? formatter(\"\\x1b[33m\", \"\\x1b[39m\") : String;\nexport const blue = enabled ? formatter(\"\\x1b[34m\", \"\\x1b[39m\") : String;\nexport const magenta = enabled ? formatter(\"\\x1b[35m\", \"\\x1b[39m\") : String;\nexport const purple = enabled ? formatter(\"\\x1b[38;2;173;127;168m\", \"\\x1b[39m\") : String;\nexport const cyan = enabled ? formatter(\"\\x1b[36m\", \"\\x1b[39m\") : String;\nexport const white = enabled ? formatter(\"\\x1b[37m\", \"\\x1b[39m\") : String;\nexport const gray = enabled ? formatter(\"\\x1b[90m\", \"\\x1b[39m\") : String;\nexport const bgBlack = enabled ? formatter(\"\\x1b[40m\", \"\\x1b[49m\") : String;\nexport const bgRed = enabled ? formatter(\"\\x1b[41m\", \"\\x1b[49m\") : String;\nexport const bgGreen = enabled ? formatter(\"\\x1b[42m\", \"\\x1b[49m\") : String;\nexport const bgYellow = enabled ? formatter(\"\\x1b[43m\", \"\\x1b[49m\") : String;\nexport const bgBlue = enabled ? formatter(\"\\x1b[44m\", \"\\x1b[49m\") : String;\nexport const bgMagenta = enabled ? formatter(\"\\x1b[45m\", \"\\x1b[49m\") : String;\nexport const bgCyan = enabled ? formatter(\"\\x1b[46m\", \"\\x1b[49m\") : String;\nexport const bgWhite = enabled ? formatter(\"\\x1b[47m\", \"\\x1b[49m\") : String;\n\n//# sourceMappingURL=picocolors.js.map","import { bold, green, magenta, red, yellow, white } from \"../../lib/picocolors\";\nexport const prefixes = {\n wait: white(bold(\"○\")),\n error: red(bold(\"⨯\")),\n warn: yellow(bold(\"⚠\")),\n ready: bold(\"▲\"),\n info: white(bold(\" \")),\n event: green(bold(\"✓\")),\n trace: magenta(bold(\"\\xbb\"))\n};\nconst LOGGING_METHOD = {\n log: \"log\",\n warn: \"warn\",\n error: \"error\"\n};\nfunction prefixedLog(prefixType, ...message) {\n if ((message[0] === \"\" || message[0] === undefined) && message.length === 1) {\n message.shift();\n }\n const consoleMethod = prefixType in LOGGING_METHOD ? LOGGING_METHOD[prefixType] : \"log\";\n const prefix = prefixes[prefixType];\n // If there's no message, don't print the prefix but a new line\n if (message.length === 0) {\n console[consoleMethod](\"\");\n } else {\n console[consoleMethod](\" \" + prefix, ...message);\n }\n}\nexport function bootstrap(...message) {\n console.log(\" \", ...message);\n}\nexport function wait(...message) {\n prefixedLog(\"wait\", ...message);\n}\nexport function error(...message) {\n prefixedLog(\"error\", ...message);\n}\nexport function warn(...message) {\n prefixedLog(\"warn\", ...message);\n}\nexport function ready(...message) {\n prefixedLog(\"ready\", ...message);\n}\nexport function info(...message) {\n prefixedLog(\"info\", ...message);\n}\nexport function event(...message) {\n prefixedLog(\"event\", ...message);\n}\nexport function trace(...message) {\n prefixedLog(\"trace\", ...message);\n}\nconst warnOnceMessages = new Set();\nexport function warnOnce(...message) {\n if (!warnOnceMessages.has(message[0])) {\n warnOnceMessages.add(message.join(\" \"));\n warn(...message);\n }\n}\n\n//# sourceMappingURL=log.js.map","export const NEXT_QUERY_PARAM_PREFIX = \"nxtP\";\nexport const PRERENDER_REVALIDATE_HEADER = \"x-prerender-revalidate\";\nexport const PRERENDER_REVALIDATE_ONLY_GENERATED_HEADER = \"x-prerender-revalidate-if-generated\";\nexport const NEXT_CACHE_TAGS_HEADER = \"x-next-cache-tags\";\nexport const NEXT_CACHE_SOFT_TAGS_HEADER = \"x-next-cache-soft-tags\";\nexport const NEXT_CACHE_REVALIDATED_TAGS_HEADER = \"x-next-revalidated-tags\";\nexport const NEXT_CACHE_REVALIDATE_TAG_TOKEN_HEADER = \"x-next-revalidate-tag-token\";\nexport const NEXT_CACHE_TAG_MAX_LENGTH = 256;\nexport const NEXT_CACHE_SOFT_TAG_MAX_LENGTH = 1024;\nexport const NEXT_CACHE_IMPLICIT_TAG_ID = \"_N_T_\";\n// in seconds\nexport const CACHE_ONE_YEAR = 31536000;\n// Patterns to detect middleware files\nexport const MIDDLEWARE_FILENAME = \"middleware\";\nexport const MIDDLEWARE_LOCATION_REGEXP = `(?:src/)?${MIDDLEWARE_FILENAME}`;\n// Pattern to detect instrumentation hooks file\nexport const INSTRUMENTATION_HOOK_FILENAME = \"instrumentation\";\n// Because on Windows absolute paths in the generated code can break because of numbers, eg 1 in the path,\n// we have to use a private alias\nexport const PAGES_DIR_ALIAS = \"private-next-pages\";\nexport const DOT_NEXT_ALIAS = \"private-dot-next\";\nexport const ROOT_DIR_ALIAS = \"private-next-root-dir\";\nexport const APP_DIR_ALIAS = \"private-next-app-dir\";\nexport const RSC_MOD_REF_PROXY_ALIAS = \"private-next-rsc-mod-ref-proxy\";\nexport const RSC_ACTION_VALIDATE_ALIAS = \"private-next-rsc-action-validate\";\nexport const RSC_ACTION_PROXY_ALIAS = \"private-next-rsc-action-proxy\";\nexport const RSC_ACTION_CLIENT_WRAPPER_ALIAS = \"private-next-rsc-action-client-wrapper\";\nexport const PUBLIC_DIR_MIDDLEWARE_CONFLICT = `You can not have a '_next' folder inside of your public folder. This conflicts with the internal '/_next' route. https://nextjs.org/docs/messages/public-next-folder-conflict`;\nexport const SSG_GET_INITIAL_PROPS_CONFLICT = `You can not use getInitialProps with getStaticProps. To use SSG, please remove your getInitialProps`;\nexport const SERVER_PROPS_GET_INIT_PROPS_CONFLICT = `You can not use getInitialProps with getServerSideProps. Please remove getInitialProps.`;\nexport const SERVER_PROPS_SSG_CONFLICT = `You can not use getStaticProps or getStaticPaths with getServerSideProps. To use SSG, please remove getServerSideProps`;\nexport const STATIC_STATUS_PAGE_GET_INITIAL_PROPS_ERROR = `can not have getInitialProps/getServerSideProps, https://nextjs.org/docs/messages/404-get-initial-props`;\nexport const SERVER_PROPS_EXPORT_ERROR = `pages with \\`getServerSideProps\\` can not be exported. See more info here: https://nextjs.org/docs/messages/gssp-export`;\nexport const GSP_NO_RETURNED_VALUE = \"Your `getStaticProps` function did not return an object. Did you forget to add a `return`?\";\nexport const GSSP_NO_RETURNED_VALUE = \"Your `getServerSideProps` function did not return an object. Did you forget to add a `return`?\";\nexport const UNSTABLE_REVALIDATE_RENAME_ERROR = \"The `unstable_revalidate` property is available for general use.\\n\" + \"Please use `revalidate` instead.\";\nexport const GSSP_COMPONENT_MEMBER_ERROR = `can not be attached to a page's component and must be exported from the page. See more info here: https://nextjs.org/docs/messages/gssp-component-member`;\nexport const NON_STANDARD_NODE_ENV = `You are using a non-standard \"NODE_ENV\" value in your environment. This creates inconsistencies in the project and is strongly advised against. Read more: https://nextjs.org/docs/messages/non-standard-node-env`;\nexport const SSG_FALLBACK_EXPORT_ERROR = `Pages with \\`fallback\\` enabled in \\`getStaticPaths\\` can not be exported. See more info here: https://nextjs.org/docs/messages/ssg-fallback-true-export`;\nexport const ESLINT_DEFAULT_DIRS = [\n \"app\",\n \"pages\",\n \"components\",\n \"lib\",\n \"src\"\n];\nexport const ESLINT_PROMPT_VALUES = [\n {\n title: \"Strict\",\n recommended: true,\n config: {\n extends: \"next/core-web-vitals\"\n }\n },\n {\n title: \"Base\",\n config: {\n extends: \"next\"\n }\n },\n {\n title: \"Cancel\",\n config: null\n }\n];\nexport const SERVER_RUNTIME = {\n edge: \"edge\",\n experimentalEdge: \"experimental-edge\",\n nodejs: \"nodejs\"\n};\n/**\n * The names of the webpack layers. These layers are the primitives for the\n * webpack chunks.\n */ const WEBPACK_LAYERS_NAMES = {\n /**\n * The layer for the shared code between the client and server bundles.\n */ shared: \"shared\",\n /**\n * React Server Components layer (rsc).\n */ reactServerComponents: \"rsc\",\n /**\n * Server Side Rendering layer for app (ssr).\n */ serverSideRendering: \"ssr\",\n /**\n * The browser client bundle layer for actions.\n */ actionBrowser: \"action-browser\",\n /**\n * The layer for the API routes.\n */ api: \"api\",\n /**\n * The layer for the middleware code.\n */ middleware: \"middleware\",\n /**\n * The layer for assets on the edge.\n */ edgeAsset: \"edge-asset\",\n /**\n * The browser client bundle layer for App directory.\n */ appPagesBrowser: \"app-pages-browser\",\n /**\n * The server bundle layer for metadata routes.\n */ appMetadataRoute: \"app-metadata-route\",\n /**\n * The layer for the server bundle for App Route handlers.\n */ appRouteHandler: \"app-route-handler\"\n};\nconst WEBPACK_LAYERS = {\n ...WEBPACK_LAYERS_NAMES,\n GROUP: {\n server: [\n WEBPACK_LAYERS_NAMES.reactServerComponents,\n WEBPACK_LAYERS_NAMES.actionBrowser,\n WEBPACK_LAYERS_NAMES.appMetadataRoute,\n WEBPACK_LAYERS_NAMES.appRouteHandler\n ],\n nonClientServerTarget: [\n // plus middleware and pages api\n WEBPACK_LAYERS_NAMES.middleware,\n WEBPACK_LAYERS_NAMES.api\n ],\n app: [\n WEBPACK_LAYERS_NAMES.reactServerComponents,\n WEBPACK_LAYERS_NAMES.actionBrowser,\n WEBPACK_LAYERS_NAMES.appMetadataRoute,\n WEBPACK_LAYERS_NAMES.appRouteHandler,\n WEBPACK_LAYERS_NAMES.serverSideRendering,\n WEBPACK_LAYERS_NAMES.appPagesBrowser\n ]\n }\n};\nconst WEBPACK_RESOURCE_QUERIES = {\n edgeSSREntry: \"__next_edge_ssr_entry__\",\n metadata: \"__next_metadata__\",\n metadataRoute: \"__next_metadata_route__\",\n metadataImageMeta: \"__next_metadata_image_meta__\"\n};\nexport { WEBPACK_LAYERS, WEBPACK_RESOURCE_QUERIES };\n\n//# sourceMappingURL=constants.js.map","export function nonNullable(value) {\n return value !== null && value !== undefined;\n}\n\n//# sourceMappingURL=non-nullable.js.map","import { HeadersAdapter } from \"../web/spec-extension/adapters/headers\";\nimport { PRERENDER_REVALIDATE_HEADER, PRERENDER_REVALIDATE_ONLY_GENERATED_HEADER } from \"../../lib/constants\";\n/**\n *\n * @param res response object\n * @param statusCode `HTTP` status code of response\n */ export function sendStatusCode(res, statusCode) {\n res.statusCode = statusCode;\n return res;\n}\n/**\n *\n * @param res response object\n * @param [statusOrUrl] `HTTP` status code of redirect\n * @param url URL of redirect\n */ export function redirect(res, statusOrUrl, url) {\n if (typeof statusOrUrl === \"string\") {\n url = statusOrUrl;\n statusOrUrl = 307;\n }\n if (typeof statusOrUrl !== \"number\" || typeof url !== \"string\") {\n throw new Error(`Invalid redirect arguments. Please use a single argument URL, e.g. res.redirect('/destination') or use a status code and URL, e.g. res.redirect(307, '/destination').`);\n }\n res.writeHead(statusOrUrl, {\n Location: url\n });\n res.write(url);\n res.end();\n return res;\n}\nexport function checkIsOnDemandRevalidate(req, previewProps) {\n const headers = HeadersAdapter.from(req.headers);\n const previewModeId = headers.get(PRERENDER_REVALIDATE_HEADER);\n const isOnDemandRevalidate = previewModeId === previewProps.previewModeId;\n const revalidateOnlyGenerated = headers.has(PRERENDER_REVALIDATE_ONLY_GENERATED_HEADER);\n return {\n isOnDemandRevalidate,\n revalidateOnlyGenerated\n };\n}\nexport const COOKIE_NAME_PRERENDER_BYPASS = `__prerender_bypass`;\nexport const COOKIE_NAME_PRERENDER_DATA = `__next_preview_data`;\nexport const RESPONSE_LIMIT_DEFAULT = 4 * 1024 * 1024;\nexport const SYMBOL_PREVIEW_DATA = Symbol(COOKIE_NAME_PRERENDER_DATA);\nexport const SYMBOL_CLEARED_COOKIES = Symbol(COOKIE_NAME_PRERENDER_BYPASS);\nexport function clearPreviewData(res, options = {}) {\n if (SYMBOL_CLEARED_COOKIES in res) {\n return res;\n }\n const { serialize } = require(\"next/dist/compiled/cookie\");\n const previous = res.getHeader(\"Set-Cookie\");\n res.setHeader(`Set-Cookie`, [\n ...typeof previous === \"string\" ? [\n previous\n ] : Array.isArray(previous) ? previous : [],\n serialize(COOKIE_NAME_PRERENDER_BYPASS, \"\", {\n // To delete a cookie, set `expires` to a date in the past:\n // https://tools.ietf.org/html/rfc6265#section-4.1.1\n // `Max-Age: 0` is not valid, thus ignored, and the cookie is persisted.\n expires: new Date(0),\n httpOnly: true,\n sameSite: process.env.NODE_ENV !== \"development\" ? \"none\" : \"lax\",\n secure: process.env.NODE_ENV !== \"development\",\n path: \"/\",\n ...options.path !== undefined ? {\n path: options.path\n } : undefined\n }),\n serialize(COOKIE_NAME_PRERENDER_DATA, \"\", {\n // To delete a cookie, set `expires` to a date in the past:\n // https://tools.ietf.org/html/rfc6265#section-4.1.1\n // `Max-Age: 0` is not valid, thus ignored, and the cookie is persisted.\n expires: new Date(0),\n httpOnly: true,\n sameSite: process.env.NODE_ENV !== \"development\" ? \"none\" : \"lax\",\n secure: process.env.NODE_ENV !== \"development\",\n path: \"/\",\n ...options.path !== undefined ? {\n path: options.path\n } : undefined\n })\n ]);\n Object.defineProperty(res, SYMBOL_CLEARED_COOKIES, {\n value: true,\n enumerable: false\n });\n return res;\n}\n/**\n * Custom error class\n */ export class ApiError extends Error {\n constructor(statusCode, message){\n super(message);\n this.statusCode = statusCode;\n }\n}\n/**\n * Sends error in `response`\n * @param res response object\n * @param statusCode of response\n * @param message of response\n */ export function sendError(res, statusCode, message) {\n res.statusCode = statusCode;\n res.statusMessage = message;\n res.end(message);\n}\n/**\n * Execute getter function only if its needed\n * @param LazyProps `req` and `params` for lazyProp\n * @param prop name of property\n * @param getter function to get data\n */ export function setLazyProp({ req }, prop, getter) {\n const opts = {\n configurable: true,\n enumerable: true\n };\n const optsReset = {\n ...opts,\n writable: true\n };\n Object.defineProperty(req, prop, {\n ...opts,\n get: ()=>{\n const value = getter();\n // we set the property on the object to avoid recalculating it\n Object.defineProperty(req, prop, {\n ...optsReset,\n value\n });\n return value;\n },\n set: (value)=>{\n Object.defineProperty(req, prop, {\n ...optsReset,\n value\n });\n }\n });\n}\n\n//# sourceMappingURL=index.js.map","import { checkIsOnDemandRevalidate } from \"../.\";\nimport { clearPreviewData, COOKIE_NAME_PRERENDER_BYPASS, COOKIE_NAME_PRERENDER_DATA, SYMBOL_PREVIEW_DATA } from \"../index\";\nimport { RequestCookies } from \"../../web/spec-extension/cookies\";\nimport { HeadersAdapter } from \"../../web/spec-extension/adapters/headers\";\nexport function tryGetPreviewData(req, res, options) {\n var _cookies_get, _cookies_get1;\n // if an On-Demand revalidation is being done preview mode\n // is disabled\n if (options && checkIsOnDemandRevalidate(req, options).isOnDemandRevalidate) {\n return false;\n }\n // Read cached preview data if present\n // TODO: use request metadata instead of a symbol\n if (SYMBOL_PREVIEW_DATA in req) {\n return req[SYMBOL_PREVIEW_DATA];\n }\n const headers = HeadersAdapter.from(req.headers);\n const cookies = new RequestCookies(headers);\n const previewModeId = (_cookies_get = cookies.get(COOKIE_NAME_PRERENDER_BYPASS)) == null ? void 0 : _cookies_get.value;\n const tokenPreviewData = (_cookies_get1 = cookies.get(COOKIE_NAME_PRERENDER_DATA)) == null ? void 0 : _cookies_get1.value;\n // Case: preview mode cookie set but data cookie is not set\n if (previewModeId && !tokenPreviewData && previewModeId === options.previewModeId) {\n // This is \"Draft Mode\" which doesn't use\n // previewData, so we return an empty object\n // for backwards compat with \"Preview Mode\".\n const data = {};\n Object.defineProperty(req, SYMBOL_PREVIEW_DATA, {\n value: data,\n enumerable: false\n });\n return data;\n }\n // Case: neither cookie is set.\n if (!previewModeId && !tokenPreviewData) {\n return false;\n }\n // Case: one cookie is set, but not the other.\n if (!previewModeId || !tokenPreviewData) {\n clearPreviewData(res);\n return false;\n }\n // Case: preview session is for an old build.\n if (previewModeId !== options.previewModeId) {\n clearPreviewData(res);\n return false;\n }\n let encryptedPreviewData;\n try {\n const jsonwebtoken = require(\"next/dist/compiled/jsonwebtoken\");\n encryptedPreviewData = jsonwebtoken.verify(tokenPreviewData, options.previewModeSigningKey);\n } catch {\n // TODO: warn\n clearPreviewData(res);\n return false;\n }\n const { decryptWithSecret } = require(\"../../crypto-utils\");\n const decryptedPreviewData = decryptWithSecret(Buffer.from(options.previewModeEncryptionKey), encryptedPreviewData.data);\n try {\n // TODO: strict runtime type checking\n const data = JSON.parse(decryptedPreviewData);\n // Cache lookup\n Object.defineProperty(req, SYMBOL_PREVIEW_DATA, {\n value: data,\n enumerable: false\n });\n return data;\n } catch {\n return false;\n }\n}\n\n//# sourceMappingURL=try-get-preview-data.js.map","const __WEBPACK_NAMESPACE_OBJECT__ = require(\"crypto\");","import crypto from \"crypto\";\n// Background:\n// https://security.stackexchange.com/questions/184305/why-would-i-ever-use-aes-256-cbc-if-aes-256-gcm-is-more-secure\nconst CIPHER_ALGORITHM = `aes-256-gcm`, CIPHER_KEY_LENGTH = 32, CIPHER_IV_LENGTH = 16, CIPHER_TAG_LENGTH = 16, CIPHER_SALT_LENGTH = 64;\nconst PBKDF2_ITERATIONS = 100000 // https://support.1password.com/pbkdf2/\n;\nexport function encryptWithSecret(secret, data) {\n const iv = crypto.randomBytes(CIPHER_IV_LENGTH);\n const salt = crypto.randomBytes(CIPHER_SALT_LENGTH);\n // https://nodejs.org/api/crypto.html#crypto_crypto_pbkdf2sync_password_salt_iterations_keylen_digest\n const key = crypto.pbkdf2Sync(secret, salt, PBKDF2_ITERATIONS, CIPHER_KEY_LENGTH, `sha512`);\n const cipher = crypto.createCipheriv(CIPHER_ALGORITHM, key, iv);\n const encrypted = Buffer.concat([\n cipher.update(data, `utf8`),\n cipher.final()\n ]);\n // https://nodejs.org/api/crypto.html#crypto_cipher_getauthtag\n const tag = cipher.getAuthTag();\n return Buffer.concat([\n // Data as required by:\n // Salt for Key: https://nodejs.org/api/crypto.html#crypto_crypto_pbkdf2sync_password_salt_iterations_keylen_digest\n // IV: https://nodejs.org/api/crypto.html#crypto_class_decipher\n // Tag: https://nodejs.org/api/crypto.html#crypto_decipher_setauthtag_buffer\n salt,\n iv,\n tag,\n encrypted\n ]).toString(`hex`);\n}\nexport function decryptWithSecret(secret, encryptedData) {\n const buffer = Buffer.from(encryptedData, `hex`);\n const salt = buffer.slice(0, CIPHER_SALT_LENGTH);\n const iv = buffer.slice(CIPHER_SALT_LENGTH, CIPHER_SALT_LENGTH + CIPHER_IV_LENGTH);\n const tag = buffer.slice(CIPHER_SALT_LENGTH + CIPHER_IV_LENGTH, CIPHER_SALT_LENGTH + CIPHER_IV_LENGTH + CIPHER_TAG_LENGTH);\n const encrypted = buffer.slice(CIPHER_SALT_LENGTH + CIPHER_IV_LENGTH + CIPHER_TAG_LENGTH);\n // https://nodejs.org/api/crypto.html#crypto_crypto_pbkdf2sync_password_salt_iterations_keylen_digest\n const key = crypto.pbkdf2Sync(secret, salt, PBKDF2_ITERATIONS, CIPHER_KEY_LENGTH, `sha512`);\n const decipher = crypto.createDecipheriv(CIPHER_ALGORITHM, key, iv);\n decipher.setAuthTag(tag);\n return decipher.update(encrypted) + decipher.final(`utf8`);\n}\n\n//# sourceMappingURL=crypto-utils.js.map","import * as Log from \"../build/output/log\";\nimport { GOOGLE_FONT_PROVIDER, DEFAULT_SERIF_FONT, DEFAULT_SANS_SERIF_FONT } from \"../shared/lib/constants\";\nconst capsizeFontsMetrics = require(\"next/dist/server/capsize-font-metrics.json\");\nconst https = require(\"https\");\nconst CHROME_UA = \"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Safari/537.36\";\nconst IE_UA = \"Mozilla/5.0 (Windows NT 10.0; Trident/7.0; rv:11.0) like Gecko\";\nfunction isGoogleFont(url) {\n return url.startsWith(GOOGLE_FONT_PROVIDER);\n}\nfunction getFontForUA(url, UA) {\n return new Promise((resolve, reject)=>{\n let rawData = \"\";\n https.get(url, {\n headers: {\n \"user-agent\": UA\n }\n }, (res)=>{\n res.on(\"data\", (chunk)=>{\n rawData += chunk;\n });\n res.on(\"end\", ()=>{\n resolve(rawData.toString(\"utf8\"));\n });\n }).on(\"error\", (e)=>{\n reject(e);\n });\n });\n}\nexport async function getFontDefinitionFromNetwork(url) {\n let result = \"\";\n /**\n * The order of IE -> Chrome is important, other wise chrome starts loading woff1.\n * CSS cascading 🤷‍♂️.\n */ try {\n if (isGoogleFont(url)) {\n result += await getFontForUA(url, IE_UA);\n }\n result += await getFontForUA(url, CHROME_UA);\n } catch (e) {\n Log.warn(`Failed to download the stylesheet for ${url}. Skipped optimizing this font.`);\n return \"\";\n }\n return result;\n}\nexport function getFontDefinitionFromManifest(url, manifest) {\n var _manifest_find;\n return ((_manifest_find = manifest.find((font)=>{\n if (font && font.url === url) {\n return true;\n }\n return false;\n })) == null ? void 0 : _manifest_find.content) || \"\";\n}\nfunction parseGoogleFontName(css) {\n const regex = /font-family: ([^;]*)/g;\n const matches = css.matchAll(regex);\n const fontNames = new Set();\n for (let font of matches){\n const fontFamily = font[1].replace(/^['\"]|['\"]$/g, \"\");\n fontNames.add(fontFamily);\n }\n return [\n ...fontNames\n ];\n}\nfunction formatName(str) {\n return str.replace(/(?:^\\w|[A-Z]|\\b\\w)/g, function(word, index) {\n return index === 0 ? word.toLowerCase() : word.toUpperCase();\n }).replace(/\\s+/g, \"\");\n}\nfunction formatOverrideValue(val) {\n return Math.abs(val * 100).toFixed(2);\n}\nexport function calculateOverrideValues(fontName) {\n const fontKey = formatName(fontName);\n const fontMetrics = capsizeFontsMetrics[fontKey];\n let { category, ascent, descent, lineGap, unitsPerEm } = fontMetrics;\n const fallbackFont = category === \"serif\" ? DEFAULT_SERIF_FONT : DEFAULT_SANS_SERIF_FONT;\n ascent = formatOverrideValue(ascent / unitsPerEm);\n descent = formatOverrideValue(descent / unitsPerEm);\n lineGap = formatOverrideValue(lineGap / unitsPerEm);\n return {\n ascent,\n descent,\n lineGap,\n fallbackFont: fallbackFont.name\n };\n}\nexport function calculateSizeAdjustValues(fontName) {\n const fontKey = formatName(fontName);\n const fontMetrics = capsizeFontsMetrics[fontKey];\n let { category, ascent, descent, lineGap, unitsPerEm, xWidthAvg } = fontMetrics;\n const mainFontAvgWidth = xWidthAvg / unitsPerEm;\n const fallbackFont = category === \"serif\" ? DEFAULT_SERIF_FONT : DEFAULT_SANS_SERIF_FONT;\n const fallbackFontName = formatName(fallbackFont.name);\n const fallbackFontMetrics = capsizeFontsMetrics[fallbackFontName];\n const fallbackFontAvgWidth = fallbackFontMetrics.xWidthAvg / fallbackFontMetrics.unitsPerEm;\n let sizeAdjust = xWidthAvg ? mainFontAvgWidth / fallbackFontAvgWidth : 1;\n ascent = formatOverrideValue(ascent / (unitsPerEm * sizeAdjust));\n descent = formatOverrideValue(descent / (unitsPerEm * sizeAdjust));\n lineGap = formatOverrideValue(lineGap / (unitsPerEm * sizeAdjust));\n return {\n ascent,\n descent,\n lineGap,\n fallbackFont: fallbackFont.name,\n sizeAdjust: formatOverrideValue(sizeAdjust)\n };\n}\nfunction calculateOverrideCSS(font) {\n const fontName = font.trim();\n const { ascent, descent, lineGap, fallbackFont } = calculateOverrideValues(fontName);\n return `\n @font-face {\n font-family: \"${fontName} Fallback\";\n ascent-override: ${ascent}%;\n descent-override: ${descent}%;\n line-gap-override: ${lineGap}%;\n src: local(\"${fallbackFont}\");\n }\n `;\n}\nfunction calculateSizeAdjustCSS(font) {\n const fontName = font.trim();\n const { ascent, descent, lineGap, fallbackFont, sizeAdjust } = calculateSizeAdjustValues(fontName);\n return `\n @font-face {\n font-family: \"${fontName} Fallback\";\n ascent-override: ${ascent}%;\n descent-override: ${descent}%;\n line-gap-override: ${lineGap}%;\n size-adjust: ${sizeAdjust}%;\n src: local(\"${fallbackFont}\");\n }\n `;\n}\nexport function getFontOverrideCss(url, css, useSizeAdjust = false) {\n if (!isGoogleFont(url)) {\n return \"\";\n }\n const calcFn = useSizeAdjust ? calculateSizeAdjustCSS : calculateOverrideCSS;\n try {\n const fontNames = parseGoogleFontName(css);\n const fontCss = fontNames.reduce((cssStr, fontName)=>{\n cssStr += calcFn(fontName);\n return cssStr;\n }, \"\");\n return fontCss;\n } catch (e) {\n console.log(\"Error getting font override values - \", e);\n return \"\";\n }\n}\n\n//# sourceMappingURL=font-utils.js.map","// Polyfill Web Streams for the Node.js runtime.\nif (!global.ReadableStream) {\n // In Node v16, ReadableStream is available natively but under the `stream` namespace.\n // In Node v18+, it's available under global.\n if (require(\"stream/web\").ReadableStream) {\n global.ReadableStream = require(\"stream/web\").ReadableStream;\n } else {\n const { ReadableStream } = require(\"next/dist/compiled/@edge-runtime/ponyfill\");\n global.ReadableStream = ReadableStream;\n }\n}\nif (!global.TransformStream) {\n // Same as ReadableStream above.\n if (require(\"stream/web\").TransformStream) {\n global.TransformStream = require(\"stream/web\").TransformStream;\n } else {\n const { TransformStream } = require(\"next/dist/compiled/@edge-runtime/ponyfill\");\n global.TransformStream = TransformStream;\n }\n}\n\n//# sourceMappingURL=node-polyfill-web-streams.js.map","export default async function optimize(html, config) {\n let AmpOptimizer;\n try {\n AmpOptimizer = require(\"next/dist/compiled/@ampproject/toolbox-optimizer\");\n } catch (_) {\n return html;\n }\n const optimizer = AmpOptimizer.create(config);\n return optimizer.transformHtml(html, config);\n}\n\n//# sourceMappingURL=optimize-amp.js.map","import { OPTIMIZED_FONT_PROVIDERS } from \"../shared/lib/constants\";\nimport { nonNullable } from \"../lib/non-nullable\";\nconst middlewareRegistry = [];\nfunction registerPostProcessor(name, middleware, condition) {\n middlewareRegistry.push({\n name,\n middleware,\n condition: condition || null\n });\n}\nasync function processHTML(html, data, options) {\n // Don't parse unless there's at least one processor middleware\n if (!middlewareRegistry[0]) {\n return html;\n }\n const { parse } = require(\"next/dist/compiled/node-html-parser\");\n const root = parse(html);\n let document = html;\n // Calls the middleware, with some instrumentation and logging\n async function callMiddleWare(middleware) {\n // let timer = Date.now()\n const inspectData = middleware.inspect(root, data);\n document = await middleware.mutate(document, inspectData, data);\n // timer = Date.now() - timer\n // if (timer > MIDDLEWARE_TIME_BUDGET) {\n // TODO: Identify a correct upper limit for the postprocess step\n // and add a warning to disable the optimization\n // }\n return;\n }\n for(let i = 0; i < middlewareRegistry.length; i++){\n let middleware = middlewareRegistry[i];\n if (!middleware.condition || middleware.condition(options)) {\n await callMiddleWare(middlewareRegistry[i].middleware);\n }\n }\n return document;\n}\nclass FontOptimizerMiddleware {\n inspect(originalDom, options) {\n if (!options.getFontDefinition) {\n return;\n }\n const fontDefinitions = [];\n // collecting all the requested font definitions\n originalDom.querySelectorAll(\"link\").filter((tag)=>tag.getAttribute(\"rel\") === \"stylesheet\" && tag.hasAttribute(\"data-href\") && OPTIMIZED_FONT_PROVIDERS.some(({ url })=>{\n const dataHref = tag.getAttribute(\"data-href\");\n return dataHref ? dataHref.startsWith(url) : false;\n })).forEach((element)=>{\n const url = element.getAttribute(\"data-href\");\n const nonce = element.getAttribute(\"nonce\");\n if (url) {\n fontDefinitions.push([\n url,\n nonce\n ]);\n }\n });\n return fontDefinitions;\n }\n constructor(){\n this.mutate = async (markup, fontDefinitions, options)=>{\n let result = markup;\n let preconnectUrls = new Set();\n if (!options.getFontDefinition) {\n return markup;\n }\n fontDefinitions.forEach((fontDef)=>{\n const [url, nonce] = fontDef;\n const fallBackLinkTag = ``;\n if (result.indexOf(``);\n // Remove inert font tag\n const escapedUrl = url.replace(/&/g, \"&\").replace(/[.*+?^${}()|[\\]\\\\]/g, \"\\\\$&\");\n const fontRegex = new RegExp(`]*data-href=\"${escapedUrl}\"[^>]*/>`);\n result = result.replace(fontRegex, \"\");\n const provider = OPTIMIZED_FONT_PROVIDERS.find((p)=>url.startsWith(p.url));\n if (provider) {\n preconnectUrls.add(provider.preconnect);\n }\n }\n });\n let preconnectTag = \"\";\n preconnectUrls.forEach((url)=>{\n preconnectTag += ``;\n });\n result = result.replace('', preconnectTag);\n return result;\n };\n }\n}\nasync function postProcessHTML(pathname, content, renderOpts, { inAmpMode, hybridAmp }) {\n const postProcessors = [\n process.env.NEXT_RUNTIME !== \"edge\" && inAmpMode ? async (html)=>{\n const optimizeAmp = require(\"./optimize-amp\").default;\n html = await optimizeAmp(html, renderOpts.ampOptimizerConfig);\n if (!renderOpts.ampSkipValidation && renderOpts.ampValidator) {\n await renderOpts.ampValidator(html, pathname);\n }\n return html;\n } : null,\n process.env.NEXT_RUNTIME !== \"edge\" && renderOpts.optimizeFonts ? async (html)=>{\n const getFontDefinition = (url)=>{\n if (renderOpts.fontManifest) {\n const { getFontDefinitionFromManifest } = require(\"./font-utils\");\n return getFontDefinitionFromManifest(url, renderOpts.fontManifest);\n }\n return \"\";\n };\n return await processHTML(html, {\n getFontDefinition\n }, {\n optimizeFonts: renderOpts.optimizeFonts\n });\n } : null,\n process.env.NEXT_RUNTIME !== \"edge\" && renderOpts.optimizeCss ? async (html)=>{\n // eslint-disable-next-line import/no-extraneous-dependencies\n const Critters = require(\"critters\");\n const cssOptimizer = new Critters({\n ssrMode: true,\n reduceInlineStyles: false,\n path: renderOpts.distDir,\n publicPath: `${renderOpts.assetPrefix}/_next/`,\n preload: \"media\",\n fonts: false,\n ...renderOpts.optimizeCss\n });\n return await cssOptimizer.process(html);\n } : null,\n inAmpMode || hybridAmp ? (html)=>{\n return html.replace(/&amp=1/g, \"&=1\");\n } : null\n ].filter(nonNullable);\n for (const postProcessor of postProcessors){\n if (postProcessor) {\n content = await postProcessor(content);\n }\n }\n return content;\n}\n// Initialization\nregisterPostProcessor(\"Inline-Fonts\", new FontOptimizerMiddleware(), // Using process.env because passing Experimental flag through loader is not possible.\n// @ts-ignore\n(options)=>options.optimizeFonts || process.env.__NEXT_OPTIMIZE_FONTS);\nexport { postProcessHTML };\n\n//# sourceMappingURL=post-process.js.map","import { ReflectAdapter } from \"./reflect\";\n/**\n * @internal\n */ export class ReadonlyHeadersError extends Error {\n constructor(){\n super(\"Headers cannot be modified. Read more: https://nextjs.org/docs/app/api-reference/functions/headers\");\n }\n static callable() {\n throw new ReadonlyHeadersError();\n }\n}\nexport class HeadersAdapter extends Headers {\n constructor(headers){\n // We've already overridden the methods that would be called, so we're just\n // calling the super constructor to ensure that the instanceof check works.\n super();\n this.headers = new Proxy(headers, {\n get (target, prop, receiver) {\n // Because this is just an object, we expect that all \"get\" operations\n // are for properties. If it's a \"get\" for a symbol, we'll just return\n // the symbol.\n if (typeof prop === \"symbol\") {\n return ReflectAdapter.get(target, prop, receiver);\n }\n const lowercased = prop.toLowerCase();\n // Let's find the original casing of the key. This assumes that there is\n // no mixed case keys (e.g. \"Content-Type\" and \"content-type\") in the\n // headers object.\n const original = Object.keys(headers).find((o)=>o.toLowerCase() === lowercased);\n // If the original casing doesn't exist, return undefined.\n if (typeof original === \"undefined\") return;\n // If the original casing exists, return the value.\n return ReflectAdapter.get(target, original, receiver);\n },\n set (target, prop, value, receiver) {\n if (typeof prop === \"symbol\") {\n return ReflectAdapter.set(target, prop, value, receiver);\n }\n const lowercased = prop.toLowerCase();\n // Let's find the original casing of the key. This assumes that there is\n // no mixed case keys (e.g. \"Content-Type\" and \"content-type\") in the\n // headers object.\n const original = Object.keys(headers).find((o)=>o.toLowerCase() === lowercased);\n // If the original casing doesn't exist, use the prop as the key.\n return ReflectAdapter.set(target, original ?? prop, value, receiver);\n },\n has (target, prop) {\n if (typeof prop === \"symbol\") return ReflectAdapter.has(target, prop);\n const lowercased = prop.toLowerCase();\n // Let's find the original casing of the key. This assumes that there is\n // no mixed case keys (e.g. \"Content-Type\" and \"content-type\") in the\n // headers object.\n const original = Object.keys(headers).find((o)=>o.toLowerCase() === lowercased);\n // If the original casing doesn't exist, return false.\n if (typeof original === \"undefined\") return false;\n // If the original casing exists, return true.\n return ReflectAdapter.has(target, original);\n },\n deleteProperty (target, prop) {\n if (typeof prop === \"symbol\") return ReflectAdapter.deleteProperty(target, prop);\n const lowercased = prop.toLowerCase();\n // Let's find the original casing of the key. This assumes that there is\n // no mixed case keys (e.g. \"Content-Type\" and \"content-type\") in the\n // headers object.\n const original = Object.keys(headers).find((o)=>o.toLowerCase() === lowercased);\n // If the original casing doesn't exist, return true.\n if (typeof original === \"undefined\") return true;\n // If the original casing exists, delete the property.\n return ReflectAdapter.deleteProperty(target, original);\n }\n });\n }\n /**\n * Seals a Headers instance to prevent modification by throwing an error when\n * any mutating method is called.\n */ static seal(headers) {\n return new Proxy(headers, {\n get (target, prop, receiver) {\n switch(prop){\n case \"append\":\n case \"delete\":\n case \"set\":\n return ReadonlyHeadersError.callable;\n default:\n return ReflectAdapter.get(target, prop, receiver);\n }\n }\n });\n }\n /**\n * Merges a header value into a string. This stores multiple values as an\n * array, so we need to merge them into a string.\n *\n * @param value a header value\n * @returns a merged header value (a string)\n */ merge(value) {\n if (Array.isArray(value)) return value.join(\", \");\n return value;\n }\n /**\n * Creates a Headers instance from a plain object or a Headers instance.\n *\n * @param headers a plain object or a Headers instance\n * @returns a headers instance\n */ static from(headers) {\n if (headers instanceof Headers) return headers;\n return new HeadersAdapter(headers);\n }\n append(name, value) {\n const existing = this.headers[name];\n if (typeof existing === \"string\") {\n this.headers[name] = [\n existing,\n value\n ];\n } else if (Array.isArray(existing)) {\n existing.push(value);\n } else {\n this.headers[name] = value;\n }\n }\n delete(name) {\n delete this.headers[name];\n }\n get(name) {\n const value = this.headers[name];\n if (typeof value !== \"undefined\") return this.merge(value);\n return null;\n }\n has(name) {\n return typeof this.headers[name] !== \"undefined\";\n }\n set(name, value) {\n this.headers[name] = value;\n }\n forEach(callbackfn, thisArg) {\n for (const [name, value] of this.entries()){\n callbackfn.call(thisArg, value, name, this);\n }\n }\n *entries() {\n for (const key of Object.keys(this.headers)){\n const name = key.toLowerCase();\n // We assert here that this is a string because we got it from the\n // Object.keys() call above.\n const value = this.get(name);\n yield [\n name,\n value\n ];\n }\n }\n *keys() {\n for (const key of Object.keys(this.headers)){\n const name = key.toLowerCase();\n yield name;\n }\n }\n *values() {\n for (const key of Object.keys(this.headers)){\n // We assert here that this is a string because we got it from the\n // Object.keys() call above.\n const value = this.get(key);\n yield value;\n }\n }\n [Symbol.iterator]() {\n return this.entries();\n }\n}\n\n//# sourceMappingURL=headers.js.map","export class ReflectAdapter {\n static get(target, prop, receiver) {\n const value = Reflect.get(target, prop, receiver);\n if (typeof value === \"function\") {\n return value.bind(target);\n }\n return value;\n }\n static set(target, prop, value, receiver) {\n return Reflect.set(target, prop, value, receiver);\n }\n static has(target, prop) {\n return Reflect.has(target, prop);\n }\n static deleteProperty(target, prop) {\n return Reflect.deleteProperty(target, prop);\n }\n}\n\n//# sourceMappingURL=reflect.js.map","import MODERN_BROWSERSLIST_TARGET from \"./modern-browserslist-target\";\nexport { MODERN_BROWSERSLIST_TARGET };\nexport const COMPILER_NAMES = {\n client: \"client\",\n server: \"server\",\n edgeServer: \"edge-server\"\n};\nexport const INTERNAL_HEADERS = [\n \"x-invoke-path\",\n \"x-invoke-status\",\n \"x-invoke-error\",\n \"x-invoke-query\",\n \"x-middleware-invoke\"\n];\nexport const COMPILER_INDEXES = {\n [COMPILER_NAMES.client]: 0,\n [COMPILER_NAMES.server]: 1,\n [COMPILER_NAMES.edgeServer]: 2\n};\nexport const PHASE_EXPORT = \"phase-export\";\nexport const PHASE_PRODUCTION_BUILD = \"phase-production-build\";\nexport const PHASE_PRODUCTION_SERVER = \"phase-production-server\";\nexport const PHASE_DEVELOPMENT_SERVER = \"phase-development-server\";\nexport const PHASE_TEST = \"phase-test\";\nexport const PHASE_INFO = \"phase-info\";\nexport const PAGES_MANIFEST = \"pages-manifest.json\";\nexport const APP_PATHS_MANIFEST = \"app-paths-manifest.json\";\nexport const APP_PATH_ROUTES_MANIFEST = \"app-path-routes-manifest.json\";\nexport const BUILD_MANIFEST = \"build-manifest.json\";\nexport const APP_BUILD_MANIFEST = \"app-build-manifest.json\";\nexport const FUNCTIONS_CONFIG_MANIFEST = \"functions-config-manifest.json\";\nexport const SUBRESOURCE_INTEGRITY_MANIFEST = \"subresource-integrity-manifest\";\nexport const NEXT_FONT_MANIFEST = \"next-font-manifest\";\nexport const EXPORT_MARKER = \"export-marker.json\";\nexport const EXPORT_DETAIL = \"export-detail.json\";\nexport const PRERENDER_MANIFEST = \"prerender-manifest.json\";\nexport const ROUTES_MANIFEST = \"routes-manifest.json\";\nexport const IMAGES_MANIFEST = \"images-manifest.json\";\nexport const SERVER_FILES_MANIFEST = \"required-server-files.json\";\nexport const DEV_CLIENT_PAGES_MANIFEST = \"_devPagesManifest.json\";\nexport const MIDDLEWARE_MANIFEST = \"middleware-manifest.json\";\nexport const DEV_MIDDLEWARE_MANIFEST = \"_devMiddlewareManifest.json\";\nexport const REACT_LOADABLE_MANIFEST = \"react-loadable-manifest.json\";\nexport const FONT_MANIFEST = \"font-manifest.json\";\nexport const SERVER_DIRECTORY = \"server\";\nexport const CONFIG_FILES = [\n \"next.config.js\",\n \"next.config.mjs\"\n];\nexport const BUILD_ID_FILE = \"BUILD_ID\";\nexport const BLOCKED_PAGES = [\n \"/_document\",\n \"/_app\",\n \"/_error\"\n];\nexport const CLIENT_PUBLIC_FILES_PATH = \"public\";\nexport const CLIENT_STATIC_FILES_PATH = \"static\";\nexport const STRING_LITERAL_DROP_BUNDLE = \"__NEXT_DROP_CLIENT_FILE__\";\nexport const NEXT_BUILTIN_DOCUMENT = \"__NEXT_BUILTIN_DOCUMENT__\";\nexport const BARREL_OPTIMIZATION_PREFIX = \"__barrel_optimize__\";\n// server/[entry]/page_client-reference-manifest.js\nexport const CLIENT_REFERENCE_MANIFEST = \"client-reference-manifest\";\n// server/server-reference-manifest\nexport const SERVER_REFERENCE_MANIFEST = \"server-reference-manifest\";\n// server/middleware-build-manifest.js\nexport const MIDDLEWARE_BUILD_MANIFEST = \"middleware-build-manifest\";\n// server/middleware-react-loadable-manifest.js\nexport const MIDDLEWARE_REACT_LOADABLE_MANIFEST = \"middleware-react-loadable-manifest\";\n// static/runtime/main.js\nexport const CLIENT_STATIC_FILES_RUNTIME_MAIN = \"main\";\nexport const CLIENT_STATIC_FILES_RUNTIME_MAIN_APP = \"\" + CLIENT_STATIC_FILES_RUNTIME_MAIN + \"-app\";\n// next internal client components chunk for layouts\nexport const APP_CLIENT_INTERNALS = \"app-pages-internals\";\n// static/runtime/react-refresh.js\nexport const CLIENT_STATIC_FILES_RUNTIME_REACT_REFRESH = \"react-refresh\";\n// static/runtime/amp.js\nexport const CLIENT_STATIC_FILES_RUNTIME_AMP = \"amp\";\n// static/runtime/webpack.js\nexport const CLIENT_STATIC_FILES_RUNTIME_WEBPACK = \"webpack\";\n// static/runtime/polyfills.js\nexport const CLIENT_STATIC_FILES_RUNTIME_POLYFILLS = \"polyfills\";\nexport const CLIENT_STATIC_FILES_RUNTIME_POLYFILLS_SYMBOL = Symbol(CLIENT_STATIC_FILES_RUNTIME_POLYFILLS);\nexport const EDGE_RUNTIME_WEBPACK = \"edge-runtime-webpack\";\nexport const TEMPORARY_REDIRECT_STATUS = 307;\nexport const PERMANENT_REDIRECT_STATUS = 308;\nexport const STATIC_PROPS_ID = \"__N_SSG\";\nexport const SERVER_PROPS_ID = \"__N_SSP\";\nexport const PAGE_SEGMENT_KEY = \"__PAGE__\";\nexport const GOOGLE_FONT_PROVIDER = \"https://fonts.googleapis.com/\";\nexport const OPTIMIZED_FONT_PROVIDERS = [\n {\n url: GOOGLE_FONT_PROVIDER,\n preconnect: \"https://fonts.gstatic.com\"\n },\n {\n url: \"https://use.typekit.net\",\n preconnect: \"https://use.typekit.net\"\n }\n];\nexport const DEFAULT_SERIF_FONT = {\n name: \"Times New Roman\",\n xAvgCharWidth: 821,\n azAvgWidth: 854.3953488372093,\n unitsPerEm: 2048\n};\nexport const DEFAULT_SANS_SERIF_FONT = {\n name: \"Arial\",\n xAvgCharWidth: 904,\n azAvgWidth: 934.5116279069767,\n unitsPerEm: 2048\n};\nexport const STATIC_STATUS_PAGES = [\n \"/500\"\n];\nexport const TRACE_OUTPUT_VERSION = 1;\n// in `MB`\nexport const TURBO_TRACE_DEFAULT_MEMORY_LIMIT = 6000;\nexport const RSC_MODULE_TYPES = {\n client: \"client\",\n server: \"server\"\n};\n// comparing\n// https://nextjs.org/docs/api-reference/edge-runtime\n// with\n// https://nodejs.org/docs/latest/api/globals.html\nexport const EDGE_UNSUPPORTED_NODE_APIS = [\n \"clearImmediate\",\n \"setImmediate\",\n \"BroadcastChannel\",\n \"ByteLengthQueuingStrategy\",\n \"CompressionStream\",\n \"CountQueuingStrategy\",\n \"DecompressionStream\",\n \"DomException\",\n \"MessageChannel\",\n \"MessageEvent\",\n \"MessagePort\",\n \"ReadableByteStreamController\",\n \"ReadableStreamBYOBRequest\",\n \"ReadableStreamDefaultController\",\n \"TransformStreamDefaultController\",\n \"WritableStreamDefaultController\"\n];\nexport const SYSTEM_ENTRYPOINTS = new Set([\n CLIENT_STATIC_FILES_RUNTIME_MAIN,\n CLIENT_STATIC_FILES_RUNTIME_REACT_REFRESH,\n CLIENT_STATIC_FILES_RUNTIME_AMP,\n CLIENT_STATIC_FILES_RUNTIME_MAIN_APP\n]);\n\n//# sourceMappingURL=constants.js.map","// Note: This file is JS because it's used by the taskfile-swc.js file, which is JS.\n// Keep file changes in sync with the corresponding `.d.ts` files.\n/**\n * These are the browser versions that support all of the following:\n * static import: https://caniuse.com/es6-module\n * dynamic import: https://caniuse.com/es6-module-dynamic-import\n * import.meta: https://caniuse.com/mdn-javascript_operators_import_meta\n */ const MODERN_BROWSERSLIST_TARGET = [\n \"chrome 64\",\n \"edge 79\",\n \"firefox 67\",\n \"opera 51\",\n \"safari 12\"\n];\nmodule.exports = MODERN_BROWSERSLIST_TARGET;\n\n//# sourceMappingURL=modern-browserslist-target.js.map","module.exports = require(\"critters\");","module.exports = require(\"next/dist/compiled/@ampproject/toolbox-optimizer\");","module.exports = require(\"next/dist/compiled/@edge-runtime/ponyfill\");","module.exports = require(\"next/dist/compiled/@next/react-dev-overlay/dist/middleware\");","module.exports = require(\"next/dist/compiled/jsonwebtoken\");","module.exports = require(\"next/dist/compiled/node-html-parser\");","module.exports = require(\"next/dist/server/capsize-font-metrics.json\");","module.exports = require(\"https\");","module.exports = require(\"path\");","module.exports = require(\"stream/web\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { setLazyProp } from \"./api-utils\";\nimport { getCookieParser } from \"./api-utils/get-cookie-parser\";\nimport React from \"react\";\nimport ReactDOMServer from \"react-dom/server.browser\";\nimport { StyleRegistry, createStyleRegistry } from \"styled-jsx\";\nimport { GSP_NO_RETURNED_VALUE, GSSP_COMPONENT_MEMBER_ERROR, GSSP_NO_RETURNED_VALUE, STATIC_STATUS_PAGE_GET_INITIAL_PROPS_ERROR, SERVER_PROPS_GET_INIT_PROPS_CONFLICT, SERVER_PROPS_SSG_CONFLICT, SSG_GET_INITIAL_PROPS_CONFLICT, UNSTABLE_REVALIDATE_RENAME_ERROR, CACHE_ONE_YEAR } from \"../lib/constants\";\nimport { NEXT_BUILTIN_DOCUMENT, SERVER_PROPS_ID, STATIC_PROPS_ID, STATIC_STATUS_PAGES } from \"../shared/lib/constants\";\nimport { isSerializableProps } from \"../lib/is-serializable-props\";\nimport { isInAmpMode } from \"../shared/lib/amp-mode\";\nimport { AmpStateContext } from \"../shared/lib/amp-context.shared-runtime\";\nimport { defaultHead } from \"../shared/lib/head\";\nimport { HeadManagerContext } from \"../shared/lib/head-manager-context.shared-runtime\";\nimport Loadable from \"../shared/lib/loadable.shared-runtime\";\nimport { LoadableContext } from \"../shared/lib/loadable-context.shared-runtime\";\nimport { RouterContext } from \"../shared/lib/router-context.shared-runtime\";\nimport { isDynamicRoute } from \"../shared/lib/router/utils/is-dynamic\";\nimport { getDisplayName, isResSent, loadGetInitialProps } from \"../shared/lib/utils\";\nimport { HtmlContext } from \"../shared/lib/html-context.shared-runtime\";\nimport { normalizePagePath } from \"../shared/lib/page-path/normalize-page-path\";\nimport { denormalizePagePath } from \"../shared/lib/page-path/denormalize-page-path\";\nimport { getRequestMeta } from \"./request-meta\";\nimport { allowedStatusCodes, getRedirectStatus } from \"../lib/redirect-status\";\nimport RenderResult from \"./render-result\";\nimport isError from \"../lib/is-error\";\nimport { streamFromString, streamToString, chainStreams, renderToInitialFizzStream, continueFizzStream } from \"./stream-utils/node-web-streams-helper\";\nimport { ImageConfigContext } from \"../shared/lib/image-config-context.shared-runtime\";\nimport stripAnsi from \"next/dist/compiled/strip-ansi\";\nimport { stripInternalQueries } from \"./internal-utils\";\nimport { adaptForAppRouterInstance, adaptForPathParams, adaptForSearchParams, PathnameContextProviderAdapter } from \"../shared/lib/router/adapters\";\nimport { AppRouterContext } from \"../shared/lib/app-router-context.shared-runtime\";\nimport { SearchParamsContext, PathParamsContext } from \"../shared/lib/hooks-client-context.shared-runtime\";\nimport { getTracer } from \"./lib/trace/tracer\";\nimport { RenderSpan } from \"./lib/trace/constants\";\nimport { ReflectAdapter } from \"./web/spec-extension/adapters/reflect\";\nimport { setRevalidateHeaders } from \"./send-payload\";\nlet tryGetPreviewData;\nlet warn;\nlet postProcessHTML;\nconst DOCTYPE = \"\";\nif (process.env.NEXT_RUNTIME !== \"edge\") {\n require(\"./node-polyfill-web-streams\");\n tryGetPreviewData = require(\"./api-utils/node/try-get-preview-data\").tryGetPreviewData;\n warn = require(\"../build/output/log\").warn;\n postProcessHTML = require(\"./post-process\").postProcessHTML;\n} else {\n warn = console.warn.bind(console);\n postProcessHTML = async (_pathname, html)=>html;\n}\nfunction noRouter() {\n const message = 'No router instance found. you should only use \"next/router\" inside the client side of your app. https://nextjs.org/docs/messages/no-router-instance';\n throw new Error(message);\n}\nasync function renderToString(element) {\n const renderStream = await ReactDOMServer.renderToReadableStream(element);\n await renderStream.allReady;\n return streamToString(renderStream);\n}\nclass ServerRouter {\n constructor(pathname, query, as, { isFallback }, isReady, basePath, locale, locales, defaultLocale, domainLocales, isPreview, isLocaleDomain){\n this.route = pathname.replace(/\\/$/, \"\") || \"/\";\n this.pathname = pathname;\n this.query = query;\n this.asPath = as;\n this.isFallback = isFallback;\n this.basePath = basePath;\n this.locale = locale;\n this.locales = locales;\n this.defaultLocale = defaultLocale;\n this.isReady = isReady;\n this.domainLocales = domainLocales;\n this.isPreview = !!isPreview;\n this.isLocaleDomain = !!isLocaleDomain;\n }\n push() {\n noRouter();\n }\n replace() {\n noRouter();\n }\n reload() {\n noRouter();\n }\n back() {\n noRouter();\n }\n forward() {\n noRouter();\n }\n prefetch() {\n noRouter();\n }\n beforePopState() {\n noRouter();\n }\n}\nfunction enhanceComponents(options, App, Component) {\n // For backwards compatibility\n if (typeof options === \"function\") {\n return {\n App,\n Component: options(Component)\n };\n }\n return {\n App: options.enhanceApp ? options.enhanceApp(App) : App,\n Component: options.enhanceComponent ? options.enhanceComponent(Component) : Component\n };\n}\nfunction renderPageTree(App, Component, props) {\n return /*#__PURE__*/ React.createElement(App, {\n Component: Component,\n ...props\n });\n}\nconst invalidKeysMsg = (methodName, invalidKeys)=>{\n const docsPathname = `invalid-${methodName.toLocaleLowerCase()}-value`;\n return `Additional keys were returned from \\`${methodName}\\`. Properties intended for your component must be nested under the \\`props\\` key, e.g.:` + `\\n\\n\\treturn { props: { title: 'My Title', content: '...' } }` + `\\n\\nKeys that need to be moved: ${invalidKeys.join(\", \")}.` + `\\nRead more: https://nextjs.org/docs/messages/${docsPathname}`;\n};\nfunction checkRedirectValues(redirect, req, method) {\n const { destination, permanent, statusCode, basePath } = redirect;\n let errors = [];\n const hasStatusCode = typeof statusCode !== \"undefined\";\n const hasPermanent = typeof permanent !== \"undefined\";\n if (hasPermanent && hasStatusCode) {\n errors.push(`\\`permanent\\` and \\`statusCode\\` can not both be provided`);\n } else if (hasPermanent && typeof permanent !== \"boolean\") {\n errors.push(`\\`permanent\\` must be \\`true\\` or \\`false\\``);\n } else if (hasStatusCode && !allowedStatusCodes.has(statusCode)) {\n errors.push(`\\`statusCode\\` must undefined or one of ${[\n ...allowedStatusCodes\n ].join(\", \")}`);\n }\n const destinationType = typeof destination;\n if (destinationType !== \"string\") {\n errors.push(`\\`destination\\` should be string but received ${destinationType}`);\n }\n const basePathType = typeof basePath;\n if (basePathType !== \"undefined\" && basePathType !== \"boolean\") {\n errors.push(`\\`basePath\\` should be undefined or a false, received ${basePathType}`);\n }\n if (errors.length > 0) {\n throw new Error(`Invalid redirect object returned from ${method} for ${req.url}\\n` + errors.join(\" and \") + \"\\n\" + `See more info here: https://nextjs.org/docs/messages/invalid-redirect-gssp`);\n }\n}\nexport function errorToJSON(err) {\n let source = \"server\";\n if (process.env.NEXT_RUNTIME !== \"edge\") {\n source = require(\"next/dist/compiled/@next/react-dev-overlay/dist/middleware\").getErrorSource(err) || \"server\";\n }\n return {\n name: err.name,\n source,\n message: stripAnsi(err.message),\n stack: err.stack,\n digest: err.digest\n };\n}\nfunction serializeError(dev, err) {\n if (dev) {\n return errorToJSON(err);\n }\n return {\n name: \"Internal Server Error.\",\n message: \"500 - Internal Server Error.\",\n statusCode: 500\n };\n}\nexport async function renderToHTMLImpl(req, res, pathname, query, renderOpts, extra) {\n var _getTracer_getRootSpanAttributes;\n // Adds support for reading `cookies` in `getServerSideProps` when SSR.\n setLazyProp({\n req: req\n }, \"cookies\", getCookieParser(req.headers));\n const renderResultMeta = {};\n // In dev we invalidate the cache by appending a timestamp to the resource URL.\n // This is a workaround to fix https://github.com/vercel/next.js/issues/5860\n // TODO: remove this workaround when https://bugs.webkit.org/show_bug.cgi?id=187726 is fixed.\n renderResultMeta.assetQueryString = renderOpts.dev ? renderOpts.assetQueryString || `?ts=${Date.now()}` : \"\";\n // if deploymentId is provided we append it to all asset requests\n if (renderOpts.deploymentId) {\n renderResultMeta.assetQueryString += `${renderResultMeta.assetQueryString ? \"&\" : \"?\"}dpl=${renderOpts.deploymentId}`;\n }\n // don't modify original query object\n query = Object.assign({}, query);\n const { err, dev = false, ampPath = \"\", pageConfig = {}, buildManifest, reactLoadableManifest, ErrorDebug, getStaticProps, getStaticPaths, getServerSideProps, isDataReq, params, previewProps, basePath, images, runtime: globalRuntime, isExperimentalCompile } = renderOpts;\n const { App } = extra;\n const assetQueryString = renderResultMeta.assetQueryString;\n let Document = extra.Document;\n let Component = renderOpts.Component;\n const OriginComponent = Component;\n let serverComponentsInlinedTransformStream = null;\n const isFallback = !!query.__nextFallback;\n const notFoundSrcPage = query.__nextNotFoundSrcPage;\n // next internal queries should be stripped out\n stripInternalQueries(query);\n const isSSG = !!getStaticProps;\n const isBuildTimeSSG = isSSG && renderOpts.nextExport;\n const defaultAppGetInitialProps = App.getInitialProps === App.origGetInitialProps;\n const hasPageGetInitialProps = !!(Component == null ? void 0 : Component.getInitialProps);\n const hasPageScripts = Component == null ? void 0 : Component.unstable_scriptLoader;\n const pageIsDynamic = isDynamicRoute(pathname);\n const defaultErrorGetInitialProps = pathname === \"/_error\" && Component.getInitialProps === Component.origGetInitialProps;\n if (renderOpts.nextExport && hasPageGetInitialProps && !defaultErrorGetInitialProps) {\n warn(`Detected getInitialProps on page '${pathname}'` + ` while running export. It's recommended to use getStaticProps` + ` which has a more correct behavior for static exporting.` + `\\nRead more: https://nextjs.org/docs/messages/get-initial-props-export`);\n }\n let isAutoExport = !hasPageGetInitialProps && defaultAppGetInitialProps && !isSSG && !getServerSideProps;\n // if we are running from experimental compile and the page\n // would normally be automatically statically optimized\n // ensure we set cache header so it's not rendered on-demand\n // every request\n if (isAutoExport && !dev && isExperimentalCompile) {\n setRevalidateHeaders(res, {\n revalidate: CACHE_ONE_YEAR,\n private: false,\n stateful: false\n });\n isAutoExport = false;\n }\n if (hasPageGetInitialProps && isSSG) {\n throw new Error(SSG_GET_INITIAL_PROPS_CONFLICT + ` ${pathname}`);\n }\n if (hasPageGetInitialProps && getServerSideProps) {\n throw new Error(SERVER_PROPS_GET_INIT_PROPS_CONFLICT + ` ${pathname}`);\n }\n if (getServerSideProps && isSSG) {\n throw new Error(SERVER_PROPS_SSG_CONFLICT + ` ${pathname}`);\n }\n if (getServerSideProps && renderOpts.nextConfigOutput === \"export\") {\n throw new Error('getServerSideProps cannot be used with \"output: export\". See more info here: https://nextjs.org/docs/advanced-features/static-html-export');\n }\n if (getStaticPaths && !pageIsDynamic) {\n throw new Error(`getStaticPaths is only allowed for dynamic SSG pages and was found on '${pathname}'.` + `\\nRead more: https://nextjs.org/docs/messages/non-dynamic-getstaticpaths-usage`);\n }\n if (!!getStaticPaths && !isSSG) {\n throw new Error(`getStaticPaths was added without a getStaticProps in ${pathname}. Without getStaticProps, getStaticPaths does nothing`);\n }\n if (isSSG && pageIsDynamic && !getStaticPaths) {\n throw new Error(`getStaticPaths is required for dynamic SSG pages and is missing for '${pathname}'.` + `\\nRead more: https://nextjs.org/docs/messages/invalid-getstaticpaths-value`);\n }\n let asPath = renderOpts.resolvedAsPath || req.url;\n if (dev) {\n const { isValidElementType } = require(\"next/dist/compiled/react-is\");\n if (!isValidElementType(Component)) {\n throw new Error(`The default export is not a React Component in page: \"${pathname}\"`);\n }\n if (!isValidElementType(App)) {\n throw new Error(`The default export is not a React Component in page: \"/_app\"`);\n }\n if (!isValidElementType(Document)) {\n throw new Error(`The default export is not a React Component in page: \"/_document\"`);\n }\n if (isAutoExport || isFallback) {\n // remove query values except ones that will be set during export\n query = {\n ...query.amp ? {\n amp: query.amp\n } : {}\n };\n asPath = `${pathname}${// ensure trailing slash is present for non-dynamic auto-export pages\n req.url.endsWith(\"/\") && pathname !== \"/\" && !pageIsDynamic ? \"/\" : \"\"}`;\n req.url = pathname;\n }\n if (pathname === \"/404\" && (hasPageGetInitialProps || getServerSideProps)) {\n throw new Error(`\\`pages/404\\` ${STATIC_STATUS_PAGE_GET_INITIAL_PROPS_ERROR}`);\n }\n if (STATIC_STATUS_PAGES.includes(pathname) && (hasPageGetInitialProps || getServerSideProps)) {\n throw new Error(`\\`pages${pathname}\\` ${STATIC_STATUS_PAGE_GET_INITIAL_PROPS_ERROR}`);\n }\n }\n for (const methodName of [\n \"getStaticProps\",\n \"getServerSideProps\",\n \"getStaticPaths\"\n ]){\n if (Component == null ? void 0 : Component[methodName]) {\n throw new Error(`page ${pathname} ${methodName} ${GSSP_COMPONENT_MEMBER_ERROR}`);\n }\n }\n await Loadable.preloadAll() // Make sure all dynamic imports are loaded\n ;\n let isPreview = undefined;\n let previewData;\n if ((isSSG || getServerSideProps) && !isFallback && process.env.NEXT_RUNTIME !== \"edge\" && previewProps) {\n // Reads of this are cached on the `req` object, so this should resolve\n // instantly. There's no need to pass this data down from a previous\n // invoke.\n previewData = tryGetPreviewData(req, res, previewProps);\n isPreview = previewData !== false;\n }\n // url will always be set\n const routerIsReady = !!(getServerSideProps || hasPageGetInitialProps || !defaultAppGetInitialProps && !isSSG || isExperimentalCompile);\n const router = new ServerRouter(pathname, query, asPath, {\n isFallback: isFallback\n }, routerIsReady, basePath, renderOpts.locale, renderOpts.locales, renderOpts.defaultLocale, renderOpts.domainLocales, isPreview, getRequestMeta(req, \"__nextIsLocaleDomain\"));\n const appRouter = adaptForAppRouterInstance(router);\n let scriptLoader = {};\n const jsxStyleRegistry = createStyleRegistry();\n const ampState = {\n ampFirst: pageConfig.amp === true,\n hasQuery: Boolean(query.amp),\n hybrid: pageConfig.amp === \"hybrid\"\n };\n // Disable AMP under the web environment\n const inAmpMode = process.env.NEXT_RUNTIME !== \"edge\" && isInAmpMode(ampState);\n let head = defaultHead(inAmpMode);\n const reactLoadableModules = [];\n let initialScripts = {};\n if (hasPageScripts) {\n initialScripts.beforeInteractive = [].concat(hasPageScripts()).filter((script)=>script.props.strategy === \"beforeInteractive\").map((script)=>script.props);\n }\n const AppContainer = ({ children })=>/*#__PURE__*/ React.createElement(AppRouterContext.Provider, {\n value: appRouter\n }, /*#__PURE__*/ React.createElement(SearchParamsContext.Provider, {\n value: adaptForSearchParams(router)\n }, /*#__PURE__*/ React.createElement(PathnameContextProviderAdapter, {\n router: router,\n isAutoExport: isAutoExport\n }, /*#__PURE__*/ React.createElement(PathParamsContext.Provider, {\n value: adaptForPathParams(router)\n }, /*#__PURE__*/ React.createElement(RouterContext.Provider, {\n value: router\n }, /*#__PURE__*/ React.createElement(AmpStateContext.Provider, {\n value: ampState\n }, /*#__PURE__*/ React.createElement(HeadManagerContext.Provider, {\n value: {\n updateHead: (state)=>{\n head = state;\n },\n updateScripts: (scripts)=>{\n scriptLoader = scripts;\n },\n scripts: initialScripts,\n mountedInstances: new Set()\n }\n }, /*#__PURE__*/ React.createElement(LoadableContext.Provider, {\n value: (moduleName)=>reactLoadableModules.push(moduleName)\n }, /*#__PURE__*/ React.createElement(StyleRegistry, {\n registry: jsxStyleRegistry\n }, /*#__PURE__*/ React.createElement(ImageConfigContext.Provider, {\n value: images\n }, children))))))))));\n // The `useId` API uses the path indexes to generate an ID for each node.\n // To guarantee the match of hydration, we need to ensure that the structure\n // of wrapper nodes is isomorphic in server and client.\n // TODO: With `enhanceApp` and `enhanceComponents` options, this approach may\n // not be useful.\n // https://github.com/facebook/react/pull/22644\n const Noop = ()=>null;\n const AppContainerWithIsomorphicFiberStructure = ({ children })=>{\n return /*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement(Noop, null), /*#__PURE__*/ React.createElement(AppContainer, null, /*#__PURE__*/ React.createElement(React.Fragment, null, dev ? /*#__PURE__*/ React.createElement(React.Fragment, null, children, /*#__PURE__*/ React.createElement(Noop, null)) : children, /*#__PURE__*/ React.createElement(Noop, null))));\n };\n const ctx = {\n err,\n req: isAutoExport ? undefined : req,\n res: isAutoExport ? undefined : res,\n pathname,\n query,\n asPath,\n locale: renderOpts.locale,\n locales: renderOpts.locales,\n defaultLocale: renderOpts.defaultLocale,\n AppTree: (props)=>{\n return /*#__PURE__*/ React.createElement(AppContainerWithIsomorphicFiberStructure, null, renderPageTree(App, OriginComponent, {\n ...props,\n router\n }));\n },\n defaultGetInitialProps: async (docCtx, options = {})=>{\n const enhanceApp = (AppComp)=>{\n return (props)=>/*#__PURE__*/ React.createElement(AppComp, props);\n };\n const { html, head: renderPageHead } = await docCtx.renderPage({\n enhanceApp\n });\n const styles = jsxStyleRegistry.styles({\n nonce: options.nonce\n });\n jsxStyleRegistry.flush();\n return {\n html,\n head: renderPageHead,\n styles\n };\n }\n };\n let props;\n const nextExport = !isSSG && (renderOpts.nextExport || dev && (isAutoExport || isFallback));\n const styledJsxInsertedHTML = ()=>{\n const styles = jsxStyleRegistry.styles();\n jsxStyleRegistry.flush();\n return /*#__PURE__*/ React.createElement(React.Fragment, null, styles);\n };\n props = await loadGetInitialProps(App, {\n AppTree: ctx.AppTree,\n Component,\n router,\n ctx\n });\n if ((isSSG || getServerSideProps) && isPreview) {\n props.__N_PREVIEW = true;\n }\n if (isSSG) {\n props[STATIC_PROPS_ID] = true;\n }\n if (isSSG && !isFallback) {\n let data;\n try {\n data = await getTracer().trace(RenderSpan.getStaticProps, {\n spanName: `getStaticProps ${pathname}`,\n attributes: {\n \"next.route\": pathname\n }\n }, ()=>getStaticProps({\n ...pageIsDynamic ? {\n params: query\n } : undefined,\n ...isPreview ? {\n draftMode: true,\n preview: true,\n previewData: previewData\n } : undefined,\n locales: renderOpts.locales,\n locale: renderOpts.locale,\n defaultLocale: renderOpts.defaultLocale\n }));\n } catch (staticPropsError) {\n // remove not found error code to prevent triggering legacy\n // 404 rendering\n if (staticPropsError && staticPropsError.code === \"ENOENT\") {\n delete staticPropsError.code;\n }\n throw staticPropsError;\n }\n if (data == null) {\n throw new Error(GSP_NO_RETURNED_VALUE);\n }\n const invalidKeys = Object.keys(data).filter((key)=>key !== \"revalidate\" && key !== \"props\" && key !== \"redirect\" && key !== \"notFound\");\n if (invalidKeys.includes(\"unstable_revalidate\")) {\n throw new Error(UNSTABLE_REVALIDATE_RENAME_ERROR);\n }\n if (invalidKeys.length) {\n throw new Error(invalidKeysMsg(\"getStaticProps\", invalidKeys));\n }\n if (process.env.NODE_ENV !== \"production\") {\n if (typeof data.notFound !== \"undefined\" && typeof data.redirect !== \"undefined\") {\n throw new Error(`\\`redirect\\` and \\`notFound\\` can not both be returned from ${isSSG ? \"getStaticProps\" : \"getServerSideProps\"} at the same time. Page: ${pathname}\\nSee more info here: https://nextjs.org/docs/messages/gssp-mixed-not-found-redirect`);\n }\n }\n if (\"notFound\" in data && data.notFound) {\n if (pathname === \"/404\") {\n throw new Error(`The /404 page can not return notFound in \"getStaticProps\", please remove it to continue!`);\n }\n renderResultMeta.isNotFound = true;\n }\n if (\"redirect\" in data && data.redirect && typeof data.redirect === \"object\") {\n checkRedirectValues(data.redirect, req, \"getStaticProps\");\n if (isBuildTimeSSG) {\n throw new Error(`\\`redirect\\` can not be returned from getStaticProps during prerendering (${req.url})\\n` + `See more info here: https://nextjs.org/docs/messages/gsp-redirect-during-prerender`);\n }\n data.props = {\n __N_REDIRECT: data.redirect.destination,\n __N_REDIRECT_STATUS: getRedirectStatus(data.redirect)\n };\n if (typeof data.redirect.basePath !== \"undefined\") {\n data.props.__N_REDIRECT_BASE_PATH = data.redirect.basePath;\n }\n renderResultMeta.isRedirect = true;\n }\n if ((dev || isBuildTimeSSG) && !renderResultMeta.isNotFound && !isSerializableProps(pathname, \"getStaticProps\", data.props)) {\n // this fn should throw an error instead of ever returning `false`\n throw new Error(\"invariant: getStaticProps did not return valid props. Please report this.\");\n }\n let revalidate;\n if (\"revalidate\" in data) {\n if (data.revalidate && renderOpts.nextConfigOutput === \"export\") {\n throw new Error('ISR cannot be used with \"output: export\". See more info here: https://nextjs.org/docs/advanced-features/static-html-export');\n }\n if (typeof data.revalidate === \"number\") {\n if (!Number.isInteger(data.revalidate)) {\n throw new Error(`A page's revalidate option must be seconds expressed as a natural number for ${req.url}. Mixed numbers, such as '${data.revalidate}', cannot be used.` + `\\nTry changing the value to '${Math.ceil(data.revalidate)}' or using \\`Math.ceil()\\` if you're computing the value.`);\n } else if (data.revalidate <= 0) {\n throw new Error(`A page's revalidate option can not be less than or equal to zero for ${req.url}. A revalidate option of zero means to revalidate after _every_ request, and implies stale data cannot be tolerated.` + `\\n\\nTo never revalidate, you can set revalidate to \\`false\\` (only ran once at build-time).` + `\\nTo revalidate as soon as possible, you can set the value to \\`1\\`.`);\n } else {\n if (data.revalidate > 31536000) {\n // if it's greater than a year for some reason error\n console.warn(`Warning: A page's revalidate option was set to more than a year for ${req.url}. This may have been done in error.` + `\\nTo only run getStaticProps at build-time and not revalidate at runtime, you can set \\`revalidate\\` to \\`false\\`!`);\n }\n revalidate = data.revalidate;\n }\n } else if (data.revalidate === true) {\n // When enabled, revalidate after 1 second. This value is optimal for\n // the most up-to-date page possible, but without a 1-to-1\n // request-refresh ratio.\n revalidate = 1;\n } else if (data.revalidate === false || typeof data.revalidate === \"undefined\") {\n // By default, we never revalidate.\n revalidate = false;\n } else {\n throw new Error(`A page's revalidate option must be seconds expressed as a natural number. Mixed numbers and strings cannot be used. Received '${JSON.stringify(data.revalidate)}' for ${req.url}`);\n }\n } else {\n // By default, we never revalidate.\n revalidate = false;\n }\n props.pageProps = Object.assign({}, props.pageProps, \"props\" in data ? data.props : undefined);\n // pass up revalidate and props for export\n renderResultMeta.revalidate = revalidate;\n renderResultMeta.pageData = props;\n // this must come after revalidate is added to renderResultMeta\n if (renderResultMeta.isNotFound) {\n return new RenderResult(null, renderResultMeta);\n }\n }\n if (getServerSideProps) {\n props[SERVER_PROPS_ID] = true;\n }\n if (getServerSideProps && !isFallback) {\n let data;\n let canAccessRes = true;\n let resOrProxy = res;\n let deferredContent = false;\n if (process.env.NODE_ENV !== \"production\") {\n resOrProxy = new Proxy(res, {\n get: function(obj, prop) {\n if (!canAccessRes) {\n const message = `You should not access 'res' after getServerSideProps resolves.` + `\\nRead more: https://nextjs.org/docs/messages/gssp-no-mutating-res`;\n if (deferredContent) {\n throw new Error(message);\n } else {\n warn(message);\n }\n }\n if (typeof prop === \"symbol\") {\n return ReflectAdapter.get(obj, prop, res);\n }\n return ReflectAdapter.get(obj, prop, res);\n }\n });\n }\n try {\n data = await getTracer().trace(RenderSpan.getServerSideProps, {\n spanName: `getServerSideProps ${pathname}`,\n attributes: {\n \"next.route\": pathname\n }\n }, async ()=>getServerSideProps({\n req: req,\n res: resOrProxy,\n query,\n resolvedUrl: renderOpts.resolvedUrl,\n ...pageIsDynamic ? {\n params: params\n } : undefined,\n ...previewData !== false ? {\n draftMode: true,\n preview: true,\n previewData: previewData\n } : undefined,\n locales: renderOpts.locales,\n locale: renderOpts.locale,\n defaultLocale: renderOpts.defaultLocale\n }));\n canAccessRes = false;\n } catch (serverSidePropsError) {\n // remove not found error code to prevent triggering legacy\n // 404 rendering\n if (isError(serverSidePropsError) && serverSidePropsError.code === \"ENOENT\") {\n delete serverSidePropsError.code;\n }\n throw serverSidePropsError;\n }\n if (data == null) {\n throw new Error(GSSP_NO_RETURNED_VALUE);\n }\n if (data.props instanceof Promise) {\n deferredContent = true;\n }\n const invalidKeys = Object.keys(data).filter((key)=>key !== \"props\" && key !== \"redirect\" && key !== \"notFound\");\n if (data.unstable_notFound) {\n throw new Error(`unstable_notFound has been renamed to notFound, please update the field to continue. Page: ${pathname}`);\n }\n if (data.unstable_redirect) {\n throw new Error(`unstable_redirect has been renamed to redirect, please update the field to continue. Page: ${pathname}`);\n }\n if (invalidKeys.length) {\n throw new Error(invalidKeysMsg(\"getServerSideProps\", invalidKeys));\n }\n if (\"notFound\" in data && data.notFound) {\n if (pathname === \"/404\") {\n throw new Error(`The /404 page can not return notFound in \"getStaticProps\", please remove it to continue!`);\n }\n renderResultMeta.isNotFound = true;\n return new RenderResult(null, renderResultMeta);\n }\n if (\"redirect\" in data && typeof data.redirect === \"object\") {\n checkRedirectValues(data.redirect, req, \"getServerSideProps\");\n data.props = {\n __N_REDIRECT: data.redirect.destination,\n __N_REDIRECT_STATUS: getRedirectStatus(data.redirect)\n };\n if (typeof data.redirect.basePath !== \"undefined\") {\n data.props.__N_REDIRECT_BASE_PATH = data.redirect.basePath;\n }\n renderResultMeta.isRedirect = true;\n }\n if (deferredContent) {\n data.props = await data.props;\n }\n if ((dev || isBuildTimeSSG) && !isSerializableProps(pathname, \"getServerSideProps\", data.props)) {\n // this fn should throw an error instead of ever returning `false`\n throw new Error(\"invariant: getServerSideProps did not return valid props. Please report this.\");\n }\n props.pageProps = Object.assign({}, props.pageProps, data.props);\n renderResultMeta.pageData = props;\n }\n if (!isSSG && // we only show this warning for legacy pages\n !getServerSideProps && process.env.NODE_ENV !== \"production\" && Object.keys((props == null ? void 0 : props.pageProps) || {}).includes(\"url\")) {\n console.warn(`The prop \\`url\\` is a reserved prop in Next.js for legacy reasons and will be overridden on page ${pathname}\\n` + `See more info here: https://nextjs.org/docs/messages/reserved-page-prop`);\n }\n // Avoid rendering page un-necessarily for getServerSideProps data request\n // and getServerSideProps/getStaticProps redirects\n if (isDataReq && !isSSG || renderResultMeta.isRedirect) {\n return new RenderResult(JSON.stringify(props), renderResultMeta);\n }\n // We don't call getStaticProps or getServerSideProps while generating\n // the fallback so make sure to set pageProps to an empty object\n if (isFallback) {\n props.pageProps = {};\n }\n // the response might be finished on the getInitialProps call\n if (isResSent(res) && !isSSG) return new RenderResult(null, renderResultMeta);\n // we preload the buildManifest for auto-export dynamic pages\n // to speed up hydrating query values\n let filteredBuildManifest = buildManifest;\n if (isAutoExport && pageIsDynamic) {\n const page = denormalizePagePath(normalizePagePath(pathname));\n // This code would be much cleaner using `immer` and directly pushing into\n // the result from `getPageFiles`, we could maybe consider that in the\n // future.\n if (page in filteredBuildManifest.pages) {\n filteredBuildManifest = {\n ...filteredBuildManifest,\n pages: {\n ...filteredBuildManifest.pages,\n [page]: [\n ...filteredBuildManifest.pages[page],\n ...filteredBuildManifest.lowPriorityFiles.filter((f)=>f.includes(\"_buildManifest\"))\n ]\n },\n lowPriorityFiles: filteredBuildManifest.lowPriorityFiles.filter((f)=>!f.includes(\"_buildManifest\"))\n };\n }\n }\n const Body = ({ children })=>{\n return inAmpMode ? children : /*#__PURE__*/ React.createElement(\"div\", {\n id: \"__next\"\n }, children);\n };\n const renderDocument = async ()=>{\n // For `Document`, there are two cases that we don't support:\n // 1. Using `Document.getInitialProps` in the Edge runtime.\n // 2. Using the class component `Document` with concurrent features.\n const BuiltinFunctionalDocument = Document[NEXT_BUILTIN_DOCUMENT];\n if (process.env.NEXT_RUNTIME === \"edge\" && Document.getInitialProps) {\n // In the Edge runtime, `Document.getInitialProps` isn't supported.\n // We throw an error here if it's customized.\n if (BuiltinFunctionalDocument) {\n Document = BuiltinFunctionalDocument;\n } else {\n throw new Error(\"`getInitialProps` in Document component is not supported with the Edge Runtime.\");\n }\n }\n async function loadDocumentInitialProps(renderShell) {\n const renderPage = async (options = {})=>{\n if (ctx.err && ErrorDebug) {\n // Always start rendering the shell even if there's an error.\n if (renderShell) {\n renderShell(App, Component);\n }\n const html = await renderToString(/*#__PURE__*/ React.createElement(Body, null, /*#__PURE__*/ React.createElement(ErrorDebug, {\n error: ctx.err\n })));\n return {\n html,\n head\n };\n }\n if (dev && (props.router || props.Component)) {\n throw new Error(`'router' and 'Component' can not be returned in getInitialProps from _app.js https://nextjs.org/docs/messages/cant-override-next-props`);\n }\n const { App: EnhancedApp, Component: EnhancedComponent } = enhanceComponents(options, App, Component);\n if (renderShell) {\n return renderShell(EnhancedApp, EnhancedComponent).then(async (stream)=>{\n await stream.allReady;\n const html = await streamToString(stream);\n return {\n html,\n head\n };\n });\n }\n const html = await renderToString(/*#__PURE__*/ React.createElement(Body, null, /*#__PURE__*/ React.createElement(AppContainerWithIsomorphicFiberStructure, null, renderPageTree(EnhancedApp, EnhancedComponent, {\n ...props,\n router\n }))));\n return {\n html,\n head\n };\n };\n const documentCtx = {\n ...ctx,\n renderPage\n };\n const docProps = await loadGetInitialProps(Document, documentCtx);\n // the response might be finished on the getInitialProps call\n if (isResSent(res) && !isSSG) return null;\n if (!docProps || typeof docProps.html !== \"string\") {\n const message = `\"${getDisplayName(Document)}.getInitialProps()\" should resolve to an object with a \"html\" prop set with a valid html string`;\n throw new Error(message);\n }\n return {\n docProps,\n documentCtx\n };\n }\n const renderContent = (_App, _Component)=>{\n const EnhancedApp = _App || App;\n const EnhancedComponent = _Component || Component;\n return ctx.err && ErrorDebug ? /*#__PURE__*/ React.createElement(Body, null, /*#__PURE__*/ React.createElement(ErrorDebug, {\n error: ctx.err\n })) : /*#__PURE__*/ React.createElement(Body, null, /*#__PURE__*/ React.createElement(AppContainerWithIsomorphicFiberStructure, null, renderPageTree(EnhancedApp, EnhancedComponent, {\n ...props,\n router\n })));\n };\n // Always using react concurrent rendering mode with required react version 18.x\n const renderShell = async (EnhancedApp, EnhancedComponent)=>{\n const content = renderContent(EnhancedApp, EnhancedComponent);\n return await renderToInitialFizzStream({\n ReactDOMServer,\n element: content\n });\n };\n const createBodyResult = getTracer().wrap(RenderSpan.createBodyResult, (initialStream, suffix)=>{\n // this must be called inside bodyResult so appWrappers is\n // up to date when `wrapApp` is called\n const getServerInsertedHTML = async ()=>{\n return renderToString(styledJsxInsertedHTML());\n };\n return continueFizzStream(initialStream, {\n suffix,\n inlinedDataStream: serverComponentsInlinedTransformStream == null ? void 0 : serverComponentsInlinedTransformStream.readable,\n generateStaticHTML: true,\n getServerInsertedHTML,\n serverInsertedHTMLToHead: false\n });\n });\n const hasDocumentGetInitialProps = !(process.env.NEXT_RUNTIME === \"edge\" || !Document.getInitialProps);\n let bodyResult;\n // If it has getInitialProps, we will render the shell in `renderPage`.\n // Otherwise we do it right now.\n let documentInitialPropsRes;\n if (hasDocumentGetInitialProps) {\n documentInitialPropsRes = await loadDocumentInitialProps(renderShell);\n if (documentInitialPropsRes === null) return null;\n const { docProps } = documentInitialPropsRes;\n // includes suffix in initial html stream\n bodyResult = (suffix)=>createBodyResult(streamFromString(docProps.html + suffix));\n } else {\n const stream = await renderShell(App, Component);\n bodyResult = (suffix)=>createBodyResult(stream, suffix);\n documentInitialPropsRes = {};\n }\n const { docProps } = documentInitialPropsRes || {};\n const documentElement = (htmlProps)=>{\n if (process.env.NEXT_RUNTIME === \"edge\") {\n return Document();\n } else {\n return /*#__PURE__*/ React.createElement(Document, {\n ...htmlProps,\n ...docProps\n });\n }\n };\n let styles;\n if (hasDocumentGetInitialProps) {\n styles = docProps.styles;\n head = docProps.head;\n } else {\n styles = jsxStyleRegistry.styles();\n jsxStyleRegistry.flush();\n }\n return {\n bodyResult,\n documentElement,\n head,\n headTags: [],\n styles\n };\n };\n (_getTracer_getRootSpanAttributes = getTracer().getRootSpanAttributes()) == null ? void 0 : _getTracer_getRootSpanAttributes.set(\"next.route\", renderOpts.page);\n const documentResult = await getTracer().trace(RenderSpan.renderDocument, {\n spanName: `render route (pages) ${renderOpts.page}`,\n attributes: {\n \"next.route\": renderOpts.page\n }\n }, async ()=>renderDocument());\n if (!documentResult) {\n return new RenderResult(null, renderResultMeta);\n }\n const dynamicImportsIds = new Set();\n const dynamicImports = new Set();\n for (const mod of reactLoadableModules){\n const manifestItem = reactLoadableManifest[mod];\n if (manifestItem) {\n dynamicImportsIds.add(manifestItem.id);\n manifestItem.files.forEach((item)=>{\n dynamicImports.add(item);\n });\n }\n }\n const hybridAmp = ampState.hybrid;\n const docComponentsRendered = {};\n const { assetPrefix, buildId, customServer, defaultLocale, disableOptimizedLoading, domainLocales, locale, locales, runtimeConfig } = renderOpts;\n const htmlProps = {\n __NEXT_DATA__: {\n props,\n page: pathname,\n query,\n buildId,\n assetPrefix: assetPrefix === \"\" ? undefined : assetPrefix,\n runtimeConfig,\n nextExport: nextExport === true ? true : undefined,\n autoExport: isAutoExport === true ? true : undefined,\n isFallback,\n isExperimentalCompile,\n dynamicIds: dynamicImportsIds.size === 0 ? undefined : Array.from(dynamicImportsIds),\n err: renderOpts.err ? serializeError(dev, renderOpts.err) : undefined,\n gsp: !!getStaticProps ? true : undefined,\n gssp: !!getServerSideProps ? true : undefined,\n customServer,\n gip: hasPageGetInitialProps ? true : undefined,\n appGip: !defaultAppGetInitialProps ? true : undefined,\n locale,\n locales,\n defaultLocale,\n domainLocales,\n isPreview: isPreview === true ? true : undefined,\n notFoundSrcPage: notFoundSrcPage && dev ? notFoundSrcPage : undefined\n },\n strictNextHead: renderOpts.strictNextHead,\n buildManifest: filteredBuildManifest,\n docComponentsRendered,\n dangerousAsPath: router.asPath,\n canonicalBase: !renderOpts.ampPath && getRequestMeta(req, \"__nextStrippedLocale\") ? `${renderOpts.canonicalBase || \"\"}/${renderOpts.locale}` : renderOpts.canonicalBase,\n ampPath,\n inAmpMode,\n isDevelopment: !!dev,\n hybridAmp,\n dynamicImports: Array.from(dynamicImports),\n assetPrefix,\n // Only enabled in production as development mode has features relying on HMR (style injection for example)\n unstable_runtimeJS: process.env.NODE_ENV === \"production\" ? pageConfig.unstable_runtimeJS : undefined,\n unstable_JsPreload: pageConfig.unstable_JsPreload,\n assetQueryString,\n scriptLoader,\n locale,\n disableOptimizedLoading,\n head: documentResult.head,\n headTags: documentResult.headTags,\n styles: documentResult.styles,\n crossOrigin: renderOpts.crossOrigin,\n optimizeCss: renderOpts.optimizeCss,\n optimizeFonts: renderOpts.optimizeFonts,\n nextConfigOutput: renderOpts.nextConfigOutput,\n nextScriptWorkers: renderOpts.nextScriptWorkers,\n runtime: globalRuntime,\n largePageDataBytes: renderOpts.largePageDataBytes,\n nextFontManifest: renderOpts.nextFontManifest\n };\n const document = /*#__PURE__*/ React.createElement(AmpStateContext.Provider, {\n value: ampState\n }, /*#__PURE__*/ React.createElement(HtmlContext.Provider, {\n value: htmlProps\n }, documentResult.documentElement(htmlProps)));\n const documentHTML = await getTracer().trace(RenderSpan.renderToString, async ()=>renderToString(document));\n if (process.env.NODE_ENV !== \"production\") {\n const nonRenderedComponents = [];\n const expectedDocComponents = [\n \"Main\",\n \"Head\",\n \"NextScript\",\n \"Html\"\n ];\n for (const comp of expectedDocComponents){\n if (!docComponentsRendered[comp]) {\n nonRenderedComponents.push(comp);\n }\n }\n if (nonRenderedComponents.length) {\n const missingComponentList = nonRenderedComponents.map((e)=>`<${e} />`).join(\", \");\n const plural = nonRenderedComponents.length !== 1 ? \"s\" : \"\";\n console.warn(`Your custom Document (pages/_document) did not render all the required subcomponent${plural}.\\n` + `Missing component${plural}: ${missingComponentList}\\n` + \"Read how to fix here: https://nextjs.org/docs/messages/missing-document-component\");\n }\n }\n const [renderTargetPrefix, renderTargetSuffix] = documentHTML.split(\"\");\n let prefix = \"\";\n if (!documentHTML.startsWith(DOCTYPE)) {\n prefix += DOCTYPE;\n }\n prefix += renderTargetPrefix;\n if (inAmpMode) {\n prefix += \"\";\n }\n const streams = [\n streamFromString(prefix),\n await documentResult.bodyResult(renderTargetSuffix)\n ];\n const postOptimize = (html)=>postProcessHTML(pathname, html, renderOpts, {\n inAmpMode,\n hybridAmp\n });\n const html = await streamToString(chainStreams(streams));\n const optimizedHtml = await postOptimize(html);\n return new RenderResult(optimizedHtml, renderResultMeta);\n}\nexport const renderToHTML = (req, res, pathname, query, renderOpts)=>{\n return renderToHTMLImpl(req, res, pathname, query, renderOpts, renderOpts);\n};\n\n//# sourceMappingURL=render.js.map","/**\n * Contains predefined constants for the trace span name in next/server.\n *\n * Currently, next/server/tracer is internal implementation only for tracking\n * next.js's implementation only with known span names defined here.\n **/ // eslint typescript has a bug with TS enums\n/* eslint-disable no-shadow */ var BaseServerSpan;\n(function(BaseServerSpan) {\n BaseServerSpan[\"handleRequest\"] = \"BaseServer.handleRequest\";\n BaseServerSpan[\"run\"] = \"BaseServer.run\";\n BaseServerSpan[\"pipe\"] = \"BaseServer.pipe\";\n BaseServerSpan[\"getStaticHTML\"] = \"BaseServer.getStaticHTML\";\n BaseServerSpan[\"render\"] = \"BaseServer.render\";\n BaseServerSpan[\"renderToResponseWithComponents\"] = \"BaseServer.renderToResponseWithComponents\";\n BaseServerSpan[\"renderToResponse\"] = \"BaseServer.renderToResponse\";\n BaseServerSpan[\"renderToHTML\"] = \"BaseServer.renderToHTML\";\n BaseServerSpan[\"renderError\"] = \"BaseServer.renderError\";\n BaseServerSpan[\"renderErrorToResponse\"] = \"BaseServer.renderErrorToResponse\";\n BaseServerSpan[\"renderErrorToHTML\"] = \"BaseServer.renderErrorToHTML\";\n BaseServerSpan[\"render404\"] = \"BaseServer.render404\";\n})(BaseServerSpan || (BaseServerSpan = {}));\nvar LoadComponentsSpan;\n(function(LoadComponentsSpan) {\n LoadComponentsSpan[\"loadDefaultErrorComponents\"] = \"LoadComponents.loadDefaultErrorComponents\";\n LoadComponentsSpan[\"loadComponents\"] = \"LoadComponents.loadComponents\";\n})(LoadComponentsSpan || (LoadComponentsSpan = {}));\nvar NextServerSpan;\n(function(NextServerSpan) {\n NextServerSpan[\"getRequestHandler\"] = \"NextServer.getRequestHandler\";\n NextServerSpan[\"getServer\"] = \"NextServer.getServer\";\n NextServerSpan[\"getServerRequestHandler\"] = \"NextServer.getServerRequestHandler\";\n NextServerSpan[\"createServer\"] = \"createServer.createServer\";\n})(NextServerSpan || (NextServerSpan = {}));\nvar NextNodeServerSpan;\n(function(NextNodeServerSpan) {\n NextNodeServerSpan[\"compression\"] = \"NextNodeServer.compression\";\n NextNodeServerSpan[\"getBuildId\"] = \"NextNodeServer.getBuildId\";\n NextNodeServerSpan[\"generateStaticRoutes\"] = \"NextNodeServer.generateStaticRoutes\";\n NextNodeServerSpan[\"generateFsStaticRoutes\"] = \"NextNodeServer.generateFsStaticRoutes\";\n NextNodeServerSpan[\"generatePublicRoutes\"] = \"NextNodeServer.generatePublicRoutes\";\n NextNodeServerSpan[\"generateImageRoutes\"] = \"NextNodeServer.generateImageRoutes.route\";\n NextNodeServerSpan[\"sendRenderResult\"] = \"NextNodeServer.sendRenderResult\";\n NextNodeServerSpan[\"proxyRequest\"] = \"NextNodeServer.proxyRequest\";\n NextNodeServerSpan[\"runApi\"] = \"NextNodeServer.runApi\";\n NextNodeServerSpan[\"render\"] = \"NextNodeServer.render\";\n NextNodeServerSpan[\"renderHTML\"] = \"NextNodeServer.renderHTML\";\n NextNodeServerSpan[\"imageOptimizer\"] = \"NextNodeServer.imageOptimizer\";\n NextNodeServerSpan[\"getPagePath\"] = \"NextNodeServer.getPagePath\";\n NextNodeServerSpan[\"getRoutesManifest\"] = \"NextNodeServer.getRoutesManifest\";\n NextNodeServerSpan[\"findPageComponents\"] = \"NextNodeServer.findPageComponents\";\n NextNodeServerSpan[\"getFontManifest\"] = \"NextNodeServer.getFontManifest\";\n NextNodeServerSpan[\"getServerComponentManifest\"] = \"NextNodeServer.getServerComponentManifest\";\n NextNodeServerSpan[\"getRequestHandler\"] = \"NextNodeServer.getRequestHandler\";\n NextNodeServerSpan[\"renderToHTML\"] = \"NextNodeServer.renderToHTML\";\n NextNodeServerSpan[\"renderError\"] = \"NextNodeServer.renderError\";\n NextNodeServerSpan[\"renderErrorToHTML\"] = \"NextNodeServer.renderErrorToHTML\";\n NextNodeServerSpan[\"render404\"] = \"NextNodeServer.render404\";\n NextNodeServerSpan[// nested inner span, does not require parent scope name\n \"route\"] = \"route\";\n NextNodeServerSpan[\"onProxyReq\"] = \"onProxyReq\";\n NextNodeServerSpan[\"apiResolver\"] = \"apiResolver\";\n NextNodeServerSpan[\"internalFetch\"] = \"internalFetch\";\n})(NextNodeServerSpan || (NextNodeServerSpan = {}));\nvar StartServerSpan;\n(function(StartServerSpan) {\n StartServerSpan[\"startServer\"] = \"startServer.startServer\";\n})(StartServerSpan || (StartServerSpan = {}));\nvar RenderSpan;\n(function(RenderSpan) {\n RenderSpan[\"getServerSideProps\"] = \"Render.getServerSideProps\";\n RenderSpan[\"getStaticProps\"] = \"Render.getStaticProps\";\n RenderSpan[\"renderToString\"] = \"Render.renderToString\";\n RenderSpan[\"renderDocument\"] = \"Render.renderDocument\";\n RenderSpan[\"createBodyResult\"] = \"Render.createBodyResult\";\n})(RenderSpan || (RenderSpan = {}));\nvar AppRenderSpan;\n(function(AppRenderSpan) {\n AppRenderSpan[\"renderToString\"] = \"AppRender.renderToString\";\n AppRenderSpan[\"renderToReadableStream\"] = \"AppRender.renderToReadableStream\";\n AppRenderSpan[\"getBodyResult\"] = \"AppRender.getBodyResult\";\n AppRenderSpan[\"fetch\"] = \"AppRender.fetch\";\n})(AppRenderSpan || (AppRenderSpan = {}));\nvar RouterSpan;\n(function(RouterSpan) {\n RouterSpan[\"executeRoute\"] = \"Router.executeRoute\";\n})(RouterSpan || (RouterSpan = {}));\nvar NodeSpan;\n(function(NodeSpan) {\n NodeSpan[\"runHandler\"] = \"Node.runHandler\";\n})(NodeSpan || (NodeSpan = {}));\nvar AppRouteRouteHandlersSpan;\n(function(AppRouteRouteHandlersSpan) {\n AppRouteRouteHandlersSpan[\"runHandler\"] = \"AppRouteRouteHandlers.runHandler\";\n})(AppRouteRouteHandlersSpan || (AppRouteRouteHandlersSpan = {}));\nvar ResolveMetadataSpan;\n(function(ResolveMetadataSpan) {\n ResolveMetadataSpan[\"generateMetadata\"] = \"ResolveMetadata.generateMetadata\";\n})(ResolveMetadataSpan || (ResolveMetadataSpan = {}));\n// This list is used to filter out spans that are not relevant to the user\nexport const NextVanillaSpanAllowlist = [\n \"BaseServer.handleRequest\",\n \"Render.getServerSideProps\",\n \"Render.getStaticProps\",\n \"AppRender.fetch\",\n \"AppRender.getBodyResult\",\n \"Render.renderDocument\",\n \"Node.runHandler\",\n \"AppRouteRouteHandlers.runHandler\",\n \"ResolveMetadata.generateMetadata\"\n];\nexport { BaseServerSpan, LoadComponentsSpan, NextServerSpan, NextNodeServerSpan, StartServerSpan, RenderSpan, RouterSpan, AppRenderSpan, NodeSpan, AppRouteRouteHandlersSpan, ResolveMetadataSpan, };\n\n//# sourceMappingURL=constants.js.map","\"use client\";\n\nimport React from \"react\";\nexport var CacheStates;\n(function(CacheStates) {\n CacheStates[\"LAZY_INITIALIZED\"] = \"LAZYINITIALIZED\";\n CacheStates[\"DATA_FETCH\"] = \"DATAFETCH\";\n CacheStates[\"READY\"] = \"READY\";\n})(CacheStates || (CacheStates = {}));\nexport const AppRouterContext = React.createContext(null);\nexport const LayoutRouterContext = React.createContext(null);\nexport const GlobalLayoutRouterContext = React.createContext(null);\nexport const TemplateContext = React.createContext(null);\nif (process.env.NODE_ENV !== \"production\") {\n AppRouterContext.displayName = \"AppRouterContext\";\n LayoutRouterContext.displayName = \"LayoutRouterContext\";\n GlobalLayoutRouterContext.displayName = \"GlobalLayoutRouterContext\";\n TemplateContext.displayName = \"TemplateContext\";\n}\n\n//# sourceMappingURL=app-router-context.shared-runtime.js.map","/**\n * RouteModule is the base class for all route modules. This class should be\n * extended by all route modules.\n */ export class RouteModule {\n constructor({ userland, definition }){\n this.userland = userland;\n this.definition = definition;\n }\n}\n\n//# sourceMappingURL=route-module.js.map","const __WEBPACK_NAMESPACE_OBJECT__ = require(\"react\");","const __WEBPACK_NAMESPACE_OBJECT__ = require(\"react-dom/server.browser\");","const __WEBPACK_NAMESPACE_OBJECT__ = require(\"styled-jsx\");","export function getObjectClassLabel(value) {\n return Object.prototype.toString.call(value);\n}\nexport function isPlainObject(value) {\n if (getObjectClassLabel(value) !== \"[object Object]\") {\n return false;\n }\n const prototype = Object.getPrototypeOf(value);\n /**\n * this used to be previously:\n *\n * `return prototype === null || prototype === Object.prototype`\n *\n * but Edge Runtime expose Object from vm, being that kind of type-checking wrongly fail.\n *\n * It was changed to the current implementation since it's resilient to serialization.\n */ return prototype === null || prototype.hasOwnProperty(\"isPrototypeOf\");\n}\n\n//# sourceMappingURL=is-plain-object.js.map","import { isPlainObject, getObjectClassLabel } from \"../shared/lib/is-plain-object\";\nconst regexpPlainIdentifier = /^[A-Za-z_$][A-Za-z0-9_$]*$/;\nexport class SerializableError extends Error {\n constructor(page, method, path, message){\n super(path ? `Error serializing \\`${path}\\` returned from \\`${method}\\` in \"${page}\".\\nReason: ${message}` : `Error serializing props returned from \\`${method}\\` in \"${page}\".\\nReason: ${message}`);\n }\n}\nexport function isSerializableProps(page, method, input) {\n if (!isPlainObject(input)) {\n throw new SerializableError(page, method, \"\", `Props must be returned as a plain object from ${method}: \\`{ props: { ... } }\\` (received: \\`${getObjectClassLabel(input)}\\`).`);\n }\n function visit(visited, value, path) {\n if (visited.has(value)) {\n throw new SerializableError(page, method, path, `Circular references cannot be expressed in JSON (references: \\`${visited.get(value) || \"(self)\"}\\`).`);\n }\n visited.set(value, path);\n }\n function isSerializable(refs, value, path) {\n const type = typeof value;\n if (// `null` can be serialized, but not `undefined`.\n value === null || // n.b. `bigint`, `function`, `symbol`, and `undefined` cannot be\n // serialized.\n //\n // `object` is special-cased below, as it may represent `null`, an Array,\n // a plain object, a class, et al.\n type === \"boolean\" || type === \"number\" || type === \"string\") {\n return true;\n }\n if (type === \"undefined\") {\n throw new SerializableError(page, method, path, \"`undefined` cannot be serialized as JSON. Please use `null` or omit this value.\");\n }\n if (isPlainObject(value)) {\n visit(refs, value, path);\n if (Object.entries(value).every(([key, nestedValue])=>{\n const nextPath = regexpPlainIdentifier.test(key) ? `${path}.${key}` : `${path}[${JSON.stringify(key)}]`;\n const newRefs = new Map(refs);\n return isSerializable(newRefs, key, nextPath) && isSerializable(newRefs, nestedValue, nextPath);\n })) {\n return true;\n }\n throw new SerializableError(page, method, path, `invariant: Unknown error encountered in Object.`);\n }\n if (Array.isArray(value)) {\n visit(refs, value, path);\n if (value.every((nestedValue, index)=>{\n const newRefs = new Map(refs);\n return isSerializable(newRefs, nestedValue, `${path}[${index}]`);\n })) {\n return true;\n }\n throw new SerializableError(page, method, path, `invariant: Unknown error encountered in Array.`);\n }\n // None of these can be expressed as JSON:\n // const type: \"bigint\" | \"symbol\" | \"object\" | \"function\"\n throw new SerializableError(page, method, path, \"`\" + type + \"`\" + (type === \"object\" ? ` (\"${Object.prototype.toString.call(value)}\")` : \"\") + \" cannot be serialized as JSON. Please only return JSON serializable data types.\");\n }\n return isSerializable(new Map(), input, \"\");\n}\n\n//# sourceMappingURL=is-serializable-props.js.map","import React from \"react\";\nexport const AmpStateContext = React.createContext({});\nif (process.env.NODE_ENV !== \"production\") {\n AmpStateContext.displayName = \"AmpStateContext\";\n}\n\n//# sourceMappingURL=amp-context.shared-runtime.js.map","import React from \"react\";\nexport const HeadManagerContext = React.createContext({});\nif (process.env.NODE_ENV !== \"production\") {\n HeadManagerContext.displayName = \"HeadManagerContext\";\n}\n\n//# sourceMappingURL=head-manager-context.shared-runtime.js.map","\"use client\";\n\nimport React from \"react\";\nexport const LoadableContext = React.createContext(null);\nif (process.env.NODE_ENV !== \"production\") {\n LoadableContext.displayName = \"LoadableContext\";\n}\n\n//# sourceMappingURL=loadable-context.shared-runtime.js.map","// TODO: Remove use of `any` type.\n/**\n@copyright (c) 2017-present James Kyle \n MIT License\n Permission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n The above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\nLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\nOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\nWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE\n*/ // https://github.com/jamiebuilds/react-loadable/blob/v5.5.0/src/index.js\n// Modified to be compatible with webpack 4 / Next.js\nimport React from \"react\";\nimport { LoadableContext } from \"./loadable-context.shared-runtime\";\nfunction resolve(obj) {\n return obj && obj.default ? obj.default : obj;\n}\nconst ALL_INITIALIZERS = [];\nconst READY_INITIALIZERS = [];\nlet initialized = false;\nfunction load(loader) {\n let promise = loader();\n let state = {\n loading: true,\n loaded: null,\n error: null\n };\n state.promise = promise.then((loaded)=>{\n state.loading = false;\n state.loaded = loaded;\n return loaded;\n }).catch((err)=>{\n state.loading = false;\n state.error = err;\n throw err;\n });\n return state;\n}\nfunction createLoadableComponent(loadFn, options) {\n let opts = Object.assign({\n loader: null,\n loading: null,\n delay: 200,\n timeout: null,\n webpack: null,\n modules: null\n }, options);\n /** @type LoadableSubscription */ let subscription = null;\n function init() {\n if (!subscription) {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n const sub = new LoadableSubscription(loadFn, opts);\n subscription = {\n getCurrentValue: sub.getCurrentValue.bind(sub),\n subscribe: sub.subscribe.bind(sub),\n retry: sub.retry.bind(sub),\n promise: sub.promise.bind(sub)\n };\n }\n return subscription.promise();\n }\n // Server only\n if (typeof window === \"undefined\") {\n ALL_INITIALIZERS.push(init);\n }\n // Client only\n if (!initialized && typeof window !== \"undefined\") {\n // require.resolveWeak check is needed for environments that don't have it available like Jest\n const moduleIds = opts.webpack && typeof require.resolveWeak === \"function\" ? opts.webpack() : opts.modules;\n if (moduleIds) {\n READY_INITIALIZERS.push((ids)=>{\n for (const moduleId of moduleIds){\n if (ids.includes(moduleId)) {\n return init();\n }\n }\n });\n }\n }\n function useLoadableModule() {\n init();\n const context = React.useContext(LoadableContext);\n if (context && Array.isArray(opts.modules)) {\n opts.modules.forEach((moduleName)=>{\n context(moduleName);\n });\n }\n }\n function LoadableComponent(props, ref) {\n useLoadableModule();\n const state = React.useSyncExternalStore(subscription.subscribe, subscription.getCurrentValue, subscription.getCurrentValue);\n React.useImperativeHandle(ref, ()=>({\n retry: subscription.retry\n }), []);\n return React.useMemo(()=>{\n if (state.loading || state.error) {\n return /*#__PURE__*/ React.createElement(opts.loading, {\n isLoading: state.loading,\n pastDelay: state.pastDelay,\n timedOut: state.timedOut,\n error: state.error,\n retry: subscription.retry\n });\n } else if (state.loaded) {\n return /*#__PURE__*/ React.createElement(resolve(state.loaded), props);\n } else {\n return null;\n }\n }, [\n props,\n state\n ]);\n }\n LoadableComponent.preload = ()=>init();\n LoadableComponent.displayName = \"LoadableComponent\";\n return /*#__PURE__*/ React.forwardRef(LoadableComponent);\n}\nclass LoadableSubscription {\n promise() {\n return this._res.promise;\n }\n retry() {\n this._clearTimeouts();\n this._res = this._loadFn(this._opts.loader);\n this._state = {\n pastDelay: false,\n timedOut: false\n };\n const { _res: res, _opts: opts } = this;\n if (res.loading) {\n if (typeof opts.delay === \"number\") {\n if (opts.delay === 0) {\n this._state.pastDelay = true;\n } else {\n this._delay = setTimeout(()=>{\n this._update({\n pastDelay: true\n });\n }, opts.delay);\n }\n }\n if (typeof opts.timeout === \"number\") {\n this._timeout = setTimeout(()=>{\n this._update({\n timedOut: true\n });\n }, opts.timeout);\n }\n }\n this._res.promise.then(()=>{\n this._update({});\n this._clearTimeouts();\n }).catch((_err)=>{\n this._update({});\n this._clearTimeouts();\n });\n this._update({});\n }\n _update(partial) {\n this._state = {\n ...this._state,\n error: this._res.error,\n loaded: this._res.loaded,\n loading: this._res.loading,\n ...partial\n };\n this._callbacks.forEach((callback)=>callback());\n }\n _clearTimeouts() {\n clearTimeout(this._delay);\n clearTimeout(this._timeout);\n }\n getCurrentValue() {\n return this._state;\n }\n subscribe(callback) {\n this._callbacks.add(callback);\n return ()=>{\n this._callbacks.delete(callback);\n };\n }\n constructor(loadFn, opts){\n this._loadFn = loadFn;\n this._opts = opts;\n this._callbacks = new Set();\n this._delay = null;\n this._timeout = null;\n this.retry();\n }\n}\nfunction Loadable(opts) {\n return createLoadableComponent(load, opts);\n}\nfunction flushInitializers(initializers, ids) {\n let promises = [];\n while(initializers.length){\n let init = initializers.pop();\n promises.push(init(ids));\n }\n return Promise.all(promises).then(()=>{\n if (initializers.length) {\n return flushInitializers(initializers, ids);\n }\n });\n}\nLoadable.preloadAll = ()=>{\n return new Promise((resolveInitializers, reject)=>{\n flushInitializers(ALL_INITIALIZERS).then(resolveInitializers, reject);\n });\n};\nLoadable.preloadReady = (ids)=>{\n if (ids === void 0) ids = [];\n return new Promise((resolvePreload)=>{\n const res = ()=>{\n initialized = true;\n return resolvePreload();\n };\n // We always will resolve, errors should be handled within loading UIs.\n flushInitializers(READY_INITIALIZERS, ids).then(res, res);\n });\n};\nif (typeof window !== \"undefined\") {\n window.__NEXT_PRELOADREADY = Loadable.preloadReady;\n}\nexport default Loadable;\n\n//# sourceMappingURL=loadable.shared-runtime.js.map","import React from \"react\";\nexport const RouterContext = React.createContext(null);\nif (process.env.NODE_ENV !== \"production\") {\n RouterContext.displayName = \"RouterContext\";\n}\n\n//# sourceMappingURL=router-context.shared-runtime.js.map","// Identify /[param]/ in route string\nconst TEST_ROUTE = /\\/\\[[^/]+?\\](?=\\/|$)/;\nexport function isDynamicRoute(route) {\n return TEST_ROUTE.test(route);\n}\n\n//# sourceMappingURL=is-dynamic.js.map","/**\n * Web vitals provided to _app.reportWebVitals by Core Web Vitals plugin developed by Google Chrome team.\n * https://nextjs.org/blog/next-9-4#integrated-web-vitals-reporting\n */ export const WEB_VITALS = [\n \"CLS\",\n \"FCP\",\n \"FID\",\n \"INP\",\n \"LCP\",\n \"TTFB\"\n];\n/**\n * Utils\n */ export function execOnce(fn) {\n let used = false;\n let result;\n return function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n if (!used) {\n used = true;\n result = fn(...args);\n }\n return result;\n };\n}\n// Scheme: https://tools.ietf.org/html/rfc3986#section-3.1\n// Absolute URL: https://tools.ietf.org/html/rfc3986#section-4.3\nconst ABSOLUTE_URL_REGEX = /^[a-zA-Z][a-zA-Z\\d+\\-.]*?:/;\nexport const isAbsoluteUrl = (url)=>ABSOLUTE_URL_REGEX.test(url);\nexport function getLocationOrigin() {\n const { protocol, hostname, port } = window.location;\n return protocol + \"//\" + hostname + (port ? \":\" + port : \"\");\n}\nexport function getURL() {\n const { href } = window.location;\n const origin = getLocationOrigin();\n return href.substring(origin.length);\n}\nexport function getDisplayName(Component) {\n return typeof Component === \"string\" ? Component : Component.displayName || Component.name || \"Unknown\";\n}\nexport function isResSent(res) {\n return res.finished || res.headersSent;\n}\nexport function normalizeRepeatedSlashes(url) {\n const urlParts = url.split(\"?\");\n const urlNoQuery = urlParts[0];\n return urlNoQuery// first we replace any non-encoded backslashes with forward\n // then normalize repeated forward slashes\n .replace(/\\\\/g, \"/\").replace(/\\/\\/+/g, \"/\") + (urlParts[1] ? \"?\" + urlParts.slice(1).join(\"?\") : \"\");\n}\nexport async function loadGetInitialProps(App, ctx) {\n if (process.env.NODE_ENV !== \"production\") {\n var _App_prototype;\n if ((_App_prototype = App.prototype) == null ? void 0 : _App_prototype.getInitialProps) {\n const message = '\"' + getDisplayName(App) + '.getInitialProps()\" is defined as an instance method - visit https://nextjs.org/docs/messages/get-initial-props-as-an-instance-method for more information.';\n throw new Error(message);\n }\n }\n // when called from _app `ctx` is nested in `ctx`\n const res = ctx.res || ctx.ctx && ctx.ctx.res;\n if (!App.getInitialProps) {\n if (ctx.ctx && ctx.Component) {\n // @ts-ignore pageProps default\n return {\n pageProps: await loadGetInitialProps(ctx.Component, ctx.ctx)\n };\n }\n return {};\n }\n const props = await App.getInitialProps(ctx);\n if (res && isResSent(res)) {\n return props;\n }\n if (!props) {\n const message = '\"' + getDisplayName(App) + '.getInitialProps()\" should resolve to an object. But found \"' + props + '\" instead.';\n throw new Error(message);\n }\n if (process.env.NODE_ENV !== \"production\") {\n if (Object.keys(props).length === 0 && !ctx.ctx) {\n console.warn(\"\" + getDisplayName(App) + \" returned an empty object from `getInitialProps`. This de-optimizes and prevents automatic static optimization. https://nextjs.org/docs/messages/empty-object-getInitialProps\");\n }\n }\n return props;\n}\nexport const SP = typeof performance !== \"undefined\";\nexport const ST = SP && [\n \"mark\",\n \"measure\",\n \"getEntriesByName\"\n].every((method)=>typeof performance[method] === \"function\");\nexport class DecodeError extends Error {\n}\nexport class NormalizeError extends Error {\n}\nexport class PageNotFoundError extends Error {\n constructor(page){\n super();\n this.code = \"ENOENT\";\n this.name = \"PageNotFoundError\";\n this.message = \"Cannot find module for page: \" + page;\n }\n}\nexport class MissingStaticPage extends Error {\n constructor(page, message){\n super();\n this.message = \"Failed to load static file for page: \" + page + \" \" + message;\n }\n}\nexport class MiddlewareNotFoundError extends Error {\n constructor(){\n super();\n this.code = \"ENOENT\";\n this.message = \"Cannot find the middleware module\";\n }\n}\nexport function stringifyError(error) {\n return JSON.stringify({\n message: error.message,\n stack: error.stack\n });\n}\n\n//# sourceMappingURL=utils.js.map","import { createContext, useContext } from \"react\";\nexport const HtmlContext = createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") {\n HtmlContext.displayName = \"HtmlContext\";\n}\nexport function useHtmlContext() {\n const context = useContext(HtmlContext);\n if (!context) {\n throw new Error(\" should not be imported outside of pages/_document.\\n\" + \"Read more: https://nextjs.org/docs/messages/no-document-import-in-page\");\n }\n return context;\n}\n\n//# sourceMappingURL=html-context.shared-runtime.js.map","/* eslint-disable no-redeclare */ // FIXME: (wyattjoh) this is a temporary solution to allow us to pass data between bundled modules\nexport const NEXT_REQUEST_META = Symbol.for(\"NextInternalRequestMeta\");\nexport function getRequestMeta(req, key) {\n const meta = req[NEXT_REQUEST_META] || {};\n return typeof key === \"string\" ? meta[key] : meta;\n}\n/**\n * Sets the request metadata.\n *\n * @param req the request to set the metadata on\n * @param meta the metadata to set\n * @returns the mutated request metadata\n */ export function setRequestMeta(req, meta) {\n req[NEXT_REQUEST_META] = meta;\n return meta;\n}\n/**\n * Adds a value to the request metadata.\n *\n * @param request the request to mutate\n * @param key the key to set\n * @param value the value to set\n * @returns the mutated request metadata\n */ export function addRequestMeta(request, key, value) {\n const meta = getRequestMeta(request);\n meta[key] = value;\n return setRequestMeta(request, meta);\n}\n/**\n * Removes a key from the request metadata.\n *\n * @param request the request to mutate\n * @param key the key to remove\n * @returns the mutated request metadata\n */ export function removeRequestMeta(request, key) {\n const meta = getRequestMeta(request);\n delete meta[key];\n return setRequestMeta(request, meta);\n}\nexport function getNextInternalQuery(query) {\n const keysToInclude = [\n \"__nextDefaultLocale\",\n \"__nextFallback\",\n \"__nextLocale\",\n \"__nextSsgPath\",\n \"_nextBubbleNoFallback\",\n \"__nextDataReq\",\n \"__nextInferredLocaleFromDefault\"\n ];\n const nextInternalQuery = {};\n for (const key of keysToInclude){\n if (key in query) {\n // @ts-ignore this can't be typed correctly\n nextInternalQuery[key] = query[key];\n }\n }\n return nextInternalQuery;\n}\n\n//# sourceMappingURL=request-meta.js.map","import { PERMANENT_REDIRECT_STATUS, TEMPORARY_REDIRECT_STATUS } from \"../shared/lib/constants\";\nexport const allowedStatusCodes = new Set([\n 301,\n 302,\n 303,\n 307,\n 308\n]);\nexport function getRedirectStatus(route) {\n return route.statusCode || (route.permanent ? PERMANENT_REDIRECT_STATUS : TEMPORARY_REDIRECT_STATUS);\n}\n// for redirects we restrict matching /_next and for all routes\n// we add an optional trailing slash at the end for easier\n// configuring between trailingSlash: true/false\nexport function modifyRouteRegex(regex, restrictedPaths) {\n if (restrictedPaths) {\n regex = regex.replace(/\\^/, `^(?!${restrictedPaths.map((path)=>path.replace(/\\//g, \"\\\\/\")).join(\"|\")})`);\n }\n regex = regex.replace(/\\$$/, \"(?:\\\\/)?$\");\n return regex;\n}\n\n//# sourceMappingURL=redirect-status.js.map","export function isAbortError(e) {\n return (e == null ? void 0 : e.name) === \"AbortError\";\n}\nexport async function pipeReadable(readable, writable, waitUntilForEnd) {\n const reader = readable.getReader();\n let readerDone = false;\n let writableClosed = false;\n // It's not enough just to check for `writable.destroyed`, because the client\n // may disconnect while we're waiting for a read. We need to immediately\n // cancel the readable, and that requires an out-of-band listener.\n function onClose() {\n writableClosed = true;\n writable.off(\"close\", onClose);\n // If the reader is not yet done, we need to cancel it so that the stream\n // source's resources can be cleaned up. If a read is in-progress, this\n // will also ensure the read promise rejects and frees our resources.\n if (!readerDone) {\n readerDone = true;\n reader.cancel().catch(()=>{});\n }\n }\n writable.on(\"close\", onClose);\n try {\n while(true){\n const { done, value } = await reader.read();\n readerDone = done;\n if (done || writableClosed) {\n break;\n }\n if (value) {\n writable.write(value);\n writable.flush == null ? void 0 : writable.flush.call(writable);\n }\n }\n } catch (e) {\n // If the client disconnects, we don't want to emit an unhandled error.\n if (!isAbortError(e)) {\n throw e;\n }\n } finally{\n writable.off(\"close\", onClose);\n // If we broke out of the loop because of a client disconnect, and the\n // close event hasn't yet fired, we can early cancel.\n if (!readerDone) {\n reader.cancel().catch(()=>{});\n }\n // If the client hasn't disconnected yet, end the writable so that the\n // response sends the final bytes.\n if (waitUntilForEnd) {\n await waitUntilForEnd;\n }\n if (!writableClosed) {\n writable.end();\n }\n }\n}\n\n//# sourceMappingURL=pipe-readable.js.map","import { pipeReadable } from \"./pipe-readable\";\nexport default class RenderResult {\n /**\n * Creates a new RenderResult instance from a static response.\n *\n * @param value the static response value\n * @returns a new RenderResult instance\n */ static fromStatic(value) {\n return new RenderResult(value);\n }\n constructor(response, { contentType, waitUntil, ...metadata } = {}){\n this.response = response;\n this.contentType = contentType;\n this.metadata = metadata;\n this.waitUntil = waitUntil;\n }\n extendMetadata(metadata) {\n Object.assign(this.metadata, metadata);\n }\n /**\n * Returns true if the response is null. It can be null if the response was\n * not found or was already sent.\n */ get isNull() {\n return this.response === null;\n }\n /**\n * Returns false if the response is a string. It can be a string if the page\n * was prerendered. If it's not, then it was generated dynamically.\n */ get isDynamic() {\n return typeof this.response !== \"string\";\n }\n /**\n * Returns true if the response is a stream. If the page was dynamic, this\n * will throw an error.\n *\n * @returns The response as a string\n */ toUnchunkedString() {\n if (typeof this.response !== \"string\") {\n throw new Error(\"Invariant: dynamic responses cannot be unchunked. This is a bug in Next.js\");\n }\n return this.response;\n }\n async pipe(res) {\n if (this.response === null) {\n throw new Error(\"Invariant: response is null. This is a bug in Next.js\");\n }\n if (typeof this.response === \"string\") {\n throw new Error(\"Invariant: static responses cannot be piped. This is a bug in Next.js\");\n }\n return await pipeReadable(this.response, res, this.waitUntil);\n }\n}\n\n//# sourceMappingURL=render-result.js.map","const __WEBPACK_NAMESPACE_OBJECT__ = require(\"next/dist/server/lib/trace/tracer\");","export function encodeText(input) {\n return new TextEncoder().encode(input);\n}\nexport function decodeText(input, textDecoder) {\n return textDecoder.decode(input, {\n stream: true\n });\n}\n\n//# sourceMappingURL=encode-decode.js.map","import { nonNullable } from \"../../lib/non-nullable\";\nimport { getTracer } from \"../lib/trace/tracer\";\nimport { AppRenderSpan } from \"../lib/trace/constants\";\nimport { decodeText, encodeText } from \"./encode-decode\";\nconst queueTask = process.env.NEXT_RUNTIME === \"edge\" ? globalThis.setTimeout : setImmediate;\nexport const streamToBufferedResult = async (renderResult)=>{\n const textDecoder = new TextDecoder();\n let concatenatedString = \"\";\n const writable = {\n write (chunk) {\n concatenatedString += decodeText(chunk, textDecoder);\n },\n end () {},\n // We do not support stream cancellation\n on () {},\n off () {}\n };\n await renderResult.pipe(writable);\n return concatenatedString;\n};\nexport function cloneTransformStream(source) {\n const sourceReader = source.readable.getReader();\n const clone = new TransformStream({\n async start (controller) {\n while(true){\n const { done, value } = await sourceReader.read();\n if (done) {\n break;\n }\n controller.enqueue(value);\n }\n },\n // skip all piped chunks\n transform () {}\n });\n return clone;\n}\nexport function chainStreams(streams) {\n const { readable, writable } = new TransformStream();\n let promise = Promise.resolve();\n for(let i = 0; i < streams.length; ++i){\n promise = promise.then(()=>streams[i].pipeTo(writable, {\n preventClose: i + 1 < streams.length\n }));\n }\n return readable;\n}\nexport function streamFromString(str) {\n return new ReadableStream({\n start (controller) {\n controller.enqueue(encodeText(str));\n controller.close();\n }\n });\n}\nexport async function streamToString(stream) {\n const reader = stream.getReader();\n const textDecoder = new TextDecoder();\n let bufferedString = \"\";\n while(true){\n const { done, value } = await reader.read();\n if (done) {\n return bufferedString;\n }\n bufferedString += decodeText(value, textDecoder);\n }\n}\nexport function createBufferedTransformStream() {\n let bufferedBytes = new Uint8Array();\n let pendingFlush = null;\n const flushBuffer = (controller)=>{\n if (!pendingFlush) {\n pendingFlush = new Promise((resolve)=>{\n queueTask(()=>{\n controller.enqueue(bufferedBytes);\n bufferedBytes = new Uint8Array();\n pendingFlush = null;\n resolve();\n });\n });\n }\n };\n return new TransformStream({\n transform (chunk, controller) {\n const newBufferedBytes = new Uint8Array(bufferedBytes.length + chunk.byteLength);\n newBufferedBytes.set(bufferedBytes);\n newBufferedBytes.set(chunk, bufferedBytes.length);\n bufferedBytes = newBufferedBytes;\n flushBuffer(controller);\n },\n flush () {\n if (pendingFlush) {\n return pendingFlush;\n }\n }\n });\n}\nexport function createInsertedHTMLStream(getServerInsertedHTML) {\n return new TransformStream({\n async transform (chunk, controller) {\n const insertedHTMLChunk = encodeText(await getServerInsertedHTML());\n controller.enqueue(insertedHTMLChunk);\n controller.enqueue(chunk);\n }\n });\n}\nexport function renderToInitialFizzStream({ ReactDOMServer, element, streamOptions }) {\n return getTracer().trace(AppRenderSpan.renderToReadableStream, async ()=>ReactDOMServer.renderToReadableStream(element, streamOptions));\n}\nfunction createHeadInsertionTransformStream(insert) {\n let inserted = false;\n let freezing = false;\n const textDecoder = new TextDecoder();\n return new TransformStream({\n async transform (chunk, controller) {\n // While react is flushing chunks, we don't apply insertions\n if (freezing) {\n controller.enqueue(chunk);\n return;\n }\n const insertion = await insert();\n if (inserted) {\n controller.enqueue(encodeText(insertion));\n controller.enqueue(chunk);\n freezing = true;\n } else {\n const content = decodeText(chunk, textDecoder);\n const index = content.indexOf(\"\");\n if (index !== -1) {\n const insertedHeadContent = content.slice(0, index) + insertion + content.slice(index);\n controller.enqueue(encodeText(insertedHeadContent));\n freezing = true;\n inserted = true;\n }\n }\n if (!inserted) {\n controller.enqueue(chunk);\n } else {\n queueTask(()=>{\n freezing = false;\n });\n }\n },\n async flush (controller) {\n // Check before closing if there's anything remaining to insert.\n const insertion = await insert();\n if (insertion) {\n controller.enqueue(encodeText(insertion));\n }\n }\n });\n}\n// Suffix after main body content - scripts before ,\n// but wait for the major chunks to be enqueued.\nfunction createDeferredSuffixStream(suffix) {\n let suffixFlushed = false;\n let suffixFlushTask = null;\n return new TransformStream({\n transform (chunk, controller) {\n controller.enqueue(chunk);\n if (!suffixFlushed && suffix.length) {\n suffixFlushed = true;\n suffixFlushTask = new Promise((res)=>{\n // NOTE: streaming flush\n // Enqueue suffix part before the major chunks are enqueued so that\n // suffix won't be flushed too early to interrupt the data stream\n queueTask(()=>{\n controller.enqueue(encodeText(suffix));\n res();\n });\n });\n }\n },\n flush (controller) {\n if (suffixFlushTask) return suffixFlushTask;\n if (!suffixFlushed && suffix.length) {\n suffixFlushed = true;\n controller.enqueue(encodeText(suffix));\n }\n }\n });\n}\n// Merge two streams into one. Ensure the final transform stream is closed\n// when both are finished.\nfunction createMergedTransformStream(dataStream) {\n let dataStreamFinished = null;\n return new TransformStream({\n transform (chunk, controller) {\n controller.enqueue(chunk);\n if (!dataStreamFinished) {\n const dataStreamReader = dataStream.getReader();\n // NOTE: streaming flush\n // We are buffering here for the inlined data stream because the\n // \"shell\" stream might be chunkenized again by the underlying stream\n // implementation, e.g. with a specific high-water mark. To ensure it's\n // the safe timing to pipe the data stream, this extra tick is\n // necessary.\n dataStreamFinished = new Promise((res)=>// We use `setTimeout` here to ensure that it's inserted after flushing\n // the shell. Note that this implementation might get stale if impl\n // details of Fizz change in the future.\n // Also we are not using `setImmediate` here because it's not available\n // broadly in all runtimes, for example some edge workers might not\n // have it.\n setTimeout(async ()=>{\n try {\n while(true){\n const { done, value } = await dataStreamReader.read();\n if (done) {\n return res();\n }\n controller.enqueue(value);\n }\n } catch (err) {\n controller.error(err);\n }\n res();\n }, 0));\n }\n },\n flush () {\n if (dataStreamFinished) {\n return dataStreamFinished;\n }\n }\n });\n}\n/**\n * This transform stream moves the suffix to the end of the stream, so results\n * like `` will be transformed to\n * ``.\n */ function createMoveSuffixStream(suffix) {\n let foundSuffix = false;\n const textDecoder = new TextDecoder();\n // Remove suffix from the stream, and enqueue it back in flush\n return new TransformStream({\n transform (chunk, controller) {\n if (!suffix || foundSuffix) {\n return controller.enqueue(chunk);\n }\n const content = decodeText(chunk, textDecoder);\n if (content.endsWith(suffix)) {\n foundSuffix = true;\n const contentWithoutSuffix = content.slice(0, -suffix.length);\n controller.enqueue(encodeText(contentWithoutSuffix));\n } else {\n controller.enqueue(chunk);\n }\n },\n flush (controller) {\n if (suffix) {\n controller.enqueue(encodeText(suffix));\n }\n }\n });\n}\nexport function createRootLayoutValidatorStream(assetPrefix = \"\", getTree) {\n let foundHtml = false;\n let foundBody = false;\n const textDecoder = new TextDecoder();\n return new TransformStream({\n async transform (chunk, controller) {\n if (!foundHtml || !foundBody) {\n const content = decodeText(chunk, textDecoder);\n if (!foundHtml && content.includes(\"self.__next_root_layout_missing_tags_error=${JSON.stringify({\n missingTags,\n assetPrefix: assetPrefix ?? \"\",\n tree: getTree()\n })}`));\n }\n }\n });\n}\nexport async function continueFizzStream(renderStream, { suffix, inlinedDataStream, generateStaticHTML, getServerInsertedHTML, serverInsertedHTMLToHead, validateRootLayout }) {\n const closeTag = \"\";\n // Suffix itself might contain close tags at the end, so we need to split it.\n const suffixUnclosed = suffix ? suffix.split(closeTag)[0] : null;\n if (generateStaticHTML) {\n await renderStream.allReady;\n }\n const transforms = [\n // Buffer everything to avoid flushing too frequently\n createBufferedTransformStream(),\n // Insert generated tags to head\n getServerInsertedHTML && !serverInsertedHTMLToHead ? createInsertedHTMLStream(getServerInsertedHTML) : null,\n // Insert suffix content\n suffixUnclosed != null ? createDeferredSuffixStream(suffixUnclosed) : null,\n // Insert the inlined data (Flight data, form state, etc.) stream into the HTML\n inlinedDataStream ? createMergedTransformStream(inlinedDataStream) : null,\n // Close tags should always be deferred to the end\n createMoveSuffixStream(closeTag),\n // Special head insertions\n // TODO-APP: Insert server side html to end of head in app layout rendering, to avoid\n // hydration errors. Remove this once it's ready to be handled by react itself.\n getServerInsertedHTML && serverInsertedHTMLToHead ? createHeadInsertionTransformStream(getServerInsertedHTML) : null,\n validateRootLayout ? createRootLayoutValidatorStream(validateRootLayout.assetPrefix, validateRootLayout.getTree) : null\n ].filter(nonNullable);\n return transforms.reduce((readable, transform)=>readable.pipeThrough(transform), renderStream);\n}\n\n//# sourceMappingURL=node-web-streams-helper.js.map","import React from \"react\";\nimport { imageConfigDefault } from \"./image-config\";\nexport const ImageConfigContext = React.createContext(imageConfigDefault);\nif (process.env.NODE_ENV !== \"production\") {\n ImageConfigContext.displayName = \"ImageConfigContext\";\n}\n\n//# sourceMappingURL=image-config-context.shared-runtime.js.map","export const VALID_LOADERS = [\n \"default\",\n \"imgix\",\n \"cloudinary\",\n \"akamai\",\n \"custom\"\n];\nexport const imageConfigDefault = {\n deviceSizes: [\n 640,\n 750,\n 828,\n 1080,\n 1200,\n 1920,\n 2048,\n 3840\n ],\n imageSizes: [\n 16,\n 32,\n 48,\n 64,\n 96,\n 128,\n 256,\n 384\n ],\n path: \"/_next/image\",\n loader: \"default\",\n loaderFile: \"\",\n domains: [],\n disableStaticImages: false,\n minimumCacheTTL: 60,\n formats: [\n \"image/webp\"\n ],\n dangerouslyAllowSVG: false,\n contentSecurityPolicy: \"script-src 'none'; frame-src 'none'; sandbox;\",\n contentDispositionType: \"inline\",\n remotePatterns: [],\n unoptimized: false\n};\n\n//# sourceMappingURL=image-config.js.map","import { NEXT_RSC_UNION_QUERY } from \"../client/components/app-router-headers\";\nconst INTERNAL_QUERY_NAMES = [\n \"__nextFallback\",\n \"__nextLocale\",\n \"__nextInferredLocaleFromDefault\",\n \"__nextDefaultLocale\",\n \"__nextIsNotFound\",\n NEXT_RSC_UNION_QUERY\n];\nconst EDGE_EXTENDED_INTERNAL_QUERY_NAMES = [\n \"__nextDataReq\"\n];\nexport function stripInternalQueries(query) {\n for (const name of INTERNAL_QUERY_NAMES){\n delete query[name];\n }\n}\nexport function stripInternalSearchParams(url, isEdge) {\n const isStringUrl = typeof url === \"string\";\n const instance = isStringUrl ? new URL(url) : url;\n for (const name of INTERNAL_QUERY_NAMES){\n instance.searchParams.delete(name);\n }\n if (isEdge) {\n for (const name of EDGE_EXTENDED_INTERNAL_QUERY_NAMES){\n instance.searchParams.delete(name);\n }\n }\n return isStringUrl ? instance.toString() : instance;\n}\n/**\n * Headers that are set by the Next.js server and should be stripped from the\n * request headers going to the user's application.\n */ const INTERNAL_HEADERS = [\n \"x-invoke-path\",\n \"x-invoke-status\",\n \"x-invoke-error\",\n \"x-invoke-query\",\n \"x-invoke-output\",\n \"x-middleware-invoke\"\n];\n/**\n * Strip internal headers from the request headers.\n *\n * @param headers the headers to strip of internal headers\n */ export function stripInternalHeaders(headers) {\n for (const key of INTERNAL_HEADERS){\n delete headers[key];\n }\n}\n\n//# sourceMappingURL=internal-utils.js.map","export const RSC = \"RSC\";\nexport const ACTION = \"Next-Action\";\nexport const NEXT_ROUTER_STATE_TREE = \"Next-Router-State-Tree\";\nexport const NEXT_ROUTER_PREFETCH = \"Next-Router-Prefetch\";\nexport const NEXT_URL = \"Next-Url\";\nexport const RSC_CONTENT_TYPE_HEADER = \"text/x-component\";\nexport const RSC_VARY_HEADER = RSC + \", \" + NEXT_ROUTER_STATE_TREE + \", \" + NEXT_ROUTER_PREFETCH + \", \" + NEXT_URL;\nexport const FLIGHT_PARAMETERS = [\n [\n RSC\n ],\n [\n NEXT_ROUTER_STATE_TREE\n ],\n [\n NEXT_ROUTER_PREFETCH\n ]\n];\nexport const NEXT_RSC_UNION_QUERY = \"_rsc\";\n\n//# sourceMappingURL=app-router-headers.js.map","\"use client\";\n\nimport { createContext } from \"react\";\nexport const SearchParamsContext = createContext(null);\nexport const PathnameContext = createContext(null);\nexport const PathParamsContext = createContext(null);\nif (process.env.NODE_ENV !== \"production\") {\n SearchParamsContext.displayName = \"SearchParamsContext\";\n PathnameContext.displayName = \"PathnameContext\";\n PathParamsContext.displayName = \"PathParamsContext\";\n}\n\n//# sourceMappingURL=hooks-client-context.shared-runtime.js.map","import { normalizeAppPath } from \"../../../shared/lib/router/utils/app-paths\";\n// order matters here, the first match will be used\nexport const INTERCEPTION_ROUTE_MARKERS = [\n \"(..)(..)\",\n \"(.)\",\n \"(..)\",\n \"(...)\"\n];\nexport function isInterceptionRouteAppPath(path) {\n // TODO-APP: add more serious validation\n return path.split(\"/\").find((segment)=>INTERCEPTION_ROUTE_MARKERS.find((m)=>segment.startsWith(m))) !== undefined;\n}\nexport function extractInterceptionRouteInformation(path) {\n let interceptingRoute, marker, interceptedRoute;\n for (const segment of path.split(\"/\")){\n marker = INTERCEPTION_ROUTE_MARKERS.find((m)=>segment.startsWith(m));\n if (marker) {\n [interceptingRoute, interceptedRoute] = path.split(marker, 2);\n break;\n }\n }\n if (!interceptingRoute || !marker || !interceptedRoute) {\n throw new Error(`Invalid interception route: ${path}. Must be in the format //(..|...|..)(..)/`);\n }\n interceptingRoute = normalizeAppPath(interceptingRoute) // normalize the path, e.g. /(blog)/feed -> /feed\n ;\n switch(marker){\n case \"(.)\":\n // (.) indicates that we should match with sibling routes, so we just need to append the intercepted route to the intercepting route\n if (interceptingRoute === \"/\") {\n interceptedRoute = `/${interceptedRoute}`;\n } else {\n interceptedRoute = interceptingRoute + \"/\" + interceptedRoute;\n }\n break;\n case \"(..)\":\n // (..) indicates that we should match at one level up, so we need to remove the last segment of the intercepting route\n if (interceptingRoute === \"/\") {\n throw new Error(`Invalid interception route: ${path}. Cannot use (..) marker at the root level, use (.) instead.`);\n }\n interceptedRoute = interceptingRoute.split(\"/\").slice(0, -1).concat(interceptedRoute).join(\"/\");\n break;\n case \"(...)\":\n // (...) will match the route segment in the root directory, so we need to use the root directory to prepend the intercepted route\n interceptedRoute = \"/\" + interceptedRoute;\n break;\n case \"(..)(..)\":\n // (..)(..) indicates that we should match at two levels up, so we need to remove the last two segments of the intercepting route\n const splitInterceptingRoute = interceptingRoute.split(\"/\");\n if (splitInterceptingRoute.length <= 2) {\n throw new Error(`Invalid interception route: ${path}. Cannot use (..)(..) marker at the root level or one level up.`);\n }\n interceptedRoute = splitInterceptingRoute.slice(0, -2).concat(interceptedRoute).join(\"/\");\n break;\n default:\n throw new Error(\"Invariant: unexpected marker\");\n }\n return {\n interceptingRoute,\n interceptedRoute\n };\n}\n\n//# sourceMappingURL=interception-routes.js.map","// regexp is based on https://github.com/sindresorhus/escape-string-regexp\nconst reHasRegExp = /[|\\\\{}()[\\]^$+*?.-]/;\nconst reReplaceRegExp = /[|\\\\{}()[\\]^$+*?.-]/g;\nexport function escapeStringRegexp(str) {\n // see also: https://github.com/lodash/lodash/blob/2da024c3b4f9947a48517639de7560457cd4ec6c/escapeRegExp.js#L23\n if (reHasRegExp.test(str)) {\n return str.replace(reReplaceRegExp, \"\\\\$&\");\n }\n return str;\n}\n\n//# sourceMappingURL=escape-regexp.js.map","import { INTERCEPTION_ROUTE_MARKERS } from \"../../../../server/future/helpers/interception-routes\";\nimport { escapeStringRegexp } from \"../../escape-regexp\";\nimport { removeTrailingSlash } from \"./remove-trailing-slash\";\nconst NEXT_QUERY_PARAM_PREFIX = \"nxtP\";\nconst NEXT_INTERCEPTION_MARKER_PREFIX = \"nxtI\";\n/**\n * Parses a given parameter from a route to a data structure that can be used\n * to generate the parametrized route. Examples:\n * - `[...slug]` -> `{ key: 'slug', repeat: true, optional: true }`\n * - `...slug` -> `{ key: 'slug', repeat: true, optional: false }`\n * - `[foo]` -> `{ key: 'foo', repeat: false, optional: true }`\n * - `bar` -> `{ key: 'bar', repeat: false, optional: false }`\n */ function parseParameter(param) {\n const optional = param.startsWith(\"[\") && param.endsWith(\"]\");\n if (optional) {\n param = param.slice(1, -1);\n }\n const repeat = param.startsWith(\"...\");\n if (repeat) {\n param = param.slice(3);\n }\n return {\n key: param,\n repeat,\n optional\n };\n}\nfunction getParametrizedRoute(route) {\n const segments = removeTrailingSlash(route).slice(1).split(\"/\");\n const groups = {};\n let groupIndex = 1;\n return {\n parameterizedRoute: segments.map((segment)=>{\n const markerMatch = INTERCEPTION_ROUTE_MARKERS.find((m)=>segment.startsWith(m));\n const paramMatches = segment.match(/\\[((?:\\[.*\\])|.+)\\]/) // Check for parameters\n ;\n if (markerMatch && paramMatches) {\n const { key, optional, repeat } = parseParameter(paramMatches[1]);\n groups[key] = {\n pos: groupIndex++,\n repeat,\n optional\n };\n return \"/\" + escapeStringRegexp(markerMatch) + \"([^/]+?)\";\n } else if (paramMatches) {\n const { key, repeat, optional } = parseParameter(paramMatches[1]);\n groups[key] = {\n pos: groupIndex++,\n repeat,\n optional\n };\n return repeat ? optional ? \"(?:/(.+?))?\" : \"/(.+?)\" : \"/([^/]+?)\";\n } else {\n return \"/\" + escapeStringRegexp(segment);\n }\n }).join(\"\"),\n groups\n };\n}\n/**\n * From a normalized route this function generates a regular expression and\n * a corresponding groups object intended to be used to store matching groups\n * from the regular expression.\n */ export function getRouteRegex(normalizedRoute) {\n const { parameterizedRoute, groups } = getParametrizedRoute(normalizedRoute);\n return {\n re: new RegExp(\"^\" + parameterizedRoute + \"(?:/)?$\"),\n groups: groups\n };\n}\n/**\n * Builds a function to generate a minimal routeKey using only a-z and minimal\n * number of characters.\n */ function buildGetSafeRouteKey() {\n let i = 0;\n return ()=>{\n let routeKey = \"\";\n let j = ++i;\n while(j > 0){\n routeKey += String.fromCharCode(97 + (j - 1) % 26);\n j = Math.floor((j - 1) / 26);\n }\n return routeKey;\n };\n}\nfunction getSafeKeyFromSegment(param) {\n let { getSafeRouteKey, segment, routeKeys, keyPrefix } = param;\n const { key, optional, repeat } = parseParameter(segment);\n // replace any non-word characters since they can break\n // the named regex\n let cleanedKey = key.replace(/\\W/g, \"\");\n if (keyPrefix) {\n cleanedKey = \"\" + keyPrefix + cleanedKey;\n }\n let invalidKey = false;\n // check if the key is still invalid and fallback to using a known\n // safe key\n if (cleanedKey.length === 0 || cleanedKey.length > 30) {\n invalidKey = true;\n }\n if (!isNaN(parseInt(cleanedKey.slice(0, 1)))) {\n invalidKey = true;\n }\n if (invalidKey) {\n cleanedKey = getSafeRouteKey();\n }\n if (keyPrefix) {\n routeKeys[cleanedKey] = \"\" + keyPrefix + key;\n } else {\n routeKeys[cleanedKey] = \"\" + key;\n }\n return repeat ? optional ? \"(?:/(?<\" + cleanedKey + \">.+?))?\" : \"/(?<\" + cleanedKey + \">.+?)\" : \"/(?<\" + cleanedKey + \">[^/]+?)\";\n}\nfunction getNamedParametrizedRoute(route, prefixRouteKeys) {\n const segments = removeTrailingSlash(route).slice(1).split(\"/\");\n const getSafeRouteKey = buildGetSafeRouteKey();\n const routeKeys = {};\n return {\n namedParameterizedRoute: segments.map((segment)=>{\n const hasInterceptionMarker = INTERCEPTION_ROUTE_MARKERS.some((m)=>segment.startsWith(m));\n const paramMatches = segment.match(/\\[((?:\\[.*\\])|.+)\\]/) // Check for parameters\n ;\n if (hasInterceptionMarker && paramMatches) {\n return getSafeKeyFromSegment({\n getSafeRouteKey,\n segment: paramMatches[1],\n routeKeys,\n keyPrefix: prefixRouteKeys ? NEXT_INTERCEPTION_MARKER_PREFIX : undefined\n });\n } else if (paramMatches) {\n return getSafeKeyFromSegment({\n getSafeRouteKey,\n segment: paramMatches[1],\n routeKeys,\n keyPrefix: prefixRouteKeys ? NEXT_QUERY_PARAM_PREFIX : undefined\n });\n } else {\n return \"/\" + escapeStringRegexp(segment);\n }\n }).join(\"\"),\n routeKeys\n };\n}\n/**\n * This function extends `getRouteRegex` generating also a named regexp where\n * each group is named along with a routeKeys object that indexes the assigned\n * named group with its corresponding key. When the routeKeys need to be\n * prefixed to uniquely identify internally the \"prefixRouteKey\" arg should\n * be \"true\" currently this is only the case when creating the routes-manifest\n * during the build\n */ export function getNamedRouteRegex(normalizedRoute, prefixRouteKey) {\n const result = getNamedParametrizedRoute(normalizedRoute, prefixRouteKey);\n return {\n ...getRouteRegex(normalizedRoute),\n namedRegex: \"^\" + result.namedParameterizedRoute + \"(?:/)?$\",\n routeKeys: result.routeKeys\n };\n}\n/**\n * Generates a named regexp.\n * This is intended to be using for build time only.\n */ export function getNamedMiddlewareRegex(normalizedRoute, options) {\n const { parameterizedRoute } = getParametrizedRoute(normalizedRoute);\n const { catchAll = true } = options;\n if (parameterizedRoute === \"/\") {\n let catchAllRegex = catchAll ? \".*\" : \"\";\n return {\n namedRegex: \"^/\" + catchAllRegex + \"$\"\n };\n }\n const { namedParameterizedRoute } = getNamedParametrizedRoute(normalizedRoute, false);\n let catchAllGroupedRegex = catchAll ? \"(?:(/.*)?)\" : \"\";\n return {\n namedRegex: \"^\" + namedParameterizedRoute + catchAllGroupedRegex + \"$\"\n };\n}\n\n//# sourceMappingURL=route-regex.js.map","import React, { useMemo, useRef } from \"react\";\nimport { PathnameContext } from \"../hooks-client-context.shared-runtime\";\nimport { isDynamicRoute } from \"./utils\";\nimport { asPathToSearchParams } from \"./utils/as-path-to-search-params\";\nimport { getRouteRegex } from \"./utils/route-regex\";\n/**\n * adaptForAppRouterInstance implements the AppRouterInstance with a NextRouter.\n *\n * @param router the NextRouter to adapt\n * @returns an AppRouterInstance\n */ export function adaptForAppRouterInstance(router) {\n return {\n back () {\n router.back();\n },\n forward () {\n router.forward();\n },\n refresh () {\n router.reload();\n },\n push (href, param) {\n let { scroll } = param === void 0 ? {} : param;\n void router.push(href, undefined, {\n scroll\n });\n },\n replace (href, param) {\n let { scroll } = param === void 0 ? {} : param;\n void router.replace(href, undefined, {\n scroll\n });\n },\n prefetch (href) {\n void router.prefetch(href);\n }\n };\n}\n/**\n * adaptForSearchParams transforms the ParsedURLQuery into URLSearchParams.\n *\n * @param router the router that contains the query.\n * @returns the search params in the URLSearchParams format\n */ export function adaptForSearchParams(router) {\n if (!router.isReady || !router.query) {\n return new URLSearchParams();\n }\n return asPathToSearchParams(router.asPath);\n}\nexport function adaptForPathParams(router) {\n if (!router.isReady || !router.query) {\n return null;\n }\n const pathParams = {};\n const routeRegex = getRouteRegex(router.pathname);\n const keys = Object.keys(routeRegex.groups);\n for (const key of keys){\n pathParams[key] = router.query[key];\n }\n return pathParams;\n}\nexport function PathnameContextProviderAdapter(param) {\n let { children, router, ...props } = param;\n const ref = useRef(props.isAutoExport);\n const value = useMemo(()=>{\n // isAutoExport is only ever `true` on the first render from the server,\n // so reset it to `false` after we read it for the first time as `true`. If\n // we don't use the value, then we don't need it.\n const isAutoExport = ref.current;\n if (isAutoExport) {\n ref.current = false;\n }\n // When the route is a dynamic route, we need to do more processing to\n // determine if we need to stop showing the pathname.\n if (isDynamicRoute(router.pathname)) {\n // When the router is rendering the fallback page, it can't possibly know\n // the path, so return `null` here. Read more about fallback pages over\n // at:\n // https://nextjs.org/docs/api-reference/data-fetching/get-static-paths#fallback-pages\n if (router.isFallback) {\n return null;\n }\n // When `isAutoExport` is true, meaning this is a page page has been\n // automatically statically optimized, and the router is not ready, then\n // we can't know the pathname yet. Read more about automatic static\n // optimization at:\n // https://nextjs.org/docs/advanced-features/automatic-static-optimization\n if (isAutoExport && !router.isReady) {\n return null;\n }\n }\n // The `router.asPath` contains the pathname seen by the browser (including\n // any query strings), so it should have that stripped. Read more about the\n // `asPath` option over at:\n // https://nextjs.org/docs/api-reference/next/router#router-object\n let url;\n try {\n url = new URL(router.asPath, \"http://f\");\n } catch (_) {\n // fallback to / for invalid asPath values e.g. //\n return \"/\";\n }\n return url.pathname;\n }, [\n router.asPath,\n router.isFallback,\n router.isReady,\n router.pathname\n ]);\n return /*#__PURE__*/ React.createElement(PathnameContext.Provider, {\n value: value\n }, children);\n}\n\n//# sourceMappingURL=adapters.js.map","/**\n * Parse cookies from the `headers` of request\n * @param req request object\n */ export function getCookieParser(headers) {\n return function parseCookie() {\n const { cookie } = headers;\n if (!cookie) {\n return {};\n }\n const { parse: parseCookieFn } = require(\"next/dist/compiled/cookie\");\n return parseCookieFn(Array.isArray(cookie) ? cookie.join(\"; \") : cookie);\n };\n}\n\n//# sourceMappingURL=get-cookie-parser.js.map","export function setRevalidateHeaders(res, options) {\n if (options.private || options.stateful) {\n if (options.private || !res.getHeader(\"Cache-Control\")) {\n res.setHeader(\"Cache-Control\", `private, no-cache, no-store, max-age=0, must-revalidate`);\n }\n } else if (typeof options.revalidate === \"number\") {\n if (options.revalidate < 1) {\n throw new Error(`invariant: invalid Cache-Control duration provided: ${options.revalidate} < 1`);\n }\n res.setHeader(\"Cache-Control\", `s-maxage=${options.revalidate}, stale-while-revalidate`);\n } else if (options.revalidate === false) {\n res.setHeader(\"Cache-Control\", `s-maxage=31536000, stale-while-revalidate`);\n }\n}\n\n//# sourceMappingURL=revalidate-headers.js.map","export function isInAmpMode(param) {\n let { ampFirst = false, hybrid = false, hasQuery = false } = param === void 0 ? {} : param;\n return ampFirst || hybrid && hasQuery;\n}\n\n//# sourceMappingURL=amp-mode.js.map","\"use client\";\n\nimport React, { useContext } from \"react\";\nimport Effect from \"./side-effect\";\nimport { AmpStateContext } from \"./amp-context.shared-runtime\";\nimport { HeadManagerContext } from \"./head-manager-context.shared-runtime\";\nimport { isInAmpMode } from \"./amp-mode\";\nimport { warnOnce } from \"./utils/warn-once\";\nexport function defaultHead(inAmpMode) {\n if (inAmpMode === void 0) inAmpMode = false;\n const head = [\n /*#__PURE__*/ React.createElement(\"meta\", {\n charSet: \"utf-8\"\n })\n ];\n if (!inAmpMode) {\n head.push(/*#__PURE__*/ React.createElement(\"meta\", {\n name: \"viewport\",\n content: \"width=device-width\"\n }));\n }\n return head;\n}\nfunction onlyReactElement(list, child) {\n // React children can be \"string\" or \"number\" in this case we ignore them for backwards compat\n if (typeof child === \"string\" || typeof child === \"number\") {\n return list;\n }\n // Adds support for React.Fragment\n if (child.type === React.Fragment) {\n return list.concat(// @ts-expect-error @types/react does not remove fragments but this could also return ReactPortal[]\n React.Children.toArray(child.props.children).reduce(// @ts-expect-error @types/react does not remove fragments but this could also return ReactPortal[]\n (fragmentList, fragmentChild)=>{\n if (typeof fragmentChild === \"string\" || typeof fragmentChild === \"number\") {\n return fragmentList;\n }\n return fragmentList.concat(fragmentChild);\n }, []));\n }\n return list.concat(child);\n}\nconst METATYPES = [\n \"name\",\n \"httpEquiv\",\n \"charSet\",\n \"itemProp\"\n];\n/*\n returns a function for filtering head child elements\n which shouldn't be duplicated, like \n Also adds support for deduplicated `key` properties\n*/ function unique() {\n const keys = new Set();\n const tags = new Set();\n const metaTypes = new Set();\n const metaCategories = {};\n return (h)=>{\n let isUnique = true;\n let hasKey = false;\n if (h.key && typeof h.key !== \"number\" && h.key.indexOf(\"$\") > 0) {\n hasKey = true;\n const key = h.key.slice(h.key.indexOf(\"$\") + 1);\n if (keys.has(key)) {\n isUnique = false;\n } else {\n keys.add(key);\n }\n }\n // eslint-disable-next-line default-case\n switch(h.type){\n case \"title\":\n case \"base\":\n if (tags.has(h.type)) {\n isUnique = false;\n } else {\n tags.add(h.type);\n }\n break;\n case \"meta\":\n for(let i = 0, len = METATYPES.length; i < len; i++){\n const metatype = METATYPES[i];\n if (!h.props.hasOwnProperty(metatype)) continue;\n if (metatype === \"charSet\") {\n if (metaTypes.has(metatype)) {\n isUnique = false;\n } else {\n metaTypes.add(metatype);\n }\n } else {\n const category = h.props[metatype];\n const categories = metaCategories[metatype] || new Set();\n if ((metatype !== \"name\" || !hasKey) && categories.has(category)) {\n isUnique = false;\n } else {\n categories.add(category);\n metaCategories[metatype] = categories;\n }\n }\n }\n break;\n }\n return isUnique;\n };\n}\n/**\n *\n * @param headChildrenElements List of children of <Head>\n */ function reduceComponents(headChildrenElements, props) {\n const { inAmpMode } = props;\n return headChildrenElements.reduce(onlyReactElement, []).reverse().concat(defaultHead(inAmpMode).reverse()).filter(unique()).reverse().map((c, i)=>{\n const key = c.key || i;\n if (process.env.NODE_ENV !== \"development\" && process.env.__NEXT_OPTIMIZE_FONTS && !inAmpMode) {\n if (c.type === \"link\" && c.props[\"href\"] && // TODO(prateekbh@): Replace this with const from `constants` when the tree shaking works.\n [\n \"https://fonts.googleapis.com/css\",\n \"https://use.typekit.net/\"\n ].some((url)=>c.props[\"href\"].startsWith(url))) {\n const newProps = {\n ...c.props || {}\n };\n newProps[\"data-href\"] = newProps[\"href\"];\n newProps[\"href\"] = undefined;\n // Add this attribute to make it easy to identify optimized tags\n newProps[\"data-optimized-fonts\"] = true;\n return /*#__PURE__*/ React.cloneElement(c, newProps);\n }\n }\n if (process.env.NODE_ENV === \"development\") {\n // omit JSON-LD structured data snippets from the warning\n if (c.type === \"script\" && c.props[\"type\"] !== \"application/ld+json\") {\n const srcMessage = c.props[\"src\"] ? '<script> tag with src=\"' + c.props[\"src\"] + '\"' : \"inline <script>\";\n warnOnce(\"Do not add <script> tags using next/head (see \" + srcMessage + \"). Use next/script instead. \\nSee more info here: https://nextjs.org/docs/messages/no-script-tags-in-head-component\");\n } else if (c.type === \"link\" && c.props[\"rel\"] === \"stylesheet\") {\n warnOnce('Do not add stylesheets using next/head (see <link rel=\"stylesheet\"> tag with href=\"' + c.props[\"href\"] + '\"). Use Document instead. \\nSee more info here: https://nextjs.org/docs/messages/no-stylesheets-in-head-component');\n }\n }\n return /*#__PURE__*/ React.cloneElement(c, {\n key\n });\n });\n}\n/**\n * This component injects elements to `<head>` of your page.\n * To avoid duplicated `tags` in `<head>` you can use the `key` property, which will make sure every tag is only rendered once.\n */ function Head(param) {\n let { children } = param;\n const ampState = useContext(AmpStateContext);\n const headManager = useContext(HeadManagerContext);\n return /*#__PURE__*/ React.createElement(Effect, {\n reduceComponentsToState: reduceComponents,\n headManager: headManager,\n inAmpMode: isInAmpMode(ampState)\n }, children);\n}\nexport default Head;\n\n//# sourceMappingURL=head.js.map","// Convert router.asPath to a URLSearchParams object\n// example: /dynamic/[slug]?foo=bar -> { foo: 'bar' }\nexport function asPathToSearchParams(asPath) {\n return new URL(asPath, \"http://n\").searchParams;\n}\n\n//# sourceMappingURL=as-path-to-search-params.js.map","/**\n * Removes the trailing slash for a given route or page path. Preserves the\n * root page. Examples:\n * - `/foo/bar/` -> `/foo/bar`\n * - `/foo/bar` -> `/foo/bar`\n * - `/` -> `/`\n */ export function removeTrailingSlash(route) {\n return route.replace(/\\/$/, \"\") || \"/\";\n}\n\n//# sourceMappingURL=remove-trailing-slash.js.map","import { isPlainObject } from \"../shared/lib/is-plain-object\";\nexport default function isError(err) {\n return typeof err === \"object\" && err !== null && \"name\" in err && \"message\" in err;\n}\nexport function getProperError(err) {\n if (isError(err)) {\n return err;\n }\n if (process.env.NODE_ENV === \"development\") {\n // provide better error for case where `throw undefined`\n // is called in development\n if (typeof err === \"undefined\") {\n return new Error(\"An undefined error was thrown, \" + \"see here for more info: https://nextjs.org/docs/messages/threw-undefined\");\n }\n if (err === null) {\n return new Error(\"A null error was thrown, \" + \"see here for more info: https://nextjs.org/docs/messages/threw-undefined\");\n }\n }\n return new Error(isPlainObject(err) ? JSON.stringify(err) : err + \"\");\n}\n\n//# sourceMappingURL=is-error.js.map","import { isDynamicRoute } from \"../router/utils\";\nimport { normalizePathSep } from \"./normalize-path-sep\";\n/**\n * Performs the opposite transformation of `normalizePagePath`. Note that\n * this function is not idempotent either in cases where there are multiple\n * leading `/index` for the page. Examples:\n * - `/index` -> `/`\n * - `/index/foo` -> `/foo`\n * - `/index/index` -> `/index`\n */ export function denormalizePagePath(page) {\n let _page = normalizePathSep(page);\n return _page.startsWith(\"/index/\") && !isDynamicRoute(_page) ? _page.slice(6) : _page !== \"/index\" ? _page : \"/\";\n}\n\n//# sourceMappingURL=denormalize-page-path.js.map","/**\n * For a given page path, this function ensures that there is no backslash\n * escaping slashes in the path. Example:\n * - `foo\\/bar\\/baz` -> `foo/bar/baz`\n */ export function normalizePathSep(path) {\n return path.replace(/\\\\/g, \"/\");\n}\n\n//# sourceMappingURL=normalize-path-sep.js.map","import { ensureLeadingSlash } from \"./ensure-leading-slash\";\nimport { isDynamicRoute } from \"../router/utils\";\nimport { NormalizeError } from \"../utils\";\n/**\n * Takes a page and transforms it into its file counterpart ensuring that the\n * output is normalized. Note this function is not idempotent because a page\n * `/index` can be referencing `/index/index.js` and `/index/index` could be\n * referencing `/index/index/index.js`. Examples:\n * - `/` -> `/index`\n * - `/index/foo` -> `/index/index/foo`\n * - `/index` -> `/index/index`\n */ export function normalizePagePath(page) {\n const normalized = /^\\/index(\\/|$)/.test(page) && !isDynamicRoute(page) ? \"/index\" + page : page === \"/\" ? \"/index\" : ensureLeadingSlash(page);\n if (process.env.NEXT_RUNTIME !== \"edge\") {\n const { posix } = require(\"path\");\n const resolvedPage = posix.normalize(normalized);\n if (resolvedPage !== normalized) {\n throw new NormalizeError(\"Requested and resolved page mismatch: \" + normalized + \" \" + resolvedPage);\n }\n }\n return normalized;\n}\n\n//# sourceMappingURL=normalize-page-path.js.map","/**\n * For a given page path, this function ensures that there is a leading slash.\n * If there is not a leading slash, one is added, otherwise it is noop.\n */ export function ensureLeadingSlash(path) {\n return path.startsWith(\"/\") ? path : \"/\" + path;\n}\n\n//# sourceMappingURL=ensure-leading-slash.js.map","\"use client\";\n\nimport React, { useContext } from \"react\";\n// Use `React.createContext` to avoid errors from the RSC checks because\n// it can't be imported directly in Server Components:\n//\n// import { createContext } from 'react'\n//\n// More info: https://github.com/vercel/next.js/pull/40686\nexport const ServerInsertedHTMLContext = /*#__PURE__*/ React.createContext(null);\nexport function useServerInsertedHTML(callback) {\n const addInsertedServerHTMLCallback = useContext(ServerInsertedHTMLContext);\n // Should have no effects on client where there's no flush effects provider\n if (addInsertedServerHTMLCallback) {\n addInsertedServerHTMLCallback(callback);\n }\n}\n\n//# sourceMappingURL=server-inserted-html.shared-runtime.js.map","import { RouteModule } from \"../route-module\";\nimport { renderToHTMLImpl, renderToHTML } from \"../../../render\";\nimport * as vendoredContexts from \"./vendored/contexts/entrypoints\";\nexport class PagesRouteModule extends RouteModule {\n constructor(options){\n super(options);\n this.components = options.components;\n }\n render(req, res, context) {\n return renderToHTMLImpl(req, res, context.page, context.query, context.renderOpts, {\n App: this.components.App,\n Document: this.components.Document\n });\n }\n}\nconst vendored = {\n contexts: vendoredContexts\n};\n// needed for the static build\nexport { renderToHTML, vendored };\nexport default PagesRouteModule;\n\n//# sourceMappingURL=module.js.map"],"names":["__defProp","Object","defineProperty","__getOwnPropDesc","getOwnPropertyDescriptor","__getOwnPropNames","getOwnPropertyNames","__hasOwnProp","prototype","hasOwnProperty","src_exports","stringifyCookie","c","_a","attrs","path","expires","Date","toUTCString","maxAge","domain","secure","httpOnly","sameSite","priority","filter","Boolean","name","encodeURIComponent","value","join","parseCookie","cookie","map","Map","pair","split","splitAt","indexOf","set","key","slice","decodeURIComponent","parseSetCookie","setCookie","string","attributes","httponly","maxage","samesite","fromEntries","value2","toLowerCase","Number","SAME_SITE","includes","PRIORITY","compact","t","newT","__export","target","all","get","enumerable","RequestCookies","ResponseCookies","module","exports","__copyProps","to","from","except","desc","call","constructor","requestHeaders","_parsed","_headers","header","parsed","Symbol","iterator","size","args","getAll","Array","length","_","n","has","delete","names","result","isArray","clear","keys","for","JSON","stringify","toString","values","v","responseHeaders","_b","_c","getSetCookie","cookieStrings","splitCookiesString","cookiesString","start","ch","lastComma","nextStart","cookiesSeparatorFound","cookiesStrings","pos","skipWhitespace","test","charAt","push","substring","cookieString","normalizeCookie","now","replace","bag","headers","serialized","append","__nccwpck_require__","ab","__dirname","e","r","parse","o","a","s","decode","i","p","f","u","substr","trim","undefined","tryDecode","serialize","encode","isNaN","isFinite","Math","floor","parseHttpDate","NaN","parseTokenList","charCodeAt","REACT_MODULE_REFERENCE","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_SERVER_CONTEXT_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_OFFSCREEN_TYPE","typeOf","object","$$typeof","type","$$typeofType","hasWarnedAboutDeprecatedIsAsyncMode","hasWarnedAboutDeprecatedIsConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Fragment","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","SuspenseList","isAsyncMode","console","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","isSuspenseList","isValidElementType","getModuleId","onlyFirst","_globalThis","env","stdout","globalThis","process","enabled","NO_COLOR","FORCE_COLOR","isTTY","CI","TERM","replaceClose","str","close","index","end","nextIndex","formatter","open","input","bold","String","red","green","yellow","magenta","white","prefixes","wait","error","warn","ready","info","event","trace","LOGGING_METHOD","log","message","prefixedLog","prefixType","shift","consoleMethod","prefix","PRERENDER_REVALIDATE_HEADER","PRERENDER_REVALIDATE_ONLY_GENERATED_HEADER","CACHE_ONE_YEAR","SSG_GET_INITIAL_PROPS_CONFLICT","SERVER_PROPS_GET_INIT_PROPS_CONFLICT","SERVER_PROPS_SSG_CONFLICT","STATIC_STATUS_PAGE_GET_INITIAL_PROPS_ERROR","GSP_NO_RETURNED_VALUE","GSSP_NO_RETURNED_VALUE","UNSTABLE_REVALIDATE_RENAME_ERROR","GSSP_COMPONENT_MEMBER_ERROR","WEBPACK_LAYERS_NAMES","shared","reactServerComponents","serverSideRendering","actionBrowser","api","middleware","edgeAsset","appPagesBrowser","appMetadataRoute","appRouteHandler","GROUP","server","nonClientServerTarget","app","nonNullable","checkIsOnDemandRevalidate","req","previewProps","previewModeId","isOnDemandRevalidate","revalidateOnlyGenerated","COOKIE_NAME_PRERENDER_BYPASS","COOKIE_NAME_PRERENDER_DATA","SYMBOL_PREVIEW_DATA","SYMBOL_CLEARED_COOKIES","clearPreviewData","res","options","previous","getHeader","setHeader","setLazyProp","prop","getter","opts","configurable","optsReset","writable","tryGetPreviewData","_cookies_get","_cookies_get1","encryptedPreviewData","cookies","tokenPreviewData","data","jsonwebtoken","verify","previewModeSigningKey","decryptWithSecret","decryptedPreviewData","Buffer","previewModeEncryptionKey","require","CIPHER_ALGORITHM","encryptWithSecret","secret","iv","salt","cipher","encrypted","concat","update","final","tag","getAuthTag","encryptedData","buffer","CIPHER_SALT_LENGTH","decipher","setAuthTag","capsizeFontsMetrics","https","isGoogleFont","url","startsWith","getFontForUA","UA","Promise","resolve","reject","rawData","on","chunk","getFontDefinitionFromNetwork","getFontDefinitionFromManifest","manifest","_manifest_find","find","font","content","formatName","word","toUpperCase","formatOverrideValue","val","abs","toFixed","calculateOverrideValues","fontName","fontKey","fontMetrics","category","ascent","descent","lineGap","unitsPerEm","fallbackFont","calculateSizeAdjustValues","xWidthAvg","mainFontAvgWidth","fallbackFontName","fallbackFontMetrics","fallbackFontAvgWidth","sizeAdjust","calculateOverrideCSS","calculateSizeAdjustCSS","getFontOverrideCss","css","useSizeAdjust","calcFn","fontNames","parseGoogleFontName","matches","matchAll","Set","fontFamily","add","fontCss","reduce","cssStr","global","ReadableStream","TransformStream","optimize","html","config","AmpOptimizer","optimizer","create","transformHtml","middlewareRegistry","processHTML","root","document","callMiddleWare","inspectData","inspect","mutate","condition","postProcessHTML","pathname","renderOpts","inAmpMode","hybridAmp","postProcessors","optimizeAmp","ampOptimizerConfig","ampSkipValidation","ampValidator","optimizeFonts","getFontDefinition","fontManifest","optimizeCss","Critters","cssOptimizer","ssrMode","reduceInlineStyles","distDir","publicPath","assetPrefix","preload","fonts","postProcessor","originalDom","fontDefinitions","querySelectorAll","getAttribute","hasAttribute","some","dataHref","forEach","element","nonce","markup","preconnectUrls","fontDef","fallBackLinkTag","fontContent","nonceStr","dataAttr","escapedUrl","fontRegex","provider","preconnect","preconnectTag","__NEXT_OPTIMIZE_FONTS","ReadonlyHeadersError","Error","callable","HeadersAdapter","Headers","Proxy","receiver","lowercased","original","deleteProperty","seal","merge","existing","callbackfn","thisArg","entries","ReflectAdapter","Reflect","bind","COMPILER_NAMES","client","edgeServer","NEXT_BUILTIN_DOCUMENT","TEMPORARY_REDIRECT_STATUS","PERMANENT_REDIRECT_STATUS","STATIC_PROPS_ID","SERVER_PROPS_ID","GOOGLE_FONT_PROVIDER","OPTIMIZED_FONT_PROVIDERS","DEFAULT_SERIF_FONT","xAvgCharWidth","azAvgWidth","DEFAULT_SANS_SERIF_FONT","STATIC_STATUS_PAGES","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","__esModule","d","definition","obj","toStringTag","BaseServerSpan","LoadComponentsSpan","NextServerSpan","NextNodeServerSpan","StartServerSpan","RenderSpan","AppRenderSpan","RouterSpan","NodeSpan","AppRouteRouteHandlersSpan","ResolveMetadataSpan","CacheStates","RouteModule","userland","getObjectClassLabel","getPrototypeOf","regexpPlainIdentifier","SerializableError","page","method","isSerializableProps","visit","visited","isSerializable","refs","every","nestedValue","nextPath","newRefs","displayName","LoadableContext","ALL_INITIALIZERS","READY_INITIALIZERS","load","loader","promise","state","loading","loaded","then","catch","err","LoadableSubscription","_res","retry","_clearTimeouts","_loadFn","_opts","_state","pastDelay","timedOut","delay","_delay","setTimeout","_update","timeout","_timeout","partial","_callbacks","callback","clearTimeout","getCurrentValue","subscribe","loadFn","Loadable","createLoadableComponent","assign","webpack","modules","subscription","init","sub","LoadableComponent","props","ref","useLoadableModule","context","moduleName","isLoading","default","flushInitializers","initializers","ids","promises","pop","preloadAll","resolveInitializers","preloadReady","resolvePreload","RouterContext","TEST_ROUTE","isDynamicRoute","route","getDisplayName","Component","finished","headersSent","loadGetInitialProps","App","ctx","_App_prototype","getInitialProps","pageProps","SP","performance","NormalizeError","HtmlContext","createContext","useHtmlContext","useContext","NEXT_REQUEST_META","getRequestMeta","meta","allowedStatusCodes","getRedirectStatus","statusCode","permanent","pipeReadable","readable","waitUntilForEnd","reader","getReader","readerDone","writableClosed","onClose","off","cancel","done","read","write","flush","RenderResult","fromStatic","response","contentType","waitUntil","metadata","extendMetadata","isNull","isDynamic","toUnchunkedString","pipe","encodeText","TextEncoder","textDecoder","stream","queueTask","setImmediate","streamFromString","controller","enqueue","streamToString","TextDecoder","bufferedString","continueFizzStream","renderStream","suffix","inlinedDataStream","generateStaticHTML","getServerInsertedHTML","serverInsertedHTMLToHead","validateRootLayout","suffixFlushed","suffixFlushTask","dataStreamFinished","closeTag","suffixUnclosed","allReady","transforms","createBufferedTransformStream","bufferedBytes","Uint8Array","pendingFlush","flushBuffer","transform","newBufferedBytes","byteLength","insertedHTMLChunk","dataStreamReader","dataStream","createMoveSuffixStream","foundSuffix","endsWith","contentWithoutSuffix","createHeadInsertionTransformStream","insert","inserted","freezing","insertion","insertedHeadContent","createRootLayoutValidatorStream","getTree","foundHtml","foundBody","missingTags","tree","pipeThrough","ImageConfigContext","deviceSizes","imageSizes","loaderFile","domains","disableStaticImages","minimumCacheTTL","formats","dangerouslyAllowSVG","contentSecurityPolicy","contentDispositionType","remotePatterns","unoptimized","INTERNAL_QUERY_NAMES","SearchParamsContext","PathnameContext","PathParamsContext","reHasRegExp","reReplaceRegExp","parseParameter","param","optional","repeat","PathnameContextProviderAdapter","children","router","useRef","isAutoExport","useMemo","current","isFallback","isReady","URL","asPath","Provider","AppRouterContext","LayoutRouterContext","GlobalLayoutRouterContext","TemplateContext","DOCTYPE","noRouter","renderToString","ServerRouter","query","as","basePath","locale","locales","defaultLocale","domainLocales","isPreview","isLocaleDomain","reload","back","forward","prefetch","beforePopState","renderPageTree","invalidKeysMsg","methodName","invalidKeys","docsPathname","toLocaleLowerCase","checkRedirectValues","redirect","destination","errors","hasStatusCode","hasPermanent","destinationType","basePathType","renderToHTMLImpl","extra","_getTracer_getRootSpanAttributes","previewData","parseCookieFn","renderResultMeta","assetQueryString","dev","deploymentId","ampPath","pageConfig","buildManifest","reactLoadableManifest","ErrorDebug","getStaticProps","getStaticPaths","getServerSideProps","isDataReq","params","images","runtime","globalRuntime","isExperimentalCompile","Document","__nextFallback","notFoundSrcPage","__nextNotFoundSrcPage","stripInternalQueries","isSSG","isBuildTimeSSG","nextExport","defaultAppGetInitialProps","origGetInitialProps","hasPageGetInitialProps","hasPageScripts","unstable_scriptLoader","pageIsDynamic","defaultErrorGetInitialProps","private","stateful","revalidate","nextConfigOutput","resolvedAsPath","amp","routerIsReady","appRouter","refresh","href","scroll","scriptLoader","jsxStyleRegistry","createStyleRegistry","ampState","ampFirst","hasQuery","hybrid","head","defaultHead","charSet","reactLoadableModules","initialScripts","beforeInteractive","script","strategy","AppContainer","searchParams","URLSearchParams","adaptForPathParams","pathParams","routeRegex","getRouteRegex","normalizedRoute","parameterizedRoute","groups","getParametrizedRoute","segments","groupIndex","markerMatch","segment","m","paramMatches","match","re","updateHead","updateScripts","scripts","mountedInstances","StyleRegistry","registry","Noop","AppContainerWithIsomorphicFiberStructure","AppTree","defaultGetInitialProps","docCtx","renderPageHead","renderPage","enhanceApp","AppComp","styles","styledJsxInsertedHTML","__N_PREVIEW","getTracer","spanName","draftMode","preview","staticPropsError","code","notFound","isNotFound","__N_REDIRECT","__N_REDIRECT_STATUS","__N_REDIRECT_BASE_PATH","isRedirect","isInteger","ceil","pageData","canAccessRes","resOrProxy","deferredContent","resolvedUrl","serverSidePropsError","unstable_notFound","unstable_redirect","filteredBuildManifest","_page","normalized","posix","resolvedPage","normalize","pages","lowPriorityFiles","Body","id","renderDocument","bodyResult","documentInitialPropsRes","loadDocumentInitialProps","renderShell","EnhancedApp","EnhancedComponent","enhanceComponent","documentCtx","docProps","renderContent","_App","_Component","renderToInitialFizzStream","ReactDOMServer","streamOptions","renderToReadableStream","createBodyResult","wrap","initialStream","hasDocumentGetInitialProps","documentElement","htmlProps","headTags","getRootSpanAttributes","documentResult","dynamicImportsIds","dynamicImports","mod","manifestItem","files","item","docComponentsRendered","buildId","customServer","disableOptimizedLoading","runtimeConfig","__NEXT_DATA__","autoExport","dynamicIds","serializeError","source","stack","digest","gsp","gssp","gip","appGip","strictNextHead","dangerousAsPath","canonicalBase","isDevelopment","unstable_runtimeJS","unstable_JsPreload","crossOrigin","nextScriptWorkers","largePageDataBytes","nextFontManifest","documentHTML","nonRenderedComponents","comp","missingComponentList","plural","renderTargetPrefix","renderTargetSuffix","streams","chainStreams","pipeTo","preventClose","optimizedHtml","renderToHTML","ServerInsertedHTMLContext","useServerInsertedHTML","addInsertedServerHTMLCallback","PagesRouteModule","components","render","vendored","contexts"],"sourceRoot":""}