hulai-website/components/common/InternalLink.vue
刘涛 a25f3a77ce sync: 同步最新呼籁官网代码到仓库
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-22 21:57:35 +08:00

38 行
800 B
Vue

<template>
<NuxtLink :to="to" class="internal-link">
<span>{{ text }}</span>
<span v-if="arrow" class="internal-link-arrow" aria-hidden="true">&rarr;</span>
</NuxtLink>
</template>
<script setup>
defineProps({
to: { type: String, required: true },
text: { type: String, required: true },
arrow: { type: Boolean, default: true },
})
</script>
<style lang="less" scoped>
.internal-link {
display: inline-flex;
align-items: center;
gap: @space-sm;
font-size: @font-size-base;
color: @color-primary;
text-decoration: none;
font-weight: @font-weight-medium;
transition: gap @transition-fast;
&:hover {
gap: @space-md;
color: @color-primary-light;
}
}
.internal-link-arrow {
font-size: @font-size-lg;
transition: transform @transition-fast;
}
</style>