summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--assets/css/post-single.css9
-rw-r--r--layouts/_default/single.html10
2 files changed, 19 insertions, 0 deletions
diff --git a/assets/css/post-single.css b/assets/css/post-single.css
index 6eb6f52..cc33958 100644
--- a/assets/css/post-single.css
+++ b/assets/css/post-single.css
@@ -13,6 +13,15 @@
.post-meta {
color: var(--secondary);
font-size: 14px;
+ display: flex;
+ flex-wrap: wrap;
+}
+
+.post-meta .i18n_list li {
+ display: inline-flex;
+ list-style: none;
+ margin: auto 3px;
+ box-shadow: 0 1px 0 var(--secondary);
}
.post-content {
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 078c5b1..6778345 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -13,6 +13,16 @@
{{ $default_txt := print .ReadingTime " " "min" }}
{{ i18n "read_time" .ReadingTime | default $default_txt }}{{ end }}
{{ if or .Params.author .Site.Params.author }} . {{ .Params.author | default .Site.Params.author }}{{ end }}
+ {{ if .IsTranslated -}}|
+ <ul class="i18n_list">
+ {{ i18n "translations" | default "Translations"}}:
+ {{ range .Translations }}
+ <li>
+ <a href="{{ .Permalink }}">{{ .Language.LanguageName }}</a>
+ </li>
+ {{ end }}
+ </ul>
+ {{ end }}
</div>
{{end}}
</header>