docs: update

This commit is contained in:
Benjamin Canac
2024-06-28 11:49:56 +02:00
parent db45bafaed
commit 4ef81991f2
6 changed files with 7 additions and 14 deletions

View File

@@ -27,7 +27,7 @@ const meta: ComputedRef<ComponentMeta> = computed(() => componentMeta.value.meta
<ProseTbody>
<ProseTr v-for="event in meta.events" :key="event.name">
<ProseTd>
<ProseCodeInline>
<ProseCodeInline class="text-primary-500 dark:text-primary-400">
{{ event.name }}
</ProseCodeInline>
</ProseTd>

View File

@@ -45,7 +45,7 @@ console.log('meta.value', meta.value)
<ProseTbody>
<ProseTr v-for="prop in meta.props" :key="prop.name">
<ProseTd>
<ProseCodeInline>
<ProseCodeInline class="text-primary-500 dark:text-primary-400">
{{ prop.name }}
</ProseCodeInline>
</ProseTd>
@@ -55,9 +55,7 @@ console.log('meta.value', meta.value)
<ProseTd>
<HighlightInlineType v-if="prop.type" :type="prop.type" />
<ProseP class="mt-1 mb-0 text-gray-500 dark:text-gray-400">
{{ prop.description }}
</ProseP>
<MDC v-if="prop.description" :value="prop.description" class="text-gray-600 dark:text-gray-300 mt-1" />
</ProseTd>
</ProseTr>
</ProseTbody>

View File

@@ -27,16 +27,14 @@ const meta: ComputedRef<ComponentMeta> = computed(() => componentMeta.value.meta
<ProseTbody>
<ProseTr v-for="slot in meta.slots" :key="slot.name">
<ProseTd>
<ProseCodeInline>
<ProseCodeInline class="text-primary-500 dark:text-primary-400">
{{ slot.name }}
</ProseCodeInline>
</ProseTd>
<ProseTd>
<HighlightInlineType v-if="slot.type" :type="slot.type" />
<ProseP class="mt-1 mb-0 text-gray-500 dark:text-gray-400">
{{ slot.description }}
</ProseP>
<MDC v-if="slot.description" :value="slot.description" class="text-gray-600 dark:text-gray-300 mt-1" />
</ProseTd>
</ProseTr>
</ProseTbody>

View File

@@ -8,7 +8,7 @@ const route = useRoute()
const name = camelCase(route.params.slug[route.params.slug.length - 1])
const { data: ast } = await useAsyncData(`${name}-theme`, () => parseMarkdown(`
const { data: ast } = await useAsyncData<any>(`${name}-theme`, () => parseMarkdown(`
\`\`\`yml
${json5.stringify(theme[name], null, 2).replace(/,([ |\t\n]+[}|\])])/g, '$1')}
\`\`\`\

View File

@@ -30,10 +30,6 @@ componentProps:
:component-slots
### Events
:component-events
## Theme
:component-theme

View File

@@ -82,6 +82,7 @@ export default defineNuxtConfig({
'/components': { redirect: '/components/app', prerender: false }
},
componentMeta: {
debug: 2,
exclude: [
'@nuxt/content',
'@nuxt/icon',