使用原生导航头
This commit is contained in:
parent
8ae294c795
commit
cd17bd49ec
|
|
@ -40,23 +40,23 @@ const items = computed<NavigationMenuItem[]>(() => [{
|
||||||
}, {
|
}, {
|
||||||
label: '应用实例',
|
label: '应用实例',
|
||||||
|
|
||||||
to: 'https://go.nuxt.com/figma-ui',
|
to: '/example',
|
||||||
target: '_blank'
|
active: route.path.startsWith('/example')
|
||||||
}, {
|
}, {
|
||||||
label: '典型案例',
|
label: '典型案例',
|
||||||
|
|
||||||
to: 'https://github.com/nuxt/ui/releases',
|
to: '/classic',
|
||||||
target: '_blank'
|
active: route.path.startsWith('/classic')
|
||||||
}, {
|
}, {
|
||||||
label: '新闻资讯',
|
label: '新闻资讯',
|
||||||
to: '/docs/components',
|
to: '/news',
|
||||||
|
|
||||||
active: route.path.startsWith('/docs/components')
|
active: route.path.startsWith('/news')
|
||||||
}, {
|
}, {
|
||||||
label: '关于我们',
|
label: '关于我们',
|
||||||
to: '/docs/components',
|
to: '/about',
|
||||||
|
|
||||||
active: route.path.startsWith('/docs/components')
|
active: route.path.startsWith('/about')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '联系我们',
|
label: '联系我们',
|
||||||
|
|
@ -68,19 +68,19 @@ const items = computed<NavigationMenuItem[]>(() => [{
|
||||||
label: '后台管理',
|
label: '后台管理',
|
||||||
to: '/contact',
|
to: '/contact',
|
||||||
|
|
||||||
active: route.path.startsWith('/123')
|
active: route.path.startsWith('/admin')
|
||||||
},
|
},
|
||||||
])
|
])
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<UHeader
|
<UHeader
|
||||||
:ui="headerUI"
|
|
||||||
|
|
||||||
>
|
>
|
||||||
<!-- 标题部分 -->
|
<!-- 标题部分 -->
|
||||||
<template #title>
|
<template #title>
|
||||||
<view class="h-6 w-auto text-white">
|
<view class="h-6 w-auto text-primary">
|
||||||
创特蜂箱
|
创特蜂箱
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -89,9 +89,7 @@ const items = computed<NavigationMenuItem[]>(() => [{
|
||||||
<UNavigationMenu
|
<UNavigationMenu
|
||||||
:items="items"
|
:items="items"
|
||||||
|
|
||||||
:ui="{
|
|
||||||
link: 'text-white text-lg font-bold '
|
|
||||||
}"
|
|
||||||
highlight
|
highlight
|
||||||
highlight-color="primary"
|
highlight-color="primary"
|
||||||
/>
|
/>
|
||||||
|
|
@ -109,5 +107,7 @@ const items = computed<NavigationMenuItem[]>(() => [{
|
||||||
</template>
|
</template>
|
||||||
</UHeader>
|
</UHeader>
|
||||||
</template>
|
</template>
|
||||||
|
//:ui="headerUI"
|
||||||
|
//:ui="{link: 'text-white text-lg font-bold '}"
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user