🌐 Localize reply-by-email subject
Use a new article.reply_to i18n key for the generated reply-by-email subject instead of the hardcoded English prefix. Add the missing translations across i18n files and keep the existing English subject as fallback. Fixes #2936
This commit is contained in:
@@ -51,12 +51,13 @@
|
||||
{{ $defaultReplyByEmail := site.Params.replyByEmail }}
|
||||
{{ $replyByEmail := default $defaultReplyByEmail .Params.replyByEmail }}
|
||||
{{ if $replyByEmail }}
|
||||
{{ $replySubject := i18n "article.reply_to" (dict "Title" .Title) | default (printf "Reply to %s" .Title) }}
|
||||
<strong class="block mt-8">
|
||||
<a
|
||||
class="email-link m-1 rounded bg-neutral-300 p-1.5 text-neutral-700 hover:bg-primary-500 hover:text-neutral dark:bg-neutral-700 dark:text-neutral-300 dark:hover:bg-primary-400 dark:hover:text-neutral-800"
|
||||
href="#"
|
||||
data-email="{{ site.Params.Author.email | base64Encode }}"
|
||||
data-subject="{{ replace (printf "Reply to %s" .Title) "\"" "'" }}">
|
||||
data-subject="{{ replace $replySubject "\"" "'" }}">
|
||||
{{ i18n "article.reply_by_email" | default "Reply by Email" }}
|
||||
</a>
|
||||
<noscript>
|
||||
|
||||
Reference in New Issue
Block a user