forked from Bunteshaus/bunteshaus.de
small fixes
This commit is contained in:
parent
f48836ef31
commit
5c66b00d90
|
@ -1,7 +0,0 @@
|
|||
{{ $url := (printf "%s#%s" .Page.Permalink .Anchor) | safeURL }}
|
||||
<h{{ .Level }} id="{{ .Anchor | safeURL }}">
|
||||
|
||||
<a class="heading-anchor" href="{{ $url }}">
|
||||
{{ .Text | safeHTML }}
|
||||
</a>
|
||||
</h{{ .Level }}>
|
|
@ -1,35 +0,0 @@
|
|||
{{- if strings.HasPrefix .Destination "http" -}}
|
||||
<a href="{{- .Destination -}}">
|
||||
<img loading="lazy"
|
||||
src="{{ .Destination | safeURL }}"
|
||||
alt="{{ .Text }}"
|
||||
{{ with .Title}} title="{{ . }}"{{ end }} />
|
||||
<div style="display: flex; justify-content: center;">{{ .Text }}</div>
|
||||
</a>
|
||||
{{- else -}}
|
||||
{{ if .Page.Resources.ByType "image" }}
|
||||
{{ $nr := .Destination }}
|
||||
{{- $pic := index (.Page.Resources.ByType "image") (int $nr) -}}
|
||||
{{- $image := .Page.Resources.GetMatch (printf "%s" ($pic | safeURL)) -}}
|
||||
<div>
|
||||
<a href="{{- $image.Permalink -}}">
|
||||
{{- $permalink := "" -}}
|
||||
|
||||
{{- if ne $image nil -}}
|
||||
{{- $permalink = $image.RelPermalink -}}
|
||||
{{- else -}}
|
||||
{{- $image = imageConfig (printf "static/%s" (.Destination | safeURL)) -}}
|
||||
{{- $permalink = (printf "/%s" (.Destination | safeURL)) -}}
|
||||
{{- end -}}
|
||||
|
||||
<div style="display: flex; justify-content: center;"><img loading="lazy"
|
||||
src="{{ $permalink }}"
|
||||
alt="{{ .Text }}"
|
||||
{{ with .Title}} title="{{ . }}"{{ end }}
|
||||
width={{ $image.Width }}
|
||||
height="{{ $image.Height }}" /></div>
|
||||
<div style="display: flex; justify-content: center;">{{ .Text }}</div>
|
||||
</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{- end -}}
|
|
@ -1,11 +0,0 @@
|
|||
{{ define "title" }}
|
||||
{{ $name := "archive" }}
|
||||
{{ if lower $name | i18n }}
|
||||
{{ $name = lower $name | i18n }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ partial "layout/archive" . }}
|
||||
{{ end }}
|
|
@ -1,27 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
{{- partial "structure/head.html" . -}}
|
||||
{{ block "css" . -}}{{- end }}
|
||||
<body>
|
||||
<div class="container">
|
||||
<header>
|
||||
{{ partialCached "structure/header" . }}
|
||||
{{ partial "structure/submenu" . }}
|
||||
</header>
|
||||
<div class="content">
|
||||
<main>
|
||||
{{ block "title" . -}}{{- end }}
|
||||
{{ block "content" . -}}{{- end }}
|
||||
{{ block "main" . -}}{{- end }}
|
||||
</main>
|
||||
<aside class="right-sidebar">
|
||||
{{ block "sidebar" . -}}{{- end }}
|
||||
</aside>
|
||||
</div>
|
||||
{{ block "pagefooter" . -}}{{- end }}
|
||||
<footer>
|
||||
{{- partial "contentlayouts/footer" . -}}
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,16 +0,0 @@
|
|||
{{ define "title" }}
|
||||
{{ $name := "contact" }}
|
||||
{{ if lower $name | i18n }}
|
||||
{{ $name = lower $name | i18n }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ if site.Params.debug }}contact.html{{ end }}
|
||||
{{- $pic := index (.Resources.ByType "image") 0 -}}
|
||||
|
||||
<article>
|
||||
{{ partial "contentlayouts/article.html" (dict "context" . "type" "contact") }}
|
||||
</article>
|
||||
{{ end }}
|
|
@ -1,28 +0,0 @@
|
|||
{{ define "title" }}
|
||||
{{ $name := "imprint" }}
|
||||
{{ if lower $name | i18n }}
|
||||
{{ $name = lower $name | i18n }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ if site.Params.debug }}imprint.html{{ end }}
|
||||
{{ if .Resources.ByType "image" }}
|
||||
<div style="clear:both;"></div>
|
||||
<div style="max-width: 25ch; padding: 0 0.8em 0.2em 0; float: right;">
|
||||
|
||||
{{ range .Resources.ByType "image" }}
|
||||
<a href="{{- .Permalink -}}"><img src="{{- .Permalink -}}"/></a>
|
||||
{{- end -}}
|
||||
{{ end }}
|
||||
|
||||
{{ if .Resources.ByType "image" }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<article>
|
||||
{{ partial "structure/contact" }}
|
||||
{{ if i18n "executive" }}{{ i18n "executive" }}{{ else }}{{ "Executive" }}{{ end }}: {{ site.Params.imprintdata.executive }}
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}
|
|
@ -1,31 +0,0 @@
|
|||
{{- define "title" -}}
|
||||
{{ $name := .Name | lower }}
|
||||
{{ if ne ($name | i18n) "" }}
|
||||
{{ $name = $name | i18n }}
|
||||
{{ else }}
|
||||
{{ if and (ne .Section "events") (ne .Section "links") }}
|
||||
{{ $name = $name | singularize }}
|
||||
{{ end }}
|
||||
{{ $name = $name | humanize }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{- end -}}
|
||||
|
||||
{{- define "main" -}}
|
||||
{{ if ne .Content "" }}
|
||||
<article style="margin-bottom: 0; margin-top: 0;">
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}<br>
|
||||
{{ range .Pages }}
|
||||
<article style="margin-bottom: 0; margin-top: 0;">
|
||||
<h3><a href="{{ .Params.link }}">{{ .Params.link }}</a></h3>
|
||||
{{ .Title }}
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{- end -}}
|
||||
|
||||
{{ define "sidebar" }}
|
||||
{{- partial "contentlayouts/menu.html" . }}
|
||||
{{ end }}
|
|
@ -1,12 +0,0 @@
|
|||
{{ define "title" }}
|
||||
<h1>{{ if i18n .Section }}{{ i18n .Section }}{{ else }}{{ "Misc" }}{{ end }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ partial "debug" (dict "context" . ) }}
|
||||
<article>
|
||||
{{ range .Pages }}
|
||||
<a href="{{ .Permalink }}">{{ .Name }}</a><br>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
|
@ -1,12 +0,0 @@
|
|||
{{ define "title" }}
|
||||
<h1>{{ if i18n .Section }}{{ i18n .Section }}{{ else }}{{ "Misc" }}{{ end }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ partial "debug" (dict "context" . ) }}
|
||||
<article>
|
||||
{{ range .Pages }}
|
||||
<a href="{{ .Permalink }}">{{ .Name }}</a><br>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
|
@ -1,31 +0,0 @@
|
|||
{{- define "title" -}}
|
||||
{{ $name := .Name | lower }}
|
||||
{{ if ne ($name | i18n) "" }}
|
||||
{{ $name = $name | i18n }}
|
||||
{{ else }}
|
||||
{{ if ne .Section "events" }}
|
||||
{{ $name = $name | singularize }}
|
||||
{{ end }}
|
||||
{{ $name = $name | humanize }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{- end -}}
|
||||
|
||||
{{- define "main" -}}
|
||||
{{ partial "debug" (dict "context" . "filename" "news.html") }}
|
||||
{{- $paginator := .Paginate .Data.Pages -}}
|
||||
|
||||
{{ if eq $paginator.PageNumber 1 }}
|
||||
{{ if ne .Content "" }}
|
||||
<article>
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ partial "contentlayouts/list.html" (dict "context" . "paginator" $paginator "amount" "5") }}
|
||||
{{ partial "structure/paginator" (dict "paginator" $paginator) }}
|
||||
{{- end -}}
|
||||
|
||||
{{ define "sidebar" }}
|
||||
{{- partial "contentlayouts/menu.html" . }}
|
||||
{{ end }}
|
|
@ -1,25 +0,0 @@
|
|||
{{- define "title" -}}
|
||||
{{ $name := .Name | lower }}
|
||||
{{ if ne ($name | i18n) "" }}
|
||||
{{ $name = $name | i18n }}
|
||||
{{ else }}
|
||||
{{ if ne .Section "events" }}
|
||||
{{ $name = $name | singularize }}
|
||||
{{ end }}
|
||||
{{ $name = $name | humanize }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{- end -}}
|
||||
|
||||
{{- define "main" -}}
|
||||
{{ partial "debug" (dict "context" . ) }}
|
||||
{{ if ne .Content "" }}
|
||||
<article>
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{- end -}}
|
||||
|
||||
{{ define "sidebar" }}
|
||||
{{- partial "contentlayouts/menu.html" . }}
|
||||
{{ end }}
|
|
@ -1,75 +0,0 @@
|
|||
{{- $pages := where (where .Site.RegularPages "Permalink" "!=" .Permalink) "Type" "in" .Site.Params.searchSections -}}
|
||||
{{- $title := lower .Title -}}
|
||||
{{- if eq $title "events" -}}
|
||||
{{- $pages = where $pages ".Params.when" "ne" nil -}}
|
||||
{{- end -}}
|
||||
{{- $limit := .Site.Config.Services.RSS.Limit -}}
|
||||
{{- if ge $limit 1 -}}
|
||||
{{- $pages = $pages | first $limit -}}
|
||||
{{- end -}}
|
||||
{{- $pages = $pages.ByLastmod.Reverse -}}
|
||||
{{- printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?>" | safeHTML }}
|
||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
||||
<channel>
|
||||
<title>{{ .Site.Title }}</title>
|
||||
<link>{{ .Permalink }}</link>
|
||||
<description>Aktuelles von {{ .Site.Title }}</description>
|
||||
<generator>Hugo -- gohugo.io</generator>{{ with .Site.LanguageCode }}
|
||||
<language>{{.}}</language>{{end}}{{ with .Site.Author.email }}
|
||||
<managingEditor>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</managingEditor>{{end}}{{ with .Site.Author.email }}
|
||||
<webMaster>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</webMaster>{{end}}{{ with .Site.Copyright }}
|
||||
<copyright>{{.}}</copyright>{{end}}{{ if not .Date.IsZero }}
|
||||
<lastBuildDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
|
||||
{{- with .OutputFormats.Get "RSS" -}}
|
||||
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
|
||||
{{- end -}}
|
||||
{{ range where $pages "Type" "in" .Site.Params.searchSections }}
|
||||
{{ $when := .Params.when }}
|
||||
{{ $about := .Params.about }}
|
||||
{{ $covid := .Params.covid }}
|
||||
{{ $contact := .Params.contact }}
|
||||
{{ $price := .Params.price }}
|
||||
{{ $featured := .Params.featured }}
|
||||
{{ $categories := slice }}
|
||||
{{ range .Params.categories }}
|
||||
{{ $categories = $categories | append . }}
|
||||
{{ end }}
|
||||
{{ $events := slice }}
|
||||
{{ range .Params.events }}
|
||||
{{ $events = $events | append . }}
|
||||
{{ end }}
|
||||
{{ $tags := slice }}
|
||||
{{ range .Params.tags }}
|
||||
{{ $tags = $tags | append . }}
|
||||
{{ end }}
|
||||
{{ $images := slice }}
|
||||
{{ range .Resources.ByType "image" }}
|
||||
{{ $images = $images | append . }}
|
||||
{{ end }}
|
||||
{{ $hash := slice $when $about $categories $events $covid $contact $price $featured $tags .Date .Lastmod .Title .Content }}
|
||||
{{ $hash = delimit $hash ", " }}
|
||||
{{ $hash = md5 $hash }}
|
||||
|
||||
<item>
|
||||
<title>{{ .Title }}</title>
|
||||
<link>{{ .Permalink }}</link>
|
||||
<pubDate>{{ .Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</pubDate>
|
||||
{{ with .Site.Author.email }}<author>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</author>{{end}}
|
||||
<guid>{{ .Permalink }}-{{ $hash }}</guid>
|
||||
<description>
|
||||
{{- $c := replace .Content "<img" "<img width=\"600\"" -}}
|
||||
{{- if $when -}}
|
||||
{{- $c = printf "<p><b>%s</b></p>%s" $when $c -}}
|
||||
{{- end -}}
|
||||
{{- $img := index (.Resources.ByType "image") 0 -}}
|
||||
{{- with $img -}}
|
||||
{{- $img := .Resize "640x" -}}
|
||||
{{- $c = printf "%s<img src=\"%s\" width=\"%d\" height=\"%d\" />" $c $img.Permalink $img.Width $img.Height -}}
|
||||
{{- end -}}
|
||||
{{- printf "<![CDATA[%s]]>" $c | safeHTML -}}
|
||||
</description>
|
||||
|
||||
</item>
|
||||
{{ end }}
|
||||
</channel>
|
||||
</rss>
|
|
@ -1,46 +0,0 @@
|
|||
{{ define "title" }}
|
||||
{{ $name := .Title }}
|
||||
{{ if lower $name | i18n }}
|
||||
{{ $name = lower $name | i18n }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{ end }}
|
||||
|
||||
{{ define "main" }}
|
||||
{{ partial "debug" (dict "context" . "caller" "single.html" )}}
|
||||
<article>
|
||||
{{ if eq .Type "tools" }}
|
||||
<article>
|
||||
{{ $tool := printf "misc/%s" .Params.tool }}
|
||||
{{ partial $tool . }}
|
||||
</article>
|
||||
{{ else }}
|
||||
<article>
|
||||
{{ partial "contentlayouts/article.html" (dict "context" . "type" "article") }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ define "pagefooter" }}
|
||||
{{ if and (ne .Section "misc") (eq .Type "tools") }}
|
||||
<div id="article_footer">
|
||||
<div style="flex-grow: 1; flex-direction: column;">
|
||||
<b>{{ if i18n "created" }}{{ i18n "created" }}{{ else }}{{ "Created" }}{{ end }}</b><br>
|
||||
{{ .Date | time.Format ":date_full" }}
|
||||
</div>
|
||||
{{ if ne .Date .Lastmod }}
|
||||
<div style="flex-grow: 1; flex-direction: column;">
|
||||
<b>{{ if i18n "lastmod" }}{{ i18n "lastmod" }}{{ else }}{{ "Last modification" }}{{ end }}</b><br>
|
||||
{{ .Lastmod | time.Format ":date_full" }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
|
||||
{{ define "sidebar" }}
|
||||
{{ if ne .Type "tools" }}
|
||||
{{- partial "contentlayouts/menu.html" . }}
|
||||
{{ end }}
|
||||
{{ end }}
|
|
@ -1,43 +0,0 @@
|
|||
{{- define "title" -}}
|
||||
{{ $name := .Name }}
|
||||
{{ if ne ($name | lower | i18n) "" }}
|
||||
{{ $name = $name | lower | i18n }}
|
||||
{{ end }}
|
||||
<h1>{{ $name }}</h1>
|
||||
{{- end -}}
|
||||
|
||||
{{- define "main" -}}
|
||||
{{ partial "debug" (dict "context" . "caller" "taxonomy.html") }}
|
||||
{{ $title := lower .Title }}
|
||||
{{- $paginator := slice -}}
|
||||
{{ $partial := "contentlayouts/list.html" }}
|
||||
{{ $what := printf ".Params.%s" $title }}
|
||||
|
||||
{{- $posts := where (where .Site.RegularPages "Permalink" "!=" .Permalink) "Type" "in" .Site.Params.searchSections }}
|
||||
|
||||
{{ if or (eq $title "about") (eq $title "featured") }}
|
||||
{{- $paginator = .Paginate (where $posts $what "eq" true) -}}
|
||||
{{ else if or (eq $title "tags") (eq $title "categories") }}
|
||||
{{- $paginator = .Paginate $posts -}}
|
||||
{{ $partial = "contentlayouts/termlist.html" }}
|
||||
{{ else if eq $title "events" }}
|
||||
{{- $paginator = .Paginate (where $posts ".Params.when" "ne" nil) -}}
|
||||
{{ else if eq .Section "about" }}
|
||||
{{- $paginator = .Paginate (where $posts ".Params.about" "eq" true) -}}
|
||||
{{ else }}
|
||||
{{- $paginator = .Paginate .Data.Pages -}}
|
||||
{{ end }}
|
||||
{{ if eq $paginator.PageNumber 1 }}
|
||||
{{ if ne .Content "" }}
|
||||
<article>
|
||||
{{ .Content }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ partial $partial (dict "context" . "paginator" $paginator "amount" "5") }}
|
||||
{{ partial "structure/paginator" (dict "paginator" $paginator) }}
|
||||
{{- end -}}
|
||||
|
||||
{{ define "sidebar" }}
|
||||
{{- partial "contentlayouts/menu.html" . }}
|
||||
{{ end }}
|
|
@ -12,8 +12,9 @@
|
|||
{{- $paginator := "" -}}
|
||||
{{ $part := .Layout }}
|
||||
{{ $partial_before := "" }}
|
||||
{{ $paginate := true }}
|
||||
{{ $paginate := false }}
|
||||
{{ if eq .Layout "article_list" }}
|
||||
{{ $paginate = true }}
|
||||
{{ if eq .Section "events" }}
|
||||
{{- $pages = where $pages ".Params.when" "ne" nil -}}
|
||||
{{ else if eq .Type "about" }}
|
||||
|
@ -32,7 +33,6 @@
|
|||
{{ else if eq .Kind "taxonomy" }}
|
||||
{{- $pages = .Data.Terms.Alphabetical -}}
|
||||
{{ $part = "tags_n_categories" }}
|
||||
{{ $paginate = false }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if eq $paginate true}}
|
||||
|
@ -40,6 +40,6 @@
|
|||
{{ end }}
|
||||
{{ if and $pre $part }}
|
||||
{{ $partial := string (printf "%s/%s" $pre $part) }}
|
||||
{{ partial $partial (dict "context" . "paginator" $paginator "pages" $pages "amount" "5" "title" $title "content" .Content "pic" $pic "type" .Type "partial_before" $partial_before) }}
|
||||
{{ partial $partial (dict "context" . "paginator" $paginator "pages" $pages "amount" "5" "title" $title "content" .Content "pic" $pic "type" .Type "partial_before" $partial_before "paginate" $paginate) }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
|
|
@ -1,51 +0,0 @@
|
|||
{{ $showmeta := "false" }}
|
||||
{{ $metas := dict "when" .context.Params.when "price" .context.Params.price "contact" .context.Params.contact "covid"
|
||||
.context.Params.covid }}
|
||||
{{ if eq .type "list" }}
|
||||
{{ $metas = dict "when" .context.Params.when "price" .context.Params.price }}
|
||||
{{ end }}
|
||||
{{ partial "contentlayouts/meta.html" $metas }}
|
||||
|
||||
{{ $small := "solo" }}
|
||||
{{ $big := "solo" }}
|
||||
{{ $img := "" }}
|
||||
{{ $thumb := "" }}
|
||||
{{ $placeholder := site.Params.placeholder }}
|
||||
{{ if ne .context.Section "misc"}}
|
||||
{{ $img = resources.Get $placeholder }}
|
||||
{{- $thumb = $img.Resize "1024x" }}
|
||||
{{ end }}
|
||||
{{- if or (.context.Resources.ByType "image") (.Summary) ($img) -}}
|
||||
{{ $small = "multiple_small" }}
|
||||
{{ $big = "multiple_big" }}
|
||||
{{ else }}
|
||||
{{ $small = "multiple_big"}}
|
||||
{{ end }}
|
||||
|
||||
{{- if and (.context.Resources.ByType "image") (ne .context.Section "misc") -}}
|
||||
{{- $img = index (.context.Resources.ByType "image") 0 -}}
|
||||
{{- $thumb = $img.Resize "1024x" }}
|
||||
{{ if ne .context.Content "" }}
|
||||
{{- $thumb = $img.Resize "2048x" }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<div id="articleinner">
|
||||
{{ if ne $img "" }}
|
||||
<div id="articlepicture" class="{{ $small }} borderrad25">
|
||||
{{ if and (ne .type "list") (.context.Resources.ByType "image") }}<a href="{{- $img.Permalink -}}">{{ end }}
|
||||
<img src="{{- $thumb.Permalink -}}" class="borderrad25" />
|
||||
{{ if ne .type "list" }}</a>{{ end }}
|
||||
{{ if eq .type "article" }}{{ .TableOfContents }}{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
{{- if or .context.Content .context.Summary -}}
|
||||
<div id="articletext" class="{{ $big }}">
|
||||
{{ if eq .type "contact" }}{{ partial "structure/contact" }}{{ end }}
|
||||
{{ if eq .type "list" }}{{- .context.Summary -}}{{ else }}{{- .context.Content -}}{{ end }}
|
||||
{{ if and .context.Truncated (eq .type "list") }}
|
||||
<div id="readmore">{{- if i18n "readmore" -}}{{- i18n "readmore" -}}{{- else -}}{{- "readmore" -}}{{- end -}}..</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{- end }}
|
||||
</div>
|
|
@ -1,55 +0,0 @@
|
|||
{{- if eq site.Params.contact true }}
|
||||
<div class="infobox">
|
||||
{{ $contact := "Contact" }}
|
||||
{{ if i18n "contact" }}
|
||||
{{ $contact = i18n "contact" }}
|
||||
{{ end }}
|
||||
<a href="{{- "contact" | absLangURL -}}">{{- $contact | strings.FirstUpper -}}:</a><br><br>
|
||||
{{- partial "structure/contact" -}}
|
||||
</div>
|
||||
{{- end -}}
|
||||
|
||||
<div class="infobox">
|
||||
{{- if eq site.Params.archive true -}}
|
||||
{{ $archive := "Archive" }}
|
||||
{{ if i18n "archive" }}
|
||||
{{ $archive = i18n "archive" }}
|
||||
{{ end }}
|
||||
<a href="{{- "archive" | absLangURL -}}">{{- $archive | strings.FirstUpper -}}</a><br><br>
|
||||
{{- end -}}
|
||||
{{- if eq site.Params.newsletter true -}}
|
||||
{{ $newsletter := "Newsletter" }}
|
||||
{{ if i18n "newsletter" }}
|
||||
{{ $newsletter = i18n "newsletter" }}
|
||||
{{ end }}
|
||||
<a href="{{- "newsletter" | absLangURL -}}">{{- $newsletter | strings.FirstUpper -}}</a><br><br>
|
||||
{{- end -}}
|
||||
<a href="{{- "misc" | absLangURL -}}">Misc</a><br><br>
|
||||
</div>
|
||||
|
||||
<div class="infobox">
|
||||
{{- if eq site.Params.imprint true -}}
|
||||
{{ $imprint := "Imprint" }}
|
||||
{{ if i18n "imprint" }}
|
||||
{{ $imprint = i18n "imprint" }}
|
||||
{{ end }}
|
||||
<a href="{{- "imprint" | absLangURL -}}">{{- $imprint | strings.FirstUpper -}}</a><br><br>
|
||||
{{- end -}}
|
||||
{{- if eq site.Params.links true -}}
|
||||
{{ $links := "Links" }}
|
||||
{{ if i18n "links" }}
|
||||
{{ $links = i18n "links" }}
|
||||
{{ end }}
|
||||
<a href="{{- "links" | absLangURL -}}">{{- $links | strings.FirstUpper -}}</a><br><br>
|
||||
{{- end -}}
|
||||
{{- if not (or (eq .Section "featured") (eq .Section "about")) -}}
|
||||
{{- with .OutputFormats.Get "rss" -}}
|
||||
{{- if .Permalink -}}
|
||||
{{- printf `<a href="%s">` .Permalink | safeHTML -}}
|
||||
{{- end -}}
|
||||
RSS</a><br><br>
|
||||
{{- end -}}
|
||||
{{ end }}
|
||||
<a href="https://schlomp.space/Bunteshaus/bunteshaus.de">Sourcecode</a>
|
||||
</div>
|
||||
|
|
@ -1,27 +0,0 @@
|
|||
{{ if gt .Site.Taxonomies.categories 0 }}
|
||||
<li class="align_menu"><a href="{{ "/news" | relLangURL}}"><h3>{{ if i18n "news" }}{{ i18n "news" }}{{ else }}{{ "News" }}{{ end }}</h3></a></li>
|
||||
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.categories }}
|
||||
{{ $orig := $taxonomyname }}
|
||||
{{ if ne (i18n $taxonomyname) "" }}
|
||||
{{ $taxonomyname = i18n $taxonomyname }}
|
||||
{{ else }}
|
||||
{{ $taxonomyname = $taxonomyname | humanize }}
|
||||
{{ end }}
|
||||
<li class="align_menu"><a href="{{ "categories/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if gt .Site.Taxonomies.events 0 }}
|
||||
<li class="align_menu"><a href="{{ "/events" | relLangURL}}"><h3>{{ if i18n "events" }}{{ i18n "events" }}{{ else }}{{ "Events" }}{{ end }}</h3></a></li>
|
||||
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.events }}
|
||||
{{ $orig := $taxonomyname }}
|
||||
{{ if ne (i18n $taxonomyname) "" }}
|
||||
{{ $taxonomyname = i18n $taxonomyname }}
|
||||
{{ else }}
|
||||
{{ $taxonomyname = $taxonomyname | humanize }}
|
||||
{{ end }}
|
||||
<li class="align_menu"><a href="{{ "events/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if .IsHome }}
|
||||
{{ partial "structure/langs" . }}
|
||||
{{ end }}
|
|
@ -1,18 +0,0 @@
|
|||
<div id="articlemeta" style="font-size: smaller;">
|
||||
{{ if .when }}
|
||||
<div>{{ .when }}</div>
|
||||
{{ end }}
|
||||
{{ if .price }}
|
||||
{{ if eq .price "free" }}
|
||||
<div>{{ if i18n "freeentry" }}{{ i18n "freeentry" }}{{ else }}{{ "Free Entry" }}{{ end }}</div>
|
||||
{{ else }}
|
||||
<div>{{ if i18n "entry" }}{{ i18n "entry" }}{{ else }}{{ "Entry" }}{{ end }}: {{ .price }}</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if .contact }}
|
||||
<div>{{ if i18n "contact" }}{{ i18n "contact" }}{{ else }}{{ "Contact" }}{{ end }} {{ .contact | markdownify }} {{ if i18n "or" }}{{ i18n "or" }}{{ else }}{{ "or" }}{{ end }} {{ site.Params.imprintdata.tel }}</div>
|
||||
{{ end }}
|
||||
{{ if .covid }}
|
||||
<div>Covid: {{ .covid }}</div>
|
||||
{{ end }}
|
||||
</div>
|
|
@ -1,29 +0,0 @@
|
|||
{{ $name := .context.Title }}
|
||||
{{ $title := lower .context.Title }}
|
||||
|
||||
|
||||
{{ range $taxonomyname, $taxonomy := .context.Site.Taxonomies }}
|
||||
{{ if eq $title $taxonomyname }}
|
||||
{{ range $key, $value := $taxonomy }}
|
||||
<a href="{{ printf "%s" $key }}">{{ $key }}</a>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
|
||||
{{ if and site.Params.debug false }}
|
||||
{{ range $taxonomyname, $taxonomy := .context.Site.Taxonomies }}
|
||||
<li><a href="/{{ $taxonomyname | urlize }}">{{ $taxonomyname }}</a>
|
||||
<ul>
|
||||
{{ range $key, $value := $taxonomy }}
|
||||
<li> {{ $key }} </li>
|
||||
<ul>
|
||||
{{ range $value.Pages }}
|
||||
<li hugo-nav="{{ .RelPermalink}}"><a href="{{ .Permalink}}"> {{ .LinkTitle }} </a> </li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ end }}
|
|
@ -1,8 +0,0 @@
|
|||
{{ if eq site.Params.debug true }}
|
||||
Title: {{ .context.Title }}<br>
|
||||
Name: {{ .context.Name }}<br>
|
||||
section: {{ .context.Section }}<br>
|
||||
type: {{ .context.Type }}<br>
|
||||
{{ if .caller }}caller: {{ .caller }}<br>{{ end }}
|
||||
kind: {{ .context.Kind }}
|
||||
{{ end }}
|
|
@ -1,16 +0,0 @@
|
|||
|
||||
{{ partial "debug" (dict "context" . "caller" "archive.html" )}}
|
||||
<article>
|
||||
{{ $prev := 3000}}
|
||||
{{range where .Site.RegularPages "Type" "in" site.Params.searchSections }}
|
||||
{{ $date := .Date }}
|
||||
{{ if gt $prev ($date.Format "2006") }}
|
||||
<h2>{{ $date.Format "2006" }}</h2>
|
||||
{{end}}
|
||||
<div class="frow">
|
||||
<div class="underline" style="margin-right: 1em;"><a href="{{.Permalink}}">{{ .Title }}</a></div>
|
||||
<div class="frow" style="margin-right: 1em;">{{- $date.Format "02" }}. {{ if $date.Format "Jan" | i18n }}{{ $date.Format "Jan" | i18n -}}{{- else -}} {{- $date.Format "Jan" -}}{{- end }} {{ $date.Format "2006 15:04" }}</div><br>
|
||||
</div>
|
||||
{{ $prev = $date.Format "2006"}}
|
||||
{{end}}
|
||||
</article>
|
|
@ -1,3 +0,0 @@
|
|||
|
||||
<input type="checkbox" name="{{ .name }}" id="{{ .name }}" value="true" style="font-size: smaller; margin-right: 0;" >
|
||||
<label for="{{ .name }}" style="font-size: smaller; margin: 0;"> {{ if i18n "expand" }}{{ i18n "expand" }}{{ else }}{{ "expand" }}{{ end }}</label>
|
|
@ -1,142 +0,0 @@
|
|||
{{ $pageform := (index .context.Page.Params.forms .form) }}
|
||||
{{ $group := slice }}
|
||||
{{ $divide := .context.Page.Params.divide }}
|
||||
<form id="myform">
|
||||
|
||||
|
||||
{{ range $pageform.fields }}
|
||||
{{ $title := .title }}
|
||||
{{ $name := $title }}
|
||||
{{ if .name }}
|
||||
{{ $name = .name }}
|
||||
{{ end }}
|
||||
|
||||
{{ if and .group (not (in $group .group))}}
|
||||
<div class="margin_top_1rem">
|
||||
{{ if i18n (singularize .group) }}{{ i18n (singularize .group) }}{{ else }}{{ humanize .group }}{{ end }}
|
||||
{{ partial "misc/expand" (dict "name" (printf "%sgroup" .group)) }}
|
||||
</div>
|
||||
{{ $group = $group | append .group }}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq .input_type "title" }}
|
||||
<h3 {{ if .group }}class="visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'"{{ end }}>{{- $name -}}{{- if .required -}}{{- " *" -}}{{- end -}}</h3>
|
||||
{{ else if eq .input_type "textarea" }}
|
||||
<div {{ if .group }}class="visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'"{{ end }}>
|
||||
<label {{ if $pageform.names }}sr-only{{ end }} for="{{ .title }}">{{- $name -}}{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<textarea name="{{ .title }}" id="{{ .title }}" rows="10" {{ if $pageform.names }}placeholder="{{ .name }}{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}></textarea>
|
||||
</div>
|
||||
{{ else if eq .input_type "radio" }}
|
||||
<div class="radio {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<label><input type="radio" name="{{ .title }}" id="{{ .title }}" value="{{ .name }}" {{ .Scratch.Get "requiredtext" }}>{{- $name -}}{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
</div>
|
||||
{{ else if eq .input_type "checkbox" }}
|
||||
<div class="checkbox {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<label><input type="checkbox" name="{{ .title }}" id="{{ .title }}" value="{{ .name }}" {{ .Scratch.Get "requiredtext" }}>{{- $name -}}{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
</div>
|
||||
{{ else if eq .input_type "results" }}
|
||||
<div id='display' class="result" style="white-space: pre; display: none; background: var(--background-body); padding: .6rem 0 1rem 1rem;"></div>
|
||||
{{ else if eq .input_type "submit" }}
|
||||
<div class="margin_top_1rem {{ if .group }}visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<input type="{{ .input_type }}" value="{{- $name -}}" onclick="showInput(event);" />
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{{ else if eq .input_type "mc" }}
|
||||
{{ $in0 := .title }}
|
||||
|
||||
{{- $finale := slice -}}
|
||||
{{ $pages := where site.RegularPages "Type" "in" site.Params.searchSections }}
|
||||
{{ if eq .title "tags" }}
|
||||
{{ range $pages }}
|
||||
{{- if .Params.tags -}}
|
||||
{{- $finale = $finale | append .Params.tags -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
{{ range $pages }}
|
||||
{{ range .Param $in0 }}
|
||||
{{- $finale = $finale | append . -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{- $finale = $finale | uniq -}}
|
||||
|
||||
<div class="margin_top_1rem {{- if .group }} visibleIf" data-visibleif-rule="{{ .group }}group == 'true'"{{ else }}"{{ end }} style="flex-direction: column;">
|
||||
<div class="{{- if .group }}margin_left_1rem{{ end }}">
|
||||
{{ .name }}
|
||||
{{ if ne .expanded true }}{{ partial "misc/expand" (dict "name" (printf "%scat" $in0)) }}{{ end }}{{- if .required -}}{{- " *" -}}{{- end -}}
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="checkbox {{ if ne .expanded true }}visibleIf" data-visibleif-rule="{{ $in0 }}cat == 'true'{{end}}">
|
||||
|
||||
|
||||
<div class="{{- if .group }} margin_left_1rem{{ end }} minmax" style="display: flex; flex-direction: column;">
|
||||
<fieldset id="{{ $in0 }}" name="{{ $in0 }}" style="display: flex; flex-direction: row; padding: 0; border: none; margin: 0 0 .3rem .5rem;">
|
||||
{{ range sort $finale }}
|
||||
<input type="checkbox" name="{{ $in0 }}" id="{{ $in0 }}-cat" value="{{ . }}"><label for="{{ $in0 }}-cat">{{ . }}</label>
|
||||
{{ end }}
|
||||
</fieldset>
|
||||
{{ if .new }}
|
||||
<label id="label" for="new{{- .title -}}">{{ .new }} <span style="font-size: x-small;">({{ $divide }})</span></label>
|
||||
<input type="text" name="new{{- .title -}}" id="new{{- .title -}}" value="" placeholder="{{ .eg }}" />
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{{ else }}
|
||||
{{ if eq .title "name" }}
|
||||
<div class="half {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="firstname">First name{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="text" name="firstname" id="firstname" {{ if $pageform.names }}placeholder="First name{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
<div class="half {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="lastname">Last name{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="text" name="lastname" id="lastname" {{ if $pageform.names }}placeholder="Last name{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
{{ else if eq .title "address" }}
|
||||
<div {{- if .group }} class="visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'"{{ end -}}>
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="address">Address{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="text" name="address" id="address" {{ if $pageform.names }}placeholder="Address{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
<div class="half {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true{{ end }}">
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="city">City{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="text" name="city" id="city" {{ if $pageform.names }}placeholder="City{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
|
||||
<div class="half {{- if .group }} visibleIf margin_left_1rem" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="postalcode">Postal code{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="text" name="postalcode" id="postalcode" {{ if $pageform.names }}placeholder="Postal code{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
{{ else }}
|
||||
<div class="margin_top_1rem {{ if .group }} visibleIf margin_left_1rem" data-visibleif-rule=" {{ .group }}group == 'true' {{ end }}" class="minmax">
|
||||
<div class="minmax" style="display: flex; flex-direction: column;">
|
||||
<label class="{{ if $pageform.names }}sr-only{{ end }}" for="{{ .title }}">{{ .name }}{{- if .required -}}{{- " *" -}}{{- end -}}</label>
|
||||
<input type="{{ .input_type }}" name="{{ .title }}" id="{{ .title }}" {{ if $pageform.names }}placeholder="{{ .name }}{{ .Scratch.Get "requiredstar" }}"{{ end }} {{ .Scratch.Get "requiredtext" }}>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
</form>
|
|
@ -1,18 +0,0 @@
|
|||
{{ define "css" }}
|
||||
<link rel="stylesheet" href="/css/visibleIf.css" type="text/css" />
|
||||
{{ end }}
|
||||
|
||||
|
||||
<article class="minmax">
|
||||
<div style="flex-direction: row;">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
<noscript><p><b>Bitte aktiviere Javascript, sonst funktioniert der Generator nicht.</b></p></noscript>
|
||||
|
||||
{{ if (index .Page.Params.forms 0) }}
|
||||
{{ partial "misc/form" (dict "context" . "form" 0) }}
|
||||
{{ end }}
|
||||
|
||||
</article>
|
||||
<script defer language="javascript" type="text/javascript" src="{{ "/js/visibleIf.js" | urlize | relURL }}"></script>
|
||||
<script defer language="javascript" type="text/javascript" src="{{ "/js/generator.js" | urlize | relURL }}"></script>
|
|
@ -1,25 +0,0 @@
|
|||
{{ $l1 := slice }}
|
||||
{{ $l2 := slice }}
|
||||
{{ range $.Site.Home.Translations }}
|
||||
{{ $l1 = $l1 | append .Language }}
|
||||
{{ end }}
|
||||
|
||||
{{ $all_lang := $.Site.Home.Translations }}
|
||||
{{ range where .Site.RegularPages "Type" "in" site.Params.searchSections }}
|
||||
{{ $missing := slice}}
|
||||
{{ if .Translations }}
|
||||
{{ range .Translations }}
|
||||
{{ $l2 = $l2 | append .Language }}
|
||||
{{ end }}
|
||||
{{ $final := $l1 | complement $l2 }}
|
||||
{{ range $final }}
|
||||
{{ $missing = $missing | append . }}
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
{{ $missing = $missing | append "all translations" }}
|
||||
{{ end }}
|
||||
{{ if $missing }}
|
||||
<a href="{{ .Permalink}}" style="margin-top: 1rem;">{{ .Name }}:</a>
|
||||
<div>missing: {{ index $missing 0 }}</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
|
@ -1,13 +0,0 @@
|
|||
{{ $byday := "" }}
|
||||
{{ $bymonth := "" }}
|
||||
{{ partial "debug" (dict "context" . "filename" "index.html") }}
|
||||
{{ range $rrule := split "RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=10" ";" }}
|
||||
{{ if in . "BYDAY" }}<br>
|
||||
{{ $byday = index (split . "=") 1 }}
|
||||
{{ end }}
|
||||
{{ if in . "BYMONTH" }}<br>
|
||||
{{ $bymonth = index (split . "=") 1 }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ $byday }}<br>
|
||||
{{ $bymonth }}<br>
|
|
@ -1,6 +0,0 @@
|
|||
{{ site.Title }}<br>
|
||||
{{ site.Params.imprintdata.street }}<br>
|
||||
{{ if i18n "pobox" }}{{ i18n "pobox" }}{{ else }}{{ "Po.Box" }}{{ end }} {{ site.Params.imprintdata.pobox }}<br>
|
||||
{{ site.Params.imprintdata.city }}<br>
|
||||
{{ if site.Params.imprintdata.tel }}<p>{{ if i18n "phone" }}{{ i18n "phone" }}{{ else }}{{ "phone" }}{{ end }}: {{ site.Params.imprintdata.tel }}</p>{{ end }}
|
||||
{{ if site.Params.imprintdata.mail }}<p>{{ if i18n "mail" }}{{ i18n "mail" }}{{ else }}{{ "mail" }}{{ end }}: {{ site.Params.imprintdata.mail | markdownify }}{{ end }}</p>
|
|
@ -1,27 +0,0 @@
|
|||
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
{{ $stylecolor := resources.Get "css/color.css" }}
|
||||
{{ $stylelayout := resources.Get "css/layout.css" }}
|
||||
{{ $allcss := slice $stylecolor $stylelayout | resources.Concat "/css/vendor.css" | minify | fingerprint "sha512" }}
|
||||
<link rel="stylesheet" href="{{ $allcss.RelPermalink }}" integrity="{{ $allcss.Data.Integrity }}">
|
||||
|
||||
{{ $title := print .Site.Title " | " .Title }}
|
||||
{{ if .IsHome }}{{ $title = .Site.Title }}{{ end }}
|
||||
<title>{{ $title }}</title>
|
||||
<meta property="og:title" content="{{ site.Title }}" />
|
||||
|
||||
<link rel="canonical" href="{{ .Permalink }}">
|
||||
{{ range .AlternativeOutputFormats -}}
|
||||
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
|
||||
{{ end -}}
|
||||
|
||||
{{ if .Site.Params.keywords -}}
|
||||
<meta name="keywords" content="{{ .Site.Params.keywords }}" />
|
||||
{{- end }}
|
||||
|
||||
<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico">
|
||||
|
||||
{{ template "_internal/opengraph.html" . }}
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
<div id="headerinner">
|
||||
<a href="/">
|
||||
<img src="/images/logo.svg" alt="SVG mit img laden" width="auto" height="100%" >
|
||||
</a>
|
||||
<div id="menu">
|
||||
{{- range site.Params.mainMenu -}}
|
||||
{{ $name := . }}
|
||||
{{ if i18n . }}
|
||||
{{ $name = i18n . }}
|
||||
{{ end }}
|
||||
<a href="{{- . | relLangURL -}}">{{- $name | humanize -}}</a>
|
||||
{{- end -}}
|
||||
|
||||
</div>
|
||||
</div>
|
|
@ -1,10 +0,0 @@
|
|||
{{ if not .IsHome }}
|
||||
{{ if .Translations }}
|
||||
<li class="align_menu"><h3>{{ "Languages" }}</h3></li>
|
||||
{{ range .Translations }}
|
||||
{{ if ne .Lang $.Lang }}
|
||||
<li class="align_menu"><a href="{{- .Permalink -}}">{{- if i18n .Lang -}}{{- i18n .Lang -}}{{- else -}}{{- humanize .Lang -}}{{ end }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
|
@ -1,102 +0,0 @@
|
|||
{{ $paginator := .paginator}}
|
||||
<div id="pagination_outer" style="display: flex; justify-content: center;">
|
||||
<div id="pagination">
|
||||
<!-- Number of links either side of the current page. -->
|
||||
{{ $adjacent_links := 2 }}
|
||||
|
||||
<!-- $max_links = ($adjacent_links * 2) + 1 -->
|
||||
{{ $max_links := (add (mul $adjacent_links 2) 1) }}
|
||||
|
||||
<!-- $lower_limit = $adjacent_links + 1 -->
|
||||
{{ $lower_limit := (add $adjacent_links 1) }}
|
||||
|
||||
<!-- $upper_limit = $paginator.TotalPages - $adjacent_links -->
|
||||
{{ $upper_limit := (sub $paginator.TotalPages $adjacent_links) }}
|
||||
|
||||
<!-- If there's more than one page. -->
|
||||
{{ if gt $paginator.TotalPages 1 }}
|
||||
|
||||
<!-- First page. -->
|
||||
{{ if ne $paginator.PageNumber 1 }}
|
||||
<a class="pagination__link pagination__link--first" href="{{ $paginator.First.URL }}">
|
||||
««
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
<!-- Previous page. -->
|
||||
{{ if $paginator.HasPrev }}
|
||||
<a href="{{ $paginator.Prev.URL }}" class="pagination__link pagination__link--previous">
|
||||
«
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
<!-- Page numbers. -->
|
||||
{{ range $paginator.Pagers }}
|
||||
{{ $page_number_flag := false }}
|
||||
|
||||
|
||||
<!-- Advanced page numbers. -->
|
||||
{{ if gt $paginator.TotalPages $max_links }}
|
||||
|
||||
<!-- Lower limit pages. -->
|
||||
<!-- If the user is on a page which is in the lower limit. -->
|
||||
{{ if le $paginator.PageNumber $lower_limit }}
|
||||
|
||||
<!-- If the current loop page is less than max_links. -->
|
||||
{{ if le .PageNumber $max_links }}
|
||||
{{ $page_number_flag = true }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Upper limit pages. -->
|
||||
<!-- If the user is on a page which is in the upper limit. -->
|
||||
{{ else if ge $paginator.PageNumber $upper_limit }}
|
||||
|
||||
<!-- If the current loop page is greater than total pages minus $max_links -->
|
||||
{{ if gt .PageNumber (sub $paginator.TotalPages $max_links) }}
|
||||
{{ $page_number_flag = true }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Middle pages. -->
|
||||
{{ else }}
|
||||
|
||||
{{ if and ( ge .PageNumber (sub $paginator.PageNumber $adjacent_links) ) ( le .PageNumber (add $paginator.PageNumber $adjacent_links) ) }}
|
||||
{{ $page_number_flag = true }}
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
|
||||
<!-- Simple page numbers. -->
|
||||
{{ else }}
|
||||
|
||||
{{ $page_number_flag = true }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
<!-- Output page numbers. -->
|
||||
{{ if eq $page_number_flag true }}
|
||||
<a href="{{ .URL }}" class="pagination__link">
|
||||
{{ if eq $paginator.PageNumber .PageNumber }}<b>{{ end }}
|
||||
{{ .PageNumber }}
|
||||
{{ if eq $paginator.PageNumber .PageNumber }}</b>{{ end }}
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
<!-- Next page. -->
|
||||
{{ if $paginator.HasNext }}
|
||||
<a href="{{ $paginator.Next.URL }}" class="pagination__link pagination__link--next">
|
||||
»
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
<!-- Last page. -->
|
||||
{{ if ne $paginator.PageNumber $paginator.TotalPages }}
|
||||
<a class="pagination__link pagination__link--last" href="{{ $paginator.Last.URL }}">
|
||||
»»
|
||||
</a>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
|
@ -1,2 +0,0 @@
|
|||
{{ partial "contentlayouts/menu.html" . }}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
<div>
|
||||
<details>
|
||||
<summary style="list-style: none; text-align: right;">Menü ☰</summary>
|
||||
<p>
|
||||
{{ partial "contentlayouts/menu.html" . }}
|
||||
</p>
|
||||
</details>
|
||||
</div>
|
|
@ -1,14 +1,16 @@
|
|||
{{ if and .amount (or .paginator .pages) }}
|
||||
{{ if and .amount (or .paginator .pages) }}
|
||||
{{ $amount := .amount }}
|
||||
{{ $pages := "" }}
|
||||
{{ if .pages }}
|
||||
{{ $pages = .pages.ByLastmod.Reverse }}
|
||||
{{ else if .paginator }}
|
||||
{{ $pages := .pages.ByLastmod.Reverse }}
|
||||
{{ if .paginator }}
|
||||
{{ $pages = .paginator.Pages.ByLastmod.Reverse }}
|
||||
{{ end }}
|
||||
{{ if .content }}
|
||||
{{ partial "snippets/content" (dict "content" .content) }}
|
||||
{{ end }}
|
||||
|
||||
{{- $paginator := .context.Paginate $pages -}}
|
||||
{{ if eq $paginator.PageNumber 1 }}
|
||||
{{ if .content }}
|
||||
{{ partial "snippets/content" (dict "content" .content) }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{- if gt (len $pages) 0 -}}
|
||||
{{ if .title }}<h2 style="margin-left: .6rem;">{{ .title }}</h2>{{ end }}
|
||||
{{- range first $amount $pages -}}
|
||||
|
@ -25,5 +27,10 @@
|
|||
</a>
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ if .paginate }}
|
||||
<div id="pagination_outer" style="display: flex; justify-content: center;">
|
||||
{{ partial "snippets/paginator" (dict "paginator" $paginator) }}
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
|
Loading…
Reference in New Issue