style: 移除 TOCHeading 和 BlogPost 组件中的 # 符号

- 移除 TOCHeading 组件中链接前的 # 符号
- 移除 BlogPost 组件中标题前的 # 符号
This commit is contained in:
KazooTTT
2025-05-18 16:59:30 +08:00
parent 64083959b3
commit 57bd44199d
2 changed files with 3 additions and 3 deletions

View File

@ -13,7 +13,7 @@ const {
<li class={`${depth > 2 ? "ms-2" : ""}`}>
<a
class={`line-clamp-2 hover:text-accent ${depth <= 2 ? "mt-3" : "mt-2 text-xs"}`}
href={`#${slug}`}><span aria-hidden="true" class="me-0.5">#</span>{text}</a
href={`#${slug}`}><span aria-hidden="true" class="me-0.5"></span>{text}</a
>
{
!!children.length && (

View File

@ -41,7 +41,7 @@ const readingTime: string = remarkPluginFrontmatter.readingTime;
</div>
<div class="flex flex-col gap-10 lg:flex-row lg:items-start">
<div
class="prose prose-base prose-headings:font-semibold prose-headings:text-accent-2 prose-headings:before:absolute prose-headings:before:-ms-4 prose-headings:before:text-gray-600 prose-headings:hover:before:text-accent sm:prose-headings:before:content-['#'] sm:prose-th:before:content-none w-full lg:!max-w-none"
class="prose prose-base prose-headings:font-semibold prose-headings:text-accent-2 prose-headings:before:absolute prose-headings:before:-ms-4 prose-headings:before:text-gray-600 prose-headings:hover:before:text-accent sm:prose-th:before:content-none w-full lg:!max-w-none"
>
<slot />
<WebMentions />
@ -61,7 +61,7 @@ const readingTime: string = remarkPluginFrontmatter.readingTime;
</div>
<div class="flex flex-col gap-10 lg:flex-row lg:items-start">
<div
class="prose prose-base prose-headings:font-semibold prose-headings:text-accent-2 prose-headings:before:absolute prose-headings:before:-ms-4 prose-headings:before:text-gray-600 prose-headings:hover:before:text-accent sm:prose-headings:before:content-['#'] sm:prose-th:before:content-none w-full lg:!max-w-none"
class="prose prose-base prose-headings:font-semibold prose-headings:text-accent-2 prose-headings:before:absolute prose-headings:before:-ms-4 prose-headings:before:text-gray-600 prose-headings:hover:before:text-accent sm:prose-th:before:content-none w-full lg:!max-w-none"
>
<slot />
<WebMentions />