docs: bump @nuxt-themes/ui-kit

This commit is contained in:
Benjamin Canac
2023-08-07 22:32:14 +02:00
parent 451e72a583
commit 16ac4a0533
7 changed files with 120 additions and 63 deletions

43
docs/error.vue Normal file
View File

@@ -0,0 +1,43 @@
<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>