i18n: added missing translations

* Note for term.html: I had to remove the "humanize" and "singularize" operators because this seems to work only for English. Exemple with French: Catégories was transforming to Catégory (accent was kept but "y" was added). So categories we're splited in 2 translations : one for singular, one for plurial.
This commit is contained in:
Victor Lourme 2020-11-18 17:38:23 +01:00
parent 4358a59d6f
commit 3423a92749
5 changed files with 37 additions and 7 deletions

View File

@ -30,3 +30,18 @@
[searchResultTitle]
other = "#PAGES_COUNT pages (#TIME_SECONDS seconds)"
[searchResultPost]
other = "Post"
[categories]
other = "Categories"
[category]
other = "Category"
[footerBuiltWith]
other = "Built with"
[footerDesignedBy]
other = "designed by"

View File

@ -30,3 +30,18 @@
[searchResultTitle]
other = "#PAGES_COUNT pages (#TIME_SECONDS secondes)"
[searchResultPost]
other = "Publication"
[categories]
other = "Catégories"
[category]
other = "Catégorie"
[footerBuiltWith]
other = "Généré avec"
[footerDesignedBy]
other = "conçu par"

View File

@ -2,7 +2,7 @@
{{ define "main" }}
{{ $categories := ($.Site.GetPage "taxonomyTerm" "categories").Pages }}
{{ if $categories }}
<h2 class="section-title">Categories</h2>
<h2 class="section-title">{{ T "categories" }}</h2>
<div class="category-list">
<div class="article-list--tile">
{{ range $categories }}

View File

@ -1,8 +1,8 @@
{{ define "main" }}
<h3 class="taxonomy-type section-title">{{ .Type | singularize | humanize }}</h3>
<h3 class="taxonomy-type section-title">{{ T "category" }}</h3>
<div class="taxonomy-card">
<div class="taxonomy-details">
<h3 class="taxonomy-count">{{ len .Pages }} post{{ if gt (len .Pages) 1 }}s{{ end }}</h3>
<h3 class="taxonomy-count">{{ len .Pages }} {{ T "searchResultPost" }}{{ if gt (len .Pages) 1 }}s{{ end }}</h3>
<h1 class="taxonomy-term">{{ .Title }}</h1>
{{ with .Params.description }}
<h2 class="taxonomy-description">{{ . }}</h2>

View File

@ -1,8 +1,8 @@
<footer class="site-footer">
<section class="copyright">&copy; {{ now.Format "2006" }} {{ .Site.Title }}</section>
<section class="powerby">
Built with <a href="https://gohugo.io/" target="_blank" rel="noopener">Hugo</a> <br />
Theme <b><a href="https://github.com/CaiJimmy/hugo-theme-stack" target="_blank" rel="noopener" data-version="1.1.0">Stack</a></b> designed by
{{ T "footerBuiltWith" }} <a href="https://gohugo.io/" target="_blank" rel="noopener">Hugo</a> <br />
Theme <b><a href="https://github.com/CaiJimmy/hugo-theme-stack" target="_blank" rel="noopener" data-version="1.1.0">Stack</a></b> {{ T "footerDesignedBy" }}
<a href="https://jimmycai.com" target="_blank" rel="noopener">Jimmy</a>
</section>
</footer>