summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2020-06-01 13:22:28 +0200
committerHarald Eilertsen <haraldei@anduin.net>2020-06-01 13:22:28 +0200
commitf2a5eb6dc20bfb9fb084671fadc11156232375b5 (patch)
tree4ffc73f93708046c915dc1f9fe0ebe88ff2617e3
parent386aa9a423f1ab1566fc2f09cb35ee7d510d9403 (diff)
downloadrabalderz-f2a5eb6dc20bfb9fb084671fadc11156232375b5.tar.gz
rabalderz-f2a5eb6dc20bfb9fb084671fadc11156232375b5.tar.bz2
rabalderz-f2a5eb6dc20bfb9fb084671fadc11156232375b5.zip
Use Zola translation system to translate more prompt.
-rw-r--r--config.toml13
-rw-r--r--templates/index.html2
2 files changed, 13 insertions, 2 deletions
diff --git a/config.toml b/config.toml
index 66db5ff..4343b80 100644
--- a/config.toml
+++ b/config.toml
@@ -12,11 +12,22 @@ compile_sass = true
highlight_code = true
# Whether to build a search index to be used later on by a JavaScript library
-build_search_index = true
+# build_search_index = true
taxonomies = [
{ name = "tags", rss = true },
]
+languages = [
+ { code = "nb", feed = true },
+ { cdoe = "en", feed = true },
+]
+
+default_language = "nb"
+
+[translations]
+nb = { moreprompt = "Les mer..." }
+en = { moreprompt = "More..." }
+
[extra]
# Put all your custom variables here
diff --git a/templates/index.html b/templates/index.html
index 7857f0d..b1bf5ee 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -36,7 +36,7 @@
<footer>
{% if post.content | length > post.summary | length %}
<a href="{{ post.permalink }}">
- {% if post.lang == 'en' %}More...{% else %}Les mer...{% endif %}
+ {{ trans(key="moreprompt", lang=post.lang) }}
</a>
{% endif %}
</footer>