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

footer.html « partials « layouts - gitlab.com/rmaguiar/hugo-theme-color-your-world.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: db453711d25fc310e47459a1348d051dfae3cc62 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<!-- Custom or default footer text -->
{{ if (templates.Exists "partials/custom/footer-text.html") }}
  {{ partial "custom/footer-text" . }}
{{ else }}

  {{ with .Site.Params.footerText }}

    {{ $processedFooterText := slice }}

    {{ range . }}
      {{ $currentParagraph := printf `<p>%s</p>` (. | markdownify | emojify) }}
      {{ $processedFooterText = $processedFooterText | append $currentParagraph }}
    {{ end }}
    
    {{ delimit $processedFooterText "" | safeHTML }}

  {{ end }}

{{ end }}

<!--
  TODO
  Maybe I should rethink this
-->

{{ if gt (len .Translations) 0 }}

  {{ $processedLangs := slice }}

  {{ range .Translations }}
    {{ $currentLang := printf `<a rel="alternate" hreflang="%s" href="%s">%s</a>` .Language.Lang .RelPermalink .Language.LanguageName }}
    {{ $processedLangs = $processedLangs | append $currentLang }}
  {{ end }}

  <p>{{ T "alsoAvailable" }}: {{ delimit $processedLangs ", " (T "and") | safeHTML }}.</p>

{{ end }}

<!-- Dark/light mode button and color picker -->
{{ partialCached "footer-opt" . }}