feat: add 404 catch-all route with NotFound view
Unmatched URLs now show a glass-card 404 page with a link back to the dashboard instead of a blank page. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -185,6 +185,11 @@ const router = createRouter({
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: '/:pathMatch(.*)*',
|
||||
name: 'not-found',
|
||||
component: () => import('../views/NotFound.vue'),
|
||||
},
|
||||
],
|
||||
})
|
||||
|
||||
|
||||
15
neode-ui/src/views/NotFound.vue
Normal file
15
neode-ui/src/views/NotFound.vue
Normal file
@@ -0,0 +1,15 @@
|
||||
<script setup lang="ts">
|
||||
import { RouterLink } from 'vue-router'
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="min-h-screen flex items-center justify-center px-4">
|
||||
<div class="glass-card px-8 py-10 text-center max-w-md">
|
||||
<h1 class="text-6xl font-bold text-white/30 mb-4">404</h1>
|
||||
<p class="text-lg text-white/70 mb-6">Page not found</p>
|
||||
<RouterLink to="/dashboard" class="glass-button inline-block px-6 py-3">
|
||||
Back to Dashboard
|
||||
</RouterLink>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
Reference in New Issue
Block a user