Skip to content

Commit

Permalink
docs: switch between v2 and v3 docs
Browse files Browse the repository at this point in the history
  • Loading branch information
farnabaz committed Nov 30, 2024
1 parent c5b1a4f commit 3db7fdf
Showing 1 changed file with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions docs/app/components/AppHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,25 @@ defineShortcuts({
>
<AppLogo class="w-auto h-6 shrink-0" />

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

Expand Down

0 comments on commit 3db7fdf

Please sign in to comment.