fix: use tag name for display in tags page (#438)

Instead of slugified tags, original tag names will
be used for displaying tag names in the tags page.
This commit is contained in:
George Zhao
2025-02-08 12:46:16 +08:00
committed by satnaing
parent 26020bbd0e
commit a56b28bc2c
3 changed files with 12 additions and 13 deletions
+3 -2
View File
@@ -1,10 +1,11 @@
---
export interface Props {
tag: string;
tagName: string;
size?: "sm" | "lg";
}
const { tag, size = "sm" } = Astro.props;
const { tag, tagName, size = "sm" } = Astro.props;
---
<li
@@ -24,7 +25,7 @@ const { tag, size = "sm" } = Astro.props;
d="M16.018 3.815 15.232 8h-4.966l.716-3.815-1.964-.37L8.232 8H4v2h3.857l-.751 4H3v2h3.731l-.714 3.805 1.965.369L8.766 16h4.966l-.714 3.805 1.965.369.783-4.174H20v-2h-3.859l.751-4H21V8h-3.733l.716-3.815-1.965-.37zM14.106 14H9.141l.751-4h4.966l-.752 4z"
></path>
</svg>
&nbsp;<span>{tag}</span>
&nbsp;<span>{tagName}</span>
</a>
</li>