diff --git a/i18n/en.toml b/i18n/en.toml index 9df0c1d..1a7e1c8 100644 --- a/i18n/en.toml +++ b/i18n/en.toml @@ -32,7 +32,7 @@ other = "#PAGES_COUNT pages (#TIME_SECONDS seconds)" [footerBuiltWith] - other = "Built with" - + other = "Built with {{ .Generator }}" + [footerDesignedBy] - other = "designed by" \ No newline at end of file + other = "Theme {{ .Theme }} designed by {{ .DesignedBy }}" \ No newline at end of file diff --git a/i18n/fr.toml b/i18n/fr.toml index 8e33004..03c4efa 100644 --- a/i18n/fr.toml +++ b/i18n/fr.toml @@ -32,7 +32,7 @@ other = "#PAGES_COUNT pages (#TIME_SECONDS secondes)" [footerBuiltWith] - other = "Généré avec" + other = "Généré avec {{ .Generator }}" [footerDesignedBy] - other = "conçu par" \ No newline at end of file + other = "Thème {{ .Theme }} conçu par {{ .DesignedBy }}" \ No newline at end of file diff --git a/layouts/partials/footer/footer.html b/layouts/partials/footer/footer.html index 9821e0c..6bd37b2 100644 --- a/layouts/partials/footer/footer.html +++ b/layouts/partials/footer/footer.html @@ -1,8 +1,12 @@ +{{- $ThemeVersion := "1.1.0" -}} <footer class="site-footer"> <section class="copyright">© {{ now.Format "2006" }} {{ .Site.Title }}</section> <section class="powerby"> - {{ 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> + {{- $Generator := `<a href="https://gohugo.io/" target="_blank" rel="noopener">Hugo</a>` -}} + {{- $Theme := printf `<b><a href="https://github.com/CaiJimmy/hugo-theme-stack" target="_blank" rel="noopener" data-version="%s">Stack</a></b>` $ThemeVersion -}} + {{- $DesignedBy := `<a href="https://jimmycai.com" target="_blank" rel="noopener">Jimmy</a>` -}} + + {{ T "footerBuiltWith" (dict "Generator" $Generator) | safeHTML }} <br /> + {{ T "footerDesignedBy" (dict "Theme" $Theme "DesignedBy" $DesignedBy) | safeHTML }} </section> </footer> \ No newline at end of file