summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author南小北 <nanxiaobei@gmail.com>2018-09-02 14:59:43 +0800
committerGitHub <noreply@github.com>2018-09-02 14:59:43 +0800
commit3730b32107f2ca4d40d9002357e95bc372f64bc7 (patch)
tree8d5aabce795d8a9d7c4762c37b0bed4e149853bf
parent1750b5b3549162ccf71389f20a7b0c631a3a7fba (diff)
parentb43e0d727e70083416171407cf0efd46afa1603c (diff)
Merge pull request #10 from movch/feat/i18n
:building_construction: Add i18n
-rw-r--r--i18n/en.yaml5
-rw-r--r--i18n/ru.yaml5
-rw-r--r--layouts/_default/list.html4
3 files changed, 12 insertions, 2 deletions
diff --git a/i18n/en.yaml b/i18n/en.yaml
new file mode 100644
index 0000000..4491f35
--- /dev/null
+++ b/i18n/en.yaml
@@ -0,0 +1,5 @@
+- id: nextPage
+ translation: "Next Page"
+
+- id: prevPage
+ translation: "Prev Page" \ No newline at end of file
diff --git a/i18n/ru.yaml b/i18n/ru.yaml
new file mode 100644
index 0000000..eb735ab
--- /dev/null
+++ b/i18n/ru.yaml
@@ -0,0 +1,5 @@
+- id: nextPage
+ translation: "Туда"
+
+- id: prevPage
+ translation: "Сюда" \ No newline at end of file
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index aa76b4f..5433b17 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -33,10 +33,10 @@
<footer class="list-footer">
<nav class="pagination">
{{ if $paginator.HasPrev }}
- <a class="pagination-prev" href="{{ $paginator.Prev.URL }}">← Prev Page</a>
+ <a class="pagination-prev" href="{{ $paginator.Prev.URL }}">← {{ i18n "prevPage" }}</a>
{{ end }}
{{ if $paginator.HasNext }}
- <a class="pagination-next" href="{{ $paginator.Next.URL }}">Next Page →</a>
+ <a class="pagination-next" href="{{ $paginator.Next.URL }}">{{ i18n "nextPage" }} →</a>
{{ end }}
</nav>
</footer>