feat(HorizontalNavigation): new component (#1279)

This commit is contained in:
Benjamin Canac
2024-01-25 10:21:06 +01:00
committed by GitHub
parent b76e761bbb
commit b8007bab5e
12 changed files with 321 additions and 34 deletions

View File

@@ -0,0 +1,22 @@
<script setup>
const route = useRoute()
const links = [{
label: 'Horizontal Navigation',
to: `${route.path.startsWith('/dev') ? '/dev' : ''}/navigation/horizontal-navigation`
}, {
label: 'Command Palette',
to: '/navigation/command-palette'
}, {
label: 'Table',
to: '/data/table'
}]
</script>
<template>
<UHorizontalNavigation :links="links">
<template #default="{ link }">
<span class="group-hover:text-primary relative">{{ link.label }}</span>
</template>
</UHorizontalNavigation>
</template>