Sidbare-Elemente in widget-Partials ausgelagert
This commit is contained in:
parent
ca19ee452b
commit
9827bb7ba7
15 changed files with 151 additions and 120 deletions
|
@ -2,7 +2,7 @@
|
|||
<nav class="nav justify-content-center navbar-expand-md navbar-dark ">
|
||||
<a class="nav-link" href="#">Impressum & Datenschutz</a>
|
||||
{{ with .OutputFormats.Get "rss" -}}
|
||||
<a class="nav-link" href="{{- .Permalink -}}">RSS-Feed</a>
|
||||
<a class="nav-link" href="{{- .Permalink | relURL -}}">RSS-Feed</a>
|
||||
{{ end }}
|
||||
</nav>
|
||||
|
||||
|
|
|
@ -23,6 +23,6 @@
|
|||
{{ end }}
|
||||
|
||||
{{ range .AlternativeOutputFormats -}}
|
||||
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
|
||||
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type (.Permalink | relURL) $.Site.Title | safeHTML }}
|
||||
{{ end }}
|
||||
</head>
|
||||
|
|
5
layouts/partials/svgs/external-links.svg
Normal file
5
layouts/partials/svgs/external-links.svg
Normal file
|
@ -0,0 +1,5 @@
|
|||
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
fill="{{ .fill }}" width="{{ .width }}" height="{{ .height }}" viewBox="0 0 32 32" aria-label="External Link">
|
||||
<path d="M25.152 16.576v5.696q0 2.144-1.504 3.648t-3.648 1.504h-14.848q-2.144 0-3.648-1.504t-1.504-3.648v-14.848q0-2.112 1.504-3.616t3.648-1.536h12.576q0.224 0 0.384 0.16t0.16 0.416v1.152q0 0.256-0.16 0.416t-0.384 0.16h-12.576q-1.184 0-2.016 0.832t-0.864 2.016v14.848q0 1.184 0.864 2.016t2.016 0.864h14.848q1.184 0 2.016-0.864t0.832-2.016v-5.696q0-0.256 0.16-0.416t0.416-0.16h1.152q0.256 0 0.416 0.16t0.16 0.416zM32 1.152v9.12q0 0.48-0.352 0.8t-0.8 0.352-0.8-0.352l-3.136-3.136-11.648 11.648q-0.16 0.192-0.416 0.192t-0.384-0.192l-2.048-2.048q-0.192-0.16-0.192-0.384t0.192-0.416l11.648-11.648-3.136-3.136q-0.352-0.352-0.352-0.8t0.352-0.8 0.8-0.352h9.12q0.48 0 0.8 0.352t0.352 0.8z">
|
||||
</path>
|
||||
</svg>
|
After Width: | Height: | Size: 913 B |
11
layouts/partials/widget/aboutme.html
Normal file
11
layouts/partials/widget/aboutme.html
Normal file
|
@ -0,0 +1,11 @@
|
|||
{{ with .avatar }}
|
||||
<div class="py-1 text-center">
|
||||
<img class="rounded-circle" src="{{ . }}" alt="Ansprechendes Bild"/>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
{{ with .description }}
|
||||
<div class="py-1">
|
||||
{{ . }}
|
||||
</div>
|
||||
{{ end }}
|
15
layouts/partials/widget/cloud.html
Normal file
15
layouts/partials/widget/cloud.html
Normal file
|
@ -0,0 +1,15 @@
|
|||
<div class="tag-cloud d-inline-block m-0 p-0">
|
||||
{{ $parentLink := ($.Params.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 }}
|
||||
</div>
|
||||
{{/* https://mertbakir.gitlab.io/hugo/tag-cloud-in-hugo/ */}}
|
2
layouts/partials/widget/header.html
Normal file
2
layouts/partials/widget/header.html
Normal file
|
@ -0,0 +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-->
|
36
layouts/partials/widget/socials.html
Normal file
36
layouts/partials/widget/socials.html
Normal file
|
@ -0,0 +1,36 @@
|
|||
<div class="py-1 social">
|
||||
<ul class="social-links">
|
||||
{{ with .Email }}
|
||||
<li><a href="mailto:{{ . }}"><i data-feather="mail"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .Phone }}
|
||||
<li><a href="tel:{{ . }}"><i class="bi" data-feather="phone"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .VoIP }}
|
||||
<li><a href="sip:{{ . }}"><i data-feather="phone"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .Github }}
|
||||
<li><a href="https://github.com/{{ . }}" target="_blank"><i data-feather="github"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .Twitter }}
|
||||
<li><a href="https://twitter.com/{{ . }}" target="_blank"><i class="bi" data-feather="twitter"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .LinkedIn }}
|
||||
<li><a href="https://linkedin.com/in/{{ . }}" target="_blank"><i class="bi" data-feather="linkedin"></i> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .Matrix }}
|
||||
<li><a href="https://matrix.to/#/{{ . }}" target="_blank"><img src="/img/matrix-badge.svg" alt="Chat on matrix"> {{ . }}</a></li>
|
||||
{{ end }}
|
||||
|
||||
{{ with .RSS }}
|
||||
<li><a href="{{ . }}"><i class="bi" data-feather="rss"></i> RSS</a></li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
<!-- Hier die Links zu Mail usw. vielleicht auch zum SIP Anschluss, vielleicht mit dem Icons aus faether oder Bootstrap -->
|
9
layouts/partials/widget/taglist.html
Normal file
9
layouts/partials/widget/taglist.html
Normal file
|
@ -0,0 +1,9 @@
|
|||
<div class="categories mb-2 d-inline-block">
|
||||
{{ $parentLink := ($.Params.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 }}
|
||||
</div>
|
Loading…
Add table
Add a link
Reference in a new issue