新建项目,集成官方docs,初次提交
This commit is contained in:
13
.editorconfig
Executable file
13
.editorconfig
Executable file
@@ -0,0 +1,13 @@
|
|||||||
|
# editorconfig.org
|
||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
indent_size = 2
|
||||||
|
indent_style = space
|
||||||
|
end_of_line = lf
|
||||||
|
charset = utf-8
|
||||||
|
trim_trailing_whitespace = true
|
||||||
|
insert_final_newline = true
|
||||||
|
|
||||||
|
[*.md]
|
||||||
|
trim_trailing_whitespace = false
|
5
.env.example
Normal file
5
.env.example
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
# Production license for @nuxt/ui-pro, get one at https://ui.nuxt.com/pro/purchase
|
||||||
|
NUXT_UI_PRO_LICENSE=
|
||||||
|
|
||||||
|
# Public URL, used for OG Image when running nuxt generate
|
||||||
|
NUXT_PUBLIC_SITE_URL=
|
27
.gitignore
vendored
Normal file
27
.gitignore
vendored
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# Nuxt dev/build outputs
|
||||||
|
.output
|
||||||
|
.data
|
||||||
|
.nuxt
|
||||||
|
.nitro
|
||||||
|
.cache
|
||||||
|
dist
|
||||||
|
|
||||||
|
# Node dependencies
|
||||||
|
node_modules
|
||||||
|
|
||||||
|
# Logs
|
||||||
|
logs
|
||||||
|
*.log
|
||||||
|
|
||||||
|
# Misc
|
||||||
|
.DS_Store
|
||||||
|
.fleet
|
||||||
|
.idea
|
||||||
|
|
||||||
|
# Local env files
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
!.env.example
|
||||||
|
|
||||||
|
# VSC
|
||||||
|
.history
|
81
README.md
Normal file
81
README.md
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
# Nuxt Docs Template
|
||||||
|
|
||||||
|
[](https://ui.nuxt.com/pro)
|
||||||
|
[](https://hub.nuxt.com/new?repo=nuxt-ui-pro/docs)
|
||||||
|
|
||||||
|
This template lets you build a documentation with [Nuxt UI Pro](https://ui.nuxt.com/pro) quickly.
|
||||||
|
|
||||||
|
- [Live demo](https://docs-template.nuxt.dev/)
|
||||||
|
- [Documentation](https://ui.nuxt.com/getting-started/installation/pro/nuxt)
|
||||||
|
|
||||||
|
<a href="https://docs-template.nuxt.dev/" target="_blank">
|
||||||
|
<picture>
|
||||||
|
<source media="(prefers-color-scheme: dark)" srcset="https://assets.hub.nuxt.com/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RvY3MtdGVtcGxhdGUubnV4dC5kZXYiLCJpYXQiOjE3Mzk0NjM0MTd9.ltVAqPgKG38O01X1zl6MXfrJc55nf9OewXNFjpZ_2JY.jpg?theme=dark">
|
||||||
|
<source media="(prefers-color-scheme: light)" srcset="https://assets.hub.nuxt.com/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RvY3MtdGVtcGxhdGUubnV4dC5kZXYiLCJpYXQiOjE3Mzk0NjM0MTd9.ltVAqPgKG38O01X1zl6MXfrJc55nf9OewXNFjpZ_2JY.jpg?theme=light">
|
||||||
|
<img alt="Nuxt Docs Template" src="https://assets.hub.nuxt.com/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RvY3MtdGVtcGxhdGUubnV4dC5kZXYiLCJpYXQiOjE3Mzk0NjM0MTd9.ltVAqPgKG38O01X1zl6MXfrJc55nf9OewXNFjpZ_2JY.jpg">
|
||||||
|
</picture>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
## Quick Start
|
||||||
|
|
||||||
|
```bash [Terminal]
|
||||||
|
npx nuxi init -t github:nuxt-ui-pro/docs
|
||||||
|
```
|
||||||
|
|
||||||
|
## Setup
|
||||||
|
|
||||||
|
Make sure to install the dependencies:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Development Server
|
||||||
|
|
||||||
|
Start the development server on `http://localhost:3000`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm dev
|
||||||
|
```
|
||||||
|
|
||||||
|
## Production
|
||||||
|
|
||||||
|
Build the application for production:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm build
|
||||||
|
```
|
||||||
|
|
||||||
|
Locally preview production build:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm preview
|
||||||
|
```
|
||||||
|
|
||||||
|
Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.
|
||||||
|
|
||||||
|
## Nuxt Studio integration
|
||||||
|
|
||||||
|
Studio is an intuitive CMS interface to edit your Nuxt Content websites.
|
||||||
|
|
||||||
|
It take advantage of the Preview API included in Nuxt Content to propose the best editing experience for your content files. Editors can benefit from a user-friendly interface to edit their Markdown, YAML or JSON files.
|
||||||
|
|
||||||
|
You can import your project on the platform without any extra setup.
|
||||||
|
|
||||||
|
However to enable the live preview on the platform, you just need to activate studio in the content configuration of your `nuxt.config.ts` file.
|
||||||
|
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
content: {
|
||||||
|
preview: {
|
||||||
|
api: 'https://api.nuxt.studio'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
Read more on [Nuxt Studio docs](https://content.nuxt.com/studio/setup).
|
||||||
|
|
||||||
|
## Renovate integration
|
||||||
|
|
||||||
|
Install [Renovate GitHub app](https://github.com/apps/renovate/installations/select_target) on your repository and you are good to go.
|
84
app/app.config.ts
Normal file
84
app/app.config.ts
Normal file
@@ -0,0 +1,84 @@
|
|||||||
|
export default defineAppConfig({
|
||||||
|
ui: {
|
||||||
|
colors: {
|
||||||
|
primary: 'green',
|
||||||
|
neutral: 'slate'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
uiPro: {
|
||||||
|
footer: {
|
||||||
|
slots: {
|
||||||
|
root: 'border-t border-default',
|
||||||
|
left: 'text-sm text-muted'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
seo: {
|
||||||
|
siteName: 'Nuxt Docs Template'
|
||||||
|
},
|
||||||
|
header: {
|
||||||
|
title: '',
|
||||||
|
to: '/',
|
||||||
|
logo: {
|
||||||
|
alt: '',
|
||||||
|
light: '',
|
||||||
|
dark: ''
|
||||||
|
},
|
||||||
|
search: true,
|
||||||
|
colorMode: true,
|
||||||
|
links: [{
|
||||||
|
'icon': 'i-simple-icons-github',
|
||||||
|
'to': 'https://github.com/nuxt-ui-pro/docs',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'GitHub'
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
footer: {
|
||||||
|
credits: `Copyright © ${new Date().getFullYear()}`,
|
||||||
|
colorMode: false,
|
||||||
|
links: [{
|
||||||
|
'icon': 'i-simple-icons-nuxtdotjs',
|
||||||
|
'to': 'https://nuxt.com',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt Website'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-discord',
|
||||||
|
'to': 'https://discord.com/invite/ps2h6QT',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt UI on Discord'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-x',
|
||||||
|
'to': 'https://x.com/nuxt_js',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt on X'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-github',
|
||||||
|
'to': 'https://github.com/nuxt/ui',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt UI on GitHub'
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
toc: {
|
||||||
|
title: 'Table of Contents',
|
||||||
|
bottom: {
|
||||||
|
title: 'Community',
|
||||||
|
edit: 'https://github.com/nuxt-ui-pro/docs/edit/main/content',
|
||||||
|
links: [{
|
||||||
|
icon: 'i-lucide-star',
|
||||||
|
label: 'Star on GitHub',
|
||||||
|
to: 'https://github.com/nuxt/ui',
|
||||||
|
target: '_blank'
|
||||||
|
}, {
|
||||||
|
icon: 'i-lucide-book-open',
|
||||||
|
label: 'Nuxt UI Pro docs',
|
||||||
|
to: 'https://ui.nuxt.com/getting-started/installation/pro/nuxt',
|
||||||
|
target: '_blank'
|
||||||
|
}, {
|
||||||
|
icon: 'i-simple-icons-nuxtdotjs',
|
||||||
|
label: 'Purchase a license',
|
||||||
|
to: 'https://ui.nuxt.com/pro/purchase',
|
||||||
|
target: '_blank'
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
51
app/app.vue
Normal file
51
app/app.vue
Normal file
@@ -0,0 +1,51 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
const { seo } = useAppConfig()
|
||||||
|
|
||||||
|
const { data: navigation } = await useAsyncData('navigation', () => queryCollectionNavigation('docs'))
|
||||||
|
const { data: files } = useLazyAsyncData('search', () => queryCollectionSearchSections('docs'), {
|
||||||
|
server: false
|
||||||
|
})
|
||||||
|
|
||||||
|
useHead({
|
||||||
|
meta: [
|
||||||
|
{ name: 'viewport', content: 'width=device-width, initial-scale=1' }
|
||||||
|
],
|
||||||
|
link: [
|
||||||
|
{ rel: 'icon', href: '/favicon.ico' }
|
||||||
|
],
|
||||||
|
htmlAttrs: {
|
||||||
|
lang: 'en'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
useSeoMeta({
|
||||||
|
titleTemplate: `%s - ${seo?.siteName}`,
|
||||||
|
ogSiteName: seo?.siteName,
|
||||||
|
twitterCard: 'summary_large_image'
|
||||||
|
})
|
||||||
|
|
||||||
|
provide('navigation', navigation)
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UApp>
|
||||||
|
<NuxtLoadingIndicator />
|
||||||
|
|
||||||
|
<AppHeader />
|
||||||
|
|
||||||
|
<UMain>
|
||||||
|
<NuxtLayout>
|
||||||
|
<NuxtPage />
|
||||||
|
</NuxtLayout>
|
||||||
|
</UMain>
|
||||||
|
|
||||||
|
<AppFooter />
|
||||||
|
|
||||||
|
<ClientOnly>
|
||||||
|
<LazyUContentSearch
|
||||||
|
:files="files"
|
||||||
|
:navigation="navigation"
|
||||||
|
/>
|
||||||
|
</ClientOnly>
|
||||||
|
</UApp>
|
||||||
|
</template>
|
20
app/assets/css/main.css
Normal file
20
app/assets/css/main.css
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
|
||||||
|
@source "../../../content/**/*";
|
||||||
|
|
||||||
|
@theme static {
|
||||||
|
--font-sans: 'Public Sans', sans-serif;
|
||||||
|
|
||||||
|
--color-green-50: #EFFDF5;
|
||||||
|
--color-green-100: #D9FBE8;
|
||||||
|
--color-green-200: #B3F5D1;
|
||||||
|
--color-green-300: #75EDAE;
|
||||||
|
--color-green-400: #00DC82;
|
||||||
|
--color-green-500: #00C16A;
|
||||||
|
--color-green-600: #00A155;
|
||||||
|
--color-green-700: #007F45;
|
||||||
|
--color-green-800: #016538;
|
||||||
|
--color-green-900: #0A5331;
|
||||||
|
--color-green-950: #052E16;
|
||||||
|
}
|
23
app/components/AppFooter.vue
Normal file
23
app/components/AppFooter.vue
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
const { footer } = useAppConfig()
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UFooter>
|
||||||
|
<template #left>
|
||||||
|
{{ footer.credits }}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #right>
|
||||||
|
<UColorModeButton v-if="footer?.colorMode" />
|
||||||
|
|
||||||
|
<template v-if="footer?.links">
|
||||||
|
<UButton
|
||||||
|
v-for="(link, index) of footer?.links"
|
||||||
|
:key="index"
|
||||||
|
v-bind="{ color: 'neutral', variant: 'ghost', ...link }"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</template>
|
||||||
|
</UFooter>
|
||||||
|
</template>
|
72
app/components/AppHeader.vue
Normal file
72
app/components/AppHeader.vue
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import type { ContentNavigationItem } from '@nuxt/content'
|
||||||
|
|
||||||
|
const navigation = inject<Ref<ContentNavigationItem[]>>('navigation')
|
||||||
|
|
||||||
|
const { header } = useAppConfig()
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UHeader
|
||||||
|
:ui="{ center: 'flex-1' }"
|
||||||
|
:to="header?.to || '/'"
|
||||||
|
>
|
||||||
|
<UContentSearchButton
|
||||||
|
v-if="header?.search"
|
||||||
|
:collapsed="false"
|
||||||
|
class="w-full"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<template
|
||||||
|
v-if="header?.logo?.dark || header?.logo?.light || header?.title"
|
||||||
|
#title
|
||||||
|
>
|
||||||
|
<UColorModeImage
|
||||||
|
v-if="header?.logo?.dark || header?.logo?.light"
|
||||||
|
:light="header?.logo?.light!"
|
||||||
|
:dark="header?.logo?.dark!"
|
||||||
|
:alt="header?.logo?.alt"
|
||||||
|
class="h-6 w-auto shrink-0"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<span v-else-if="header?.title">
|
||||||
|
{{ header.title }}
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template
|
||||||
|
v-else
|
||||||
|
#left
|
||||||
|
>
|
||||||
|
<NuxtLink :to="header?.to || '/'">
|
||||||
|
<LogoPro class="w-auto h-6 shrink-0" />
|
||||||
|
</NuxtLink>
|
||||||
|
|
||||||
|
<TemplateMenu />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #right>
|
||||||
|
<UContentSearchButton
|
||||||
|
v-if="header?.search"
|
||||||
|
class="lg:hidden"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<UColorModeButton v-if="header?.colorMode" />
|
||||||
|
|
||||||
|
<template v-if="header?.links">
|
||||||
|
<UButton
|
||||||
|
v-for="(link, index) of header.links"
|
||||||
|
:key="index"
|
||||||
|
v-bind="{ color: 'neutral', variant: 'ghost', ...link }"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #body>
|
||||||
|
<UContentNavigation
|
||||||
|
highlight
|
||||||
|
:navigation="navigation"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</UHeader>
|
||||||
|
</template>
|
52
app/components/LogoPro.vue
Normal file
52
app/components/LogoPro.vue
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
<template>
|
||||||
|
<svg
|
||||||
|
width="1352"
|
||||||
|
height="200"
|
||||||
|
viewBox="0 0 1352 200"
|
||||||
|
fill="none"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
>
|
||||||
|
<path
|
||||||
|
d="M377 200C379.16 200 381 198.209 381 196V103C381 103 386 112 395 127L434 194C435.785 197.74 439.744 200 443 200H470V50H443C441.202 50 439 51.4941 439 54V148L421 116L385 55C383.248 51.8912 379.479 50 376 50H350V200H377Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M726 92H739C742.314 92 745 89.3137 745 86V60H773V92H800V116H773V159C773 169.5 778.057 174 787 174H800V200H783C759.948 200 745 185.071 745 160V116H726V92Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M591 92V154C591 168.004 585.742 179.809 578 188C570.258 196.191 559.566 200 545 200C530.434 200 518.742 196.191 511 188C503.389 179.809 498 168.004 498 154V92H514C517.412 92 520.769 92.622 523 95C525.231 97.2459 526 98.5652 526 102V154C526 162.059 526.457 167.037 530 171C533.543 174.831 537.914 176 545 176C552.217 176 555.457 174.831 559 171C562.543 167.037 563 162.059 563 154V102C563 98.5652 563.769 96.378 566 94C567.96 91.9107 570.028 91.9599 573 92C573.411 92.0055 574.586 92 575 92H591Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M676 144L710 92H684C680.723 92 677.812 93.1758 676 96L660 120L645 97C643.188 94.1758 639.277 92 636 92H611L645 143L608 200H634C637.25 200 640.182 196.787 642 194L660 167L679 195C680.818 197.787 683.75 200 687 200H713L676 144Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M168 200H279C282.542 200 285.932 198.756 289 197C292.068 195.244 295.23 193.041 297 190C298.77 186.959 300.002 183.51 300 179.999C299.998 176.488 298.773 173.04 297 170.001L222 41C220.23 37.96 218.067 35.7552 215 34C211.933 32.2448 207.542 31 204 31C200.458 31 197.067 32.2448 194 34C190.933 35.7552 188.77 37.96 187 41L168 74L130 9.99764C128.228 6.95784 126.068 3.75491 123 2C119.932 0.245087 116.542 0 113 0C109.458 0 106.068 0.245087 103 2C99.9323 3.75491 96.7717 6.95784 95 9.99764L2 170.001C0.226979 173.04 0.00154312 176.488 1.90993e-06 179.999C-0.0015393 183.51 0.229648 186.959 2 190C3.77035 193.04 6.93245 195.244 10 197C13.0675 198.756 16.4578 200 20 200H90C117.737 200 137.925 187.558 152 164L186 105L204 74L259 168H186L168 200ZM89 168H40L113 42L150 105L125.491 147.725C116.144 163.01 105.488 168 89 168Z"
|
||||||
|
fill="var(--ui-primary)"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M958 60.0001H938C933.524 60.0001 929.926 59.9395 927 63C924.074 65.8905 925 67.5792 925 72V141C925 151.372 923.648 156.899 919 162C914.352 166.931 908.468 169 899 169C889.705 169 882.648 166.931 878 162C873.352 156.899 873 151.372 873 141V72.0001C873 67.5793 872.926 65.8906 870 63.0001C867.074 59.9396 863.476 60.0001 859 60.0001H840V141C840 159.023 845.016 173.458 855 184C865.156 194.542 879.893 200 899 200C918.107 200 932.844 194.542 943 184C953.156 173.458 958 159.023 958 141V60.0001Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
fill-rule="evenodd"
|
||||||
|
clip-rule="evenodd"
|
||||||
|
d="M1000 60.0233L1020 60V77L1020 128V156.007L1020 181L1020 189.004C1020 192.938 1019.98 194.429 1017 197.001C1014.02 199.725 1009.56 200 1005 200H986.001V181.006L986 130.012V70.0215C986 66.1576 986.016 64.5494 989 62.023C991.819 59.6358 995.437 60.0233 1000 60.0233Z"
|
||||||
|
fill="currentColor"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M1060 200V60H1117C1126.67 60 1134.98 61.2896 1142 65C1149.16 68.7104 1155.29 74.3744 1159 81C1162.71 87.6256 1164 95.3867 1164 104C1164 112.481 1162.71 120.374 1159 127C1155.29 133.626 1149.16 138.157 1142 142C1134.98 145.71 1126.67 148 1117 148H1090V200H1060ZM1115 123C1121.63 123 1126.69 121.578 1130 118C1133.31 114.29 1135 109.433 1135 104C1135 98.567 1133.31 93.5778 1130 90C1126.69 86.2896 1121.63 85 1115 85H1090V123H1115Z"
|
||||||
|
fill="var(--ui-primary)"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M1226 123C1219.37 123 1214.31 124.965 1211 130C1207.69 135.035 1206 142.122 1206 151V200H1178V100H1200C1203.31 100 1206 102.686 1206 106V116C1208.65 109.904 1211.16 106.518 1215 104C1218.98 101.482 1224.77 100 1231 100H1242V123H1226Z"
|
||||||
|
fill="var(--ui-primary)"
|
||||||
|
/>
|
||||||
|
<path
|
||||||
|
d="M1299 200C1288.93 200 1280.08 197.373 1272 193C1263.92 188.495 1257.51 182.818 1253 175C1248.49 167.049 1246 157.806 1246 148C1246 138.194 1248.49 129.818 1253 122C1257.51 114.049 1263.92 107.373 1272 103C1280.08 98.4946 1288.93 97 1299 97C1309.07 97 1318.92 98.4946 1327 103C1335.08 107.373 1340.49 114.049 1345 122C1349.51 129.818 1352 138.194 1352 148C1352 157.806 1349.51 167.049 1345 175C1340.49 182.818 1335.08 188.495 1327 193C1318.92 197.373 1309.07 200 1299 200ZM1299 176C1306.42 176 1312.36 173.168 1317 168C1321.64 162.832 1324 156.216 1324 148C1324 139.652 1321.64 133.168 1317 128C1312.36 122.832 1306.42 120 1299 120C1291.58 120 1285.64 122.832 1281 128C1276.36 133.168 1274 139.652 1274 148C1274 156.216 1276.36 162.832 1281 168C1285.64 173.168 1291.58 176 1299 176Z"
|
||||||
|
fill="var(--ui-primary)"
|
||||||
|
/>
|
||||||
|
</svg>
|
||||||
|
</template>
|
76
app/components/OgImage/OgImageDocs.vue
Normal file
76
app/components/OgImage/OgImageDocs.vue
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
<script lang="ts" setup>
|
||||||
|
const props = withDefaults(defineProps<{ title?: string, description?: string, headline?: string }>(), {
|
||||||
|
title: 'title',
|
||||||
|
description: 'description'
|
||||||
|
})
|
||||||
|
|
||||||
|
const title = computed(() => (props.title || '').slice(0, 60))
|
||||||
|
const description = computed(() => (props.description || '').slice(0, 200))
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div class="w-full h-full flex flex-col justify-center bg-[#020420]">
|
||||||
|
<svg
|
||||||
|
class="absolute right-0 top-0"
|
||||||
|
width="629"
|
||||||
|
height="593"
|
||||||
|
viewBox="0 0 629 593"
|
||||||
|
fill="none"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
>
|
||||||
|
<g filter="url(#filter0_f_199_94966)">
|
||||||
|
<path
|
||||||
|
d="M628.5 -578L639.334 -94.4223L806.598 -548.281L659.827 -87.387L965.396 -462.344L676.925 -74.0787L1087.69 -329.501L688.776 -55.9396L1160.22 -164.149L694.095 -34.9354L1175.13 15.7948L692.306 -13.3422L1130.8 190.83L683.602 6.50012L1032.04 341.989L668.927 22.4412L889.557 452.891L649.872 32.7537L718.78 511.519L628.5 36.32L538.22 511.519L607.128 32.7537L367.443 452.891L588.073 22.4412L224.955 341.989L573.398 6.50012L126.198 190.83L564.694 -13.3422L81.8734 15.7948L562.905 -34.9354L96.7839 -164.149L568.224 -55.9396L169.314 -329.501L580.075 -74.0787L291.604 -462.344L597.173 -87.387L450.402 -548.281L617.666 -94.4223L628.5 -578Z"
|
||||||
|
fill="#00DC82"
|
||||||
|
/>
|
||||||
|
</g>
|
||||||
|
<defs>
|
||||||
|
<filter
|
||||||
|
id="filter0_f_199_94966"
|
||||||
|
x="0.873535"
|
||||||
|
y="-659"
|
||||||
|
width="1255.25"
|
||||||
|
height="1251.52"
|
||||||
|
filterUnits="userSpaceOnUse"
|
||||||
|
color-interpolation-filters="sRGB"
|
||||||
|
>
|
||||||
|
<feFlood
|
||||||
|
flood-opacity="0"
|
||||||
|
result="BackgroundImageFix"
|
||||||
|
/>
|
||||||
|
<feBlend
|
||||||
|
mode="normal"
|
||||||
|
in="SourceGraphic"
|
||||||
|
in2="BackgroundImageFix"
|
||||||
|
result="shape"
|
||||||
|
/>
|
||||||
|
<feGaussianBlur
|
||||||
|
stdDeviation="40.5"
|
||||||
|
result="effect1_foregroundBlur_199_94966"
|
||||||
|
/>
|
||||||
|
</filter>
|
||||||
|
</defs>
|
||||||
|
</svg>
|
||||||
|
|
||||||
|
<div class="pl-[100px]">
|
||||||
|
<p
|
||||||
|
v-if="headline"
|
||||||
|
class="uppercase text-[24px] text-[#00DC82] mb-4 font-semibold"
|
||||||
|
>
|
||||||
|
{{ headline }}
|
||||||
|
</p>
|
||||||
|
<h1
|
||||||
|
v-if="title"
|
||||||
|
class="m-0 text-[75px] font-semibold mb-4 text-white flex items-center"
|
||||||
|
>
|
||||||
|
<span>{{ title }}</span>
|
||||||
|
</h1>
|
||||||
|
<p
|
||||||
|
v-if="description"
|
||||||
|
class="text-[32px] text-[#E4E4E7] leading-tight w-[700px]"
|
||||||
|
>
|
||||||
|
{{ description }}
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
42
app/components/TemplateMenu.vue
Normal file
42
app/components/TemplateMenu.vue
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
<template>
|
||||||
|
<UDropdownMenu
|
||||||
|
v-slot="{ open }"
|
||||||
|
:modal="false"
|
||||||
|
:items="[{
|
||||||
|
label: 'Starter',
|
||||||
|
to: 'https://ui-pro-starter.nuxt.dev/'
|
||||||
|
}, {
|
||||||
|
label: 'Landing',
|
||||||
|
to: 'https://landing-template.nuxt.dev/'
|
||||||
|
}, {
|
||||||
|
label: 'Docs',
|
||||||
|
to: 'https://docs-template.nuxt.dev/',
|
||||||
|
color: 'primary',
|
||||||
|
checked: true,
|
||||||
|
type: 'checkbox'
|
||||||
|
}, {
|
||||||
|
label: 'SaaS',
|
||||||
|
to: 'https://saas-template.nuxt.dev/'
|
||||||
|
}, {
|
||||||
|
label: 'Dashboard',
|
||||||
|
to: 'https://dashboard-template.nuxt.dev/'
|
||||||
|
}, {
|
||||||
|
label: 'Chat',
|
||||||
|
to: 'https://chat-template.nuxt.dev/'
|
||||||
|
}]"
|
||||||
|
:ui="{ content: 'w-(--reka-dropdown-menu-trigger-width) min-w-0' }"
|
||||||
|
size="xs"
|
||||||
|
>
|
||||||
|
<UButton
|
||||||
|
label="Docs"
|
||||||
|
variant="subtle"
|
||||||
|
trailing-icon="i-lucide-chevron-down"
|
||||||
|
size="xs"
|
||||||
|
class="-mb-[6px] font-semibold rounded-full truncate"
|
||||||
|
:class="[open && 'bg-primary/15']"
|
||||||
|
:ui="{
|
||||||
|
trailingIcon: ['transition-transform duration-200', open ? 'rotate-180' : undefined].filter(Boolean).join(' ')
|
||||||
|
}"
|
||||||
|
/>
|
||||||
|
</UDropdownMenu>
|
||||||
|
</template>
|
42
app/error.vue
Normal file
42
app/error.vue
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import type { NuxtError } from '#app'
|
||||||
|
|
||||||
|
defineProps<{
|
||||||
|
error: NuxtError
|
||||||
|
}>()
|
||||||
|
|
||||||
|
useHead({
|
||||||
|
htmlAttrs: {
|
||||||
|
lang: 'en'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
useSeoMeta({
|
||||||
|
title: 'Page not found',
|
||||||
|
description: 'We are sorry but this page could not be found.'
|
||||||
|
})
|
||||||
|
|
||||||
|
const { data: navigation } = await useAsyncData('navigation', () => queryCollectionNavigation('docs'))
|
||||||
|
const { data: files } = useLazyAsyncData('search', () => queryCollectionSearchSections('docs'), {
|
||||||
|
server: false
|
||||||
|
})
|
||||||
|
|
||||||
|
provide('navigation', navigation)
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UApp>
|
||||||
|
<AppHeader />
|
||||||
|
|
||||||
|
<UError :error="error" />
|
||||||
|
|
||||||
|
<AppFooter />
|
||||||
|
|
||||||
|
<ClientOnly>
|
||||||
|
<LazyUContentSearch
|
||||||
|
:files="files"
|
||||||
|
:navigation="navigation"
|
||||||
|
/>
|
||||||
|
</ClientOnly>
|
||||||
|
</UApp>
|
||||||
|
</template>
|
22
app/layouts/docs.vue
Normal file
22
app/layouts/docs.vue
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import type { ContentNavigationItem } from '@nuxt/content'
|
||||||
|
|
||||||
|
const navigation = inject<Ref<ContentNavigationItem[]>>('navigation')
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UContainer>
|
||||||
|
<UPage>
|
||||||
|
<template #left>
|
||||||
|
<UPageAside>
|
||||||
|
<UContentNavigation
|
||||||
|
highlight
|
||||||
|
:navigation="navigation"
|
||||||
|
/>
|
||||||
|
</UPageAside>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<slot />
|
||||||
|
</UPage>
|
||||||
|
</UContainer>
|
||||||
|
</template>
|
105
app/pages/[...slug].vue
Normal file
105
app/pages/[...slug].vue
Normal file
@@ -0,0 +1,105 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import type { ContentNavigationItem } from '@nuxt/content'
|
||||||
|
import { findPageHeadline } from '#ui-pro/utils/content'
|
||||||
|
|
||||||
|
definePageMeta({
|
||||||
|
layout: 'docs'
|
||||||
|
})
|
||||||
|
|
||||||
|
const route = useRoute()
|
||||||
|
const { toc } = useAppConfig()
|
||||||
|
const navigation = inject<Ref<ContentNavigationItem[]>>('navigation')
|
||||||
|
|
||||||
|
const { data: page } = await useAsyncData(route.path, () => queryCollection('docs').path(route.path).first())
|
||||||
|
if (!page.value) {
|
||||||
|
throw createError({ statusCode: 404, statusMessage: 'Page not found', fatal: true })
|
||||||
|
}
|
||||||
|
|
||||||
|
const { data: surround } = await useAsyncData(`${route.path}-surround`, () => {
|
||||||
|
return queryCollectionItemSurroundings('docs', route.path, {
|
||||||
|
fields: ['description']
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
const title = page.value.seo?.title || page.value.title
|
||||||
|
const description = page.value.seo?.description || page.value.description
|
||||||
|
|
||||||
|
useSeoMeta({
|
||||||
|
title,
|
||||||
|
ogTitle: title,
|
||||||
|
description,
|
||||||
|
ogDescription: description
|
||||||
|
})
|
||||||
|
|
||||||
|
const headline = computed(() => findPageHeadline(navigation?.value, page.value))
|
||||||
|
|
||||||
|
defineOgImageComponent('Docs', {
|
||||||
|
headline: headline.value
|
||||||
|
})
|
||||||
|
|
||||||
|
const links = computed(() => {
|
||||||
|
const links = []
|
||||||
|
if (toc?.bottom?.edit) {
|
||||||
|
links.push({
|
||||||
|
icon: 'i-lucide-external-link',
|
||||||
|
label: 'Edit this page',
|
||||||
|
to: `${toc.bottom.edit}/${page?.value?.stem}.${page?.value?.extension}`,
|
||||||
|
target: '_blank'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
return [...links, ...(toc?.bottom?.links || [])].filter(Boolean)
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<UPage v-if="page">
|
||||||
|
<UPageHeader
|
||||||
|
:title="page.title"
|
||||||
|
:description="page.description"
|
||||||
|
:links="page.links"
|
||||||
|
:headline="headline"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<UPageBody>
|
||||||
|
<ContentRenderer
|
||||||
|
v-if="page"
|
||||||
|
:value="page"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<USeparator v-if="surround?.length" />
|
||||||
|
|
||||||
|
<UContentSurround :surround="surround" />
|
||||||
|
</UPageBody>
|
||||||
|
|
||||||
|
<template
|
||||||
|
v-if="page?.body?.toc?.links?.length"
|
||||||
|
#right
|
||||||
|
>
|
||||||
|
<UContentToc
|
||||||
|
:title="toc?.title"
|
||||||
|
:links="page.body?.toc?.links"
|
||||||
|
>
|
||||||
|
<template
|
||||||
|
v-if="toc?.bottom"
|
||||||
|
#bottom
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
class="hidden lg:block space-y-6"
|
||||||
|
:class="{ '!mt-6': page.body?.toc?.links?.length }"
|
||||||
|
>
|
||||||
|
<USeparator
|
||||||
|
v-if="page.body?.toc?.links?.length"
|
||||||
|
type="dashed"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<UPageLinks
|
||||||
|
:title="toc.bottom.title"
|
||||||
|
:links="links"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</UContentToc>
|
||||||
|
</template>
|
||||||
|
</UPage>
|
||||||
|
</template>
|
27
app/pages/index.vue
Normal file
27
app/pages/index.vue
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
const { data: page } = await useAsyncData('index', () => queryCollection('landing').path('/').first())
|
||||||
|
if (!page.value) {
|
||||||
|
throw createError({ statusCode: 404, statusMessage: 'Page not found', fatal: true })
|
||||||
|
}
|
||||||
|
|
||||||
|
const title = page.value.seo?.title || page.value.title
|
||||||
|
const description = page.value.seo?.description || page.value.description
|
||||||
|
|
||||||
|
useSeoMeta({
|
||||||
|
titleTemplate: '',
|
||||||
|
title,
|
||||||
|
ogTitle: title,
|
||||||
|
description,
|
||||||
|
ogDescription: description,
|
||||||
|
ogImage: 'https://assets.hub.nuxt.com/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RvY3MtdGVtcGxhdGUubnV4dC5kZXYiLCJpYXQiOjE3Mzk0NjM0MTd9.ltVAqPgKG38O01X1zl6MXfrJc55nf9OewXNFjpZ_2JY.jpg?theme=light',
|
||||||
|
twitterImage: 'https://assets.hub.nuxt.com/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RvY3MtdGVtcGxhdGUubnV4dC5kZXYiLCJpYXQiOjE3Mzk0NjM0MTd9.ltVAqPgKG38O01X1zl6MXfrJc55nf9OewXNFjpZ_2JY.jpg?theme=light'
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<ContentRenderer
|
||||||
|
v-if="page"
|
||||||
|
:value="page"
|
||||||
|
:prose="false"
|
||||||
|
/>
|
||||||
|
</template>
|
25
content.config.ts
Normal file
25
content.config.ts
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
import { defineContentConfig, defineCollection, z } from '@nuxt/content'
|
||||||
|
|
||||||
|
export default defineContentConfig({
|
||||||
|
collections: {
|
||||||
|
landing: defineCollection({
|
||||||
|
type: 'page',
|
||||||
|
source: 'index.md'
|
||||||
|
}),
|
||||||
|
docs: defineCollection({
|
||||||
|
type: 'page',
|
||||||
|
source: {
|
||||||
|
include: '**',
|
||||||
|
exclude: ['index.md']
|
||||||
|
},
|
||||||
|
schema: z.object({
|
||||||
|
links: z.array(z.object({
|
||||||
|
label: z.string(),
|
||||||
|
icon: z.string(),
|
||||||
|
to: z.string(),
|
||||||
|
target: z.string().optional()
|
||||||
|
})).optional()
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
2
content/1.getting-started/.navigation.yml
Normal file
2
content/1.getting-started/.navigation.yml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
title: Getting Started
|
||||||
|
icon: false
|
86
content/1.getting-started/1.index.md
Normal file
86
content/1.getting-started/1.index.md
Normal file
@@ -0,0 +1,86 @@
|
|||||||
|
---
|
||||||
|
title: Introduction
|
||||||
|
description: Welcome to Nuxt UI Pro documentation template.
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-house
|
||||||
|
---
|
||||||
|
|
||||||
|
This template is a ready-to-use documentation template made with [Nuxt UI Pro](https://ui.nuxt.com/pro), a collection of premium components built on top of [Nuxt UI](https://ui.nuxt.com) to create beautiful & responsive Nuxt applications in minutes.
|
||||||
|
|
||||||
|
There are already many websites based on this template:
|
||||||
|
|
||||||
|
::card-group
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt
|
||||||
|
to: https://nuxt.com
|
||||||
|
---
|
||||||
|
The Nuxt website
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt UI
|
||||||
|
to: https://ui.nuxt.com
|
||||||
|
---
|
||||||
|
The documentation of `@nuxt/ui` and `@nuxt/ui-pro`
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt Image
|
||||||
|
to: https://image.nuxt.com
|
||||||
|
---
|
||||||
|
The documentation of `@nuxt/image`
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt Content
|
||||||
|
to: https://content.nuxt.com
|
||||||
|
---
|
||||||
|
The documentation of `@nuxt/content`
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt Devtools
|
||||||
|
to: https://devtools.nuxt.com
|
||||||
|
---
|
||||||
|
The documentation of `@nuxt/devtools`
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
title: Nuxt Hub
|
||||||
|
to: https://hub.nuxt.com
|
||||||
|
---
|
||||||
|
The best place to manage your projects, environments and variables.
|
||||||
|
:::
|
||||||
|
::
|
||||||
|
|
||||||
|
## Key Features
|
||||||
|
|
||||||
|
This template includes a range of features designed to streamline documentation management:
|
||||||
|
|
||||||
|
- **Powered by** [**Nuxt 3**](https://nuxt.com): Utilizes the latest Nuxt framework for optimal performance.
|
||||||
|
- **Built with** [**Nuxt UI**](https://ui.nuxt.com) **and** [**Nuxt UI Pro**](https://ui.nuxt.com/pro): Integrates a comprehensive suite of UI components.
|
||||||
|
- [**MDC Syntax**](https://content.nuxt.com/usage/markdown) **via** [**Nuxt Content**](https://content.nuxt.com): Supports Markdown with component integration for dynamic content.
|
||||||
|
- [**Nuxt Studio**](https://content.nuxt.com/docs/studio) **Compatible**: Offers integration with Nuxt Studio for content editing.
|
||||||
|
- **Auto-generated Sidebar Navigation**: Automatically generates navigation from content structure.
|
||||||
|
- **Full-Text Search**: Includes built-in search functionality for content discovery.
|
||||||
|
- **Optimized Typography**: Features refined typography for enhanced readability.
|
||||||
|
- **Dark Mode**: Offers dark mode support for user preference.
|
||||||
|
- **Extensive Functionality**: Explore the template to fully appreciate its capabilities.
|
29
content/1.getting-started/2.installation.md
Normal file
29
content/1.getting-started/2.installation.md
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
---
|
||||||
|
title: Installation
|
||||||
|
description: Get started with Nuxt UI Pro documentation template.
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-download
|
||||||
|
---
|
||||||
|
|
||||||
|
::tip{target="_blank" to="https://content.nuxt.com/templates/docs"}
|
||||||
|
Use this template on Nuxt Studio and start your documentation in seconds.
|
||||||
|
::
|
||||||
|
|
||||||
|
## Quick Start
|
||||||
|
|
||||||
|
You can start a fresh new project with:
|
||||||
|
|
||||||
|
```bash [Terminal]
|
||||||
|
npx nuxi init -t github:nuxt-ui-pro/docs
|
||||||
|
```
|
||||||
|
|
||||||
|
or create a new repository from GitHub:
|
||||||
|
|
||||||
|
1. Open <https://github.com/nuxt-ui-pro/docs>
|
||||||
|
2. Click on `Use this template` button
|
||||||
|
3. Enter repository name and click on `Create repository from template` button
|
||||||
|
4. Clone your new repository
|
||||||
|
5. Install dependencies with your favorite package manager
|
||||||
|
6. Start development server
|
||||||
|
|
||||||
|
That's it! You can now start writing your documentation in the [`content/`](https://content.nuxt.com/usage/content-directory) directory 🚀
|
127
content/1.getting-started/3.usage.md
Normal file
127
content/1.getting-started/3.usage.md
Normal file
@@ -0,0 +1,127 @@
|
|||||||
|
---
|
||||||
|
title: Usage
|
||||||
|
description: Learn how to write and customize your documentation.
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-sliders
|
||||||
|
---
|
||||||
|
|
||||||
|
This is only a basic example of what you can achieve with [Nuxt UI Pro](https://ui.nuxt.com/pro/guide), you can tweak it to match your needs. The template uses several Nuxt modules underneath like [`@nuxt/content`](https://content.nuxt.com) for the content and [`nuxt-og-image`](https://nuxtseo.com/og-image/getting-started/installation) for social previews.
|
||||||
|
|
||||||
|
::tip
|
||||||
|
---
|
||||||
|
target: _blank
|
||||||
|
to: https://ui.nuxt.com/getting-started/installation/pro/nuxt
|
||||||
|
---
|
||||||
|
Learn more on how to take the most out of Nuxt UI Pro!
|
||||||
|
::
|
||||||
|
|
||||||
|
## Writing content
|
||||||
|
|
||||||
|
You can just start writing `.md` or `.yml` files in the [`content/`](https://content.nuxt.com/usage/content-directory) directory to have your pages updated. The navigation will be automatically generated in the left aside and in the mobile menu. You will also be able to go through your content with full-text search.
|
||||||
|
|
||||||
|
## App Configuration
|
||||||
|
|
||||||
|
In addition to `@nuxt/ui-pro` configuration through the `app.config.ts`, this template lets you customize the `Header`, `Footer` and the `Table of contents` components.
|
||||||
|
|
||||||
|
### Header
|
||||||
|
|
||||||
|
```ts [app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
header: {
|
||||||
|
title: '',
|
||||||
|
to: '/',
|
||||||
|
// Logo configuration
|
||||||
|
logo: {
|
||||||
|
alt: '',
|
||||||
|
// Light mode
|
||||||
|
light: '',
|
||||||
|
// Dark mode
|
||||||
|
dark: ''
|
||||||
|
},
|
||||||
|
// Show or hide the search bar
|
||||||
|
search: true,
|
||||||
|
// Show or hide the color mode button
|
||||||
|
colorMode: true,
|
||||||
|
// Customize links
|
||||||
|
links: [{
|
||||||
|
'icon': 'i-simple-icons-github',
|
||||||
|
'to': 'https://github.com/nuxt-ui-pro/docs',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'GitHub'
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
### Footer
|
||||||
|
|
||||||
|
```ts [app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
footer: {
|
||||||
|
// Update bottom left credits
|
||||||
|
credits: `Copyright © ${new Date().getFullYear()}`,
|
||||||
|
// Show or hide the color mode button
|
||||||
|
colorMode: false,
|
||||||
|
// Customize links
|
||||||
|
links: [{
|
||||||
|
'icon': 'i-simple-icons-nuxtdotjs',
|
||||||
|
'to': 'https://nuxt.com',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt Website'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-discord',
|
||||||
|
'to': 'https://discord.com/invite/ps2h6QT',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt UI on Discord'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-x',
|
||||||
|
'to': 'https://x.com/nuxt_js',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt on X'
|
||||||
|
}, {
|
||||||
|
'icon': 'i-simple-icons-github',
|
||||||
|
'to': 'https://github.com/nuxt/ui',
|
||||||
|
'target': '_blank',
|
||||||
|
'aria-label': 'Nuxt UI on GitHub'
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
### Table of contents
|
||||||
|
|
||||||
|
```ts [app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
toc: {
|
||||||
|
// Title of the main table of contents
|
||||||
|
title: 'Table of Contents',
|
||||||
|
// Customize links
|
||||||
|
bottom: {
|
||||||
|
// Title of the bottom table of contents
|
||||||
|
title: 'Community',
|
||||||
|
// URL of your repository content folder
|
||||||
|
edit: 'https://github.com/nuxt-ui-pro/docs/edit/main/content',
|
||||||
|
links: [{
|
||||||
|
icon: 'i-lucide-star',
|
||||||
|
label: 'Star on GitHub',
|
||||||
|
to: 'https://github.com/nuxt/ui',
|
||||||
|
target: '_blank'
|
||||||
|
}, {
|
||||||
|
icon: 'i-lucide-book-open',
|
||||||
|
label: 'Nuxt UI Pro docs',
|
||||||
|
to: 'https://ui.nuxt.com/getting-started/installation/pro/nuxt',
|
||||||
|
target: '_blank'
|
||||||
|
}, {
|
||||||
|
icon: 'i-simple-icons-nuxtdotjs',
|
||||||
|
label: 'Purchase a license',
|
||||||
|
to: 'https://ui.nuxt.com/pro/purchase',
|
||||||
|
target: '_blank'
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
::tip{target="_blank" to="https://content.nuxt.com/docs/studio/config"}
|
||||||
|
This template integrates with Nuxt Studio, providing a visual interface for editing your documentation - perfect for non-technical contributors.
|
||||||
|
::
|
1
content/2.essentials/.navigation.yml
Normal file
1
content/2.essentials/.navigation.yml
Normal file
@@ -0,0 +1 @@
|
|||||||
|
title: Essentials
|
230
content/2.essentials/1.markdown-syntax.md
Normal file
230
content/2.essentials/1.markdown-syntax.md
Normal file
@@ -0,0 +1,230 @@
|
|||||||
|
---
|
||||||
|
title: Markdown Syntax
|
||||||
|
description: Text, title, and styling in standard markdown.
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-heading-1
|
||||||
|
---
|
||||||
|
|
||||||
|
## Titles
|
||||||
|
|
||||||
|
Use titles to introduce main sections. They structure your documentation and help users navigate content.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
## Titles
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
## Titles
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Subtitles
|
||||||
|
|
||||||
|
Use subtitles to divide sections further. They create a more detailed content hierarchy for better readability.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
### Subtitles
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
### Subtitles
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
::tip
|
||||||
|
Each title and subtitle creates an anchor and shows up automatically in the table of contents.
|
||||||
|
::
|
||||||
|
|
||||||
|
## Text Formatting
|
||||||
|
|
||||||
|
Nuxt UI Pro supports most Markdown formatting options.
|
||||||
|
|
||||||
|
| Style | How to use | Result |
|
||||||
|
| ------ | ------------ | ---------- |
|
||||||
|
| Bold | `**bold**` | **Bold** |
|
||||||
|
| Italic | `*italic*` | *Italic* |
|
||||||
|
| Strike | `~~strike~~` | ~~Strike~~ |
|
||||||
|
|
||||||
|
Combine formatting for richer text styles and visual emphasis.
|
||||||
|
|
||||||
|
| Style | How to use | Result |
|
||||||
|
| ------------- | ------------------- | ----------------- |
|
||||||
|
| Bold Italic | `**_bold italic_**` | ***Bold Italic*** |
|
||||||
|
| Bold Strike | `~~**bold**~~` | ~~**Bold**~~ |
|
||||||
|
| Italic Strike | `~~*italic*~~` | ~~*Italic*~~ |
|
||||||
|
|
||||||
|
For exponents, indices, or mathematical notations, use HTML `<sup>` and `<sub>` tags.
|
||||||
|
|
||||||
|
| Style | How to use | Result |
|
||||||
|
| ----------- | ------------------------ | ----------- |
|
||||||
|
| Superscript | `<sup>superscript</sup>` | superscript |
|
||||||
|
| Subscript | `<sub>subscript</sub>` | subscript |
|
||||||
|
|
||||||
|
## Links
|
||||||
|
|
||||||
|
Links connect different parts of your documentation and external resources, essential for user navigation and providing references.
|
||||||
|
To create a link, wrap the link text in brackets `[]()`.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
[Nuxt UI Pro](https://ui.nuxt.com/getting-started/installation/pro/nuxt)
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
[Nuxt UI Pro](https://ui.nuxt.com/getting-started/installation/pro/nuxt)
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Internal links
|
||||||
|
|
||||||
|
For linking within your documentation, use root-relative paths like `/getting-started/installation`.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
[Installation](/getting-started/installation)
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
[Installation](/getting-started/installation)
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
## Lists
|
||||||
|
|
||||||
|
Organize related items in a structured, readable format. Markdown supports unordered, ordered, and nested lists for various content needs.
|
||||||
|
|
||||||
|
### Unordered
|
||||||
|
|
||||||
|
Use unordered lists for items without a specific sequence. Start each item with a `-` symbol.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
- I'm a list item.
|
||||||
|
- I'm another list item.
|
||||||
|
- I'm the last list item.
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
- I'm a list item.
|
||||||
|
- I'm another list item.
|
||||||
|
- I'm the last list item.
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Ordered
|
||||||
|
|
||||||
|
Use ordered lists when item order matters, like steps in a process. Start each item with a number.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
1. I'm a list item.
|
||||||
|
2. I'm another list item.
|
||||||
|
3. I'm the last list item.
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
1. I'm a list item.
|
||||||
|
2. I'm another list item.
|
||||||
|
3. I'm the last list item.
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Nested
|
||||||
|
|
||||||
|
Create hierarchical lists with sub-items for complex structures. Indent sub-items by four spaces for nesting.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
- I'm a list item.
|
||||||
|
- I'm a nested list item.
|
||||||
|
- I'm another nested list item.
|
||||||
|
- I'm another list item.
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
- I'm a list item.
|
||||||
|
- I'm a nested list item.
|
||||||
|
- I'm another nested list item.
|
||||||
|
- I'm another list item.
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
## Tables
|
||||||
|
|
||||||
|
Present structured data in rows and columns clearly. Tables are ideal for comparing data or listing properties.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
| Prop | Default | Type |
|
||||||
|
| ------- | --------- | -------- |
|
||||||
|
| `name` | | `string` |
|
||||||
|
| `size` | `md` | `string` |
|
||||||
|
| `color` | `neutral` | `string` |
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
| Prop | Default | Type |
|
||||||
|
|---------|-----------|--------------------------|
|
||||||
|
| `name` | | `string`{lang="ts-type"} |
|
||||||
|
| `size` | `md` | `string`{lang="ts-type"} |
|
||||||
|
| `color` | `neutral` | `string`{lang="ts-type"} |
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
## Blockquotes
|
||||||
|
|
||||||
|
Highlight important quotations, citations, or emphasized text. Blockquotes visually distinguish quoted content.
|
||||||
|
|
||||||
|
### Singleline
|
||||||
|
|
||||||
|
Single-line blockquotes are best for short, impactful quotes or citations that fit within a single line. To create a single-line blockquote, add a `>` in front of a paragraph. Ideal for short and impactful quotes.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
> Nuxt UI Pro is a collection of Vue components, composables and utils built on top of Nuxt UI, oriented on structure and layout and designed to be used as building blocks for your app.
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
> Nuxt UI Pro is a collection of Vue components, composables and utils built on top of Nuxt UI, oriented on structure and layout and designed to be used as building blocks for your app.
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Multiline
|
||||||
|
|
||||||
|
Multi-line blockquotes are suitable for longer quotes or when you need to include multiple paragraphs within a single quotation.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
> Nuxt UI Pro is a collection of Vue components, composables and utils built on top of Nuxt UI, oriented on structure and layout and designed to be used as building blocks for your app.
|
||||||
|
>
|
||||||
|
> Create beautiful, responsive, and accessible Vue applications with Nuxt UI Pro.
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
> Nuxt UI Pro is a collection of Vue components, composables and utils built on top of Nuxt UI, oriented on structure and layout and designed to be used as building blocks for your app.
|
||||||
|
>
|
||||||
|
> Create beautiful, responsive, and accessible Vue applications with Nuxt UI Pro.
|
||||||
|
```
|
||||||
|
::
|
458
content/2.essentials/2.code-blocks.md
Normal file
458
content/2.essentials/2.code-blocks.md
Normal file
@@ -0,0 +1,458 @@
|
|||||||
|
---
|
||||||
|
title: Code Blocks
|
||||||
|
description: Display inline code and code blocks
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-code-xml
|
||||||
|
---
|
||||||
|
|
||||||
|
## Basic
|
||||||
|
|
||||||
|
### Inline Code
|
||||||
|
|
||||||
|
Use inline code to display code snippets within text paragraphs. It's ideal for referencing code elements directly in sentences.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
`inline code`
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
`inline code`
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Code Blocks
|
||||||
|
|
||||||
|
Use code blocks to display multi-line code snippets with syntax highlighting. Code blocks are essential for presenting code examples clearly.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
```ts
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
```ts
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
When writing a code-block, you can specify a filename that will be displayed on top of the code block. An icon will be automatically displayed based on the extension or the name.
|
||||||
|
Filenames help users understand the code's location and purpose within a project.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
::tip
|
||||||
|
Some icons are already defined by default, but you can add more in your `app.config.ts` through the `uiPro.prose.codeIcon` key:
|
||||||
|
|
||||||
|
```ts [app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
uiPro: {
|
||||||
|
prose: {
|
||||||
|
codeIcon: {
|
||||||
|
terminal: 'i-ph-terminal-window-duotone'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
Every code-block has a built-in copy button that will copy the code to your clipboard.
|
||||||
|
|
||||||
|
::tip
|
||||||
|
You can change the icon in your `app.config.ts` through the `ui.icons.copy` and `ui.icons.copyCheck` keys:
|
||||||
|
|
||||||
|
```ts [app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
ui: {
|
||||||
|
icons: {
|
||||||
|
copy: 'i-lucide-copy',
|
||||||
|
copyCheck: 'i-lucide-copy-check'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
#### Highlight Line
|
||||||
|
|
||||||
|
To highlight lines of code, add `{}` around the line numbers you want to highlight.
|
||||||
|
Line highlighting is useful for focusing users on important parts of code examples.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
ui: {
|
||||||
|
icons: {
|
||||||
|
copy: 'i-lucide-copy',
|
||||||
|
copyCheck: 'i-lucide-copy-check'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
```ts [nuxt.config.ts]{4-5}
|
||||||
|
export default defineAppConfig({
|
||||||
|
ui: {
|
||||||
|
icons: {
|
||||||
|
copy: 'i-lucide-copy',
|
||||||
|
copyCheck: 'i-lucide-copy-check'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
## Advanced
|
||||||
|
|
||||||
|
### CodeGroup
|
||||||
|
|
||||||
|
Group code blocks in tabs using `code-group`. `code-group` is perfect for showing code examples in multiple languages or package managers.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::code-group{.w-full}
|
||||||
|
```bash [pnpm]
|
||||||
|
pnpm add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [yarn]
|
||||||
|
yarn add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [npm]
|
||||||
|
npm install @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [bun]
|
||||||
|
bun add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
:::code-group
|
||||||
|
|
||||||
|
```bash [pnpm]
|
||||||
|
pnpm add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [yarn]
|
||||||
|
yarn add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [npm]
|
||||||
|
npm install @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash [bun]
|
||||||
|
bun add @nuxt/ui-pro@next
|
||||||
|
```
|
||||||
|
|
||||||
|
::
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
::note{to="#pre"}
|
||||||
|
Like the `ProsePre` component, the `CodeGroup` handles filenames, icons and copy button.
|
||||||
|
::
|
||||||
|
|
||||||
|
### CodeTree
|
||||||
|
|
||||||
|
Display code blocks in a file tree view using `code-tree`. `code-tree` is excellent for showcasing project structures and file relationships.
|
||||||
|
|
||||||
|
::code-preview{class="[&>div]:*:my-0 [&>div]:*:w-full"}
|
||||||
|
:::code-tree{default-value="app/app.config.ts"}
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro'],
|
||||||
|
|
||||||
|
future: {
|
||||||
|
compatibilityVersion: 4
|
||||||
|
},
|
||||||
|
|
||||||
|
css: ['~/assets/css/main.css']
|
||||||
|
})
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
```css [app/assets/css/main.css]
|
||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
```
|
||||||
|
|
||||||
|
```ts [app/app.config.ts]
|
||||||
|
export default defineAppConfig({
|
||||||
|
ui: {
|
||||||
|
colors: {
|
||||||
|
primary: 'sky',
|
||||||
|
colors: 'slate'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
```vue [app/app.vue]
|
||||||
|
<template>
|
||||||
|
<UApp>
|
||||||
|
<NuxtPage />
|
||||||
|
</UApp>
|
||||||
|
</template>
|
||||||
|
```
|
||||||
|
|
||||||
|
```json [package.json]
|
||||||
|
{
|
||||||
|
"name": "nuxt-app",
|
||||||
|
"private": true,
|
||||||
|
"type": "module",
|
||||||
|
"scripts": {
|
||||||
|
"build": "nuxt build",
|
||||||
|
"dev": "nuxt dev",
|
||||||
|
"generate": "nuxt generate",
|
||||||
|
"preview": "nuxt preview",
|
||||||
|
"postinstall": "nuxt prepare",
|
||||||
|
"lint": "eslint .",
|
||||||
|
"lint:fix": "eslint --fix ."
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"@iconify-json/lucide": "^1.2.18",
|
||||||
|
"@nuxt/ui-pro": "3.0.0-alpha.10",
|
||||||
|
"nuxt": "^3.15.1"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"eslint": "9.20.1",
|
||||||
|
"typescript": "^5.7.2",
|
||||||
|
"vue-tsc": "^2.2.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
```json [tsconfig.json]
|
||||||
|
{
|
||||||
|
"extends": "./.nuxt/tsconfig.json"
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
````md [README.md]
|
||||||
|
# Nuxt 3 Minimal Starter
|
||||||
|
|
||||||
|
Look at the [Nuxt 3 documentation](https://nuxt.com/docs/getting-started/introduction) to learn more.
|
||||||
|
|
||||||
|
## Setup
|
||||||
|
|
||||||
|
Make sure to install the dependencies:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# npm
|
||||||
|
npm install
|
||||||
|
|
||||||
|
# pnpm
|
||||||
|
pnpm install
|
||||||
|
|
||||||
|
# yarn
|
||||||
|
yarn install
|
||||||
|
|
||||||
|
# bun
|
||||||
|
bun install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Development Server
|
||||||
|
|
||||||
|
Start the development server on `http://localhost:3000`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# npm
|
||||||
|
npm run dev
|
||||||
|
|
||||||
|
# pnpm
|
||||||
|
pnpm run dev
|
||||||
|
|
||||||
|
# yarn
|
||||||
|
yarn dev
|
||||||
|
|
||||||
|
# bun
|
||||||
|
bun run dev
|
||||||
|
```
|
||||||
|
|
||||||
|
## Production
|
||||||
|
|
||||||
|
Build the application for production:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# npm
|
||||||
|
npm run build
|
||||||
|
|
||||||
|
# pnpm
|
||||||
|
pnpm run build
|
||||||
|
|
||||||
|
# yarn
|
||||||
|
yarn build
|
||||||
|
|
||||||
|
# bun
|
||||||
|
bun run build
|
||||||
|
```
|
||||||
|
|
||||||
|
Locally preview production build:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# npm
|
||||||
|
npm run preview
|
||||||
|
|
||||||
|
# pnpm
|
||||||
|
pnpm run preview
|
||||||
|
|
||||||
|
# yarn
|
||||||
|
yarn preview
|
||||||
|
|
||||||
|
# bun
|
||||||
|
bun run preview
|
||||||
|
```
|
||||||
|
|
||||||
|
Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.
|
||||||
|
````
|
||||||
|
:::
|
||||||
|
::
|
||||||
|
|
||||||
|
::note
|
||||||
|
---
|
||||||
|
target: _blank
|
||||||
|
to: https://ui.nuxt.com/getting-started/typography#codetree
|
||||||
|
---
|
||||||
|
Learn more about the `code-tree` component.
|
||||||
|
::
|
||||||
|
|
||||||
|
### `CodePreview`
|
||||||
|
|
||||||
|
Use `code-preview` to show code output alongside the code. `code-preview` is ideal for interactive examples and demonstrating code results.
|
||||||
|
Write the code to be previewed in a the `default` slot and the actual code in the `code` slot.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
label: Preview
|
||||||
|
---
|
||||||
|
:::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
`inline code`
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
`inline code`
|
||||||
|
```
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
::code-preview
|
||||||
|
`inline code`
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
`inline code`
|
||||||
|
```
|
||||||
|
::
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
### `CodeCollapse`
|
||||||
|
|
||||||
|
Use `code-collapse` for long code blocks to keep pages clean. `code-collapse` allows users to expand code blocks only when needed, improving readability.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::code-collapse{class="[&>div]:my-0"}
|
||||||
|
```css [main.css]
|
||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
|
||||||
|
@theme {
|
||||||
|
--font-sans: 'Public Sans', sans-serif;
|
||||||
|
|
||||||
|
--breakpoint-3xl: 1920px;
|
||||||
|
|
||||||
|
--color-green-50: #EFFDF5;
|
||||||
|
--color-green-100: #D9FBE8;
|
||||||
|
--color-green-200: #B3F5D1;
|
||||||
|
--color-green-300: #75EDAE;
|
||||||
|
--color-green-400: #00DC82;
|
||||||
|
--color-green-500: #00C16A;
|
||||||
|
--color-green-600: #00A155;
|
||||||
|
--color-green-700: #007F45;
|
||||||
|
--color-green-800: #016538;
|
||||||
|
--color-green-900: #0A5331;
|
||||||
|
--color-green-950: #052E16;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
::code-collapse
|
||||||
|
|
||||||
|
```css [main.css]
|
||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
|
||||||
|
@theme {
|
||||||
|
--font-sans: 'Public Sans', sans-serif;
|
||||||
|
|
||||||
|
--breakpoint-3xl: 1920px;
|
||||||
|
|
||||||
|
--color-green-50: #EFFDF5;
|
||||||
|
--color-green-100: #D9FBE8;
|
||||||
|
--color-green-200: #B3F5D1;
|
||||||
|
--color-green-300: #75EDAE;
|
||||||
|
--color-green-400: #00DC82;
|
||||||
|
--color-green-500: #00C16A;
|
||||||
|
--color-green-600: #00A155;
|
||||||
|
--color-green-700: #007F45;
|
||||||
|
--color-green-800: #016538;
|
||||||
|
--color-green-900: #0A5331;
|
||||||
|
--color-green-950: #052E16;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
::
|
||||||
|
````
|
||||||
|
::
|
489
content/2.essentials/3.prose-components.md
Normal file
489
content/2.essentials/3.prose-components.md
Normal file
@@ -0,0 +1,489 @@
|
|||||||
|
---
|
||||||
|
title: Prose Components
|
||||||
|
description: Components to help you structure your content.
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-component
|
||||||
|
---
|
||||||
|
|
||||||
|
### Accordion
|
||||||
|
|
||||||
|
Use `accordion` and `accordion-item` to create collapsible content sections. Accordions are useful for organizing FAQs, expandable details, or grouped information in an interactive way.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
:::accordion
|
||||||
|
::::accordion-item
|
||||||
|
---
|
||||||
|
icon: i-lucide-circle-help
|
||||||
|
label: What are the main considerations when upgrading to Nuxt UI v3?
|
||||||
|
---
|
||||||
|
The transition to v3 involves significant changes, including new component structures, updated theming approaches, and revised TypeScript definitions. We recommend a careful, incremental upgrade process, starting with thorough testing in a development environment.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::accordion-item
|
||||||
|
---
|
||||||
|
icon: i-lucide-circle-help
|
||||||
|
label: Is Nuxt UI v3 compatible with standalone Vue projects?
|
||||||
|
---
|
||||||
|
Nuxt UI is now compatible with Vue! You can follow the [installation guide](/getting-started/installation) to get started.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::accordion-item{icon="i-lucide-circle-help" label="What about Nuxt UI Pro?"}
|
||||||
|
We've also rebuilt Nuxt UI Pro from scratch and released a `v3.0.0-alpha.x` package but it only contains the components to build this documentation yet. This will be a free update, so the license you buy now will be valid for v3. We're actively working to finish the rewrite of all Nuxt UI Pro components.
|
||||||
|
::::
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::accordion
|
||||||
|
|
||||||
|
:::accordion-item{label="What are the main considerations when upgrading to Nuxt UI v3?" icon="i-lucide-circle-help"}
|
||||||
|
The transition to v3 involves significant changes, including new component structures, updated theming approaches, and revised TypeScript definitions. We recommend a careful, incremental upgrade process, starting with thorough testing in a development environment.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::accordion-item{label="Is Nuxt UI v3 compatible with standalone Vue projects?" icon="i-lucide-circle-help"}
|
||||||
|
Nuxt UI is now compatible with Vue! You can follow the [installation guide](/getting-started/installation) to get started.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::accordion-item{label="What about Nuxt UI Pro?" icon="i-lucide-circle-help"}
|
||||||
|
We've also rebuilt Nuxt UI Pro from scratch and released a `v3.0.0-alpha.x` package but it only contains the components to build this documentation yet. This will be a free update, so the license you buy now will be valid for v3. We're actively working to finish the rewrite of all Nuxt UI Pro components.
|
||||||
|
:::
|
||||||
|
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Badge
|
||||||
|
|
||||||
|
Use badge to display status indicators or labels. Badges are great for highlighting version numbers, statuses, or categories within your content.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
label: Preview
|
||||||
|
---
|
||||||
|
:::badge
|
||||||
|
**v3.0.0-alpha.10**
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::badge
|
||||||
|
**v3.0.0-alpha.10**
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Callout
|
||||||
|
|
||||||
|
Use callout to emphasize important contextual information. Callouts draw attention to notes, tips, warnings, or cautions, making key information stand out.
|
||||||
|
|
||||||
|
Customize with `icon` and `color` props or use `note`, `tip`, `warning`, `caution` shortcuts for pre-defined semantic styles.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::callout
|
||||||
|
This is a `callout` with full **markdown** support.
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::callout
|
||||||
|
This is a `callout` with full **markdown** support.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
:::div{.flex.flex-col.gap-4.w-full}
|
||||||
|
::::note{.w-full.my-0}
|
||||||
|
Here's some additional information for you.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::tip{.w-full.my-0}
|
||||||
|
Here's a helpful suggestion.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::warning{.w-full.my-0}
|
||||||
|
Be careful with this action as it might have unexpected results.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::caution{.w-full.my-0}
|
||||||
|
This action cannot be undone.
|
||||||
|
::::
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::note
|
||||||
|
Here's some additional information.
|
||||||
|
::
|
||||||
|
|
||||||
|
::tip
|
||||||
|
Here's a helpful suggestion.
|
||||||
|
::
|
||||||
|
|
||||||
|
::warning
|
||||||
|
Be careful with this action as it might have unexpected results.
|
||||||
|
::
|
||||||
|
|
||||||
|
::caution
|
||||||
|
This action cannot be undone.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Card
|
||||||
|
|
||||||
|
Use `card` to highlight content blocks. Cards are useful for showcasing features, resources, or related information in visually distinct and interactive containers.
|
||||||
|
|
||||||
|
Customize with `title`, `icon`, and `color` props. Cards can also act as links using `<NuxtLink>` properties for navigation.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0 [&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
target: _blank
|
||||||
|
title: Dashboard
|
||||||
|
to: https://github.com/nuxt-ui-pro/dashboard
|
||||||
|
---
|
||||||
|
A dashboard with multi-column layout.
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::card
|
||||||
|
---
|
||||||
|
title: Dashboard
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
to: https://github.com/nuxt-ui-pro/dashboard
|
||||||
|
target: _blank
|
||||||
|
---
|
||||||
|
A dashboard with multi-column layout.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### CardGroup
|
||||||
|
|
||||||
|
Use `card-group` to arrange cards in a grid layout. `card-group` is ideal for displaying collections of cards in a structured, visually appealing, and responsive grid.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
:::card-group{.w-full}
|
||||||
|
::::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
target: _blank
|
||||||
|
title: Dashboard
|
||||||
|
to: https://github.com/nuxt-ui-pro/dashboard
|
||||||
|
---
|
||||||
|
A dashboard with multi-column layout.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
target: _blank
|
||||||
|
title: SaaS
|
||||||
|
to: https://github.com/nuxt-ui-pro/saas
|
||||||
|
---
|
||||||
|
A template with landing, pricing, docs and blog.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
target: _blank
|
||||||
|
title: Docs
|
||||||
|
to: https://github.com/nuxt-ui-pro/docs
|
||||||
|
---
|
||||||
|
A documentation with `@nuxt/content`.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::card
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
target: _blank
|
||||||
|
title: Landing
|
||||||
|
to: https://github.com/nuxt-ui-pro/landing
|
||||||
|
---
|
||||||
|
A landing page you can use as starting point.
|
||||||
|
::::
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::card-group
|
||||||
|
|
||||||
|
::card
|
||||||
|
---
|
||||||
|
title: Dashboard
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
to: https://github.com/nuxt-ui-pro/dashboard
|
||||||
|
target: _blank
|
||||||
|
---
|
||||||
|
A dashboard with multi-column layout.
|
||||||
|
::
|
||||||
|
|
||||||
|
::card
|
||||||
|
---
|
||||||
|
title: SaaS
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
to: https://github.com/nuxt-ui-pro/saas
|
||||||
|
target: _blank
|
||||||
|
---
|
||||||
|
A template with landing, pricing, docs and blog.
|
||||||
|
::
|
||||||
|
|
||||||
|
::card
|
||||||
|
---
|
||||||
|
title: Docs
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
to: https://github.com/nuxt-ui-pro/docs
|
||||||
|
target: _blank
|
||||||
|
---
|
||||||
|
A documentation with `@nuxt/content`.
|
||||||
|
::
|
||||||
|
|
||||||
|
::card
|
||||||
|
---
|
||||||
|
title: Landing
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
to: https://github.com/nuxt-ui-pro/landing
|
||||||
|
target: _blank
|
||||||
|
---
|
||||||
|
A landing page you can use as starting point.
|
||||||
|
::
|
||||||
|
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Collapsible
|
||||||
|
|
||||||
|
Use `collapsible` to hide and reveal content sections. `collapsible` is ideal for showing optional details, technical specifications, or less frequently needed information.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::collapsible
|
||||||
|
| Prop | Default | Type |
|
||||||
|
| ------- | --------- | -------- |
|
||||||
|
| `name` | | `string` |
|
||||||
|
| `size` | `md` | `string` |
|
||||||
|
| `color` | `neutral` | `string` |
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::collapsible
|
||||||
|
|
||||||
|
| Prop | Default | Type |
|
||||||
|
|---------|-----------|--------------------------|
|
||||||
|
| `name` | | `string`{lang="ts-type"} |
|
||||||
|
| `size` | `md` | `string`{lang="ts-type"} |
|
||||||
|
| `color` | `neutral` | `string`{lang="ts-type"} |
|
||||||
|
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Field
|
||||||
|
|
||||||
|
Use `field` to describe a specific field, property, or parameter. `field` components are perfect for documenting API parameters, component props, or configuration options.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
:::field{.w-full required name="name" type="string"}
|
||||||
|
The `description` can be set as prop or in the default slot with full **markdown** support.
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::field{name="name" type="string" required}
|
||||||
|
The `description` can be set as prop or in the default slot with full **markdown** support.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### FieldGroup
|
||||||
|
|
||||||
|
Use `field-group` to group related fields together in a list. `field-group` helps organize and structure documentation for multiple related fields or properties.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
:::field-group
|
||||||
|
::::field{name="analytics" type="boolean"}
|
||||||
|
Default to `false` - Enables analytics for your project (coming soon).
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::field{name="blob" type="boolean"}
|
||||||
|
Default to `false` - Enables blob storage to store static assets, such as images, videos and more.
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::field{name="cache" type="boolean"}
|
||||||
|
Default to `false` - Enables cache storage to cache your server route responses or functions using Nitro's `cachedEventHandler` and `cachedFunction`
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::field{name="database" type="boolean"}
|
||||||
|
Default to `false` - Enables SQL database to store your application's data.
|
||||||
|
::::
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
::field-group
|
||||||
|
::field{name="analytics" type="boolean"}
|
||||||
|
Default to `false` - Enables analytics for your project (coming soon).
|
||||||
|
::
|
||||||
|
|
||||||
|
::field{name="blob" type="boolean"}
|
||||||
|
Default to `false` - Enables blob storage to store static assets, such as images, videos and more.
|
||||||
|
::
|
||||||
|
|
||||||
|
::field{name="cache" type="boolean"}
|
||||||
|
Default to `false` - Enables cache storage to cache your server route responses or functions using Nitro's `cachedEventHandler` and `cachedFunction`
|
||||||
|
::
|
||||||
|
|
||||||
|
::field{name="database" type="boolean"}
|
||||||
|
Default to `false` - Enables SQL database to store your application's data.
|
||||||
|
::
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Icon
|
||||||
|
|
||||||
|
Use `icon` to insert icons from icon libraries. Icons provide visual cues and enhance the user interface of your documentation.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
:icon{name="i-simple-icons-nuxtdotjs"}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
:icon{name="i-simple-icons-nuxtdotjs"}
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Kbd
|
||||||
|
|
||||||
|
Use `kbd` to display keyboard keys or shortcuts. `kbd` components clearly indicate keyboard inputs for instructions or command references.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
`` ``
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
:kbd{value="meta"} :kbd{value="K"}
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
### Tabs
|
||||||
|
|
||||||
|
Use `tabs` and `tabs-item` to organize content into tabbed interfaces. Tabs are effective for separating content into logical sections, improving content discoverability and organization.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:my-0"
|
||||||
|
---
|
||||||
|
:::tabs{.w-full}
|
||||||
|
::::tabs-item{icon="i-lucide-code" label="Code"}
|
||||||
|
```mdc
|
||||||
|
::callout
|
||||||
|
Lorem velit voluptate ex reprehenderit ullamco et culpa.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
::::
|
||||||
|
|
||||||
|
::::tabs-item{icon="i-lucide-eye" label="Preview"}
|
||||||
|
:::::callout
|
||||||
|
Lorem velit voluptate ex reprehenderit ullamco et culpa.
|
||||||
|
:::::
|
||||||
|
::::
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
::tabs
|
||||||
|
|
||||||
|
:::tabs-item{label="Code" icon="i-lucide-code"}
|
||||||
|
|
||||||
|
```mdc
|
||||||
|
::callout
|
||||||
|
Lorem velit voluptate ex reprehenderit ullamco et culpa.
|
||||||
|
::
|
||||||
|
```
|
||||||
|
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::tabs-item{label="Preview" icon="i-lucide-eye"}
|
||||||
|
|
||||||
|
::::callout
|
||||||
|
Lorem velit voluptate ex reprehenderit ullamco et culpa.
|
||||||
|
::::
|
||||||
|
|
||||||
|
:::
|
||||||
|
|
||||||
|
::
|
||||||
|
````
|
||||||
|
::
|
||||||
|
|
||||||
|
### Steps
|
||||||
|
|
||||||
|
Use `steps` to create step-by-step guides from document headings. `steps` component automatically numbers headings, creating a numbered guide for processes and tutorials.
|
||||||
|
|
||||||
|
Set the `level` prop to define the heading level to include in the step-by-step guide.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:::steps{level="4"}
|
||||||
|
#### Add the Nuxt UI Pro module in your `nuxt.config.ts`
|
||||||
|
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Import Tailwind CSS and Nuxt UI Pro in your CSS
|
||||||
|
|
||||||
|
```css [assets/css/main.css]
|
||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
```
|
||||||
|
:::
|
||||||
|
|
||||||
|
#code
|
||||||
|
````mdc
|
||||||
|
::steps{level="4"}
|
||||||
|
|
||||||
|
#### Add the Nuxt UI Pro module in your `nuxt.config.ts`{lang="ts-type"}
|
||||||
|
|
||||||
|
```ts [nuxt.config.ts]
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: ['@nuxt/ui-pro']
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Import Tailwind CSS and Nuxt UI Pro in your CSS
|
||||||
|
|
||||||
|
```css [assets/css/main.css]
|
||||||
|
@import "tailwindcss";
|
||||||
|
@import "@nuxt/ui-pro";
|
||||||
|
```
|
||||||
|
|
||||||
|
::
|
||||||
|
````
|
||||||
|
::
|
57
content/2.essentials/4.images-embeds.md
Normal file
57
content/2.essentials/4.images-embeds.md
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
---
|
||||||
|
title: Images and Embeds
|
||||||
|
description: Add image, video, and other HTML elements
|
||||||
|
navigation:
|
||||||
|
icon: i-lucide-image
|
||||||
|
---
|
||||||
|
|
||||||
|
## Image
|
||||||
|
|
||||||
|
### Using Markdown
|
||||||
|
|
||||||
|
Display images using standard Markdown syntax. Markdown images are simple to implement for basic image display.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|

|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|

|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
::note
|
||||||
|
If [`@nuxt/image`](https://image.nuxt.com/get-started/installation) is installed, the `<NuxtImg>` component will be used instead of the native `img` tag.
|
||||||
|
::
|
||||||
|
|
||||||
|
### Using Embeds
|
||||||
|
|
||||||
|
Use embeds for more image customization. Embeds offer greater control over image attributes like size and styling.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
{height="150"}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
:img{src="https://nuxt.com/new-social.jpg" alt="Nuxt Social Image" height="150"}
|
||||||
|
```
|
||||||
|
::
|
||||||
|
|
||||||
|
## Embeds and HTML elements
|
||||||
|
|
||||||
|
Embeds allow adding various HTML elements like videos and iframes. This feature extends documentation capabilities to include interactive and multimedia content.
|
||||||
|
|
||||||
|
::code-preview
|
||||||
|
---
|
||||||
|
class: "[&>div]:*:w-full"
|
||||||
|
---
|
||||||
|
:iframe{src="https://www.youtube-nocookie.com/embed/_eQxomah-nA?si=pDSzchUBDKb2NQu7" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen style="aspect-ratio: 16/9;"}
|
||||||
|
|
||||||
|
|
||||||
|
#code
|
||||||
|
```mdc
|
||||||
|
:iframe{src="https://www.youtube-nocookie.com/embed/_eQxomah-nA?si=pDSzchUBDKb2NQu7" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen style="aspect-ratio: 16/9;"}
|
||||||
|
```
|
||||||
|
::
|
169
content/index.md
Normal file
169
content/index.md
Normal file
@@ -0,0 +1,169 @@
|
|||||||
|
---
|
||||||
|
seo:
|
||||||
|
title: Nuxt Docs Template
|
||||||
|
description: Nuxt UI Pro is a collection of premium Vue components built on top
|
||||||
|
of Nuxt UI to create beautiful & responsive Nuxt applications in minutes.
|
||||||
|
---
|
||||||
|
|
||||||
|
::u-page-hero
|
||||||
|
---
|
||||||
|
orientation: horizontal
|
||||||
|
---
|
||||||
|
:::prose-pre
|
||||||
|
---
|
||||||
|
code: npx nuxi init -t github:nuxt-ui-pro/docs
|
||||||
|
filename: Terminal
|
||||||
|
---
|
||||||
|
```bash
|
||||||
|
npx nuxi init -t github:nuxt-ui-pro/docs
|
||||||
|
```
|
||||||
|
:::
|
||||||
|
|
||||||
|
#title
|
||||||
|
Build your docs with Nuxt UI Pro
|
||||||
|
|
||||||
|
#description
|
||||||
|
Nuxt UI Pro is a collection of premium components built on top of Nuxt UI to create beautiful & responsive applications in minutes.
|
||||||
|
|
||||||
|
#links
|
||||||
|
:::u-button
|
||||||
|
---
|
||||||
|
size: xl
|
||||||
|
to: /getting-started
|
||||||
|
trailing-icon: i-lucide-arrow-right
|
||||||
|
---
|
||||||
|
Get started
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-button
|
||||||
|
---
|
||||||
|
color: neutral
|
||||||
|
icon: i-simple-icons-github
|
||||||
|
size: xl
|
||||||
|
target: _blank
|
||||||
|
to: https://github.com/nuxt-ui-pro/docs
|
||||||
|
variant: subtle
|
||||||
|
---
|
||||||
|
Use this template
|
||||||
|
:::
|
||||||
|
::
|
||||||
|
|
||||||
|
::u-page-section
|
||||||
|
#title
|
||||||
|
All-in-one documentation template
|
||||||
|
|
||||||
|
#links
|
||||||
|
:::u-button
|
||||||
|
---
|
||||||
|
color: neutral
|
||||||
|
size: lg
|
||||||
|
target: _blank
|
||||||
|
to: https://ui.nuxt.com/getting-started/installation/pro/nuxt
|
||||||
|
trailingIcon: i-lucide-arrow-right
|
||||||
|
variant: subtle
|
||||||
|
---
|
||||||
|
Discover Nuxt UI Pro v3
|
||||||
|
:::
|
||||||
|
|
||||||
|
#features
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxt
|
||||||
|
target: _blank
|
||||||
|
to: https://nuxt.com
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
Nuxt 3
|
||||||
|
|
||||||
|
#description
|
||||||
|
Powered by Nuxt 3 for optimal performances and SEO.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-markdown
|
||||||
|
target: _blank
|
||||||
|
to: https://content.nuxt.com
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
Markdown
|
||||||
|
|
||||||
|
#description
|
||||||
|
Write your pages with MDC thanks to Nuxt Content.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-lucide-sparkles
|
||||||
|
target: _blank
|
||||||
|
to: https://ui.nuxt.com
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
Nuxt UI v3
|
||||||
|
|
||||||
|
#description
|
||||||
|
Offers a very large set of full customizable components.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-typescript
|
||||||
|
target: _blank
|
||||||
|
to: https://www.typescriptlang.org
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
TypeScript
|
||||||
|
|
||||||
|
#description
|
||||||
|
A fully typed development experience.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-simple-icons-nuxtdotjs
|
||||||
|
target: _blank
|
||||||
|
to: https://content.nuxt.com/docs/studio
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
Nuxt Studio
|
||||||
|
|
||||||
|
#description
|
||||||
|
Supported by Nuxt Studio for fast updates and previews.
|
||||||
|
:::
|
||||||
|
|
||||||
|
:::u-page-feature
|
||||||
|
---
|
||||||
|
icon: i-lucide-search
|
||||||
|
target: _blank
|
||||||
|
to: https://ui.nuxt.com/components/content-search
|
||||||
|
---
|
||||||
|
#title
|
||||||
|
Search
|
||||||
|
|
||||||
|
#description
|
||||||
|
A full-text search modal powered by Fuse.js.
|
||||||
|
:::
|
||||||
|
::
|
||||||
|
|
||||||
|
::u-page-section
|
||||||
|
:::u-page-c-t-a
|
||||||
|
---
|
||||||
|
links:
|
||||||
|
- label: Buy now
|
||||||
|
to: https://ui.nuxt.com/pro/purchase
|
||||||
|
target: _blank
|
||||||
|
icon: i-lucide-shopping-cart
|
||||||
|
color: neutral
|
||||||
|
- label: License
|
||||||
|
to: https://ui.nuxt.com/getting-started/license
|
||||||
|
trailingIcon: i-lucide-circle-help
|
||||||
|
target: _blank
|
||||||
|
color: neutral
|
||||||
|
variant: subtle
|
||||||
|
description: Nuxt UI Pro is free in development, but you need a license to use
|
||||||
|
it in production.
|
||||||
|
title: Start with Nuxt UI Pro today!
|
||||||
|
variant: subtle
|
||||||
|
---
|
||||||
|
:::
|
||||||
|
::
|
6
eslint.config.mjs
Normal file
6
eslint.config.mjs
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
// @ts-check
|
||||||
|
import withNuxt from './.nuxt/eslint.config.mjs'
|
||||||
|
|
||||||
|
export default withNuxt(
|
||||||
|
// Your custom configs here
|
||||||
|
)
|
78
nuxt.config.ts
Normal file
78
nuxt.config.ts
Normal file
@@ -0,0 +1,78 @@
|
|||||||
|
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||||
|
export default defineNuxtConfig({
|
||||||
|
modules: [
|
||||||
|
'@nuxt/eslint',
|
||||||
|
'@nuxt/image',
|
||||||
|
'@nuxt/ui-pro',
|
||||||
|
'@nuxt/content',
|
||||||
|
'nuxt-og-image',
|
||||||
|
'nuxt-llms'
|
||||||
|
],
|
||||||
|
|
||||||
|
devtools: {
|
||||||
|
enabled: true
|
||||||
|
},
|
||||||
|
|
||||||
|
css: ['~/assets/css/main.css'],
|
||||||
|
|
||||||
|
content: {
|
||||||
|
build: {
|
||||||
|
markdown: {
|
||||||
|
toc: {
|
||||||
|
searchDepth: 1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
compatibilityDate: '2024-07-11',
|
||||||
|
|
||||||
|
nitro: {
|
||||||
|
prerender: {
|
||||||
|
routes: [
|
||||||
|
'/'
|
||||||
|
],
|
||||||
|
crawlLinks: true,
|
||||||
|
autoSubfolderIndex: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
eslint: {
|
||||||
|
config: {
|
||||||
|
stylistic: {
|
||||||
|
commaDangle: 'never',
|
||||||
|
braceStyle: '1tbs'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
icon: {
|
||||||
|
provider: 'iconify'
|
||||||
|
},
|
||||||
|
|
||||||
|
llms: {
|
||||||
|
domain: 'https://docs-template.nuxt.dev/',
|
||||||
|
title: 'Nuxt Docs Template',
|
||||||
|
description: 'A template for building documentation with Nuxt UI Pro and Nuxt Content.',
|
||||||
|
full: {
|
||||||
|
title: 'Nuxt Docs Template - Full Documentation',
|
||||||
|
description: 'This is the full documentation for the Nuxt Docs Template.'
|
||||||
|
},
|
||||||
|
sections: [
|
||||||
|
{
|
||||||
|
title: 'Getting Started',
|
||||||
|
contentCollection: 'docs',
|
||||||
|
contentFilters: [
|
||||||
|
{ field: 'path', operator: 'LIKE', value: '/getting-started%' }
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: 'Essentials',
|
||||||
|
contentCollection: 'docs',
|
||||||
|
contentFilters: [
|
||||||
|
{ field: 'path', operator: 'LIKE', value: '/essentials%' }
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
})
|
247
nuxt.schema.ts
Normal file
247
nuxt.schema.ts
Normal file
@@ -0,0 +1,247 @@
|
|||||||
|
import { field, group } from '@nuxt/content/preview'
|
||||||
|
|
||||||
|
export default defineNuxtSchema({
|
||||||
|
appConfig: {
|
||||||
|
ui: group({
|
||||||
|
title: 'UI',
|
||||||
|
description: 'UI Customization.',
|
||||||
|
icon: 'i-mdi-palette-outline',
|
||||||
|
fields: {
|
||||||
|
colors: group({
|
||||||
|
title: 'Colors',
|
||||||
|
description: 'Manage main colors of your application',
|
||||||
|
icon: 'i-mdi-palette-outline',
|
||||||
|
fields: {
|
||||||
|
primary: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Primary',
|
||||||
|
description: 'Primary color of your UI.',
|
||||||
|
icon: 'i-mdi-palette-outline',
|
||||||
|
default: 'green',
|
||||||
|
required: ['red', 'orange', 'amber', 'yellow', 'lime', 'green', 'emerald', 'teal', 'cyan', 'sky', 'blue', 'indigo', 'violet', 'purple', 'fuchsia', 'pink', 'rose']
|
||||||
|
}),
|
||||||
|
neutral: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Neutral',
|
||||||
|
description: 'Neutral color of your UI.',
|
||||||
|
icon: 'i-mdi-palette-outline',
|
||||||
|
default: 'slate',
|
||||||
|
required: ['slate', 'gray', 'zinc', 'neutral', 'stone']
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
icons: group({
|
||||||
|
title: 'Icons',
|
||||||
|
description: 'Manage icons used in the application.',
|
||||||
|
icon: 'i-mdi-application-settings-outline',
|
||||||
|
fields: {
|
||||||
|
search: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'Search Bar',
|
||||||
|
description: 'Icon to display in the search bar.',
|
||||||
|
icon: 'i-mdi-magnify',
|
||||||
|
default: 'i-lucide-search'
|
||||||
|
}),
|
||||||
|
dark: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'Dark mode',
|
||||||
|
description: 'Icon of color mode button for dark mode.',
|
||||||
|
icon: 'i-mdi-moon-waning-crescent',
|
||||||
|
default: 'i-lucide-moon'
|
||||||
|
}),
|
||||||
|
light: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'Light mode',
|
||||||
|
description: 'Icon of color mode button for light mode.',
|
||||||
|
icon: 'i-mdi-white-balance-sunny',
|
||||||
|
default: 'i-lucide-sun'
|
||||||
|
}),
|
||||||
|
external: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'External Link',
|
||||||
|
description: 'Icon for external link.',
|
||||||
|
icon: 'i-mdi-arrow-top-right',
|
||||||
|
default: 'i-lucide-external-link'
|
||||||
|
}),
|
||||||
|
chevron: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'Chevron',
|
||||||
|
description: 'Icon for chevron.',
|
||||||
|
icon: 'i-mdi-chevron-down',
|
||||||
|
default: 'i-lucide-chevron-down'
|
||||||
|
}),
|
||||||
|
hash: field({
|
||||||
|
type: 'icon',
|
||||||
|
title: 'Hash',
|
||||||
|
description: 'Icon for hash anchors.',
|
||||||
|
icon: 'i-ph-hash',
|
||||||
|
default: 'i-lucide-hash'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
seo: group({
|
||||||
|
title: 'SEO',
|
||||||
|
description: 'SEO configuration.',
|
||||||
|
icon: 'i-ph-app-window',
|
||||||
|
fields: {
|
||||||
|
siteName: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Site Name',
|
||||||
|
description: 'Name used in ogSiteName and used as second part of your page title (My page title - Nuxt UI Pro).',
|
||||||
|
icon: 'i-mdi-web',
|
||||||
|
default: []
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
header: group({
|
||||||
|
title: 'Header',
|
||||||
|
description: 'Header configuration.',
|
||||||
|
icon: 'i-mdi-page-layout-header',
|
||||||
|
fields: {
|
||||||
|
title: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Title',
|
||||||
|
description: 'Title to display in the header.',
|
||||||
|
icon: 'i-mdi-format-title',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
to: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'To',
|
||||||
|
description: 'URL to redirect to when the title is clicked.',
|
||||||
|
icon: 'i-mdi-link-variant',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
logo: group({
|
||||||
|
title: 'Logo',
|
||||||
|
description: 'Header logo configuration.',
|
||||||
|
icon: 'i-mdi-image-filter-center-focus-strong-outline',
|
||||||
|
fields: {
|
||||||
|
light: field({
|
||||||
|
type: 'media',
|
||||||
|
title: 'Light Mode Logo',
|
||||||
|
description: 'Pick an image from your gallery.',
|
||||||
|
icon: 'i-mdi-white-balance-sunny',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
dark: field({
|
||||||
|
type: 'media',
|
||||||
|
title: 'Dark Mode Logo',
|
||||||
|
description: 'Pick an image from your gallery.',
|
||||||
|
icon: 'i-mdi-moon-waning-crescent',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
alt: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Alt',
|
||||||
|
description: 'Alt to display for accessibility.',
|
||||||
|
icon: 'i-mdi-alphabet-latin',
|
||||||
|
default: ''
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
search: field({
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Search Bar',
|
||||||
|
description: 'Hide or display the search bar.',
|
||||||
|
icon: 'i-mdi-magnify',
|
||||||
|
default: true
|
||||||
|
}),
|
||||||
|
colorMode: field({
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Color Mode',
|
||||||
|
description: 'Hide or display the color mode button in your header.',
|
||||||
|
icon: 'i-mdi-moon-waning-crescent',
|
||||||
|
default: true
|
||||||
|
}),
|
||||||
|
links: field({
|
||||||
|
type: 'array',
|
||||||
|
title: 'Links',
|
||||||
|
description: 'Array of link object displayed in header.',
|
||||||
|
icon: 'i-mdi-link-variant',
|
||||||
|
default: []
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
footer: group({
|
||||||
|
title: 'Footer',
|
||||||
|
description: 'Footer configuration.',
|
||||||
|
icon: 'i-mdi-page-layout-footer',
|
||||||
|
fields: {
|
||||||
|
credits: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Footer credits section',
|
||||||
|
description: 'Text to display as credits in the footer.',
|
||||||
|
icon: 'i-mdi-circle-edit-outline',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
colorMode: field({
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Color Mode',
|
||||||
|
description: 'Hide or display the color mode button in the footer.',
|
||||||
|
icon: 'i-mdi-moon-waning-crescent',
|
||||||
|
default: false
|
||||||
|
}),
|
||||||
|
links: field({
|
||||||
|
type: 'array',
|
||||||
|
title: 'Links',
|
||||||
|
description: 'Array of link object displayed in footer.',
|
||||||
|
icon: 'i-mdi-link-variant',
|
||||||
|
default: []
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
toc: group({
|
||||||
|
title: 'Table of contents',
|
||||||
|
description: 'TOC configuration.',
|
||||||
|
icon: 'i-mdi-table-of-contents',
|
||||||
|
fields: {
|
||||||
|
title: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Title',
|
||||||
|
description: 'Text to display as title of the main toc.',
|
||||||
|
icon: 'i-mdi-format-title',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
bottom: group({
|
||||||
|
title: 'Bottom',
|
||||||
|
description: 'Bottom TOC configuration.',
|
||||||
|
icon: 'i-mdi-table-of-contents',
|
||||||
|
fields: {
|
||||||
|
title: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Title',
|
||||||
|
description: 'Text to display as title of the bottom toc.',
|
||||||
|
icon: 'i-mdi-format-title',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
edit: field({
|
||||||
|
type: 'string',
|
||||||
|
title: 'Edit Page Link',
|
||||||
|
description: 'URL of your repository content folder.',
|
||||||
|
icon: 'i-ph-note-pencil',
|
||||||
|
default: ''
|
||||||
|
}),
|
||||||
|
links: field({
|
||||||
|
type: 'array',
|
||||||
|
title: 'Links',
|
||||||
|
description: 'Array of link object displayed in bottom toc.',
|
||||||
|
icon: 'i-mdi-link-variant',
|
||||||
|
default: []
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
declare module '@nuxt/schema' {
|
||||||
|
interface CustomAppConfig {
|
||||||
|
ui: {
|
||||||
|
icons: object
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
44
package.json
Normal file
44
package.json
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
{
|
||||||
|
"name": "nuxt-ui-pro-template-docs",
|
||||||
|
"private": true,
|
||||||
|
"type": "module",
|
||||||
|
"scripts": {
|
||||||
|
"build": "nuxt build",
|
||||||
|
"dev": "nuxt dev",
|
||||||
|
"generate": "nuxt generate",
|
||||||
|
"preview": "nuxt preview",
|
||||||
|
"postinstall": "nuxt prepare",
|
||||||
|
"lint": "eslint .",
|
||||||
|
"typecheck": "nuxt typecheck"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"@iconify-json/lucide": "^1.2.57",
|
||||||
|
"@iconify-json/simple-icons": "^1.2.43",
|
||||||
|
"@iconify-json/vscode-icons": "^1.2.23",
|
||||||
|
"@nuxt/content": "^3.6.3",
|
||||||
|
"@nuxt/image": "^1.10.0",
|
||||||
|
"@nuxt/ui-pro": "^3.2.0",
|
||||||
|
"better-sqlite3": "^12.2.0",
|
||||||
|
"nuxt": "^4.0.0",
|
||||||
|
"nuxt-llms": "0.1.3",
|
||||||
|
"nuxt-og-image": "^5.1.9"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"@nuxt/eslint": "^1.5.2",
|
||||||
|
"eslint": "^9.31.0",
|
||||||
|
"typescript": "^5.8.3",
|
||||||
|
"vue-tsc": "^3.0.1"
|
||||||
|
},
|
||||||
|
"resolutions": {
|
||||||
|
"unimport": "4.1.1"
|
||||||
|
},
|
||||||
|
"pnpm": {
|
||||||
|
"onlyBuiltDependencies": [
|
||||||
|
"better-sqlite3"
|
||||||
|
],
|
||||||
|
"ignoredBuiltDependencies": [
|
||||||
|
"vue-demi"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"packageManager": "pnpm@10.13.1"
|
||||||
|
}
|
13460
pnpm-lock.yaml
generated
Normal file
13460
pnpm-lock.yaml
generated
Normal file
File diff suppressed because it is too large
Load Diff
BIN
public/favicon.ico
Normal file
BIN
public/favicon.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.2 KiB |
14
renovate.json
Normal file
14
renovate.json
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
"extends": [
|
||||||
|
"github>nuxt/renovate-config-nuxt"
|
||||||
|
],
|
||||||
|
"lockFileMaintenance": {
|
||||||
|
"enabled": true
|
||||||
|
},
|
||||||
|
"baseBranches": ["v1", "main"],
|
||||||
|
"packageRules": [{
|
||||||
|
"matchDepTypes": ["resolutions"],
|
||||||
|
"enabled": false
|
||||||
|
}],
|
||||||
|
"postUpdateOptions": ["pnpmDedupe"]
|
||||||
|
}
|
4
tsconfig.json
Normal file
4
tsconfig.json
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
// https://nuxt.com/docs/guide/concepts/typescript
|
||||||
|
"extends": "./.nuxt/tsconfig.json"
|
||||||
|
}
|
Reference in New Issue
Block a user