组件
高亮文本 Highlight
Highlight:搜索命中高亮。命中文字使用 accent 的浅色背景,不是霓虹效果。组件渲染普通 `<mark>` 元素,外观由全文档的 mark 默认样式承担。部件。
#基础用法
The page is warm paper, the words are ink, and hierarchy rises from light rather than boxes.
<script setup lang="ts">
import { Highlight } from "@bysages/vue";
</script>
<template>
<p class="max-w-[46ch] leading-[1.7]">
<Highlight
query="ink"
text="The page is warm paper, the words are ink, and hierarchy rises from light rather than boxes."
/>
</p>
</template>