|
| 1 | +import Unocss from 'unocss/vite' |
| 2 | +import { defineConfig } from 'vitepress' |
| 3 | +import { version } from '../../package.json' |
| 4 | + |
| 5 | +export default defineConfig({ |
| 6 | + title: 'FormKit-PrimeVue', |
| 7 | + description: 'Formkit PrimeVue Integration', |
| 8 | + base: '/formkit-primevue/', |
| 9 | + themeConfig: { |
| 10 | + footer: { |
| 11 | + message: 'Nuxt 3 PrimeVue Module', |
| 12 | + copyright: 'Copyright © 2023 SFXCode', |
| 13 | + }, |
| 14 | + socialLinks: [ |
| 15 | + { icon: 'github', link: 'https://github.com/sfxcode/formkit-primevue' }, |
| 16 | + ], |
| 17 | + editLink: { |
| 18 | + pattern: 'https://github.com/sfxcode/formkit-primevue/edit/main/docs/:path', |
| 19 | + text: 'Edit this page on GitHub', |
| 20 | + }, |
| 21 | + nav: nav(), |
| 22 | + search: { |
| 23 | + provider: 'local' |
| 24 | + }, |
| 25 | + sidebar: { |
| 26 | + '/guide/': sidebarGuide(), |
| 27 | + '/config/': sidebarConfig(), |
| 28 | + }, |
| 29 | + }, |
| 30 | + markdown: { |
| 31 | + headers: { |
| 32 | + level: [0, 0], |
| 33 | + }, |
| 34 | + }, |
| 35 | + vite: { |
| 36 | + plugins: [ |
| 37 | + Unocss({ |
| 38 | + configFile: '../../unocss.config.ts', |
| 39 | + }), |
| 40 | + ], |
| 41 | + }, |
| 42 | +}) |
| 43 | + |
| 44 | +function nav() { |
| 45 | + return [ |
| 46 | + { text: 'Guide', link: '/guide/', activeMatch: '/guide/' }, |
| 47 | + { |
| 48 | + text: 'External Docs', |
| 49 | + items: [ |
| 50 | + { |
| 51 | + text: 'PrimeVue', |
| 52 | + link: 'https://www.primefaces.org/primevue', |
| 53 | + }, |
| 54 | + { |
| 55 | + text: 'Formkit', |
| 56 | + link: 'https://formkit.com', |
| 57 | + }, |
| 58 | + ], |
| 59 | + }, |
| 60 | + { |
| 61 | + text: version, |
| 62 | + items: [ |
| 63 | + { |
| 64 | + text: 'Changelog', |
| 65 | + link: 'https://github.com/sfxcode/formkit-primevue/blob/main/CHANGELOG.md', |
| 66 | + }, |
| 67 | + ], |
| 68 | + }, |
| 69 | + ] |
| 70 | +} |
| 71 | + |
| 72 | +function sidebarGuide() { |
| 73 | + return [ |
| 74 | + { |
| 75 | + text: 'Introduction', |
| 76 | + collapsible: true, |
| 77 | + items: [ |
| 78 | + { text: 'What is this?', link: '/guide/' }, |
| 79 | + { text: 'Getting started', link: '/guide/getting-started' }, |
| 80 | + ], |
| 81 | + }, |
| 82 | + { |
| 83 | + text: 'Guide', |
| 84 | + collapsible: true, |
| 85 | + items: [ |
| 86 | + { text: 'Usage', link: '/guide/usage' }, |
| 87 | + { text: 'PrimeVue Inputs', link: '/guide/inputs' }, |
| 88 | + { text: 'Sample Apps', link: '/guide/examples' }, |
| 89 | + ], |
| 90 | + }, |
| 91 | + ] |
| 92 | +} |
| 93 | + |
| 94 | +function sidebarConfig() { |
| 95 | + return [ |
| 96 | + { |
| 97 | + text: 'Config', |
| 98 | + items: [ |
| 99 | + { text: 'Introduction', link: '/config/' }, |
| 100 | + ], |
| 101 | + }, |
| 102 | + ] |
| 103 | +} |
0 commit comments