diff --git a/src/layouts/Layout.vue b/src/layouts/Layout.vue index 09c8b7db3..fc753348d 100644 --- a/src/layouts/Layout.vue +++ b/src/layouts/Layout.vue @@ -48,7 +48,7 @@ - + diff --git a/src/pages/NotFound.vue b/src/pages/NotFound.vue new file mode 100644 index 000000000..16ba8a558 --- /dev/null +++ b/src/pages/NotFound.vue @@ -0,0 +1,99 @@ + + + + + + + Uptime Kuma + + + + + + + + Uptime Kuma + + + + + + 🐻 {{ $t("Page Not Found") }} + + + + Most likely causes: + + The resource is no longer available. + There might be a typing error in the address. + + + What you can try: + + Retype the address. + Go back to the previous page. + + + + + + + + + diff --git a/src/router.js b/src/router.js index 76dfa5cbe..f59192d3e 100644 --- a/src/router.js +++ b/src/router.js @@ -20,6 +20,7 @@ import Backup from "./components/settings/Backup.vue"; import About from "./components/settings/About.vue"; import ManageStatusPage from "./pages/ManageStatusPage.vue"; import AddStatusPage from "./pages/AddStatusPage.vue"; +import NotFound from "./pages/NotFound.vue"; const routes = [ { @@ -128,6 +129,10 @@ const routes = [ path: "/status/:slug", component: StatusPage, }, + { + path: "/:pathMatch(.*)*", + component: NotFound, + }, ]; export const router = createRouter({