import { useSSRContext, mergeProps, withCtx, createTextVNode, toDisplayString, defineComponent, computed, ref, h, resolveComponent } from 'vue'; import { l as hasProtocol, j as joinURL, p as parseURL, q as parseQuery, r as withTrailingSlash, t as withoutTrailingSlash } from '../../nitro/node-server.mjs'; import { u as useRouter, n as nuxtLinkDefaults, a as useRuntimeConfig, b as navigateTo } from '../server.mjs'; import { u as useHead } from './index-0ac4f71f.mjs'; import { ssrRenderAttrs, ssrInterpolate, ssrRenderComponent } from 'vue/server-renderer'; import { _ as _export_sfc } from './_plugin-vue_export-helper-cc2b3d55.mjs'; import 'node:http'; import 'node:https'; import 'fs'; import 'path'; import 'node:fs'; import 'node:url'; import 'unhead'; import '@unhead/shared'; import 'vue-router'; const firstNonUndefined = (...args) => args.find((arg) => arg !== void 0); const DEFAULT_EXTERNAL_REL_ATTRIBUTE = "noopener noreferrer"; /*! @__NO_SIDE_EFFECTS__ */ // @__NO_SIDE_EFFECTS__ function defineNuxtLink(options) { const componentName = options.componentName || "NuxtLink"; const resolveTrailingSlashBehavior = (to, resolve) => { if (!to || options.trailingSlash !== "append" && options.trailingSlash !== "remove") { return to; } const normalizeTrailingSlash = options.trailingSlash === "append" ? withTrailingSlash : withoutTrailingSlash; if (typeof to === "string") { return normalizeTrailingSlash(to, true); } const path = "path" in to ? to.path : resolve(to).path; return { ...to, name: void 0, // named routes would otherwise always override trailing slash behavior path: normalizeTrailingSlash(path, true) }; }; return defineComponent({ name: componentName, props: { // Routing to: { type: [String, Object], default: void 0, required: false }, href: { type: [String, Object], default: void 0, required: false }, // Attributes target: { type: String, default: void 0, required: false }, rel: { type: String, default: void 0, required: false }, noRel: { type: Boolean, default: void 0, required: false }, // Prefetching prefetch: { type: Boolean, default: void 0, required: false }, noPrefetch: { type: Boolean, default: void 0, required: false }, // Styling activeClass: { type: String, default: void 0, required: false }, exactActiveClass: { type: String, default: void 0, required: false }, prefetchedClass: { type: String, default: void 0, required: false }, // Vue Router's `` additional props replace: { type: Boolean, default: void 0, required: false }, ariaCurrentValue: { type: String, default: void 0, required: false }, // Edge cases handling external: { type: Boolean, default: void 0, required: false }, // Slot API custom: { type: Boolean, default: void 0, required: false } }, setup(props, { slots }) { const router = useRouter(); const config = useRuntimeConfig(); const to = computed(() => { const path = props.to || props.href || ""; return resolveTrailingSlashBehavior(path, router.resolve); }); const isProtocolURL = computed(() => typeof to.value === "string" && hasProtocol(to.value, { acceptRelative: true })); const isExternal = computed(() => { if (props.external) { return true; } if (props.target && props.target !== "_self") { return true; } if (typeof to.value === "object") { return false; } return to.value === "" || isProtocolURL.value; }); const prefetched = ref(false); const el = void 0; const elRef = void 0; return () => { var _a2; var _a, _b; if (!isExternal.value) { const routerLinkProps = { ref: elRef, to: to.value, activeClass: props.activeClass || options.activeClass, exactActiveClass: props.exactActiveClass || options.exactActiveClass, replace: props.replace, ariaCurrentValue: props.ariaCurrentValue, custom: props.custom }; if (!props.custom) { if (prefetched.value) { routerLinkProps.class = props.prefetchedClass || options.prefetchedClass; } routerLinkProps.rel = props.rel; } return h( resolveComponent("RouterLink"), routerLinkProps, slots.default ); } const href = typeof to.value === "object" ? (_a2 = (_a = router.resolve(to.value)) == null ? void 0 : _a.href) != null ? _a2 : null : to.value && !props.external && !isProtocolURL.value ? resolveTrailingSlashBehavior(joinURL(config.app.baseURL, to.value), router.resolve) : to.value || null; const target = props.target || null; const rel = props.noRel ? null : firstNonUndefined(props.rel, options.externalRelAttribute, href ? DEFAULT_EXTERNAL_REL_ATTRIBUTE : "") || null; const navigate = () => navigateTo(href, { replace: props.replace }); if (props.custom) { if (!slots.default) { return null; } return slots.default({ href, navigate, get route() { if (!href) { return void 0; } const url = parseURL(href); return { path: url.pathname, fullPath: url.pathname, get query() { return parseQuery(url.search); }, hash: url.hash, // stub properties for compat with vue-router params: {}, name: void 0, matched: [], redirectedFrom: void 0, meta: {}, href }; }, rel, target, isExternal: isExternal.value, isActive: false, isExactActive: false }); } return h("a", { ref: el, href, rel, target }, (_b = slots.default) == null ? void 0 : _b.call(slots)); }; } }); } const __nuxt_component_0 = /* @__PURE__ */ defineNuxtLink(nuxtLinkDefaults); const _sfc_main = { __name: "error-404", __ssrInlineRender: true, props: { appName: { type: String, default: "Nuxt" }, version: { type: String, default: "" }, statusCode: { type: Number, default: 404 }, statusMessage: { type: String, default: "Not Found" }, description: { type: String, default: "Sorry, the page you are looking for could not be found." }, backHome: { type: String, default: "Go back home" } }, setup(__props) { const props = __props; useHead({ title: `${props.statusCode} - ${props.statusMessage} | ${props.appName}`, script: [], style: [ { children: `*,:before,:after{-webkit-box-sizing:border-box;box-sizing:border-box;border-width:0;border-style:solid;border-color:#e0e0e0}*{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(14, 165, 233, .5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000}:root{-moz-tab-size:4;-o-tab-size:4;tab-size:4}a{color:inherit;text-decoration:inherit}body{margin:0;font-family:inherit;line-height:inherit}html{-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";line-height:1.5}h1,p{margin:0}h1{font-size:inherit;font-weight:inherit}` } ] }); return (_ctx, _push, _parent, _attrs) => { const _component_NuxtLink = __nuxt_component_0; _push(`

${ssrInterpolate(__props.statusCode)}

${ssrInterpolate(__props.description)}

`); _push(ssrRenderComponent(_component_NuxtLink, { to: "/", class: "gradient-border text-md sm:text-xl py-2 px-4 sm:py-3 sm:px-6 cursor-pointer" }, { default: withCtx((_, _push2, _parent2, _scopeId) => { if (_push2) { _push2(`${ssrInterpolate(__props.backHome)}`); } else { return [ createTextVNode(toDisplayString(__props.backHome), 1) ]; } }), _: 1 }, _parent)); _push(`
`); }; } }; const _sfc_setup = _sfc_main.setup; _sfc_main.setup = (props, ctx) => { const ssrContext = useSSRContext(); (ssrContext.modules || (ssrContext.modules = /* @__PURE__ */ new Set())).add("node_modules/@nuxt/ui-templates/dist/templates/error-404.vue"); return _sfc_setup ? _sfc_setup(props, ctx) : void 0; }; const error404 = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-ccd3db62"]]); export { error404 as default }; //# sourceMappingURL=error-404-6c4afc63.mjs.map