mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 20:19:34 +01:00
44 lines
870 B
Vue
44 lines
870 B
Vue
<template>
|
|
<div>
|
|
<Header />
|
|
|
|
<UContainer>
|
|
<UMain>
|
|
<UPage>
|
|
<UPageError :error="error" />
|
|
</UPage>
|
|
</UMain>
|
|
</UContainer>
|
|
|
|
<ClientOnly>
|
|
<UDocsSearch :files="files" :navigation="navigation" />
|
|
</ClientOnly>
|
|
|
|
<UNotifications />
|
|
</div>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
import type { NuxtError } from '#app'
|
|
|
|
useSeoMeta({
|
|
title: 'Page not found',
|
|
description: 'We are sorry but this page could not be found.'
|
|
})
|
|
|
|
defineProps<{
|
|
error: NuxtError
|
|
}>()
|
|
|
|
const { data: navigation } = await useAsyncData('navigation', () => fetchContentNavigation(), {
|
|
default: () => []
|
|
})
|
|
const { data: files } = await useLazyAsyncData('files', () => queryContent().where({ _type: 'markdown', navigation: { $ne: false } }).find(), {
|
|
default: () => []
|
|
})
|
|
|
|
// Provide
|
|
|
|
provide('navigation', navigation)
|
|
</script>
|