summaryrefslogtreecommitdiff
path: root/src/components/blog/webmentions/Comments.astro
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/blog/webmentions/Comments.astro')
-rw-r--r--src/components/blog/webmentions/Comments.astro9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/components/blog/webmentions/Comments.astro b/src/components/blog/webmentions/Comments.astro
index af14bd0..9d274f9 100644
--- a/src/components/blog/webmentions/Comments.astro
+++ b/src/components/blog/webmentions/Comments.astro
@@ -1,13 +1,15 @@
---
import { Image } from "astro:assets";
import { Icon } from "astro-icon/components";
+import { t } from "@/i18n/translations";
import type { WebmentionsChildren } from "@/types";
interface Props {
mentions: WebmentionsChildren[];
+ language?: string | undefined;
}
-const { mentions } = Astro.props;
+const { mentions, language } = Astro.props;
const validComments = ["mention-of", "in-reply-to"];
@@ -20,7 +22,8 @@ const comments = mentions.filter(
!!comments.length && (
<div>
<p class="text-accent-2 mb-0">
- <strong>{comments.length}</strong> Mention{comments.length > 1 ? "s" : ""}
+ <strong>{comments.length}</strong>{" "}
+ {comments.length > 1 ? t(language, "mentions") : t(language, "mention")}
</p>
<ul class="divide-global-text/20 mt-0 divide-y ps-0" role="list">
{comments.map((mention) => (
@@ -65,7 +68,7 @@ const comments = mentions.filter(
target="_blank"
>
<span class="hidden" id="cmt-source">
- Visit the source of this webmention
+ {t(language, "visitWebmentionSource")}
</span>
<Icon
aria-hidden="true"