Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/vickylaixy/hugo-theme-introduction.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanzei <hanzei@mailbox.org>2018-06-27 03:10:46 +0300
committerHanzei <hanzei@mailbox.org>2018-06-27 03:31:18 +0300
commit389a69a6e71228b536af28776156fda30d22e217 (patch)
tree8ddc2bca6c5abbd5d3e40f8383e46de8a8ad028b /layouts/blog
parentc555b2b52c149aa8bd083b670583e4b3bb963f10 (diff)
Add Multilingual support
Diffstat (limited to 'layouts/blog')
-rw-r--r--layouts/blog/list.html32
-rw-r--r--layouts/blog/single.html6
2 files changed, 19 insertions, 19 deletions
diff --git a/layouts/blog/list.html b/layouts/blog/list.html
index faade24..876975b 100644
--- a/layouts/blog/list.html
+++ b/layouts/blog/list.html
@@ -17,24 +17,24 @@
<!-- Begin Blog container -->
<div class="container">
{{ if .Site.Params.showLatest }}
- <h2 class="title is-2 top-pad">Latest Post</h2>
- {{ range first 1 (where .Data.Pages.ByPublishDate.Reverse "Section" "blog") }}
- <div class="summary">{{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }}
- <h3 class="title is-3 strong-post-title">
- <a href="{{ .RelPermalink }}">
- {{ .Title }}
- </a>
- </h3>
- <div class="markdown">
- {{ .Summary }}
- {{ if .Truncated }}
- <a href="{{ .RelPermalink }}">...Read More</a>
- {{ end }}
- </div>
+ <h2 class="title is-2 top-pad">{{ i18n "index_blog_latestPosts" . }}</h2>
+ {{ range first 1 (where .Data.Pages.ByPublishDate.Reverse "Section" "blog") }}
+ <div class="summary">{{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }}
+ <h3 class="title is-3 strong-post-title">
+ <a href="{{ .RelPermalink }}">
+ {{ .Title }}
+ </a>
+ </h3>
+ <div class="markdown">
+ {{ .Summary }}
+ {{ if .Truncated }}
+ <a href="{{ .RelPermalink }}">{{ i18n "index_blog_readMore" . }}</a>
+ {{ end }}
</div>
- {{ end }}
+ </div>
+ {{ end }}
{{ end }}
- <h2 class="title is-2 top-pad">All Posts</h2>
+ <h2 class="title is-2 top-pad">{{ i18n "index_blog_allPosts" . }}</h2>
<ul>
{{ range .Data.Pages.ByPublishDate }}
{{ if eq .Section "blog" }}
diff --git a/layouts/blog/single.html b/layouts/blog/single.html
index 8b1c47d..6a24536 100644
--- a/layouts/blog/single.html
+++ b/layouts/blog/single.html
@@ -4,7 +4,7 @@
<div class="section" id="top">
<!-- Begin Title -->
<div class="container hero {{ if .Site.Params.fadeIn | default true }}fade-in one{{ end }}">
- <h1 class="bold-title is-1">{{ (.Site.GetPage "section" "blog") .Title }}</h1>
+ <h1 class="bold-title is-1">{{ (.Site.GetPage "section" "blog").Title }}</h1>
</div>
<!-- End Title -->
<!-- Everything below fades in two! -->
@@ -17,11 +17,11 @@
</h2>
<div class="post-data">
{{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }} |
- {{ if eq 1 .ReadingTime }}{{ .ReadingTime }} minute read{{ else }}{{ .ReadingTime }} minutes read{{ end }}
+ {{ i18n "blog_readingTime" .ReadingTime }}
</div>
{{ if .Site.Params.shareButtons }}
<div class="blog-share">
- Share this:
+ {{ i18n "blog_shareThis" . }}:
{{ if .Site.Params.shareTwitter }}
<a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=Read%20{{ .Title }}%20{{ .Permalink }}" onclick="window.open(this.href, 'twitter-share', 'width=550,height=235');return false;">
<i class="fa fa-twitter"></i>