Skip to content

Commit 3db7fdf

Browse files
committed
docs: switch between v2 and v3 docs
1 parent c5b1a4f commit 3db7fdf

File tree

1 file changed

+19
-6
lines changed

1 file changed

+19
-6
lines changed

docs/app/components/AppHeader.vue

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,25 @@ defineShortcuts({
3030
>
3131
<AppLogo class="w-auto h-6 shrink-0" />
3232

33-
<UBadge
34-
:label="`v${config.version}`"
35-
variant="subtle"
36-
size="sm"
37-
class="hidden -mb-[2px] font-semibold sm:inline-block truncate"
38-
/>
33+
<UDropdownMenu
34+
v-slot="{ open }"
35+
:modal="false"
36+
:items="[{ label: `v${config.version}`, active: true, color: 'primary', checked: true, type: 'checkbox' }, { label: 'v2.13.4', to: 'https://content.nuxt.com' }]"
37+
:ui="{ content: 'w-(--radix-dropdown-menu-trigger-width) min-w-0' }"
38+
size="xs"
39+
>
40+
<UButton
41+
:label="`v${config.version}`"
42+
variant="subtle"
43+
trailing-icon="i-lucide-chevron-down"
44+
size="xs"
45+
class="-mb-[3px] font-semibold rounded-full truncate"
46+
:class="[open && 'bg-[var(--ui-primary)]/15 ']"
47+
:ui="{
48+
trailingIcon: ['transition-transform duration-200', open ? 'rotate-180' : undefined].filter(Boolean).join(' '),
49+
}"
50+
/>
51+
</UDropdownMenu>
3952
</NuxtLink>
4053
</template>
4154

0 commit comments

Comments
 (0)