Einbinden von CustomCSS setzt keine Site-Base mehr davor + kleinere Anpassungen um Leerzeilen zu vermeiden

This commit is contained in:
mdn 2023-01-22 00:47:23 +01:00
parent c14beceef6
commit 631c22e7c6
18 changed files with 134 additions and 146 deletions

View file

@ -1,11 +1,11 @@
{{ with .avatar }}
{{- with .avatar }}
<div class="py-1 text-center">
<img class="rounded-circle" src="{{ . }}" alt="Ansprechendes Bild"/>
</div>
{{ end }}
{{- end -}}
{{ with .description }}
{{- with .description }}
<div class="py-1">
{{ . }}
</div>
{{ end }}
{{- end }}

View file

@ -1,15 +1,15 @@
<div class="tag-cloud d-inline-block m-0 p-0">
{{ $parentLink := (site.GetPage (printf "/%s" .ident)).Permalink }}
{{ $maxCnt := mul 1.0 (index .tax.ByCount 0).Count }}
{{ $minCnt := mul 1.0 (index .tax.ByCount.Reverse 0).Count }}
{{ $div := math.Max 1 (sub $maxCnt $minCnt) }}
{{ range $key, $sites := .tax }}
{{- $parentLink := (site.GetPage (printf "/%s" .ident)).Permalink -}}
{{- $maxCnt := mul 1.0 (index .tax.ByCount 0).Count -}}
{{- $minCnt := mul 1.0 (index .tax.ByCount.Reverse 0).Count -}}
{{- $div := math.Max 1 (sub $maxCnt $minCnt) -}}
{{- range $key, $sites := .tax }}
<!-- add (mul (math.Pow (div $sites.Count $maxCnt) 2.0) 14.0) 8.0 px -->
{{- (printf `<a class="tag-cloud-link m-1 p-1" style="font-size: %.3frem;" href="%s" aria-label="%s %d Einträge">%s<sup>%d</sup></a>`
(add (mul (math.Pow (div (sub $sites.Count $minCnt) $div) 2.0) 0.6) 0.8)
((printf "%s%s" $parentLink $key) | relURL) $key $sites.Count $key $sites.Count
) | safeHTML -}}
<!--<span class="badge">{{ $sites.Count }}</span>-->
{{ end }}
{{- end }}
</div>
{{/* https://mertbakir.gitlab.io/hugo/tag-cloud-in-hugo/ */}}
{{/* https://mertbakir.gitlab.io/hugo/tag-cloud-in-hugo/ */}}

View file

@ -1,2 +1,2 @@
<h4 class="fst-italic border-bottom border-dark mt-2">{{ .title }}</h4>
<!--h4 class="py-1 mb-3 fst-italic text-bg-dark text-center">{{ .title }}</h4-->
<!--h4 class="py-1 mb-3 fst-italic text-bg-dark text-center">{{ .title }}</h4-->

View file

@ -1,16 +1,16 @@
<ul>
{{ range (where . "visible" 1) }}
{{- range (where . "visible" 1) }}
<li>
{{ .name }}
<ul>
{{ range (where .urls "visible" 1) }}
{{- range (where .urls "visible" 1) }}
<li>
<a href="{{ .url }}" target="{{- .target -}}" alt="{{- .description }}">{{ .name }}</a>
<br/>
{{ .description }}
{{- .description }}
</li>
{{ end }}
{{- end }}
</ul>
</li>
{{ end }}
{{- end }}
</ul>

View file

@ -1,36 +1,36 @@
<div class="py-1 social">
<ul class="social-links">
{{ with .Email }}
{{- with .Email }}
<li><a href="mailto:{{ . }}"><i data-feather="mail"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .Phone }}
<li><a href="tel:{{ . }}"><i class="bi" data-feather="phone"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .VoIP }}
<li><a href="sip:{{ . }}"><i data-feather="phone"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .Github }}
<li><a href="https://github.com/{{ . }}" target="_blank"><i data-feather="github"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .Twitter }}
<li><a href="https://twitter.com/{{ . }}" target="_blank"><i class="bi" data-feather="twitter"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .LinkedIn }}
<li><a href="https://linkedin.com/in/{{ . }}" target="_blank"><i class="bi" data-feather="linkedin"></i>&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .Matrix }}
<li><a href="https://matrix.to/#/{{ . }}" target="_blank"><img src="/img/matrix-badge.svg" alt="Chat on matrix">&nbsp;{{ . }}</a></li>
{{ end }}
{{- end -}}
{{ with .RSS }}
<li><a href="{{ . }}"><i class="bi" data-feather="rss"></i>&nbsp;RSS</a></li>
{{ end }}
{{- end }}
</ul>
</div>
<!-- Hier die Links zu Mail usw. vielleicht auch zum SIP Anschluss, vielleicht mit dem Icons aus faether oder Bootstrap -->

View file

@ -1,9 +1,9 @@
<div class="categories mb-2 d-inline-block">
{{ $parentLink := (site.GetPage (printf "/%s" .ident)).Permalink }}
{{ range $key, $sites := .tax }}
{{- $parentLink := (site.GetPage (printf "/%s" .ident)).Permalink -}}
{{- range $key, $sites := .tax }}
<div class="m-1 d-inline-flex">
<a class="bg-dark text-white py-1 px-2 m-0 rounded-start" href="{{ (printf "%s%s" $parentLink $key) | relURL }}">{{ $key }}</a>
<div class="bg-danger text-white py-1 px-2 m-0 rounded-end">{{ $sites.Count }}</div>
</div>
{{ end }}
{{- end }}
</div>