{"version":3,"file":"start.8eb29400.js","sources":["../../../../../../node_modules/@sveltejs/kit/src/utils/url.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/hash.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/client/fetcher.js","../../../../../../node_modules/@sveltejs/kit/src/utils/routing.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/client/parse.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/client/session-storage.js","../../../../../../node_modules/devalue/src/constants.js","../../../../../../node_modules/devalue/src/parse.js","../../../../../../node_modules/@sveltejs/kit/src/utils/array.js","../../../../../../node_modules/@sveltejs/kit/src/utils/exports.js","../../../../../../node_modules/@sveltejs/kit/src/utils/promises.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/shared.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/client/client.js","../../../../../../node_modules/@sveltejs/kit/src/runtime/client/start.js"],"sourcesContent":["import { BROWSER } from 'esm-env';\n\n/**\n * Matches a URI scheme. See https://www.rfc-editor.org/rfc/rfc3986#section-3.1\n * @type {RegExp}\n */\nexport const SCHEME = /^[a-z][a-z\\d+\\-.]+:/i;\n\nconst absolute = /^([a-z]+:)?\\/?\\//;\n\n/**\n * @param {string} base\n * @param {string} path\n */\nexport function resolve(base, path) {\n\tif (SCHEME.test(path)) return path;\n\tif (path[0] === '#') return base + path;\n\n\tconst base_match = absolute.exec(base);\n\tconst path_match = absolute.exec(path);\n\n\tif (!base_match) {\n\t\tthrow new Error(`bad base path: \"${base}\"`);\n\t}\n\n\tconst baseparts = path_match ? [] : base.slice(base_match[0].length).split('/');\n\tconst pathparts = path_match ? path.slice(path_match[0].length).split('/') : path.split('/');\n\n\tbaseparts.pop();\n\n\tfor (let i = 0; i < pathparts.length; i += 1) {\n\t\tconst part = pathparts[i];\n\t\tif (part === '.') continue;\n\t\telse if (part === '..') baseparts.pop();\n\t\telse baseparts.push(part);\n\t}\n\n\tconst prefix = (path_match && path_match[0]) || (base_match && base_match[0]) || '';\n\n\treturn `${prefix}${baseparts.join('/')}`;\n}\n\n/** @param {string} path */\nexport function is_root_relative(path) {\n\treturn path[0] === '/' && path[1] !== '/';\n}\n\n/**\n * @param {string} path\n * @param {import('types').TrailingSlash} trailing_slash\n */\nexport function normalize_path(path, trailing_slash) {\n\tif (path === '/' || trailing_slash === 'ignore') return path;\n\n\tif (trailing_slash === 'never') {\n\t\treturn path.endsWith('/') ? path.slice(0, -1) : path;\n\t} else if (trailing_slash === 'always' && !path.endsWith('/')) {\n\t\treturn path + '/';\n\t}\n\n\treturn path;\n}\n\n/**\n * Decode pathname excluding %25 to prevent further double decoding of params\n * @param {string} pathname\n */\nexport function decode_pathname(pathname) {\n\treturn pathname.split('%25').map(decodeURI).join('%25');\n}\n\n/** @param {Record} params */\nexport function decode_params(params) {\n\tfor (const key in params) {\n\t\t// input has already been decoded by decodeURI\n\t\t// now handle the rest\n\t\tparams[key] = decodeURIComponent(params[key]);\n\t}\n\n\treturn params;\n}\n\n/**\n * The error when a URL is malformed is not very helpful, so we augment it with the URI\n * @param {string} uri\n */\nexport function decode_uri(uri) {\n\ttry {\n\t\treturn decodeURI(uri);\n\t} catch (e) {\n\t\tif (e instanceof Error) {\n\t\t\te.message = `Failed to decode URI: ${uri}\\n` + e.message;\n\t\t}\n\t\tthrow e;\n\t}\n}\n\n/**\n * URL properties that could change during the lifetime of the page,\n * which excludes things like `origin`\n */\nconst tracked_url_properties = /** @type {const} */ ([\n\t'href',\n\t'pathname',\n\t'search',\n\t'searchParams',\n\t'toString',\n\t'toJSON'\n]);\n\n/**\n * @param {URL} url\n * @param {() => void} callback\n */\nexport function make_trackable(url, callback) {\n\tconst tracked = new URL(url);\n\n\tfor (const property of tracked_url_properties) {\n\t\tObject.defineProperty(tracked, property, {\n\t\t\tget() {\n\t\t\t\tcallback();\n\t\t\t\treturn url[property];\n\t\t\t},\n\n\t\t\tenumerable: true,\n\t\t\tconfigurable: true\n\t\t});\n\t}\n\n\tif (!BROWSER) {\n\t\t// @ts-ignore\n\t\ttracked[Symbol.for('nodejs.util.inspect.custom')] = (depth, opts, inspect) => {\n\t\t\treturn inspect(url, opts);\n\t\t};\n\t}\n\n\tdisable_hash(tracked);\n\n\treturn tracked;\n}\n\n/**\n * Disallow access to `url.hash` on the server and in `load`\n * @param {URL} url\n */\nexport function disable_hash(url) {\n\tallow_nodejs_console_log(url);\n\n\tObject.defineProperty(url, 'hash', {\n\t\tget() {\n\t\t\tthrow new Error(\n\t\t\t\t'Cannot access event.url.hash. Consider using `$page.url.hash` inside a component instead'\n\t\t\t);\n\t\t}\n\t});\n}\n\n/**\n * Disallow access to `url.search` and `url.searchParams` during prerendering\n * @param {URL} url\n */\nexport function disable_search(url) {\n\tallow_nodejs_console_log(url);\n\n\tfor (const property of ['search', 'searchParams']) {\n\t\tObject.defineProperty(url, property, {\n\t\t\tget() {\n\t\t\t\tthrow new Error(`Cannot access url.${property} on a page with prerendering enabled`);\n\t\t\t}\n\t\t});\n\t}\n}\n\n/**\n * Allow URL to be console logged, bypassing disabled properties.\n * @param {URL} url\n */\nfunction allow_nodejs_console_log(url) {\n\tif (!BROWSER) {\n\t\t// @ts-ignore\n\t\turl[Symbol.for('nodejs.util.inspect.custom')] = (depth, opts, inspect) => {\n\t\t\treturn inspect(new URL(url), opts);\n\t\t};\n\t}\n}\n\nconst DATA_SUFFIX = '/__data.json';\n\n/** @param {string} pathname */\nexport function has_data_suffix(pathname) {\n\treturn pathname.endsWith(DATA_SUFFIX);\n}\n\n/** @param {string} pathname */\nexport function add_data_suffix(pathname) {\n\treturn pathname.replace(/\\/$/, '') + DATA_SUFFIX;\n}\n\n/** @param {string} pathname */\nexport function strip_data_suffix(pathname) {\n\treturn pathname.slice(0, -DATA_SUFFIX.length);\n}\n","/**\n * Hash using djb2\n * @param {import('types').StrictBody[]} values\n */\nexport function hash(...values) {\n\tlet hash = 5381;\n\n\tfor (const value of values) {\n\t\tif (typeof value === 'string') {\n\t\t\tlet i = value.length;\n\t\t\twhile (i) hash = (hash * 33) ^ value.charCodeAt(--i);\n\t\t} else if (ArrayBuffer.isView(value)) {\n\t\t\tconst buffer = new Uint8Array(value.buffer, value.byteOffset, value.byteLength);\n\t\t\tlet i = buffer.length;\n\t\t\twhile (i) hash = (hash * 33) ^ buffer[--i];\n\t\t} else {\n\t\t\tthrow new TypeError('value must be a string or TypedArray');\n\t\t}\n\t}\n\n\treturn (hash >>> 0).toString(36);\n}\n","import { DEV } from 'esm-env';\nimport { hash } from '../hash.js';\n\nlet loading = 0;\n\nexport const native_fetch = window.fetch;\n\nexport function lock_fetch() {\n\tloading += 1;\n}\n\nexport function unlock_fetch() {\n\tloading -= 1;\n}\n\nif (DEV) {\n\tlet can_inspect_stack_trace = false;\n\n\tconst check_stack_trace = async () => {\n\t\tconst stack = /** @type {string} */ (new Error().stack);\n\t\tcan_inspect_stack_trace = stack.includes('check_stack_trace');\n\t};\n\n\tcheck_stack_trace();\n\n\t/**\n\t * @param {RequestInfo | URL} input\n\t * @param {RequestInit & Record | undefined} init\n\t */\n\twindow.fetch = (input, init) => {\n\t\t// Check if fetch was called via load_node. the lock method only checks if it was called at the\n\t\t// same time, but not necessarily if it was called from `load`.\n\t\t// We use just the filename as the method name sometimes does not appear on the CI.\n\t\tconst url = input instanceof Request ? input.url : input.toString();\n\t\tconst stack_array = /** @type {string} */ (new Error().stack).split('\\n');\n\t\t// We need to do a cutoff because Safari and Firefox maintain the stack\n\t\t// across events and for example traces a `fetch` call triggered from a button\n\t\t// back to the creation of the event listener and the element creation itself,\n\t\t// where at some point client.js will show up, leading to false positives.\n\t\tconst cutoff = stack_array.findIndex((a) => a.includes('load@') || a.includes('at load'));\n\t\tconst stack = stack_array.slice(0, cutoff + 2).join('\\n');\n\n\t\tconst in_load_heuristic = can_inspect_stack_trace\n\t\t\t? stack.includes('src/runtime/client/client.js')\n\t\t\t: loading;\n\n\t\t// This flag is set in initial_fetch and subsequent_fetch\n\t\tconst used_kit_fetch = init?.__sveltekit_fetch__;\n\n\t\tif (in_load_heuristic && !used_kit_fetch) {\n\t\t\tconsole.warn(\n\t\t\t\t`Loading ${url} using \\`window.fetch\\`. For best results, use the \\`fetch\\` that is passed to your \\`load\\` function: https://kit.svelte.dev/docs/load#making-fetch-requests`\n\t\t\t);\n\t\t}\n\n\t\tconst method = input instanceof Request ? input.method : init?.method || 'GET';\n\n\t\tif (method !== 'GET') {\n\t\t\tcache.delete(build_selector(input));\n\t\t}\n\n\t\treturn native_fetch(input, init);\n\t};\n} else {\n\twindow.fetch = (input, init) => {\n\t\tconst method = input instanceof Request ? input.method : init?.method || 'GET';\n\n\t\tif (method !== 'GET') {\n\t\t\tcache.delete(build_selector(input));\n\t\t}\n\n\t\treturn native_fetch(input, init);\n\t};\n}\n\nconst cache = new Map();\n\n/**\n * @param {string} text\n * @returns {ArrayBufferLike}\n */\nfunction b64_decode(text) {\n\tconst d = atob(text);\n\n\tconst u8 = new Uint8Array(d.length);\n\n\tfor (let i = 0; i < d.length; i++) {\n\t\tu8[i] = d.charCodeAt(i);\n\t}\n\n\treturn u8.buffer;\n}\n\n/**\n * Should be called on the initial run of load functions that hydrate the page.\n * Saves any requests with cache-control max-age to the cache.\n * @param {URL | string} resource\n * @param {RequestInit} [opts]\n */\nexport function initial_fetch(resource, opts) {\n\tconst selector = build_selector(resource, opts);\n\n\tconst script = document.querySelector(selector);\n\tif (script?.textContent) {\n\t\tlet { body, ...init } = JSON.parse(script.textContent);\n\n\t\tconst ttl = script.getAttribute('data-ttl');\n\t\tif (ttl) cache.set(selector, { body, init, ttl: 1000 * Number(ttl) });\n\t\tconst b64 = script.getAttribute('data-b64');\n\t\tif (b64 !== null) {\n\t\t\t// Can't use native_fetch('data:...;base64,${body}')\n\t\t\t// csp can block the request\n\t\t\tbody = b64_decode(body);\n\t\t}\n\n\t\treturn Promise.resolve(new Response(body, init));\n\t}\n\n\treturn DEV ? dev_fetch(resource, opts) : window.fetch(resource, opts);\n}\n\n/**\n * Tries to get the response from the cache, if max-age allows it, else does a fetch.\n * @param {URL | string} resource\n * @param {string} resolved\n * @param {RequestInit} [opts]\n */\nexport function subsequent_fetch(resource, resolved, opts) {\n\tif (cache.size > 0) {\n\t\tconst selector = build_selector(resource, opts);\n\t\tconst cached = cache.get(selector);\n\t\tif (cached) {\n\t\t\t// https://developer.mozilla.org/en-US/docs/Web/API/Request/cache#value\n\t\t\tif (\n\t\t\t\tperformance.now() < cached.ttl &&\n\t\t\t\t['default', 'force-cache', 'only-if-cached', undefined].includes(opts?.cache)\n\t\t\t) {\n\t\t\t\treturn new Response(cached.body, cached.init);\n\t\t\t}\n\n\t\t\tcache.delete(selector);\n\t\t}\n\t}\n\n\treturn DEV ? dev_fetch(resolved, opts) : window.fetch(resolved, opts);\n}\n\n/**\n * @param {RequestInfo | URL} resource\n * @param {RequestInit & Record | undefined} opts\n */\nfunction dev_fetch(resource, opts) {\n\tconst patched_opts = { ...opts };\n\t// This assigns the __sveltekit_fetch__ flag and makes it non-enumerable\n\tObject.defineProperty(patched_opts, '__sveltekit_fetch__', {\n\t\tvalue: true,\n\t\twritable: true,\n\t\tconfigurable: true\n\t});\n\treturn window.fetch(resource, patched_opts);\n}\n\n/**\n * Build the cache key for a given request\n * @param {URL | RequestInfo} resource\n * @param {RequestInit} [opts]\n */\nfunction build_selector(resource, opts) {\n\tconst url = JSON.stringify(resource instanceof Request ? resource.url : resource);\n\n\tlet selector = `script[data-sveltekit-fetched][data-url=${url}]`;\n\n\tif (opts?.headers || opts?.body) {\n\t\t/** @type {import('types').StrictBody[]} */\n\t\tconst values = [];\n\n\t\tif (opts.headers) {\n\t\t\tvalues.push([...new Headers(opts.headers)].join(','));\n\t\t}\n\n\t\tif (opts.body && (typeof opts.body === 'string' || ArrayBuffer.isView(opts.body))) {\n\t\t\tvalues.push(opts.body);\n\t\t}\n\n\t\tselector += `[data-hash=\"${hash(...values)}\"]`;\n\t}\n\n\treturn selector;\n}\n","const param_pattern = /^(\\[)?(\\.\\.\\.)?(\\w+)(?:=(\\w+))?(\\])?$/;\n\n/**\n * Creates the regex pattern, extracts parameter names, and generates types for a route\n * @param {string} id\n */\nexport function parse_route_id(id) {\n\t/** @type {import('types').RouteParam[]} */\n\tconst params = [];\n\n\tconst pattern =\n\t\tid === '/'\n\t\t\t? /^\\/$/\n\t\t\t: new RegExp(\n\t\t\t\t\t`^${get_route_segments(id)\n\t\t\t\t\t\t.map((segment) => {\n\t\t\t\t\t\t\t// special case — /[...rest]/ could contain zero segments\n\t\t\t\t\t\t\tconst rest_match = /^\\[\\.\\.\\.(\\w+)(?:=(\\w+))?\\]$/.exec(segment);\n\t\t\t\t\t\t\tif (rest_match) {\n\t\t\t\t\t\t\t\tparams.push({\n\t\t\t\t\t\t\t\t\tname: rest_match[1],\n\t\t\t\t\t\t\t\t\tmatcher: rest_match[2],\n\t\t\t\t\t\t\t\t\toptional: false,\n\t\t\t\t\t\t\t\t\trest: true,\n\t\t\t\t\t\t\t\t\tchained: true\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\treturn '(?:/(.*))?';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// special case — /[[optional]]/ could contain zero segments\n\t\t\t\t\t\t\tconst optional_match = /^\\[\\[(\\w+)(?:=(\\w+))?\\]\\]$/.exec(segment);\n\t\t\t\t\t\t\tif (optional_match) {\n\t\t\t\t\t\t\t\tparams.push({\n\t\t\t\t\t\t\t\t\tname: optional_match[1],\n\t\t\t\t\t\t\t\t\tmatcher: optional_match[2],\n\t\t\t\t\t\t\t\t\toptional: true,\n\t\t\t\t\t\t\t\t\trest: false,\n\t\t\t\t\t\t\t\t\tchained: true\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\treturn '(?:/([^/]+))?';\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (!segment) {\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tconst parts = segment.split(/\\[(.+?)\\](?!\\])/);\n\t\t\t\t\t\t\tconst result = parts\n\t\t\t\t\t\t\t\t.map((content, i) => {\n\t\t\t\t\t\t\t\t\tif (i % 2) {\n\t\t\t\t\t\t\t\t\t\tif (content.startsWith('x+')) {\n\t\t\t\t\t\t\t\t\t\t\treturn escape(String.fromCharCode(parseInt(content.slice(2), 16)));\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tif (content.startsWith('u+')) {\n\t\t\t\t\t\t\t\t\t\t\treturn escape(\n\t\t\t\t\t\t\t\t\t\t\t\tString.fromCharCode(\n\t\t\t\t\t\t\t\t\t\t\t\t\t...content\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.slice(2)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.split('-')\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.map((code) => parseInt(code, 16))\n\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tconst match = param_pattern.exec(content);\n\t\t\t\t\t\t\t\t\t\tif (!match) {\n\t\t\t\t\t\t\t\t\t\t\tthrow new Error(\n\t\t\t\t\t\t\t\t\t\t\t\t`Invalid param: ${content}. Params and matcher names can only have underscores and alphanumeric characters.`\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tconst [, is_optional, is_rest, name, matcher] = match;\n\t\t\t\t\t\t\t\t\t\t// It's assumed that the following invalid route id cases are already checked\n\t\t\t\t\t\t\t\t\t\t// - unbalanced brackets\n\t\t\t\t\t\t\t\t\t\t// - optional param following rest param\n\n\t\t\t\t\t\t\t\t\t\tparams.push({\n\t\t\t\t\t\t\t\t\t\t\tname,\n\t\t\t\t\t\t\t\t\t\t\tmatcher,\n\t\t\t\t\t\t\t\t\t\t\toptional: !!is_optional,\n\t\t\t\t\t\t\t\t\t\t\trest: !!is_rest,\n\t\t\t\t\t\t\t\t\t\t\tchained: is_rest ? i === 1 && parts[0] === '' : false\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t\treturn is_rest ? '(.*?)' : is_optional ? '([^/]*)?' : '([^/]+?)';\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\treturn escape(content);\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t.join('');\n\n\t\t\t\t\t\t\treturn '/' + result;\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.join('')}/?$`\n\t\t\t\t);\n\n\treturn { pattern, params };\n}\n\nconst optional_param_regex = /\\/\\[\\[\\w+?(?:=\\w+)?\\]\\]/;\n\n/**\n * Removes optional params from a route ID.\n * @param {string} id\n * @returns The route id with optional params removed\n */\nexport function remove_optional_params(id) {\n\treturn id.replace(optional_param_regex, '');\n}\n\n/**\n * Returns `false` for `(group)` segments\n * @param {string} segment\n */\nfunction affects_path(segment) {\n\treturn !/^\\([^)]+\\)$/.test(segment);\n}\n\n/**\n * Splits a route id into its segments, removing segments that\n * don't affect the path (i.e. groups). The root route is represented by `/`\n * and will be returned as `['']`.\n * @param {string} route\n * @returns string[]\n */\nexport function get_route_segments(route) {\n\treturn route.slice(1).split('/').filter(affects_path);\n}\n\n/**\n * @param {RegExpMatchArray} match\n * @param {import('types').RouteParam[]} params\n * @param {Record} matchers\n */\nexport function exec(match, params, matchers) {\n\t/** @type {Record} */\n\tconst result = {};\n\n\tconst values = match.slice(1);\n\tconst values_needing_match = values.filter((value) => value !== undefined);\n\n\tlet buffered = 0;\n\n\tfor (let i = 0; i < params.length; i += 1) {\n\t\tconst param = params[i];\n\t\tlet value = values[i - buffered];\n\n\t\t// in the `[[a=b]]/.../[...rest]` case, if one or more optional parameters\n\t\t// weren't matched, roll the skipped values into the rest\n\t\tif (param.chained && param.rest && buffered) {\n\t\t\tvalue = values\n\t\t\t\t.slice(i - buffered, i + 1)\n\t\t\t\t.filter((s) => s)\n\t\t\t\t.join('/');\n\n\t\t\tbuffered = 0;\n\t\t}\n\n\t\t// if `value` is undefined, it means this is an optional or rest parameter\n\t\tif (value === undefined) {\n\t\t\tif (param.rest) result[param.name] = '';\n\t\t\tcontinue;\n\t\t}\n\n\t\tif (!param.matcher || matchers[param.matcher](value)) {\n\t\t\tresult[param.name] = value;\n\n\t\t\t// Now that the params match, reset the buffer if the next param isn't the [...rest]\n\t\t\t// and the next value is defined, otherwise the buffer will cause us to skip values\n\t\t\tconst next_param = params[i + 1];\n\t\t\tconst next_value = values[i + 1];\n\t\t\tif (next_param && !next_param.rest && next_param.optional && next_value && param.chained) {\n\t\t\t\tbuffered = 0;\n\t\t\t}\n\n\t\t\t// There are no more params and no more values, but all non-empty values have been matched\n\t\t\tif (\n\t\t\t\t!next_param &&\n\t\t\t\t!next_value &&\n\t\t\t\tObject.keys(result).length === values_needing_match.length\n\t\t\t) {\n\t\t\t\tbuffered = 0;\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\n\t\t// in the `/[[a=b]]/...` case, if the value didn't satisfy the matcher,\n\t\t// keep track of the number of skipped optional parameters and continue\n\t\tif (param.optional && param.chained) {\n\t\t\tbuffered++;\n\t\t\tcontinue;\n\t\t}\n\n\t\t// otherwise, if the matcher returns `false`, the route did not match\n\t\treturn;\n\t}\n\n\tif (buffered) return;\n\treturn result;\n}\n\n/** @param {string} str */\nfunction escape(str) {\n\treturn (\n\t\tstr\n\t\t\t.normalize()\n\t\t\t// escape [ and ] before escaping other characters, since they are used in the replacements\n\t\t\t.replace(/[[\\]]/g, '\\\\$&')\n\t\t\t// replace %, /, ? and # with their encoded versions because decode_pathname leaves them untouched\n\t\t\t.replace(/%/g, '%25')\n\t\t\t.replace(/\\//g, '%2[Ff]')\n\t\t\t.replace(/\\?/g, '%3[Ff]')\n\t\t\t.replace(/#/g, '%23')\n\t\t\t// escape characters that have special meaning in regex\n\t\t\t.replace(/[.*+?^${}()|\\\\]/g, '\\\\$&')\n\t);\n}\n","import { exec, parse_route_id } from '../../utils/routing.js';\n\n/**\n * @param {import('./types.js').SvelteKitApp} app\n * @returns {import('types').CSRRoute[]}\n */\nexport function parse({ nodes, server_loads, dictionary, matchers }) {\n\tconst layouts_with_server_load = new Set(server_loads);\n\n\treturn Object.entries(dictionary).map(([id, [leaf, layouts, errors]]) => {\n\t\tconst { pattern, params } = parse_route_id(id);\n\n\t\tconst route = {\n\t\t\tid,\n\t\t\t/** @param {string} path */\n\t\t\texec: (path) => {\n\t\t\t\tconst match = pattern.exec(path);\n\t\t\t\tif (match) return exec(match, params, matchers);\n\t\t\t},\n\t\t\terrors: [1, ...(errors || [])].map((n) => nodes[n]),\n\t\t\tlayouts: [0, ...(layouts || [])].map(create_layout_loader),\n\t\t\tleaf: create_leaf_loader(leaf)\n\t\t};\n\n\t\t// bit of a hack, but ensures that layout/error node lists are the same\n\t\t// length, without which the wrong data will be applied if the route\n\t\t// manifest looks like `[[a, b], [c,], d]`\n\t\troute.errors.length = route.layouts.length = Math.max(\n\t\t\troute.errors.length,\n\t\t\troute.layouts.length\n\t\t);\n\n\t\treturn route;\n\t});\n\n\t/**\n\t * @param {number} id\n\t * @returns {[boolean, import('types').CSRPageNodeLoader]}\n\t */\n\tfunction create_leaf_loader(id) {\n\t\t// whether or not the route uses the server data is\n\t\t// encoded using the ones' complement, to save space\n\t\tconst uses_server_data = id < 0;\n\t\tif (uses_server_data) id = ~id;\n\t\treturn [uses_server_data, nodes[id]];\n\t}\n\n\t/**\n\t * @param {number | undefined} id\n\t * @returns {[boolean, import('types').CSRPageNodeLoader] | undefined}\n\t */\n\tfunction create_layout_loader(id) {\n\t\t// whether or not the layout uses the server data is\n\t\t// encoded in the layouts array, to save space\n\t\treturn id === undefined ? id : [layouts_with_server_load.has(id), nodes[id]];\n\t}\n}\n","/**\n * Read a value from `sessionStorage`\n * @param {string} key\n */\nexport function get(key) {\n\ttry {\n\t\treturn JSON.parse(sessionStorage[key]);\n\t} catch {\n\t\t// do nothing\n\t}\n}\n\n/**\n * Write a value to `sessionStorage`\n * @param {string} key\n * @param {any} value\n */\nexport function set(key, value) {\n\tconst json = JSON.stringify(value);\n\ttry {\n\t\tsessionStorage[key] = json;\n\t} catch {\n\t\t// do nothing\n\t}\n}\n","export const UNDEFINED = -1;\nexport const HOLE = -2;\nexport const NAN = -3;\nexport const POSITIVE_INFINITY = -4;\nexport const NEGATIVE_INFINITY = -5;\nexport const NEGATIVE_ZERO = -6;\n","import {\n\tHOLE,\n\tNAN,\n\tNEGATIVE_INFINITY,\n\tNEGATIVE_ZERO,\n\tPOSITIVE_INFINITY,\n\tUNDEFINED\n} from './constants.js';\n\n/**\n * Revive a value serialized with `devalue.stringify`\n * @param {string} serialized\n * @param {Record any>} [revivers]\n */\nexport function parse(serialized, revivers) {\n\treturn unflatten(JSON.parse(serialized), revivers);\n}\n\n/**\n * Revive a value flattened with `devalue.stringify`\n * @param {number | any[]} parsed\n * @param {Record any>} [revivers]\n */\nexport function unflatten(parsed, revivers) {\n\tif (typeof parsed === 'number') return hydrate(parsed, true);\n\n\tif (!Array.isArray(parsed) || parsed.length === 0) {\n\t\tthrow new Error('Invalid input');\n\t}\n\n\tconst values = /** @type {any[]} */ (parsed);\n\n\tconst hydrated = Array(values.length);\n\n\t/**\n\t * @param {number} index\n\t * @returns {any}\n\t */\n\tfunction hydrate(index, standalone = false) {\n\t\tif (index === UNDEFINED) return undefined;\n\t\tif (index === NAN) return NaN;\n\t\tif (index === POSITIVE_INFINITY) return Infinity;\n\t\tif (index === NEGATIVE_INFINITY) return -Infinity;\n\t\tif (index === NEGATIVE_ZERO) return -0;\n\n\t\tif (standalone) throw new Error(`Invalid input`);\n\n\t\tif (index in hydrated) return hydrated[index];\n\n\t\tconst value = values[index];\n\n\t\tif (!value || typeof value !== 'object') {\n\t\t\thydrated[index] = value;\n\t\t} else if (Array.isArray(value)) {\n\t\t\tif (typeof value[0] === 'string') {\n\t\t\t\tconst type = value[0];\n\n\t\t\t\tconst reviver = revivers?.[type];\n\t\t\t\tif (reviver) {\n\t\t\t\t\treturn (hydrated[index] = reviver(hydrate(value[1])));\n\t\t\t\t}\n\n\t\t\t\tswitch (type) {\n\t\t\t\t\tcase 'Date':\n\t\t\t\t\t\thydrated[index] = new Date(value[1]);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'Set':\n\t\t\t\t\t\tconst set = new Set();\n\t\t\t\t\t\thydrated[index] = set;\n\t\t\t\t\t\tfor (let i = 1; i < value.length; i += 1) {\n\t\t\t\t\t\t\tset.add(hydrate(value[i]));\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'Map':\n\t\t\t\t\t\tconst map = new Map();\n\t\t\t\t\t\thydrated[index] = map;\n\t\t\t\t\t\tfor (let i = 1; i < value.length; i += 2) {\n\t\t\t\t\t\t\tmap.set(hydrate(value[i]), hydrate(value[i + 1]));\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'RegExp':\n\t\t\t\t\t\thydrated[index] = new RegExp(value[1], value[2]);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'Object':\n\t\t\t\t\t\thydrated[index] = Object(value[1]);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'BigInt':\n\t\t\t\t\t\thydrated[index] = BigInt(value[1]);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'null':\n\t\t\t\t\t\tconst obj = Object.create(null);\n\t\t\t\t\t\thydrated[index] = obj;\n\t\t\t\t\t\tfor (let i = 1; i < value.length; i += 2) {\n\t\t\t\t\t\t\tobj[value[i]] = hydrate(value[i + 1]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tthrow new Error(`Unknown type ${type}`);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tconst array = new Array(value.length);\n\t\t\t\thydrated[index] = array;\n\n\t\t\t\tfor (let i = 0; i < value.length; i += 1) {\n\t\t\t\t\tconst n = value[i];\n\t\t\t\t\tif (n === HOLE) continue;\n\n\t\t\t\t\tarray[i] = hydrate(n);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t/** @type {Record} */\n\t\t\tconst object = {};\n\t\t\thydrated[index] = object;\n\n\t\t\tfor (const key in value) {\n\t\t\t\tconst n = value[key];\n\t\t\t\tobject[key] = hydrate(n);\n\t\t\t}\n\t\t}\n\n\t\treturn hydrated[index];\n\t}\n\n\treturn hydrate(0);\n}\n","/**\n * Removes nullish values from an array.\n *\n * @template T\n * @param {Array} arr\n */\nexport function compact(arr) {\n\treturn arr.filter(/** @returns {val is NonNullable} */ (val) => val != null);\n}\n","/**\n * @param {Set} expected\n */\nfunction validator(expected) {\n\t/**\n\t * @param {any} module\n\t * @param {string} [file]\n\t */\n\tfunction validate(module, file) {\n\t\tif (!module) return;\n\n\t\tfor (const key in module) {\n\t\t\tif (key[0] === '_' || expected.has(key)) continue; // key is valid in this module\n\n\t\t\tconst values = [...expected.values()];\n\n\t\t\tconst hint =\n\t\t\t\thint_for_supported_files(key, file?.slice(file.lastIndexOf('.'))) ??\n\t\t\t\t`valid exports are ${values.join(', ')}, or anything with a '_' prefix`;\n\n\t\t\tthrow new Error(`Invalid export '${key}'${file ? ` in ${file}` : ''} (${hint})`);\n\t\t}\n\t}\n\n\treturn validate;\n}\n\n/**\n * @param {string} key\n * @param {string} ext\n * @returns {string | void}\n */\nfunction hint_for_supported_files(key, ext = '.js') {\n\tconst supported_files = [];\n\n\tif (valid_layout_exports.has(key)) {\n\t\tsupported_files.push(`+layout${ext}`);\n\t}\n\n\tif (valid_page_exports.has(key)) {\n\t\tsupported_files.push(`+page${ext}`);\n\t}\n\n\tif (valid_layout_server_exports.has(key)) {\n\t\tsupported_files.push(`+layout.server${ext}`);\n\t}\n\n\tif (valid_page_server_exports.has(key)) {\n\t\tsupported_files.push(`+page.server${ext}`);\n\t}\n\n\tif (valid_server_exports.has(key)) {\n\t\tsupported_files.push(`+server${ext}`);\n\t}\n\n\tif (supported_files.length > 0) {\n\t\treturn `'${key}' is a valid export in ${supported_files.slice(0, -1).join(', ')}${\n\t\t\tsupported_files.length > 1 ? ' or ' : ''\n\t\t}${supported_files.at(-1)}`;\n\t}\n}\n\nconst valid_layout_exports = new Set([\n\t'load',\n\t'prerender',\n\t'csr',\n\t'ssr',\n\t'trailingSlash',\n\t'config'\n]);\nconst valid_page_exports = new Set([...valid_layout_exports, 'entries']);\nconst valid_layout_server_exports = new Set([...valid_layout_exports]);\nconst valid_page_server_exports = new Set([...valid_layout_server_exports, 'actions', 'entries']);\nconst valid_server_exports = new Set([\n\t'GET',\n\t'POST',\n\t'PATCH',\n\t'PUT',\n\t'DELETE',\n\t'OPTIONS',\n\t'HEAD',\n\t'fallback',\n\t'prerender',\n\t'trailingSlash',\n\t'config',\n\t'entries'\n]);\n\nexport const validate_layout_exports = validator(valid_layout_exports);\nexport const validate_page_exports = validator(valid_page_exports);\nexport const validate_layout_server_exports = validator(valid_layout_server_exports);\nexport const validate_page_server_exports = validator(valid_page_server_exports);\nexport const validate_server_exports = validator(valid_server_exports);\n","import { DEV } from 'esm-env';\n\n/** @type {Set | null} */\nlet warned = null;\n\n// TODO v2: remove all references to unwrap_promises\n\n/**\n * Given an object, return a new object where all top level values are awaited\n *\n * @param {Record} object\n * @param {string | null} [id]\n * @returns {Promise>}\n */\nexport async function unwrap_promises(object, id) {\n\tif (DEV) {\n\t\t/** @type {string[]} */\n\t\tconst promises = [];\n\n\t\tfor (const key in object) {\n\t\t\tif (typeof object[key]?.then === 'function') {\n\t\t\t\tpromises.push(key);\n\t\t\t}\n\t\t}\n\n\t\tif (promises.length > 0) {\n\t\t\tif (!warned) warned = new Set();\n\n\t\t\tconst last = promises.pop();\n\n\t\t\tconst properties =\n\t\t\t\tpromises.length > 0\n\t\t\t\t\t? `${promises.map((p) => `\"${p}\"`).join(', ')} and \"${last}\" properties`\n\t\t\t\t\t: `\"${last}\" property`;\n\n\t\t\tconst location = id ? `the \\`load\\` function in ${id}` : 'a `load` function';\n\n\t\t\tconst description = promises.length > 0 ? 'are promises' : 'is a promise';\n\n\t\t\tconst message = `The top-level ${properties} returned from ${location} ${description}.`;\n\n\t\t\tif (!warned.has(message)) {\n\t\t\t\tconsole.warn(\n\t\t\t\t\t`\\n${message}\\n\\nIn SvelteKit 2.0, these will no longer be awaited automatically. To get rid of this warning, await all promises included as top-level properties in \\`load\\` return values.\\n`\n\t\t\t\t);\n\n\t\t\t\twarned.add(message);\n\t\t\t}\n\t\t}\n\t}\n\n\tfor (const key in object) {\n\t\tif (typeof object[key]?.then === 'function') {\n\t\t\treturn Object.fromEntries(\n\t\t\t\tawait Promise.all(Object.entries(object).map(async ([key, value]) => [key, await value]))\n\t\t\t);\n\t\t}\n\t}\n\n\treturn object;\n}\n","/**\n * @param {string} route_id\n * @param {string} dep\n */\nexport function validate_depends(route_id, dep) {\n\tconst match = /^(moz-icon|view-source|jar):/.exec(dep);\n\tif (match) {\n\t\tconsole.warn(\n\t\t\t`${route_id}: Calling \\`depends('${dep}')\\` will throw an error in Firefox because \\`${match[1]}\\` is a special URI scheme`\n\t\t);\n\t}\n}\n\nexport const INVALIDATED_PARAM = 'x-sveltekit-invalidated';\n\nexport const TRAILING_SLASH_PARAM = 'x-sveltekit-trailing-slash';\n","import { DEV } from 'esm-env';\nimport { onMount, tick } from 'svelte';\nimport {\n\tadd_data_suffix,\n\tdecode_params,\n\tdecode_pathname,\n\tmake_trackable,\n\tnormalize_path\n} from '../../utils/url.js';\nimport {\n\tinitial_fetch,\n\tlock_fetch,\n\tnative_fetch,\n\tsubsequent_fetch,\n\tunlock_fetch\n} from './fetcher.js';\nimport { parse } from './parse.js';\nimport * as storage from './session-storage.js';\nimport {\n\tfind_anchor,\n\tget_base_uri,\n\tget_link_info,\n\tget_router_options,\n\tis_external_url,\n\tscroll_state,\n\torigin\n} from './utils.js';\n\nimport { base } from '__sveltekit/paths';\nimport * as devalue from 'devalue';\nimport { compact } from '../../utils/array.js';\nimport { validate_page_exports } from '../../utils/exports.js';\nimport { unwrap_promises } from '../../utils/promises.js';\nimport { HttpError, Redirect, NotFound } from '../control.js';\nimport { INVALIDATED_PARAM, TRAILING_SLASH_PARAM, validate_depends } from '../shared.js';\nimport { INDEX_KEY, PRELOAD_PRIORITIES, SCROLL_KEY, SNAPSHOT_KEY } from './constants.js';\nimport { stores } from './singletons.js';\n\nlet errored = false;\n\n// We track the scroll position associated with each history entry in sessionStorage,\n// rather than on history.state itself, because when navigation is driven by\n// popstate it's too late to update the scroll position associated with the\n// state we're navigating from\n\n/** @typedef {{ x: number, y: number }} ScrollPosition */\n/** @type {Record} */\nconst scroll_positions = storage.get(SCROLL_KEY) ?? {};\n\n/** @type {Record} */\nconst snapshots = storage.get(SNAPSHOT_KEY) ?? {};\n\n/** @param {number} index */\nfunction update_scroll_positions(index) {\n\tscroll_positions[index] = scroll_state();\n}\n\n/**\n * Loads `href` the old-fashioned way, with a full page reload.\n * Returns a `Promise` that never resolves (to prevent any\n * subsequent work, e.g. history manipulation, from happening)\n * @param {URL} url\n */\nfunction native_navigation(url) {\n\tlocation.href = url.href;\n\treturn new Promise(() => {});\n}\n\n/**\n * @param {import('./types.js').SvelteKitApp} app\n * @param {HTMLElement} target\n * @returns {import('./types.js').Client}\n */\nexport function create_client(app, target) {\n\tconst routes = parse(app);\n\n\tconst default_layout_loader = app.nodes[0];\n\tconst default_error_loader = app.nodes[1];\n\n\t// we import the root layout/error nodes eagerly, so that\n\t// connectivity errors after initialisation don't nuke the app\n\tdefault_layout_loader();\n\tdefault_error_loader();\n\n\tconst container = __SVELTEKIT_EMBEDDED__ ? target : document.documentElement;\n\t/** @type {Array<((url: URL) => boolean)>} */\n\tconst invalidated = [];\n\n\t/**\n\t * An array of the `+layout.svelte` and `+page.svelte` component instances\n\t * that currently live on the page — used for capturing and restoring snapshots.\n\t * It's updated/manipulated through `bind:this` in `Root.svelte`.\n\t * @type {import('svelte').SvelteComponent[]}\n\t */\n\tconst components = [];\n\n\t/** @type {{id: string, promise: Promise} | null} */\n\tlet load_cache = null;\n\n\tconst callbacks = {\n\t\t/** @type {Array<(navigation: import('@sveltejs/kit').BeforeNavigate) => void>} */\n\t\tbefore_navigate: [],\n\n\t\t/** @type {Array<(navigation: import('@sveltejs/kit').OnNavigate) => import('types').MaybePromise<(() => void) | void>>} */\n\t\ton_navigate: [],\n\n\t\t/** @type {Array<(navigation: import('@sveltejs/kit').AfterNavigate) => void>} */\n\t\tafter_navigate: []\n\t};\n\n\t/** @type {import('./types.js').NavigationState} */\n\tlet current = {\n\t\tbranch: [],\n\t\terror: null,\n\t\t// @ts-ignore - we need the initial value to be null\n\t\turl: null\n\t};\n\n\t/** this being true means we SSR'd */\n\tlet hydrated = false;\n\tlet started = false;\n\tlet autoscroll = true;\n\tlet updating = false;\n\tlet navigating = false;\n\tlet hash_navigating = false;\n\n\tlet force_invalidation = false;\n\n\t/** @type {import('svelte').SvelteComponent} */\n\tlet root;\n\n\t// keeping track of the history index in order to prevent popstate navigation events if needed\n\tlet current_history_index = history.state?.[INDEX_KEY];\n\n\tif (!current_history_index) {\n\t\t// we use Date.now() as an offset so that cross-document navigations\n\t\t// within the app don't result in data loss\n\t\tcurrent_history_index = Date.now();\n\n\t\t// create initial history entry, so we can return here\n\t\thistory.replaceState(\n\t\t\t{ ...history.state, [INDEX_KEY]: current_history_index },\n\t\t\t'',\n\t\t\tlocation.href\n\t\t);\n\t}\n\n\t// if we reload the page, or Cmd-Shift-T back to it,\n\t// recover scroll position\n\tconst scroll = scroll_positions[current_history_index];\n\tif (scroll) {\n\t\thistory.scrollRestoration = 'manual';\n\t\tscrollTo(scroll.x, scroll.y);\n\t}\n\n\t/** @type {import('@sveltejs/kit').Page} */\n\tlet page;\n\n\t/** @type {{}} */\n\tlet token;\n\n\t/** @type {Promise | null} */\n\tlet pending_invalidate;\n\n\tasync function invalidate() {\n\t\t// Accept all invalidations as they come, don't swallow any while another invalidation\n\t\t// is running because subsequent invalidations may make earlier ones outdated,\n\t\t// but batch multiple synchronous invalidations.\n\t\tpending_invalidate = pending_invalidate || Promise.resolve();\n\t\tawait pending_invalidate;\n\t\tif (!pending_invalidate) return;\n\t\tpending_invalidate = null;\n\n\t\tconst url = new URL(location.href);\n\t\tconst intent = get_navigation_intent(url, true);\n\t\t// Clear preload, it might be affected by the invalidation.\n\t\t// Also solves an edge case where a preload is triggered, the navigation for it\n\t\t// was then triggered and is still running while the invalidation kicks in,\n\t\t// at which point the invalidation should take over and \"win\".\n\t\tload_cache = null;\n\n\t\tconst nav_token = (token = {});\n\t\tconst navigation_result = intent && (await load_route(intent));\n\t\tif (nav_token !== token) return;\n\n\t\tif (navigation_result) {\n\t\t\tif (navigation_result.type === 'redirect') {\n\t\t\t\treturn goto(new URL(navigation_result.location, url).href, {}, 1, nav_token);\n\t\t\t} else {\n\t\t\t\tif (navigation_result.props.page !== undefined) {\n\t\t\t\t\tpage = navigation_result.props.page;\n\t\t\t\t}\n\t\t\t\troot.$set(navigation_result.props);\n\t\t\t}\n\t\t}\n\t}\n\n\t/** @param {number} index */\n\tfunction capture_snapshot(index) {\n\t\tif (components.some((c) => c?.snapshot)) {\n\t\t\tsnapshots[index] = components.map((c) => c?.snapshot?.capture());\n\t\t}\n\t}\n\n\t/** @param {number} index */\n\tfunction restore_snapshot(index) {\n\t\tsnapshots[index]?.forEach((value, i) => {\n\t\t\tcomponents[i]?.snapshot?.restore(value);\n\t\t});\n\t}\n\n\tfunction persist_state() {\n\t\tupdate_scroll_positions(current_history_index);\n\t\tstorage.set(SCROLL_KEY, scroll_positions);\n\n\t\tcapture_snapshot(current_history_index);\n\t\tstorage.set(SNAPSHOT_KEY, snapshots);\n\t}\n\n\t/**\n\t * @param {string | URL} url\n\t * @param {{ noScroll?: boolean; replaceState?: boolean; keepFocus?: boolean; state?: any; invalidateAll?: boolean }} opts\n\t * @param {number} redirect_count\n\t * @param {{}} [nav_token]\n\t */\n\tasync function goto(\n\t\turl,\n\t\t{\n\t\t\tnoScroll = false,\n\t\t\treplaceState = false,\n\t\t\tkeepFocus = false,\n\t\t\tstate = {},\n\t\t\tinvalidateAll = false\n\t\t},\n\t\tredirect_count,\n\t\tnav_token\n\t) {\n\t\tif (typeof url === 'string') {\n\t\t\turl = new URL(url, get_base_uri(document));\n\t\t}\n\n\t\treturn navigate({\n\t\t\turl,\n\t\t\tscroll: noScroll ? scroll_state() : null,\n\t\t\tkeepfocus: keepFocus,\n\t\t\tredirect_count,\n\t\t\tdetails: {\n\t\t\t\tstate,\n\t\t\t\treplaceState\n\t\t\t},\n\t\t\tnav_token,\n\t\t\taccepted: () => {\n\t\t\t\tif (invalidateAll) {\n\t\t\t\t\tforce_invalidation = true;\n\t\t\t\t}\n\t\t\t},\n\t\t\tblocked: () => {},\n\t\t\ttype: 'goto'\n\t\t});\n\t}\n\n\t/** @param {import('./types.js').NavigationIntent} intent */\n\tasync function preload_data(intent) {\n\t\tload_cache = {\n\t\t\tid: intent.id,\n\t\t\tpromise: load_route(intent).then((result) => {\n\t\t\t\tif (result.type === 'loaded' && result.state.error) {\n\t\t\t\t\t// Don't cache errors, because they might be transient\n\t\t\t\t\tload_cache = null;\n\t\t\t\t}\n\t\t\t\treturn result;\n\t\t\t})\n\t\t};\n\n\t\treturn load_cache.promise;\n\t}\n\n\t/** @param {...string} pathnames */\n\tasync function preload_code(...pathnames) {\n\t\tif (DEV && pathnames.length > 1) {\n\t\t\tconsole.warn('Calling `preloadCode` with multiple arguments is deprecated');\n\t\t}\n\n\t\tconst matching = routes.filter((route) => pathnames.some((pathname) => route.exec(pathname)));\n\n\t\tconst promises = matching.map((r) => {\n\t\t\treturn Promise.all([...r.layouts, r.leaf].map((load) => load?.[1]()));\n\t\t});\n\n\t\tawait Promise.all(promises);\n\t}\n\n\t/** @param {import('./types.js').NavigationFinished} result */\n\tfunction initialize(result) {\n\t\tif (DEV && result.state.error && document.querySelector('vite-error-overlay')) return;\n\n\t\tcurrent = result.state;\n\n\t\tconst style = document.querySelector('style[data-sveltekit]');\n\t\tif (style) style.remove();\n\n\t\tpage = /** @type {import('@sveltejs/kit').Page} */ (result.props.page);\n\n\t\troot = new app.root({\n\t\t\ttarget,\n\t\t\tprops: { ...result.props, stores, components },\n\t\t\thydrate: true\n\t\t});\n\n\t\trestore_snapshot(current_history_index);\n\n\t\t/** @type {import('@sveltejs/kit').AfterNavigate} */\n\t\tconst navigation = {\n\t\t\tfrom: null,\n\t\t\tto: {\n\t\t\t\tparams: current.params,\n\t\t\t\troute: { id: current.route?.id ?? null },\n\t\t\t\turl: new URL(location.href)\n\t\t\t},\n\t\t\twillUnload: false,\n\t\t\ttype: 'enter',\n\t\t\tcomplete: Promise.resolve()\n\t\t};\n\t\tcallbacks.after_navigate.forEach((fn) => fn(navigation));\n\n\t\tstarted = true;\n\t}\n\n\t/**\n\t *\n\t * @param {{\n\t * url: URL;\n\t * params: Record;\n\t * branch: Array;\n\t * status: number;\n\t * error: App.Error | null;\n\t * route: import('types').CSRRoute | null;\n\t * form?: Record | null;\n\t * }} opts\n\t */\n\tasync function get_navigation_result_from_branch({\n\t\turl,\n\t\tparams,\n\t\tbranch,\n\t\tstatus,\n\t\terror,\n\t\troute,\n\t\tform\n\t}) {\n\t\t/** @type {import('types').TrailingSlash} */\n\t\tlet slash = 'never';\n\t\tfor (const node of branch) {\n\t\t\tif (node?.slash !== undefined) slash = node.slash;\n\t\t}\n\t\turl.pathname = normalize_path(url.pathname, slash);\n\t\t// eslint-disable-next-line\n\t\turl.search = url.search; // turn `/?` into `/`\n\n\t\t/** @type {import('./types.js').NavigationFinished} */\n\t\tconst result = {\n\t\t\ttype: 'loaded',\n\t\t\tstate: {\n\t\t\t\turl,\n\t\t\t\tparams,\n\t\t\t\tbranch,\n\t\t\t\terror,\n\t\t\t\troute\n\t\t\t},\n\t\t\tprops: {\n\t\t\t\t// @ts-ignore Somehow it's getting SvelteComponent and SvelteComponentDev mixed up\n\t\t\t\tconstructors: compact(branch).map((branch_node) => branch_node.node.component)\n\t\t\t}\n\t\t};\n\n\t\tif (form !== undefined) {\n\t\t\tresult.props.form = form;\n\t\t}\n\n\t\tlet data = {};\n\t\tlet data_changed = !page;\n\n\t\tlet p = 0;\n\n\t\tfor (let i = 0; i < Math.max(branch.length, current.branch.length); i += 1) {\n\t\t\tconst node = branch[i];\n\t\t\tconst prev = current.branch[i];\n\n\t\t\tif (node?.data !== prev?.data) data_changed = true;\n\t\t\tif (!node) continue;\n\n\t\t\tdata = { ...data, ...node.data };\n\n\t\t\t// Only set props if the node actually updated. This prevents needless rerenders.\n\t\t\tif (data_changed) {\n\t\t\t\tresult.props[`data_${p}`] = data;\n\t\t\t}\n\n\t\t\tp += 1;\n\t\t}\n\n\t\tconst page_changed =\n\t\t\t!current.url ||\n\t\t\turl.href !== current.url.href ||\n\t\t\tcurrent.error !== error ||\n\t\t\t(form !== undefined && form !== page.form) ||\n\t\t\tdata_changed;\n\n\t\tif (page_changed) {\n\t\t\tresult.props.page = {\n\t\t\t\terror,\n\t\t\t\tparams,\n\t\t\t\troute: {\n\t\t\t\t\tid: route?.id ?? null\n\t\t\t\t},\n\t\t\t\tstatus,\n\t\t\t\turl: new URL(url),\n\t\t\t\tform: form ?? null,\n\t\t\t\t// The whole page store is updated, but this way the object reference stays the same\n\t\t\t\tdata: data_changed ? data : page.data\n\t\t\t};\n\t\t}\n\n\t\treturn result;\n\t}\n\n\t/**\n\t * Call the load function of the given node, if it exists.\n\t * If `server_data` is passed, this is treated as the initial run and the page endpoint is not requested.\n\t *\n\t * @param {{\n\t * loader: import('types').CSRPageNodeLoader;\n\t * \t parent: () => Promise>;\n\t * url: URL;\n\t * params: Record;\n\t * route: { id: string | null };\n\t * \t server_data_node: import('./types.js').DataNode | null;\n\t * }} options\n\t * @returns {Promise}\n\t */\n\tasync function load_node({ loader, parent, url, params, route, server_data_node }) {\n\t\t/** @type {Record | null} */\n\t\tlet data = null;\n\n\t\t/** @type {import('types').Uses} */\n\t\tconst uses = {\n\t\t\tdependencies: new Set(),\n\t\t\tparams: new Set(),\n\t\t\tparent: false,\n\t\t\troute: false,\n\t\t\turl: false\n\t\t};\n\n\t\tconst node = await loader();\n\n\t\tif (DEV) {\n\t\t\tvalidate_page_exports(node.universal);\n\t\t}\n\n\t\tif (node.universal?.load) {\n\t\t\t/** @param {string[]} deps */\n\t\t\tfunction depends(...deps) {\n\t\t\t\tfor (const dep of deps) {\n\t\t\t\t\tif (DEV) validate_depends(/** @type {string} */ (route.id), dep);\n\n\t\t\t\t\tconst { href } = new URL(dep, url);\n\t\t\t\t\tuses.dependencies.add(href);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/** @type {import('@sveltejs/kit').LoadEvent} */\n\t\t\tconst load_input = {\n\t\t\t\troute: new Proxy(route, {\n\t\t\t\t\tget: (target, key) => {\n\t\t\t\t\t\tuses.route = true;\n\t\t\t\t\t\treturn target[/** @type {'id'} */ (key)];\n\t\t\t\t\t}\n\t\t\t\t}),\n\t\t\t\tparams: new Proxy(params, {\n\t\t\t\t\tget: (target, key) => {\n\t\t\t\t\t\tuses.params.add(/** @type {string} */ (key));\n\t\t\t\t\t\treturn target[/** @type {string} */ (key)];\n\t\t\t\t\t}\n\t\t\t\t}),\n\t\t\t\tdata: server_data_node?.data ?? null,\n\t\t\t\turl: make_trackable(url, () => {\n\t\t\t\t\tuses.url = true;\n\t\t\t\t}),\n\t\t\t\tasync fetch(resource, init) {\n\t\t\t\t\t/** @type {URL | string} */\n\t\t\t\t\tlet requested;\n\n\t\t\t\t\tif (resource instanceof Request) {\n\t\t\t\t\t\trequested = resource.url;\n\n\t\t\t\t\t\t// we're not allowed to modify the received `Request` object, so in order\n\t\t\t\t\t\t// to fixup relative urls we create a new equivalent `init` object instead\n\t\t\t\t\t\tinit = {\n\t\t\t\t\t\t\t// the request body must be consumed in memory until browsers\n\t\t\t\t\t\t\t// implement streaming request bodies and/or the body getter\n\t\t\t\t\t\t\tbody:\n\t\t\t\t\t\t\t\tresource.method === 'GET' || resource.method === 'HEAD'\n\t\t\t\t\t\t\t\t\t? undefined\n\t\t\t\t\t\t\t\t\t: await resource.blob(),\n\t\t\t\t\t\t\tcache: resource.cache,\n\t\t\t\t\t\t\tcredentials: resource.credentials,\n\t\t\t\t\t\t\theaders: resource.headers,\n\t\t\t\t\t\t\tintegrity: resource.integrity,\n\t\t\t\t\t\t\tkeepalive: resource.keepalive,\n\t\t\t\t\t\t\tmethod: resource.method,\n\t\t\t\t\t\t\tmode: resource.mode,\n\t\t\t\t\t\t\tredirect: resource.redirect,\n\t\t\t\t\t\t\treferrer: resource.referrer,\n\t\t\t\t\t\t\treferrerPolicy: resource.referrerPolicy,\n\t\t\t\t\t\t\tsignal: resource.signal,\n\t\t\t\t\t\t\t...init\n\t\t\t\t\t\t};\n\t\t\t\t\t} else {\n\t\t\t\t\t\trequested = resource;\n\t\t\t\t\t}\n\n\t\t\t\t\t// we must fixup relative urls so they are resolved from the target page\n\t\t\t\t\tconst resolved = new URL(requested, url);\n\t\t\t\t\tdepends(resolved.href);\n\n\t\t\t\t\t// match ssr serialized data url, which is important to find cached responses\n\t\t\t\t\tif (resolved.origin === url.origin) {\n\t\t\t\t\t\trequested = resolved.href.slice(url.origin.length);\n\t\t\t\t\t}\n\n\t\t\t\t\t// prerendered pages may be served from any origin, so `initial_fetch` urls shouldn't be resolved\n\t\t\t\t\treturn started\n\t\t\t\t\t\t? subsequent_fetch(requested, resolved.href, init)\n\t\t\t\t\t\t: initial_fetch(requested, init);\n\t\t\t\t},\n\t\t\t\tsetHeaders: () => {}, // noop\n\t\t\t\tdepends,\n\t\t\t\tparent() {\n\t\t\t\t\tuses.parent = true;\n\t\t\t\t\treturn parent();\n\t\t\t\t}\n\t\t\t};\n\n\t\t\tif (DEV) {\n\t\t\t\ttry {\n\t\t\t\t\tlock_fetch();\n\t\t\t\t\tdata = (await node.universal.load.call(null, load_input)) ?? null;\n\t\t\t\t\tif (data != null && Object.getPrototypeOf(data) !== Object.prototype) {\n\t\t\t\t\t\tthrow new Error(\n\t\t\t\t\t\t\t`a load function related to route '${route.id}' returned ${\n\t\t\t\t\t\t\t\ttypeof data !== 'object'\n\t\t\t\t\t\t\t\t\t? `a ${typeof data}`\n\t\t\t\t\t\t\t\t\t: data instanceof Response\n\t\t\t\t\t\t\t\t\t\t? 'a Response object'\n\t\t\t\t\t\t\t\t\t\t: Array.isArray(data)\n\t\t\t\t\t\t\t\t\t\t\t? 'an array'\n\t\t\t\t\t\t\t\t\t\t\t: 'a non-plain object'\n\t\t\t\t\t\t\t}, but must return a plain object at the top level (i.e. \\`return {...}\\`)`\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t} finally {\n\t\t\t\t\tunlock_fetch();\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tdata = (await node.universal.load.call(null, load_input)) ?? null;\n\t\t\t}\n\t\t\tdata = data ? await unwrap_promises(data, route.id) : null;\n\t\t}\n\n\t\treturn {\n\t\t\tnode,\n\t\t\tloader,\n\t\t\tserver: server_data_node,\n\t\t\tuniversal: node.universal?.load ? { type: 'data', data, uses } : null,\n\t\t\tdata: data ?? server_data_node?.data ?? null,\n\t\t\t// if `paths.base === '/a/b/c`, then the root route is `/a/b/c/`,\n\t\t\t// regardless of the `trailingSlash` route option\n\t\t\tslash:\n\t\t\t\turl.pathname === base || url.pathname === base + '/'\n\t\t\t\t\t? 'always'\n\t\t\t\t\t: node.universal?.trailingSlash ?? server_data_node?.slash\n\t\t};\n\t}\n\n\t/**\n\t * @param {boolean} parent_changed\n\t * @param {boolean} route_changed\n\t * @param {boolean} url_changed\n\t * @param {import('types').Uses | undefined} uses\n\t * @param {Record} params\n\t */\n\tfunction has_changed(parent_changed, route_changed, url_changed, uses, params) {\n\t\tif (force_invalidation) return true;\n\n\t\tif (!uses) return false;\n\n\t\tif (uses.parent && parent_changed) return true;\n\t\tif (uses.route && route_changed) return true;\n\t\tif (uses.url && url_changed) return true;\n\n\t\tfor (const param of uses.params) {\n\t\t\tif (params[param] !== current.params[param]) return true;\n\t\t}\n\n\t\tfor (const href of uses.dependencies) {\n\t\t\tif (invalidated.some((fn) => fn(new URL(href)))) return true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/**\n\t * @param {import('types').ServerDataNode | import('types').ServerDataSkippedNode | null} node\n\t * @param {import('./types.js').DataNode | null} [previous]\n\t * @returns {import('./types.js').DataNode | null}\n\t */\n\tfunction create_data_node(node, previous) {\n\t\tif (node?.type === 'data') return node;\n\t\tif (node?.type === 'skip') return previous ?? null;\n\t\treturn null;\n\t}\n\n\t/**\n\t * @param {import('./types.js').NavigationIntent} intent\n\t * @returns {Promise}\n\t */\n\tasync function load_route({ id, invalidating, url, params, route }) {\n\t\tif (load_cache?.id === id) {\n\t\t\treturn load_cache.promise;\n\t\t}\n\n\t\tconst { errors, layouts, leaf } = route;\n\n\t\tconst loaders = [...layouts, leaf];\n\n\t\t// preload modules to avoid waterfall, but handle rejections\n\t\t// so they don't get reported to Sentry et al (we don't need\n\t\t// to act on the failures at this point)\n\t\terrors.forEach((loader) => loader?.().catch(() => {}));\n\t\tloaders.forEach((loader) => loader?.[1]().catch(() => {}));\n\n\t\t/** @type {import('types').ServerNodesResponse | import('types').ServerRedirectNode | null} */\n\t\tlet server_data = null;\n\n\t\tconst url_changed = current.url ? id !== current.url.pathname + current.url.search : false;\n\t\tconst route_changed = current.route ? route.id !== current.route.id : false;\n\n\t\tlet parent_invalid = false;\n\t\tconst invalid_server_nodes = loaders.map((loader, i) => {\n\t\t\tconst previous = current.branch[i];\n\n\t\t\tconst invalid =\n\t\t\t\t!!loader?.[0] &&\n\t\t\t\t(previous?.loader !== loader[1] ||\n\t\t\t\t\thas_changed(parent_invalid, route_changed, url_changed, previous.server?.uses, params));\n\n\t\t\tif (invalid) {\n\t\t\t\t// For the next one\n\t\t\t\tparent_invalid = true;\n\t\t\t}\n\n\t\t\treturn invalid;\n\t\t});\n\n\t\tif (invalid_server_nodes.some(Boolean)) {\n\t\t\ttry {\n\t\t\t\tserver_data = await load_data(url, invalid_server_nodes);\n\t\t\t} catch (error) {\n\t\t\t\treturn load_root_error_page({\n\t\t\t\t\tstatus: error instanceof HttpError ? error.status : 500,\n\t\t\t\t\terror: await handle_error(error, { url, params, route: { id: route.id } }),\n\t\t\t\t\turl,\n\t\t\t\t\troute\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tif (server_data.type === 'redirect') {\n\t\t\t\treturn server_data;\n\t\t\t}\n\t\t}\n\n\t\tconst server_data_nodes = server_data?.nodes;\n\n\t\tlet parent_changed = false;\n\n\t\tconst branch_promises = loaders.map(async (loader, i) => {\n\t\t\tif (!loader) return;\n\n\t\t\t/** @type {import('./types.js').BranchNode | undefined} */\n\t\t\tconst previous = current.branch[i];\n\n\t\t\tconst server_data_node = server_data_nodes?.[i];\n\n\t\t\t// re-use data from previous load if it's still valid\n\t\t\tconst valid =\n\t\t\t\t(!server_data_node || server_data_node.type === 'skip') &&\n\t\t\t\tloader[1] === previous?.loader &&\n\t\t\t\t!has_changed(parent_changed, route_changed, url_changed, previous.universal?.uses, params);\n\t\t\tif (valid) return previous;\n\n\t\t\tparent_changed = true;\n\n\t\t\tif (server_data_node?.type === 'error') {\n\t\t\t\t// rethrow and catch below\n\t\t\t\tthrow server_data_node;\n\t\t\t}\n\n\t\t\treturn load_node({\n\t\t\t\tloader: loader[1],\n\t\t\t\turl,\n\t\t\t\tparams,\n\t\t\t\troute,\n\t\t\t\tparent: async () => {\n\t\t\t\t\tconst data = {};\n\t\t\t\t\tfor (let j = 0; j < i; j += 1) {\n\t\t\t\t\t\tObject.assign(data, (await branch_promises[j])?.data);\n\t\t\t\t\t}\n\t\t\t\t\treturn data;\n\t\t\t\t},\n\t\t\t\tserver_data_node: create_data_node(\n\t\t\t\t\t// server_data_node is undefined if it wasn't reloaded from the server;\n\t\t\t\t\t// and if current loader uses server data, we want to reuse previous data.\n\t\t\t\t\tserver_data_node === undefined && loader[0] ? { type: 'skip' } : server_data_node ?? null,\n\t\t\t\t\tloader[0] ? previous?.server : undefined\n\t\t\t\t)\n\t\t\t});\n\t\t});\n\n\t\t// if we don't do this, rejections will be unhandled\n\t\tfor (const p of branch_promises) p.catch(() => {});\n\n\t\t/** @type {Array} */\n\t\tconst branch = [];\n\n\t\tfor (let i = 0; i < loaders.length; i += 1) {\n\t\t\tif (loaders[i]) {\n\t\t\t\ttry {\n\t\t\t\t\tbranch.push(await branch_promises[i]);\n\t\t\t\t} catch (err) {\n\t\t\t\t\tif (err instanceof Redirect) {\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\ttype: 'redirect',\n\t\t\t\t\t\t\tlocation: err.location\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\n\t\t\t\t\tlet status = 500;\n\t\t\t\t\t/** @type {App.Error} */\n\t\t\t\t\tlet error;\n\n\t\t\t\t\tif (server_data_nodes?.includes(/** @type {import('types').ServerErrorNode} */ (err))) {\n\t\t\t\t\t\t// this is the server error rethrown above, reconstruct but don't invoke\n\t\t\t\t\t\t// the client error handler; it should've already been handled on the server\n\t\t\t\t\t\tstatus = /** @type {import('types').ServerErrorNode} */ (err).status ?? status;\n\t\t\t\t\t\terror = /** @type {import('types').ServerErrorNode} */ (err).error;\n\t\t\t\t\t} else if (err instanceof HttpError) {\n\t\t\t\t\t\tstatus = err.status;\n\t\t\t\t\t\terror = err.body;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Referenced node could have been removed due to redeploy, check\n\t\t\t\t\t\tconst updated = await stores.updated.check();\n\t\t\t\t\t\tif (updated) {\n\t\t\t\t\t\t\treturn await native_navigation(url);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\terror = await handle_error(err, { params, url, route: { id: route.id } });\n\t\t\t\t\t}\n\n\t\t\t\t\tconst error_load = await load_nearest_error_page(i, branch, errors);\n\t\t\t\t\tif (error_load) {\n\t\t\t\t\t\treturn await get_navigation_result_from_branch({\n\t\t\t\t\t\t\turl,\n\t\t\t\t\t\t\tparams,\n\t\t\t\t\t\t\tbranch: branch.slice(0, error_load.idx).concat(error_load.node),\n\t\t\t\t\t\t\tstatus,\n\t\t\t\t\t\t\terror,\n\t\t\t\t\t\t\troute\n\t\t\t\t\t\t});\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// if we get here, it's because the root `load` function failed,\n\t\t\t\t\t\t// and we need to fall back to the server\n\t\t\t\t\t\treturn await server_fallback(url, { id: route.id }, error, status);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// push an empty slot so we can rewind past gaps to the\n\t\t\t\t// layout that corresponds with an +error.svelte page\n\t\t\t\tbranch.push(undefined);\n\t\t\t}\n\t\t}\n\n\t\treturn await get_navigation_result_from_branch({\n\t\t\turl,\n\t\t\tparams,\n\t\t\tbranch,\n\t\t\tstatus: 200,\n\t\t\terror: null,\n\t\t\troute,\n\t\t\t// Reset `form` on navigation, but not invalidation\n\t\t\tform: invalidating ? undefined : null\n\t\t});\n\t}\n\n\t/**\n\t * @param {number} i Start index to backtrack from\n\t * @param {Array} branch Branch to backtrack\n\t * @param {Array} errors All error pages for this branch\n\t * @returns {Promise<{idx: number; node: import('./types.js').BranchNode} | undefined>}\n\t */\n\tasync function load_nearest_error_page(i, branch, errors) {\n\t\twhile (i--) {\n\t\t\tif (errors[i]) {\n\t\t\t\tlet j = i;\n\t\t\t\twhile (!branch[j]) j -= 1;\n\t\t\t\ttry {\n\t\t\t\t\treturn {\n\t\t\t\t\t\tidx: j + 1,\n\t\t\t\t\t\tnode: {\n\t\t\t\t\t\t\tnode: await /** @type {import('types').CSRPageNodeLoader } */ (errors[i])(),\n\t\t\t\t\t\t\tloader: /** @type {import('types').CSRPageNodeLoader } */ (errors[i]),\n\t\t\t\t\t\t\tdata: {},\n\t\t\t\t\t\t\tserver: null,\n\t\t\t\t\t\t\tuniversal: null\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t} catch (e) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * @param {{\n\t * status: number;\n\t * error: App.Error;\n\t * url: URL;\n\t * route: { id: string | null }\n\t * }} opts\n\t * @returns {Promise}\n\t */\n\tasync function load_root_error_page({ status, error, url, route }) {\n\t\t/** @type {Record} */\n\t\tconst params = {}; // error page does not have params\n\n\t\t/** @type {import('types').ServerDataNode | null} */\n\t\tlet server_data_node = null;\n\n\t\tconst default_layout_has_server_load = app.server_loads[0] === 0;\n\n\t\tif (default_layout_has_server_load) {\n\t\t\t// TODO post-https://github.com/sveltejs/kit/discussions/6124 we can use\n\t\t\t// existing root layout data\n\t\t\ttry {\n\t\t\t\tconst server_data = await load_data(url, [true]);\n\n\t\t\t\tif (\n\t\t\t\t\tserver_data.type !== 'data' ||\n\t\t\t\t\t(server_data.nodes[0] && server_data.nodes[0].type !== 'data')\n\t\t\t\t) {\n\t\t\t\t\tthrow 0;\n\t\t\t\t}\n\n\t\t\t\tserver_data_node = server_data.nodes[0] ?? null;\n\t\t\t} catch {\n\t\t\t\t// at this point we have no choice but to fall back to the server, if it wouldn't\n\t\t\t\t// bring us right back here, turning this into an endless loop\n\t\t\t\tif (url.origin !== origin || url.pathname !== location.pathname || hydrated) {\n\t\t\t\t\tawait native_navigation(url);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tconst root_layout = await load_node({\n\t\t\tloader: default_layout_loader,\n\t\t\turl,\n\t\t\tparams,\n\t\t\troute,\n\t\t\tparent: () => Promise.resolve({}),\n\t\t\tserver_data_node: create_data_node(server_data_node)\n\t\t});\n\n\t\t/** @type {import('./types.js').BranchNode} */\n\t\tconst root_error = {\n\t\t\tnode: await default_error_loader(),\n\t\t\tloader: default_error_loader,\n\t\t\tuniversal: null,\n\t\t\tserver: null,\n\t\t\tdata: null\n\t\t};\n\n\t\treturn await get_navigation_result_from_branch({\n\t\t\turl,\n\t\t\tparams,\n\t\t\tbranch: [root_layout, root_error],\n\t\t\tstatus,\n\t\t\terror,\n\t\t\troute: null\n\t\t});\n\t}\n\n\t/**\n\t * @param {URL} url\n\t * @param {boolean} invalidating\n\t */\n\tfunction get_navigation_intent(url, invalidating) {\n\t\tif (is_external_url(url, base)) return;\n\n\t\tconst path = get_url_path(url);\n\n\t\tfor (const route of routes) {\n\t\t\tconst params = route.exec(path);\n\n\t\t\tif (params) {\n\t\t\t\tconst id = url.pathname + url.search;\n\t\t\t\t/** @type {import('./types.js').NavigationIntent} */\n\t\t\t\tconst intent = { id, invalidating, route, params: decode_params(params), url };\n\t\t\t\treturn intent;\n\t\t\t}\n\t\t}\n\t}\n\n\t/** @param {URL} url */\n\tfunction get_url_path(url) {\n\t\treturn decode_pathname(url.pathname.slice(base.length) || '/');\n\t}\n\n\t/**\n\t * @param {{\n\t * url: URL;\n\t * type: import('@sveltejs/kit').Navigation[\"type\"];\n\t * intent?: import('./types.js').NavigationIntent;\n\t * delta?: number;\n\t * }} opts\n\t */\n\tfunction before_navigate({ url, type, intent, delta }) {\n\t\tlet should_block = false;\n\n\t\tconst nav = create_navigation(current, intent, url, type);\n\n\t\tif (delta !== undefined) {\n\t\t\tnav.navigation.delta = delta;\n\t\t}\n\n\t\tconst cancellable = {\n\t\t\t...nav.navigation,\n\t\t\tcancel: () => {\n\t\t\t\tshould_block = true;\n\t\t\t\tnav.reject(new Error('navigation was cancelled'));\n\t\t\t}\n\t\t};\n\n\t\tif (!navigating) {\n\t\t\t// Don't run the event during redirects\n\t\t\tcallbacks.before_navigate.forEach((fn) => fn(cancellable));\n\t\t}\n\n\t\treturn should_block ? null : nav;\n\t}\n\n\t/**\n\t * @param {{\n\t * url: URL;\n\t * scroll: { x: number, y: number } | null;\n\t * keepfocus: boolean;\n\t * redirect_count: number;\n\t * details: {\n\t * replaceState: boolean;\n\t * state: any;\n\t * } | null;\n\t * type: import('@sveltejs/kit').Navigation[\"type\"];\n\t * delta?: number;\n\t * nav_token?: {};\n\t * accepted: () => void;\n\t * blocked: () => void;\n\t * }} opts\n\t */\n\tasync function navigate({\n\t\turl,\n\t\tscroll,\n\t\tkeepfocus,\n\t\tredirect_count,\n\t\tdetails,\n\t\ttype,\n\t\tdelta,\n\t\tnav_token = {},\n\t\taccepted,\n\t\tblocked\n\t}) {\n\t\tconst intent = get_navigation_intent(url, false);\n\t\tconst nav = before_navigate({ url, type, delta, intent });\n\n\t\tif (!nav) {\n\t\t\tblocked();\n\t\t\treturn;\n\t\t}\n\n\t\t// store this before calling `accepted()`, which may change the index\n\t\tconst previous_history_index = current_history_index;\n\n\t\taccepted();\n\n\t\tnavigating = true;\n\n\t\tif (started) {\n\t\t\tstores.navigating.set(nav.navigation);\n\t\t}\n\n\t\ttoken = nav_token;\n\t\tlet navigation_result = intent && (await load_route(intent));\n\n\t\tif (!navigation_result) {\n\t\t\tif (is_external_url(url, base)) {\n\t\t\t\treturn await native_navigation(url);\n\t\t\t}\n\t\t\tnavigation_result = await server_fallback(\n\t\t\t\turl,\n\t\t\t\t{ id: null },\n\t\t\t\tawait handle_error(new Error(`Not found: ${url.pathname}`), {\n\t\t\t\t\turl,\n\t\t\t\t\tparams: {},\n\t\t\t\t\troute: { id: null }\n\t\t\t\t}),\n\t\t\t\t404\n\t\t\t);\n\t\t}\n\n\t\t// if this is an internal navigation intent, use the normalized\n\t\t// URL for the rest of the function\n\t\turl = intent?.url || url;\n\n\t\t// abort if user navigated during update\n\t\tif (token !== nav_token) {\n\t\t\tnav.reject(new Error('navigation was aborted'));\n\t\t\treturn false;\n\t\t}\n\n\t\tif (navigation_result.type === 'redirect') {\n\t\t\t// whatwg fetch spec https://fetch.spec.whatwg.org/#http-redirect-fetch says to error after 20 redirects\n\t\t\tif (redirect_count >= 20) {\n\t\t\t\tnavigation_result = await load_root_error_page({\n\t\t\t\t\tstatus: 500,\n\t\t\t\t\terror: await handle_error(new Error('Redirect loop'), {\n\t\t\t\t\t\turl,\n\t\t\t\t\t\tparams: {},\n\t\t\t\t\t\troute: { id: null }\n\t\t\t\t\t}),\n\t\t\t\t\turl,\n\t\t\t\t\troute: { id: null }\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tgoto(new URL(navigation_result.location, url).href, {}, redirect_count + 1, nav_token);\n\t\t\t\treturn false;\n\t\t\t}\n\t\t} else if (/** @type {number} */ (navigation_result.props.page?.status) >= 400) {\n\t\t\tconst updated = await stores.updated.check();\n\t\t\tif (updated) {\n\t\t\t\tawait native_navigation(url);\n\t\t\t}\n\t\t}\n\n\t\t// reset invalidation only after a finished navigation. If there are redirects or\n\t\t// additional invalidations, they should get the same invalidation treatment\n\t\tinvalidated.length = 0;\n\t\tforce_invalidation = false;\n\n\t\tupdating = true;\n\n\t\tupdate_scroll_positions(previous_history_index);\n\t\tcapture_snapshot(previous_history_index);\n\n\t\t// ensure the url pathname matches the page's trailing slash option\n\t\tif (\n\t\t\tnavigation_result.props.page?.url &&\n\t\t\tnavigation_result.props.page.url.pathname !== url.pathname\n\t\t) {\n\t\t\turl.pathname = navigation_result.props.page?.url.pathname;\n\t\t}\n\n\t\tif (details) {\n\t\t\tconst change = details.replaceState ? 0 : 1;\n\t\t\tdetails.state[INDEX_KEY] = current_history_index += change;\n\t\t\thistory[details.replaceState ? 'replaceState' : 'pushState'](details.state, '', url);\n\n\t\t\tif (!details.replaceState) {\n\t\t\t\t// if we navigated back, then pushed a new state, we can\n\t\t\t\t// release memory by pruning the scroll/snapshot lookup\n\t\t\t\tlet i = current_history_index + 1;\n\t\t\t\twhile (snapshots[i] || scroll_positions[i]) {\n\t\t\t\t\tdelete snapshots[i];\n\t\t\t\t\tdelete scroll_positions[i];\n\t\t\t\t\ti += 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// reset preload synchronously after the history state has been set to avoid race conditions\n\t\tload_cache = null;\n\n\t\tif (started) {\n\t\t\tcurrent = navigation_result.state;\n\n\t\t\t// reset url before updating page store\n\t\t\tif (navigation_result.props.page) {\n\t\t\t\tnavigation_result.props.page.url = url;\n\t\t\t}\n\n\t\t\tconst after_navigate = (\n\t\t\t\tawait Promise.all(\n\t\t\t\t\tcallbacks.on_navigate.map((fn) =>\n\t\t\t\t\t\tfn(/** @type {import('@sveltejs/kit').OnNavigate} */ (nav.navigation))\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t).filter((value) => typeof value === 'function');\n\n\t\t\tif (after_navigate.length > 0) {\n\t\t\t\tfunction cleanup() {\n\t\t\t\t\tcallbacks.after_navigate = callbacks.after_navigate.filter(\n\t\t\t\t\t\t// @ts-ignore\n\t\t\t\t\t\t(fn) => !after_navigate.includes(fn)\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tafter_navigate.push(cleanup);\n\n\t\t\t\t// @ts-ignore\n\t\t\t\tcallbacks.after_navigate.push(...after_navigate);\n\t\t\t}\n\n\t\t\troot.$set(navigation_result.props);\n\t\t} else {\n\t\t\tinitialize(navigation_result);\n\t\t}\n\n\t\tconst { activeElement } = document;\n\n\t\t// need to render the DOM before we can scroll to the rendered elements and do focus management\n\t\tawait tick();\n\n\t\t// we reset scroll before dealing with focus, to avoid a flash of unscrolled content\n\t\tif (autoscroll) {\n\t\t\tconst deep_linked =\n\t\t\t\turl.hash && document.getElementById(decodeURIComponent(url.hash.slice(1)));\n\t\t\tif (scroll) {\n\t\t\t\tscrollTo(scroll.x, scroll.y);\n\t\t\t} else if (deep_linked) {\n\t\t\t\t// Here we use `scrollIntoView` on the element instead of `scrollTo`\n\t\t\t\t// because it natively supports the `scroll-margin` and `scroll-behavior`\n\t\t\t\t// CSS properties.\n\t\t\t\tdeep_linked.scrollIntoView();\n\t\t\t} else {\n\t\t\t\tscrollTo(0, 0);\n\t\t\t}\n\t\t}\n\n\t\tconst changed_focus =\n\t\t\t// reset focus only if any manual focus management didn't override it\n\t\t\tdocument.activeElement !== activeElement &&\n\t\t\t// also refocus when activeElement is body already because the\n\t\t\t// focus event might not have been fired on it yet\n\t\t\tdocument.activeElement !== document.body;\n\n\t\tif (!keepfocus && !changed_focus) {\n\t\t\treset_focus();\n\t\t}\n\n\t\tautoscroll = true;\n\n\t\tif (navigation_result.props.page) {\n\t\t\tpage = navigation_result.props.page;\n\t\t}\n\n\t\tnavigating = false;\n\n\t\tif (type === 'popstate') {\n\t\t\trestore_snapshot(current_history_index);\n\t\t}\n\n\t\tnav.fulfil(undefined);\n\n\t\tcallbacks.after_navigate.forEach((fn) =>\n\t\t\tfn(/** @type {import('@sveltejs/kit').AfterNavigate} */ (nav.navigation))\n\t\t);\n\t\tstores.navigating.set(null);\n\n\t\tupdating = false;\n\t}\n\n\t/**\n\t * Does a full page reload if it wouldn't result in an endless loop in the SPA case\n\t * @param {URL} url\n\t * @param {{ id: string | null }} route\n\t * @param {App.Error} error\n\t * @param {number} status\n\t * @returns {Promise}\n\t */\n\tasync function server_fallback(url, route, error, status) {\n\t\tif (url.origin === origin && url.pathname === location.pathname && !hydrated) {\n\t\t\t// We would reload the same page we're currently on, which isn't hydrated,\n\t\t\t// which means no SSR, which means we would end up in an endless loop\n\t\t\treturn await load_root_error_page({\n\t\t\t\tstatus,\n\t\t\t\terror,\n\t\t\t\turl,\n\t\t\t\troute\n\t\t\t});\n\t\t}\n\n\t\tif (DEV && status !== 404) {\n\t\t\tconsole.error(\n\t\t\t\t'An error occurred while loading the page. This will cause a full page reload. (This message will only appear during development.)'\n\t\t\t);\n\n\t\t\tdebugger; // eslint-disable-line\n\t\t}\n\n\t\treturn await native_navigation(url);\n\t}\n\n\tif (import.meta.hot) {\n\t\timport.meta.hot.on('vite:beforeUpdate', () => {\n\t\t\tif (current.error) location.reload();\n\t\t});\n\t}\n\n\tfunction setup_preload() {\n\t\t/** @type {NodeJS.Timeout} */\n\t\tlet mousemove_timeout;\n\n\t\tcontainer.addEventListener('mousemove', (event) => {\n\t\t\tconst target = /** @type {Element} */ (event.target);\n\n\t\t\tclearTimeout(mousemove_timeout);\n\t\t\tmousemove_timeout = setTimeout(() => {\n\t\t\t\tpreload(target, 2);\n\t\t\t}, 20);\n\t\t});\n\n\t\t/** @param {Event} event */\n\t\tfunction tap(event) {\n\t\t\tpreload(/** @type {Element} */ (event.composedPath()[0]), 1);\n\t\t}\n\n\t\tcontainer.addEventListener('mousedown', tap);\n\t\tcontainer.addEventListener('touchstart', tap, { passive: true });\n\n\t\tconst observer = new IntersectionObserver(\n\t\t\t(entries) => {\n\t\t\t\tfor (const entry of entries) {\n\t\t\t\t\tif (entry.isIntersecting) {\n\t\t\t\t\t\tpreload_code(\n\t\t\t\t\t\t\tget_url_path(new URL(/** @type {HTMLAnchorElement} */ (entry.target).href))\n\t\t\t\t\t\t);\n\t\t\t\t\t\tobserver.unobserve(entry.target);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t},\n\t\t\t{ threshold: 0 }\n\t\t);\n\n\t\t/**\n\t\t * @param {Element} element\n\t\t * @param {number} priority\n\t\t */\n\t\tfunction preload(element, priority) {\n\t\t\tconst a = find_anchor(element, container);\n\t\t\tif (!a) return;\n\n\t\t\tconst { url, external, download } = get_link_info(a, base);\n\t\t\tif (external || download) return;\n\n\t\t\tconst options = get_router_options(a);\n\n\t\t\tif (!options.reload) {\n\t\t\t\tif (priority <= options.preload_data) {\n\t\t\t\t\tconst intent = get_navigation_intent(/** @type {URL} */ (url), false);\n\t\t\t\t\tif (intent) {\n\t\t\t\t\t\tif (DEV) {\n\t\t\t\t\t\t\tpreload_data(intent).then((result) => {\n\t\t\t\t\t\t\t\tif (result.type === 'loaded' && result.state.error) {\n\t\t\t\t\t\t\t\t\tconsole.warn(\n\t\t\t\t\t\t\t\t\t\t`Preloading data for ${intent.url.pathname} failed with the following error: ${result.state.error.message}\\n` +\n\t\t\t\t\t\t\t\t\t\t\t'If this error is transient, you can ignore it. Otherwise, consider disabling preloading for this route. ' +\n\t\t\t\t\t\t\t\t\t\t\t'This route was preloaded due to a data-sveltekit-preload-data attribute. ' +\n\t\t\t\t\t\t\t\t\t\t\t'See https://kit.svelte.dev/docs/link-options for more info'\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tpreload_data(intent);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else if (priority <= options.preload_code) {\n\t\t\t\t\tpreload_code(get_url_path(/** @type {URL} */ (url)));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfunction after_navigate() {\n\t\t\tobserver.disconnect();\n\n\t\t\tfor (const a of container.querySelectorAll('a')) {\n\t\t\t\tconst { url, external, download } = get_link_info(a, base);\n\t\t\t\tif (external || download) continue;\n\n\t\t\t\tconst options = get_router_options(a);\n\t\t\t\tif (options.reload) continue;\n\n\t\t\t\tif (options.preload_code === PRELOAD_PRIORITIES.viewport) {\n\t\t\t\t\tobserver.observe(a);\n\t\t\t\t}\n\n\t\t\t\tif (options.preload_code === PRELOAD_PRIORITIES.eager) {\n\t\t\t\t\tpreload_code(get_url_path(/** @type {URL} */ (url)));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tcallbacks.after_navigate.push(after_navigate);\n\t\tafter_navigate();\n\t}\n\n\t/**\n\t * @param {unknown} error\n\t * @param {import('@sveltejs/kit').NavigationEvent} event\n\t * @returns {import('types').MaybePromise}\n\t */\n\tfunction handle_error(error, event) {\n\t\tif (error instanceof HttpError) {\n\t\t\treturn error.body;\n\t\t}\n\n\t\tif (DEV) {\n\t\t\terrored = true;\n\t\t\tconsole.warn('The next HMR update will cause the page to reload');\n\t\t}\n\n\t\treturn (\n\t\t\tapp.hooks.handleError({ error, event }) ??\n\t\t\t/** @type {any} */ ({\n\t\t\t\tmessage:\n\t\t\t\t\tevent.route.id === null && error instanceof NotFound ? 'Not Found' : 'Internal Error'\n\t\t\t})\n\t\t);\n\t}\n\n\treturn {\n\t\tafter_navigate: (fn) => {\n\t\t\tonMount(() => {\n\t\t\t\tcallbacks.after_navigate.push(fn);\n\n\t\t\t\treturn () => {\n\t\t\t\t\tconst i = callbacks.after_navigate.indexOf(fn);\n\t\t\t\t\tcallbacks.after_navigate.splice(i, 1);\n\t\t\t\t};\n\t\t\t});\n\t\t},\n\n\t\tbefore_navigate: (fn) => {\n\t\t\tonMount(() => {\n\t\t\t\tcallbacks.before_navigate.push(fn);\n\n\t\t\t\treturn () => {\n\t\t\t\t\tconst i = callbacks.before_navigate.indexOf(fn);\n\t\t\t\t\tcallbacks.before_navigate.splice(i, 1);\n\t\t\t\t};\n\t\t\t});\n\t\t},\n\n\t\ton_navigate: (fn) => {\n\t\t\tonMount(() => {\n\t\t\t\tcallbacks.on_navigate.push(fn);\n\n\t\t\t\treturn () => {\n\t\t\t\t\tconst i = callbacks.on_navigate.indexOf(fn);\n\t\t\t\t\tcallbacks.on_navigate.splice(i, 1);\n\t\t\t\t};\n\t\t\t});\n\t\t},\n\n\t\tdisable_scroll_handling: () => {\n\t\t\tif (DEV && started && !updating) {\n\t\t\t\tthrow new Error('Can only disable scroll handling during navigation');\n\t\t\t}\n\n\t\t\tif (updating || !started) {\n\t\t\t\tautoscroll = false;\n\t\t\t}\n\t\t},\n\n\t\tgoto: (href, opts = {}) => {\n\t\t\treturn goto(href, opts, 0);\n\t\t},\n\n\t\tinvalidate: (resource) => {\n\t\t\tif (typeof resource === 'function') {\n\t\t\t\tinvalidated.push(resource);\n\t\t\t} else {\n\t\t\t\tconst { href } = new URL(resource, location.href);\n\t\t\t\tinvalidated.push((url) => url.href === href);\n\t\t\t}\n\n\t\t\treturn invalidate();\n\t\t},\n\n\t\tinvalidate_all: () => {\n\t\t\tforce_invalidation = true;\n\t\t\treturn invalidate();\n\t\t},\n\n\t\tpreload_data: async (href) => {\n\t\t\tconst url = new URL(href, get_base_uri(document));\n\t\t\tconst intent = get_navigation_intent(url, false);\n\n\t\t\tif (!intent) {\n\t\t\t\tthrow new Error(`Attempted to preload a URL that does not belong to this app: ${url}`);\n\t\t\t}\n\n\t\t\tawait preload_data(intent);\n\t\t},\n\n\t\tpreload_code,\n\n\t\tapply_action: async (result) => {\n\t\t\tif (result.type === 'error') {\n\t\t\t\tconst url = new URL(location.href);\n\n\t\t\t\tconst { branch, route } = current;\n\t\t\t\tif (!route) return;\n\n\t\t\t\tconst error_load = await load_nearest_error_page(\n\t\t\t\t\tcurrent.branch.length,\n\t\t\t\t\tbranch,\n\t\t\t\t\troute.errors\n\t\t\t\t);\n\t\t\t\tif (error_load) {\n\t\t\t\t\tconst navigation_result = await get_navigation_result_from_branch({\n\t\t\t\t\t\turl,\n\t\t\t\t\t\tparams: current.params,\n\t\t\t\t\t\tbranch: branch.slice(0, error_load.idx).concat(error_load.node),\n\t\t\t\t\t\tstatus: result.status ?? 500,\n\t\t\t\t\t\terror: result.error,\n\t\t\t\t\t\troute\n\t\t\t\t\t});\n\n\t\t\t\t\tcurrent = navigation_result.state;\n\n\t\t\t\t\troot.$set(navigation_result.props);\n\n\t\t\t\t\ttick().then(reset_focus);\n\t\t\t\t}\n\t\t\t} else if (result.type === 'redirect') {\n\t\t\t\tgoto(result.location, { invalidateAll: true }, 0);\n\t\t\t} else {\n\t\t\t\t/** @type {Record} */\n\t\t\t\troot.$set({\n\t\t\t\t\t// this brings Svelte's view of the world in line with SvelteKit's\n\t\t\t\t\t// after use:enhance reset the form....\n\t\t\t\t\tform: null,\n\t\t\t\t\tpage: { ...page, form: result.data, status: result.status }\n\t\t\t\t});\n\n\t\t\t\t// ...so that setting the `form` prop takes effect and isn't ignored\n\t\t\t\tawait tick();\n\t\t\t\troot.$set({ form: result.data });\n\n\t\t\t\tif (result.type === 'success') {\n\t\t\t\t\treset_focus();\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\t_start_router: () => {\n\t\t\thistory.scrollRestoration = 'manual';\n\n\t\t\t// Adopted from Nuxt.js\n\t\t\t// Reset scrollRestoration to auto when leaving page, allowing page reload\n\t\t\t// and back-navigation from other pages to use the browser to restore the\n\t\t\t// scrolling position.\n\t\t\taddEventListener('beforeunload', (e) => {\n\t\t\t\tlet should_block = false;\n\n\t\t\t\tpersist_state();\n\n\t\t\t\tif (!navigating) {\n\t\t\t\t\tconst nav = create_navigation(current, undefined, null, 'leave');\n\n\t\t\t\t\t// If we're navigating, beforeNavigate was already called. If we end up in here during navigation,\n\t\t\t\t\t// it's due to an external or full-page-reload link, for which we don't want to call the hook again.\n\t\t\t\t\t/** @type {import('@sveltejs/kit').BeforeNavigate} */\n\t\t\t\t\tconst navigation = {\n\t\t\t\t\t\t...nav.navigation,\n\t\t\t\t\t\tcancel: () => {\n\t\t\t\t\t\t\tshould_block = true;\n\t\t\t\t\t\t\tnav.reject(new Error('navigation was cancelled'));\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\n\t\t\t\t\tcallbacks.before_navigate.forEach((fn) => fn(navigation));\n\t\t\t\t}\n\n\t\t\t\tif (should_block) {\n\t\t\t\t\te.preventDefault();\n\t\t\t\t\te.returnValue = '';\n\t\t\t\t} else {\n\t\t\t\t\thistory.scrollRestoration = 'auto';\n\t\t\t\t}\n\t\t\t});\n\n\t\t\taddEventListener('visibilitychange', () => {\n\t\t\t\tif (document.visibilityState === 'hidden') {\n\t\t\t\t\tpersist_state();\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// @ts-expect-error this isn't supported everywhere yet\n\t\t\tif (!navigator.connection?.saveData) {\n\t\t\t\tsetup_preload();\n\t\t\t}\n\n\t\t\t/** @param {MouseEvent} event */\n\t\t\tcontainer.addEventListener('click', (event) => {\n\t\t\t\t// Adapted from https://github.com/visionmedia/page.js\n\t\t\t\t// MIT license https://github.com/visionmedia/page.js#license\n\t\t\t\tif (event.button || event.which !== 1) return;\n\t\t\t\tif (event.metaKey || event.ctrlKey || event.shiftKey || event.altKey) return;\n\t\t\t\tif (event.defaultPrevented) return;\n\n\t\t\t\tconst a = find_anchor(/** @type {Element} */ (event.composedPath()[0]), container);\n\t\t\t\tif (!a) return;\n\n\t\t\t\tconst { url, external, target, download } = get_link_info(a, base);\n\t\t\t\tif (!url) return;\n\n\t\t\t\t// bail out before `beforeNavigate` if link opens in a different tab\n\t\t\t\tif (target === '_parent' || target === '_top') {\n\t\t\t\t\tif (window.parent !== window) return;\n\t\t\t\t} else if (target && target !== '_self') {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst options = get_router_options(a);\n\t\t\t\tconst is_svg_a_element = a instanceof SVGAElement;\n\n\t\t\t\t// Ignore URL protocols that differ to the current one and are not http(s) (e.g. `mailto:`, `tel:`, `myapp:`, etc.)\n\t\t\t\t// This may be wrong when the protocol is x: and the link goes to y:.. which should be treated as an external\n\t\t\t\t// navigation, but it's not clear how to handle that case and it's not likely to come up in practice.\n\t\t\t\t// MEMO: Without this condition, firefox will open mailer twice.\n\t\t\t\t// See:\n\t\t\t\t// - https://github.com/sveltejs/kit/issues/4045\n\t\t\t\t// - https://github.com/sveltejs/kit/issues/5725\n\t\t\t\t// - https://github.com/sveltejs/kit/issues/6496\n\t\t\t\tif (\n\t\t\t\t\t!is_svg_a_element &&\n\t\t\t\t\turl.protocol !== location.protocol &&\n\t\t\t\t\t!(url.protocol === 'https:' || url.protocol === 'http:')\n\t\t\t\t)\n\t\t\t\t\treturn;\n\n\t\t\t\tif (download) return;\n\n\t\t\t\t// Ignore the following but fire beforeNavigate\n\t\t\t\tif (external || options.reload) {\n\t\t\t\t\tif (before_navigate({ url, type: 'link' })) {\n\t\t\t\t\t\t// set `navigating` to `true` to prevent `beforeNavigate` callbacks\n\t\t\t\t\t\t// being called when the page unloads\n\t\t\t\t\t\tnavigating = true;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t}\n\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// Check if new url only differs by hash and use the browser default behavior in that case\n\t\t\t\t// This will ensure the `hashchange` event is fired\n\t\t\t\t// Removing the hash does a full page navigation in the browser, so make sure a hash is present\n\t\t\t\tconst [nonhash, hash] = url.href.split('#');\n\t\t\t\tif (hash !== undefined && nonhash === location.href.split('#')[0]) {\n\t\t\t\t\t// If we are trying to navigate to the same hash, we should only\n\t\t\t\t\t// attempt to scroll to that element and avoid any history changes.\n\t\t\t\t\t// Otherwise, this can cause Firefox to incorrectly assign a null\n\t\t\t\t\t// history state value without any signal that we can detect.\n\t\t\t\t\tif (current.url.hash === url.hash) {\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\ta.ownerDocument.getElementById(hash)?.scrollIntoView();\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t// set this flag to distinguish between navigations triggered by\n\t\t\t\t\t// clicking a hash link and those triggered by popstate\n\t\t\t\t\thash_navigating = true;\n\n\t\t\t\t\tupdate_scroll_positions(current_history_index);\n\n\t\t\t\t\tupdate_url(url);\n\n\t\t\t\t\tif (!options.replace_state) return;\n\n\t\t\t\t\t// hashchange event shouldn't occur if the router is replacing state.\n\t\t\t\t\thash_navigating = false;\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t}\n\n\t\t\t\tnavigate({\n\t\t\t\t\turl,\n\t\t\t\t\tscroll: options.noscroll ? scroll_state() : null,\n\t\t\t\t\tkeepfocus: options.keep_focus ?? false,\n\t\t\t\t\tredirect_count: 0,\n\t\t\t\t\tdetails: {\n\t\t\t\t\t\tstate: {},\n\t\t\t\t\t\treplaceState: options.replace_state ?? url.href === location.href\n\t\t\t\t\t},\n\t\t\t\t\taccepted: () => event.preventDefault(),\n\t\t\t\t\tblocked: () => event.preventDefault(),\n\t\t\t\t\ttype: 'link'\n\t\t\t\t});\n\t\t\t});\n\n\t\t\tcontainer.addEventListener('submit', (event) => {\n\t\t\t\tif (event.defaultPrevented) return;\n\n\t\t\t\tconst form = /** @type {HTMLFormElement} */ (\n\t\t\t\t\tHTMLFormElement.prototype.cloneNode.call(event.target)\n\t\t\t\t);\n\n\t\t\t\tconst submitter = /** @type {HTMLButtonElement | HTMLInputElement | null} */ (\n\t\t\t\t\tevent.submitter\n\t\t\t\t);\n\n\t\t\t\tconst method = submitter?.formMethod || form.method;\n\n\t\t\t\tif (method !== 'get') return;\n\n\t\t\t\tconst url = new URL(\n\t\t\t\t\t(submitter?.hasAttribute('formaction') && submitter?.formAction) || form.action\n\t\t\t\t);\n\n\t\t\t\tif (is_external_url(url, base)) return;\n\n\t\t\t\tconst event_form = /** @type {HTMLFormElement} */ (event.target);\n\n\t\t\t\tconst { keep_focus, noscroll, reload, replace_state } = get_router_options(event_form);\n\t\t\t\tif (reload) return;\n\n\t\t\t\tevent.preventDefault();\n\t\t\t\tevent.stopPropagation();\n\n\t\t\t\tconst data = new FormData(event_form);\n\n\t\t\t\tconst submitter_name = submitter?.getAttribute('name');\n\t\t\t\tif (submitter_name) {\n\t\t\t\t\tdata.append(submitter_name, submitter?.getAttribute('value') ?? '');\n\t\t\t\t}\n\n\t\t\t\t// @ts-expect-error `URLSearchParams(fd)` is kosher, but typescript doesn't know that\n\t\t\t\turl.search = new URLSearchParams(data).toString();\n\n\t\t\t\tnavigate({\n\t\t\t\t\turl,\n\t\t\t\t\tscroll: noscroll ? scroll_state() : null,\n\t\t\t\t\tkeepfocus: keep_focus ?? false,\n\t\t\t\t\tredirect_count: 0,\n\t\t\t\t\tdetails: {\n\t\t\t\t\t\tstate: {},\n\t\t\t\t\t\treplaceState: replace_state ?? url.href === location.href\n\t\t\t\t\t},\n\t\t\t\t\tnav_token: {},\n\t\t\t\t\taccepted: () => {},\n\t\t\t\t\tblocked: () => {},\n\t\t\t\t\ttype: 'form'\n\t\t\t\t});\n\t\t\t});\n\n\t\t\taddEventListener('popstate', async (event) => {\n\t\t\t\ttoken = {};\n\t\t\t\tif (event.state?.[INDEX_KEY]) {\n\t\t\t\t\t// if a popstate-driven navigation is cancelled, we need to counteract it\n\t\t\t\t\t// with history.go, which means we end up back here, hence this check\n\t\t\t\t\tif (event.state[INDEX_KEY] === current_history_index) return;\n\n\t\t\t\t\tconst scroll = scroll_positions[event.state[INDEX_KEY]];\n\t\t\t\t\tconst url = new URL(location.href);\n\n\t\t\t\t\t// if the only change is the hash, we don't need to do anything (see https://github.com/sveltejs/kit/pull/10636 for why we need to do `url?.`)...\n\t\t\t\t\tif (current.url?.href.split('#')[0] === location.href.split('#')[0]) {\n\t\t\t\t\t\t// ...except update our internal URL tracking and handle scroll\n\t\t\t\t\t\tupdate_url(url);\n\t\t\t\t\t\tscroll_positions[current_history_index] = scroll_state();\n\t\t\t\t\t\tcurrent_history_index = event.state[INDEX_KEY];\n\t\t\t\t\t\tscrollTo(scroll.x, scroll.y);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst delta = event.state[INDEX_KEY] - current_history_index;\n\n\t\t\t\t\tawait navigate({\n\t\t\t\t\t\turl,\n\t\t\t\t\t\tscroll,\n\t\t\t\t\t\tkeepfocus: false,\n\t\t\t\t\t\tredirect_count: 0,\n\t\t\t\t\t\tdetails: null,\n\t\t\t\t\t\taccepted: () => {\n\t\t\t\t\t\t\tcurrent_history_index = event.state[INDEX_KEY];\n\t\t\t\t\t\t},\n\t\t\t\t\t\tblocked: () => {\n\t\t\t\t\t\t\thistory.go(-delta);\n\t\t\t\t\t\t},\n\t\t\t\t\t\ttype: 'popstate',\n\t\t\t\t\t\tdelta,\n\t\t\t\t\t\tnav_token: token\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\t// since popstate event is also emitted when an anchor referencing the same\n\t\t\t\t\t// document is clicked, we have to check that the router isn't already handling\n\t\t\t\t\t// the navigation. otherwise we would be updating the page store twice.\n\t\t\t\t\tif (!hash_navigating) {\n\t\t\t\t\t\tconst url = new URL(location.href);\n\t\t\t\t\t\tupdate_url(url);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\n\t\t\taddEventListener('hashchange', () => {\n\t\t\t\t// if the hashchange happened as a result of clicking on a link,\n\t\t\t\t// we need to update history, otherwise we have to leave it alone\n\t\t\t\tif (hash_navigating) {\n\t\t\t\t\thash_navigating = false;\n\t\t\t\t\thistory.replaceState(\n\t\t\t\t\t\t{ ...history.state, [INDEX_KEY]: ++current_history_index },\n\t\t\t\t\t\t'',\n\t\t\t\t\t\tlocation.href\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// fix link[rel=icon], because browsers will occasionally try to load relative\n\t\t\t// URLs after a pushState/replaceState, resulting in a 404 — see\n\t\t\t// https://github.com/sveltejs/kit/issues/3748#issuecomment-1125980897\n\t\t\tfor (const link of document.querySelectorAll('link')) {\n\t\t\t\tif (link.rel === 'icon') link.href = link.href; // eslint-disable-line\n\t\t\t}\n\n\t\t\taddEventListener('pageshow', (event) => {\n\t\t\t\t// If the user navigates to another site and then uses the back button and\n\t\t\t\t// bfcache hits, we need to set navigating to null, the site doesn't know\n\t\t\t\t// the navigation away from it was successful.\n\t\t\t\t// Info about bfcache here: https://web.dev/bfcache\n\t\t\t\tif (event.persisted) {\n\t\t\t\t\tstores.navigating.set(null);\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t/**\n\t\t\t * @param {URL} url\n\t\t\t */\n\t\t\tfunction update_url(url) {\n\t\t\t\tcurrent.url = url;\n\t\t\t\tstores.page.set({ ...page, url });\n\t\t\t\tstores.page.notify();\n\t\t\t}\n\t\t},\n\n\t\t_hydrate: async ({\n\t\t\tstatus = 200,\n\t\t\terror,\n\t\t\tnode_ids,\n\t\t\tparams,\n\t\t\troute,\n\t\t\tdata: server_data_nodes,\n\t\t\tform\n\t\t}) => {\n\t\t\thydrated = true;\n\n\t\t\tconst url = new URL(location.href);\n\n\t\t\tif (!__SVELTEKIT_EMBEDDED__) {\n\t\t\t\t// See https://github.com/sveltejs/kit/pull/4935#issuecomment-1328093358 for one motivation\n\t\t\t\t// of determining the params on the client side.\n\t\t\t\t({ params = {}, route = { id: null } } = get_navigation_intent(url, false) || {});\n\t\t\t}\n\n\t\t\t/** @type {import('./types.js').NavigationFinished | undefined} */\n\t\t\tlet result;\n\n\t\t\ttry {\n\t\t\t\tconst branch_promises = node_ids.map(async (n, i) => {\n\t\t\t\t\tconst server_data_node = server_data_nodes[i];\n\t\t\t\t\t// Type isn't completely accurate, we still need to deserialize uses\n\t\t\t\t\tif (server_data_node?.uses) {\n\t\t\t\t\t\tserver_data_node.uses = deserialize_uses(server_data_node.uses);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn load_node({\n\t\t\t\t\t\tloader: app.nodes[n],\n\t\t\t\t\t\turl,\n\t\t\t\t\t\tparams,\n\t\t\t\t\t\troute,\n\t\t\t\t\t\tparent: async () => {\n\t\t\t\t\t\t\tconst data = {};\n\t\t\t\t\t\t\tfor (let j = 0; j < i; j += 1) {\n\t\t\t\t\t\t\t\tObject.assign(data, (await branch_promises[j]).data);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn data;\n\t\t\t\t\t\t},\n\t\t\t\t\t\tserver_data_node: create_data_node(server_data_node)\n\t\t\t\t\t});\n\t\t\t\t});\n\n\t\t\t\t/** @type {Array} */\n\t\t\t\tconst branch = await Promise.all(branch_promises);\n\n\t\t\t\tconst parsed_route = routes.find(({ id }) => id === route.id);\n\n\t\t\t\t// server-side will have compacted the branch, reinstate empty slots\n\t\t\t\t// so that error boundaries can be lined up correctly\n\t\t\t\tif (parsed_route) {\n\t\t\t\t\tconst layouts = parsed_route.layouts;\n\t\t\t\t\tfor (let i = 0; i < layouts.length; i++) {\n\t\t\t\t\t\tif (!layouts[i]) {\n\t\t\t\t\t\t\tbranch.splice(i, 0, undefined);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tresult = await get_navigation_result_from_branch({\n\t\t\t\t\turl,\n\t\t\t\t\tparams,\n\t\t\t\t\tbranch,\n\t\t\t\t\tstatus,\n\t\t\t\t\terror,\n\t\t\t\t\tform,\n\t\t\t\t\troute: parsed_route ?? null\n\t\t\t\t});\n\t\t\t} catch (error) {\n\t\t\t\tif (error instanceof Redirect) {\n\t\t\t\t\t// this is a real edge case — `load` would need to return\n\t\t\t\t\t// a redirect but only in the browser\n\t\t\t\t\tawait native_navigation(new URL(error.location, location.href));\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tresult = await load_root_error_page({\n\t\t\t\t\tstatus: error instanceof HttpError ? error.status : 500,\n\t\t\t\t\terror: await handle_error(error, { url, params, route }),\n\t\t\t\t\turl,\n\t\t\t\t\troute\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tinitialize(result);\n\t\t}\n\t};\n}\n\n/**\n * @param {URL} url\n * @param {boolean[]} invalid\n * @returns {Promise}\n */\nasync function load_data(url, invalid) {\n\tconst data_url = new URL(url);\n\tdata_url.pathname = add_data_suffix(url.pathname);\n\tif (url.pathname.endsWith('/')) {\n\t\tdata_url.searchParams.append(TRAILING_SLASH_PARAM, '1');\n\t}\n\tif (DEV && url.searchParams.has(INVALIDATED_PARAM)) {\n\t\tthrow new Error(`Cannot used reserved query parameter \"${INVALIDATED_PARAM}\"`);\n\t}\n\tdata_url.searchParams.append(INVALIDATED_PARAM, invalid.map((i) => (i ? '1' : '0')).join(''));\n\n\tconst res = await native_fetch(data_url.href);\n\n\t// if `__data.json` doesn't exist or the server has an internal error,\n\t// fallback to native navigation so we avoid parsing the HTML error page as a JSON\n\tif (res.headers.get('content-type')?.includes('text/html')) {\n\t\tawait native_navigation(url);\n\t}\n\n\tif (!res.ok) {\n\t\t// error message is a JSON-stringified string which devalue can't handle at the top level\n\t\t// turn it into a HttpError to not call handleError on the client again (was already handled on the server)\n\t\tthrow new HttpError(res.status, await res.json());\n\t}\n\n\t// TODO: fix eslint error / figure out if it actually applies to our situation\n\t// eslint-disable-next-line\n\treturn new Promise(async (resolve) => {\n\t\t/**\n\t\t * Map of deferred promises that will be resolved by a subsequent chunk of data\n\t\t * @type {Map}\n\t\t */\n\t\tconst deferreds = new Map();\n\t\tconst reader = /** @type {ReadableStream} */ (res.body).getReader();\n\t\tconst decoder = new TextDecoder();\n\n\t\t/**\n\t\t * @param {any} data\n\t\t */\n\t\tfunction deserialize(data) {\n\t\t\treturn devalue.unflatten(data, {\n\t\t\t\tPromise: (id) => {\n\t\t\t\t\treturn new Promise((fulfil, reject) => {\n\t\t\t\t\t\tdeferreds.set(id, { fulfil, reject });\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\tlet text = '';\n\n\t\twhile (true) {\n\t\t\t// Format follows ndjson (each line is a JSON object) or regular JSON spec\n\t\t\tconst { done, value } = await reader.read();\n\t\t\tif (done && !text) break;\n\n\t\t\ttext += !value && text ? '\\n' : decoder.decode(value); // no value -> final chunk -> add a new line to trigger the last parse\n\n\t\t\twhile (true) {\n\t\t\t\tconst split = text.indexOf('\\n');\n\t\t\t\tif (split === -1) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tconst node = JSON.parse(text.slice(0, split));\n\t\t\t\ttext = text.slice(split + 1);\n\n\t\t\t\tif (node.type === 'redirect') {\n\t\t\t\t\treturn resolve(node);\n\t\t\t\t}\n\n\t\t\t\tif (node.type === 'data') {\n\t\t\t\t\t// This is the first (and possibly only, if no pending promises) chunk\n\t\t\t\t\tnode.nodes?.forEach((/** @type {any} */ node) => {\n\t\t\t\t\t\tif (node?.type === 'data') {\n\t\t\t\t\t\t\tnode.uses = deserialize_uses(node.uses);\n\t\t\t\t\t\t\tnode.data = deserialize(node.data);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t\tresolve(node);\n\t\t\t\t} else if (node.type === 'chunk') {\n\t\t\t\t\t// This is a subsequent chunk containing deferred data\n\t\t\t\t\tconst { id, data, error } = node;\n\t\t\t\t\tconst deferred = /** @type {import('types').Deferred} */ (deferreds.get(id));\n\t\t\t\t\tdeferreds.delete(id);\n\n\t\t\t\t\tif (error) {\n\t\t\t\t\t\tdeferred.reject(deserialize(error));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdeferred.fulfil(deserialize(data));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t});\n\n\t// TODO edge case handling necessary? stream() read fails?\n}\n\n/**\n * @param {any} uses\n * @return {import('types').Uses}\n */\nfunction deserialize_uses(uses) {\n\treturn {\n\t\tdependencies: new Set(uses?.dependencies ?? []),\n\t\tparams: new Set(uses?.params ?? []),\n\t\tparent: !!uses?.parent,\n\t\troute: !!uses?.route,\n\t\turl: !!uses?.url\n\t};\n}\n\nfunction reset_focus() {\n\tconst autofocus = document.querySelector('[autofocus]');\n\tif (autofocus) {\n\t\t// @ts-ignore\n\t\tautofocus.focus();\n\t} else {\n\t\t// Reset page selection and focus\n\t\t// We try to mimic browsers' behaviour as closely as possible by targeting the\n\t\t// first scrollable region, but unfortunately it's not a perfect match — e.g.\n\t\t// shift-tabbing won't immediately cycle up from the end of the page on Chromium\n\t\t// See https://html.spec.whatwg.org/multipage/interaction.html#get-the-focusable-area\n\t\tconst root = document.body;\n\t\tconst tabindex = root.getAttribute('tabindex');\n\n\t\troot.tabIndex = -1;\n\t\t// @ts-expect-error\n\t\troot.focus({ preventScroll: true, focusVisible: false });\n\n\t\t// restore `tabindex` as to prevent `root` from stealing input from elements\n\t\tif (tabindex !== null) {\n\t\t\troot.setAttribute('tabindex', tabindex);\n\t\t} else {\n\t\t\troot.removeAttribute('tabindex');\n\t\t}\n\n\t\t// capture current selection, so we can compare the state after\n\t\t// snapshot restoration and afterNavigate callbacks have run\n\t\tconst selection = getSelection();\n\n\t\tif (selection && selection.type !== 'None') {\n\t\t\t/** @type {Range[]} */\n\t\t\tconst ranges = [];\n\n\t\t\tfor (let i = 0; i < selection.rangeCount; i += 1) {\n\t\t\t\tranges.push(selection.getRangeAt(i));\n\t\t\t}\n\n\t\t\tsetTimeout(() => {\n\t\t\t\tif (selection.rangeCount !== ranges.length) return;\n\n\t\t\t\tfor (let i = 0; i < selection.rangeCount; i += 1) {\n\t\t\t\t\tconst a = ranges[i];\n\t\t\t\t\tconst b = selection.getRangeAt(i);\n\n\t\t\t\t\t// we need to do a deep comparison rather than just `a !== b` because\n\t\t\t\t\t// Safari behaves differently to other browsers\n\t\t\t\t\tif (\n\t\t\t\t\t\ta.commonAncestorContainer !== b.commonAncestorContainer ||\n\t\t\t\t\t\ta.startContainer !== b.startContainer ||\n\t\t\t\t\t\ta.endContainer !== b.endContainer ||\n\t\t\t\t\t\ta.startOffset !== b.startOffset ||\n\t\t\t\t\t\ta.endOffset !== b.endOffset\n\t\t\t\t\t) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// if the selection hasn't changed (as a result of an element being (auto)focused,\n\t\t\t\t// or a programmatic selection, we reset everything as part of the navigation)\n\t\t\t\t// fixes https://github.com/sveltejs/kit/issues/8439\n\t\t\t\tselection.removeAllRanges();\n\t\t\t});\n\t\t}\n\t}\n}\n\n/**\n * @param {import('./types.js').NavigationState} current\n * @param {import('./types.js').NavigationIntent | undefined} intent\n * @param {URL | null} url\n * @param {Exclude} type\n */\nfunction create_navigation(current, intent, url, type) {\n\t/** @type {(value: any) => void} */\n\tlet fulfil;\n\n\t/** @type {(error: any) => void} */\n\tlet reject;\n\n\tconst complete = new Promise((f, r) => {\n\t\tfulfil = f;\n\t\treject = r;\n\t});\n\n\t// Handle any errors off-chain so that it doesn't show up as an unhandled rejection\n\tcomplete.catch(() => {});\n\n\t/** @type {import('@sveltejs/kit').Navigation} */\n\tconst navigation = {\n\t\tfrom: {\n\t\t\tparams: current.params,\n\t\t\troute: { id: current.route?.id ?? null },\n\t\t\turl: current.url\n\t\t},\n\t\tto: url && {\n\t\t\tparams: intent?.params ?? null,\n\t\t\troute: { id: intent?.route?.id ?? null },\n\t\t\turl\n\t\t},\n\t\twillUnload: !intent,\n\t\ttype,\n\t\tcomplete\n\t};\n\n\treturn {\n\t\tnavigation,\n\t\t// @ts-expect-error\n\t\tfulfil,\n\t\t// @ts-expect-error\n\t\treject\n\t};\n}\n\nif (DEV) {\n\t// Nasty hack to silence harmless warnings the user can do nothing about\n\tconst console_warn = console.warn;\n\tconsole.warn = function warn(...args) {\n\t\tif (\n\t\t\targs.length === 1 &&\n\t\t\t/<(Layout|Page|Error)(_[\\w$]+)?> was created (with unknown|without expected) prop '(data|form)'/.test(\n\t\t\t\targs[0]\n\t\t\t)\n\t\t) {\n\t\t\treturn;\n\t\t}\n\t\tconsole_warn(...args);\n\t};\n\n\tif (import.meta.hot) {\n\t\timport.meta.hot.on('vite:beforeUpdate', () => {\n\t\t\tif (errored) {\n\t\t\t\tlocation.reload();\n\t\t\t}\n\t\t});\n\t}\n}\n","import { DEV } from 'esm-env';\nimport { create_client } from './client.js';\nimport { init } from './singletons.js';\n\n/**\n * @param {import('./types.js').SvelteKitApp} app\n * @param {HTMLElement} target\n * @param {Parameters[0]} [hydrate]\n */\nexport async function start(app, target, hydrate) {\n\tif (DEV && target === document.body) {\n\t\tconsole.warn(\n\t\t\t'Placing %sveltekit.body% directly inside is not recommended, as your app may break for users who have certain browser extensions installed.\\n\\nConsider wrapping it in an element:\\n\\n
\\n %sveltekit.body%\\n
'\n\t\t);\n\t}\n\n\tconst client = create_client(app, target);\n\n\tinit({ client });\n\n\tif (hydrate) {\n\t\tawait client._hydrate(hydrate);\n\t} else {\n\t\tclient.goto(location.href, { replaceState: true });\n\t}\n\n\tclient._start_router();\n}\n"],"names":["normalize_path","path","trailing_slash","decode_pathname","pathname","decode_params","params","key","tracked_url_properties","make_trackable","url","callback","tracked","property","disable_hash","DATA_SUFFIX","add_data_suffix","hash","values","value","buffer","i","native_fetch","input","init","cache","build_selector","b64_decode","text","d","u8","initial_fetch","resource","opts","selector","script","body","ttl","subsequent_fetch","resolved","cached","param_pattern","parse_route_id","id","get_route_segments","segment","rest_match","optional_match","parts","content","escape","code","match","is_optional","is_rest","name","matcher","affects_path","route","exec","matchers","result","values_needing_match","buffered","param","s","next_param","next_value","str","parse","nodes","server_loads","dictionary","layouts_with_server_load","leaf","layouts","errors","pattern","n","create_layout_loader","create_leaf_loader","uses_server_data","get","set","json","UNDEFINED","HOLE","NAN","POSITIVE_INFINITY","NEGATIVE_INFINITY","NEGATIVE_ZERO","unflatten","parsed","revivers","hydrate","hydrated","index","standalone","type","reviver","map","obj","array","object","compact","arr","val","valid_layout_exports","valid_layout_server_exports","unwrap_promises","_a","INVALIDATED_PARAM","TRAILING_SLASH_PARAM","scroll_positions","storage.get","SCROLL_KEY","snapshots","SNAPSHOT_KEY","update_scroll_positions","scroll_state","native_navigation","create_client","app","target","routes","default_layout_loader","default_error_loader","container","invalidated","components","load_cache","callbacks","current","started","autoscroll","updating","navigating","hash_navigating","force_invalidation","root","current_history_index","INDEX_KEY","scroll","page","token","pending_invalidate","invalidate","intent","get_navigation_intent","nav_token","navigation_result","load_route","goto","capture_snapshot","c","restore_snapshot","_b","persist_state","storage.set","noScroll","replaceState","keepFocus","state","invalidateAll","redirect_count","get_base_uri","navigate","preload_data","preload_code","pathnames","promises","r","load","initialize","style","stores","navigation","fn","get_navigation_result_from_branch","branch","status","error","form","slash","node","branch_node","data","data_changed","p","prev","load_node","loader","parent","server_data_node","uses","depends","deps","dep","href","load_input","requested","base","_c","has_changed","parent_changed","route_changed","url_changed","create_data_node","previous","invalidating","loaders","server_data","parent_invalid","invalid_server_nodes","invalid","load_data","load_root_error_page","HttpError","handle_error","server_data_nodes","branch_promises","j","err","Redirect","error_load","load_nearest_error_page","server_fallback","origin","root_layout","root_error","is_external_url","get_url_path","before_navigate","delta","should_block","nav","create_navigation","cancellable","keepfocus","details","accepted","blocked","previous_history_index","change","after_navigate","cleanup","activeElement","tick","deep_linked","changed_focus","reset_focus","setup_preload","mousemove_timeout","event","preload","tap","observer","entries","entry","element","priority","a","find_anchor","external","download","get_link_info","options","get_router_options","PRELOAD_PRIORITIES","NotFound","onMount","e","nonhash","update_url","submitter","event_form","keep_focus","noscroll","reload","replace_state","submitter_name","link","node_ids","deserialize_uses","parsed_route","data_url","res","resolve","deferreds","reader","decoder","deserialize","devalue.unflatten","fulfil","reject","done","split","deferred","autofocus","tabindex","selection","ranges","b","complete","f","start","client"],"mappings":"2RAmDO,SAASA,GAAeC,EAAMC,EAAgB,CACpD,OAAID,IAAS,KAAOC,IAAmB,SAAiBD,EAEpDC,IAAmB,QACfD,EAAK,SAAS,GAAG,EAAIA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