This commit is contained in:
parent
00aa1e0d3d
commit
8b5814ecef
|
|
@ -1,29 +0,0 @@
|
|||
<script setup lang="ts">
|
||||
const router = useRouter()
|
||||
|
||||
function onBack() {
|
||||
if (window.history.state.back)
|
||||
history.back()
|
||||
else
|
||||
router.replace('/')
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div text="center gray-300 dark:gray-200">
|
||||
<van-icon name="warn-o" size="3em" />
|
||||
<div> Not found </div>
|
||||
|
||||
<div class="mt-2">
|
||||
<button van-haptics-feedback class="btn" @click="onBack">
|
||||
Back
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<route lang="json5">
|
||||
{
|
||||
name: '404'
|
||||
}
|
||||
</route>
|
||||
|
|
@ -5,19 +5,19 @@ const checked = computed({
|
|||
})
|
||||
|
||||
const menuItems = computed(() => ([
|
||||
{ title: 'Mock', route: 'mock' },
|
||||
/* { title: 'Mock', route: 'mock' },
|
||||
{ title: 'Charts', route: 'charts' },
|
||||
{ title: 'UnoCSS', route: 'unocss' },
|
||||
{ title: 'Counter', route: 'counter' },
|
||||
{ title: 'KeepAlive', route: 'keepalive' },
|
||||
{ title: 'ScrollCache', route: 'scroll-cache' },
|
||||
{ title: '404', route: 'unknown' }, */
|
||||
{ title: 'AI Chat', route: 'llm-chat' },
|
||||
{ title: '404', route: 'unknown' },
|
||||
]))
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<van-cell-group title="Settings" :border="false" :inset="true">
|
||||
<!-- <van-cell-group title="Settings" :border="false" :inset="true">
|
||||
<van-cell center title="Dark Mode">
|
||||
<template #right-icon>
|
||||
<van-switch
|
||||
|
|
@ -27,9 +27,9 @@ const menuItems = computed(() => ([
|
|||
/>
|
||||
</template>
|
||||
</van-cell>
|
||||
</van-cell-group>
|
||||
</van-cell-group> -->
|
||||
|
||||
<van-cell-group title="Examples" :border="false" :inset="true">
|
||||
<van-cell-group :border="false" :inset="true">
|
||||
<template v-for="item in menuItems" :key="item.route">
|
||||
<van-cell :title="item.title" :to="item.route" is-link />
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -30,13 +30,6 @@ declare module 'vue-router/auto-routes' {
|
|||
Record<never, never>,
|
||||
| never
|
||||
>,
|
||||
'404': RouteRecordInfo<
|
||||
'404',
|
||||
'/:all(.*)',
|
||||
{ all: ParamValue<true> },
|
||||
{ all: ParamValue<false> },
|
||||
| never
|
||||
>,
|
||||
'Charts': RouteRecordInfo<
|
||||
'Charts',
|
||||
'/charts',
|
||||
|
|
@ -140,12 +133,6 @@ declare module 'vue-router/auto-routes' {
|
|||
views:
|
||||
| never
|
||||
}
|
||||
'src/pages/[...all].vue': {
|
||||
routes:
|
||||
| '404'
|
||||
views:
|
||||
| never
|
||||
}
|
||||
'src/pages/charts/index.vue': {
|
||||
routes:
|
||||
| 'Charts'
|
||||
|
|
|
|||
Loading…
Reference in New Issue