组件
链接 Link
Link:链接。平时低调,悬停时颜色加深,聚焦时显示光晕,颜色使用 accent。下划线可始终显示、仅悬停时显示或不显示。
#基础用法
The catalogue always underlines — a quiet rail under the ink.
The default underlines on hover — rest keeps the page still.
And some links never underline — the pigment alone carries them.
<script setup lang="ts">
import { Link } from "@bysages/vue";
</script>
<template>
<div class="grid gap-3 max-w-112">
<p class="m-0 text-secondary">
The catalogue
<Link href="#" underline="always">always underlines</Link>
— a quiet rail under the ink.
</p>
<p class="m-0 text-secondary">
The default
<Link href="#">underlines on hover</Link>
— rest keeps the page still.
</p>
<p class="m-0 text-secondary">
And
<Link href="#" underline="none">some links never underline</Link>
— the pigment alone carries them.
</p>
</div>
</template>
#属性
#Link
Link:链接。平时低调,悬停时颜色加深,聚焦时显示光晕,颜色使用 accent。下划线可始终显示、仅悬停时显示或不显示。
| 属性 | 类型 | 默认值 | 描述 |
|---|---|---|---|
underline | String as PropType<"always" | "hover" | "none"> | "hover" | — |