diff --git a/docs/app/components/Header.vue b/docs/app/components/Header.vue index eea89734..1d0977b2 100644 --- a/docs/app/components/Header.vue +++ b/docs/app/components/Header.vue @@ -22,9 +22,7 @@ onMounted(() => { const navigation = inject>('navigation') -const githubLink = computed(() => { - return `https://github.com/nuxt/${value.value}` -}) +const githubLink = computed(() => `https://github.com/nuxt/${value.value}`) const desktopLinks = computed(() => props.links.map(({ icon, ...link }) => link)) const mobileLinks = computed(() => [ @@ -36,6 +34,16 @@ const mobileLinks = computed(() => [ target: '_blank' } ]) + +const items = computed(() => { + const ui2 = { label: 'v2.22.0', to: 'https://ui2.nuxt.com' } + const uiPro1 = { label: 'v1.8.0', to: 'https://ui2.nuxt.com/pro' } + + return [ + { label: `v${config.version}`, active: true, color: 'primary' as const, checked: true, type: 'checkbox' as const }, + route.path === '/' ? ui2 : route.path.startsWith('/pro') ? uiPro1 : module.value === 'ui-pro' ? uiPro1 : ui2 + ] +})