small fixes

This commit is contained in:
teldra 2022-06-17 17:45:53 +02:00
parent 05094ce3fb
commit 27dd8cf845
68 changed files with 771 additions and 511 deletions

View File

@ -1,34 +1,34 @@
# keywords for seo
keywords = "buntes haus celle, buntes haus, bunteshaus, celle, buntes haus e.V., www.bunteshaus.de, celle, punk, reggae, ska, konzerte, partys, soziokultur, soziokulturelles zentrum celle, elektro, electroe, jugendzentrum, celle, dum n bass, konzert, musik, politik, kultur, alternativ, cd kaserne celle, cd kaserne, plenum, celle, antifa, antira, anti akw, anti atom celle, veranstaltungen, infoladen, proberaum celle, archiv für neue soziale bewegungen in celle, hartz 4 IV beratung celle, skaten, graffiti, sprayen, kunst, fahrradwerkstatt, deka dance celle, dekadance, Revista, probably the friendliest Place on Earth"
#do you want a contact page?
#do you want a contact link?
contact = true
#do you want an archive?
#do you want an archive link?
archive = true
#do you want an searchpage??
#do you want an searchpage link?
search = true
#do you want a newsletter page?
#do you want a newsletter link?
newsletter = true
#do you want a links page?
#do you want a "links" link?
links = true
# do you want an imprint?
# do you want an imprint link?
imprint = true
#do you want an media folder?
media = true
#do you want an files link?
files = true
#do you want an misc folder?
misc = true
#do you want an tools link?
tools = true
#do you want an rss link?
rss = true
#do you want to show a link to the sourcecode?
#do you want an sourcecode link?
sourcecode = true
# what is seen in the header?

View File

@ -1,6 +1,5 @@
---
title: "Über uns"
layout: "gen_list"
---
Wir sind das Buntehaus, ein [soziokulturelles](/bunteshaus/soziokultur) Zentrum in Celle.
Wir leben vom mitmachen und so.

View File

@ -1,4 +1,3 @@
---
title: "Archiv"
layout: "archive"
---

View File

@ -1,6 +1,5 @@
---
title: "Kontakt"
layout: "contact_imprint"
banner: false
---
Konzerte: konzerte@bunteshaus.de

View File

@ -1,4 +1,3 @@
---
title: "Termine"
layout: "gen_list"
---

View File

@ -1,4 +1,3 @@
---
title: "featureds"
layout: "gen_list"
title: "featured"
---

View File

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

View File

Before

Width:  |  Height:  |  Size: 382 KiB

After

Width:  |  Height:  |  Size: 382 KiB

View File

Before

Width:  |  Height:  |  Size: 240 KiB

After

Width:  |  Height:  |  Size: 240 KiB

View File

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

View File

Before

Width:  |  Height:  |  Size: 3.0 MiB

After

Width:  |  Height:  |  Size: 3.0 MiB

View File

Before

Width:  |  Height:  |  Size: 4.7 MiB

After

Width:  |  Height:  |  Size: 4.7 MiB

View File

Before

Width:  |  Height:  |  Size: 225 KiB

After

Width:  |  Height:  |  Size: 225 KiB

View File

@ -0,0 +1,4 @@
---
title: "Dateien"
banner: false
---

View File

@ -1,6 +1,5 @@
---
title: "Impressum"
layout: "contact_imprint"
banner: false
---
Angaben gemäß § 5 TMG

View File

@ -1,5 +1,4 @@
---
title: "Links"
layout: "links"
banner: false
---

View File

@ -2,3 +2,4 @@
title: "Gruppe LiST: Land in Sicht - Transition Celle"
link: "https://list-celle.over-blog.com/"
---
Befreundete Gruppe

View File

@ -1,5 +0,0 @@
---
title: "Verschiedenes"
layout: "section_list"
banner: false
---

View File

@ -1,5 +0,0 @@
---
title: "Medien"
layout: "media"
banner: false
---

View File

@ -1,4 +1,3 @@
---
title: "Neuigkeiten"
layout: "gen_list"
---

View File

@ -1,6 +1,5 @@
---
title: "Newsletter"
layout: "generic_single"
---
Wenn ihr in unseren Newsletter aufgenommen werden wollt, schickt uns eine email!

View File

@ -1,4 +1,3 @@
---
title: "Regelmässig"
layout: "gen_list"
---

View File

@ -1,7 +1,5 @@
---
title: "Volltextsuche"
summary: "Seite nach Stichworten durchsuchen"
date: 2020-10-29
layout: "search"
---
{{< search >}}

View File

@ -1,5 +1,4 @@
---
title: "Tools"
layout: "section_list"
banner: false
---

View File

@ -1,3 +1,20 @@
// Breakpoints
$bp-tiny: 40em; // 640px
$bp-small: 48em; // 768px
$bp-medium: 64em; // 1024px
$bp-large: 85.375em; // 1366px
$bp-xlarge: 120em; // 1920px
$bp-xxlarge: 160em; // 2560px
// Media Queries
$mq-tiny: "(min-width: #{$bp-tiny})";
$mq-small: "(min-width: #{$bp-small})";
$mq-medium: "(min-width: #{$bp-medium})";
$mq-large: "(min-width: #{$bp-large})";
$mq-xlarge: "(min-width: #{$bp-xlarge})";
$mq-xxlarge: "(min-width: #{$bp-xxlarge})";
$mq-retina: "(-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi)";
.b {
height: calc(89vh / 5 );
}
@ -41,7 +58,7 @@
max-height: 5em;
}
@media (min-width: 640px) {
@media #{$mq-tiny} {
.banner {
width: 89%;
margin-left: auto;

View File

@ -8,6 +8,7 @@
}
// Breakpoints
$bp-tiny: 40em; // 640px
$bp-small: 48em; // 768px
$bp-medium: 64em; // 1024px
$bp-large: 85.375em; // 1366px
@ -15,6 +16,7 @@ $bp-xlarge: 120em; // 1920px
$bp-xxlarge: 160em; // 2560px
// Media Queries
$mq-tiny: "(min-width: #{$bp-tiny})";
$mq-small: "(min-width: #{$bp-small})";
$mq-medium: "(min-width: #{$bp-medium})";
$mq-large: "(min-width: #{$bp-large})";

View File

@ -16,13 +16,8 @@
margin-top: 0rem;
}
.text > img {
width: 64%;
}
.img-only {
height: 40vh;
background-size: 100% auto;
background-position: top;
background-repeat: no-repeat;
width: 60%;
margin-left: 2rem;
}
.articlemeta {
margin-bottom: 1em;
@ -35,18 +30,3 @@
text-align: right;
}
}
@media (min-width: 640px) {
}
@media (min-width: 768px) {
}
@media (min-width: 1024px) {
}
@media (min-width: 1280px) {
}
@media (min-width: 1920px) {
}

View File

@ -6,25 +6,24 @@
<header>
{{ partialCached "snippets/header" . }}
</header>
<div class="fakeheader">
</div>
<div class="main_wrapper">
{{ partial "snippets/banner" . -}}
<main class="main">
{{ if not .IsHome}}
<button onclick="history.back()" style="align-self: flex-end; margin-top: 1em; padding: 0; background-color: var(--background-body);">{{ if i18n "back" }}{{ i18n "back" }}{{ else }}{{ "back" }}{{ end }}</button>
{{ end }}
{{ block "content" . -}}{{- end }}
{{ block "intro" . -}}{{- end }}
<div class="main_upper">
{{ block "add_content" . -}}{{- end }}
{{ block "content" . -}}{{- end }}
{{ block "sidebar" . -}}{{- end }}
</div>
{{ block "pagefooter" . -}}{{- end }}
{{ block "inner_footer" . -}}{{- end }}
</main>
<footer class="footer">
{{- partial "snippets/footer" . -}}
</footer>
</div>
{{ block "debug" . }}{{ end }}
</div>
</body>
</html>

View File

@ -1,90 +1,29 @@
{{ define "title" }}
<h1>{{ if .Title }}
{{ .Title }}
{{ else }}
{{ if i18n .Section }}
{{ i18n .Section }}
{{ else }}
{{ .Section }}
{{ end }}
{{ end }}</h1>
{{ end }}
{{ define "content" }}
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "add_content" }}
{{ define "content" }}
{{- $pages := where .Site.RegularPages "Permalink" "!=" .Permalink -}}
{{- $paginator := "" -}}
{{- $partial := .Layout -}}
{{ $folder := "layout" }}
{{- $paginate := true -}}
{{- if eq .Layout "gen_list" -}}
{{ if eq .Section "events" }}
{{- $pages = where $pages ".Params.when" "ne" nil -}}
{{ else if eq .Type "about" }}
{{- $pages = (where $pages ".Params.about" "=" true) -}}
{{ else if eq .Section "news" }}
{{- $pages = .Data.Pages -}}
{{ else if eq .Section "featured" }}
{{- $pages = where $pages ".Params.featured" "=" true -}}
{{ else if eq .Section "recurrent" }}
{{- $pages = where $pages ".Params.recurrent" "=" true -}}
{{ end }}
{{ else if eq .Layout "links" -}}
{{ if eq .Kind "term" }}
{{- $pages = .Data.Pages -}}
{{ else }}
{{ if eq .Kind "term" }}
{{- $pages = .Data.Pages -}}
{{ $partial = "gen_list" }}
{{ else if eq .Kind "taxonomy" }}
{{ $paginate = false }}
{{- $pages = .Data.Terms.ByCount -}}
{{ $partial = "tags_n_categories" }}
{{ end }}
{{ $partial = "gen_list" }}
{{ $folder = "news" }}
{{ else if eq .Kind "taxonomy" }}
{{ $paginate = false }}
{{- $pages = .Data.Terms.ByCount -}}
{{ $partial = "tags_n_categories" }}
{{ end }}
{{ if and $folder $partial }}
{{ $partial = string (printf "%s/%s" $folder $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}
{{ $partial = string (printf "layout/%s" $partial) }}
{{ if eq .Type "about" }}<div class="list">{{ end }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ if eq .Type "about" }}</div>{{ end }}
{{ end }}
{{ define "sidebar" }}
{{ if eq .Section "news" }}
{{ if gt .Site.Taxonomies.categories 0 }}
<aside class="sidebar">
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.categories }}
{{ $orig := $taxonomyname }}
{{ if ne (i18n $taxonomyname) "" }}
{{ $taxonomyname = i18n $taxonomyname }}
{{ else }}
{{ $taxonomyname = $taxonomyname | humanize }}
{{ end }}
<div class="align_menu"><a href="{{ "categories/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></div>
{{ end }}
</aside>
{{ end }}
{{ else if or (eq .Section "events") (eq .Section "recurrent") }}
{{ if gt .Site.Taxonomies.events 0 }}
<aside class="sidebar">
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
<div class="align_menu"><a href="{{ "recurrent/" | relLangURL}}">{{ i18n "recurrent" }}</a></div>
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.events }}
{{ $orig := $taxonomyname }}
{{ if ne (i18n $taxonomyname) "" }}
{{ $taxonomyname = i18n $taxonomyname }}
{{ else }}
{{ $taxonomyname = $taxonomyname | humanize }}
{{ end }}
<div class="align_menu"><a href="{{ "events/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></div>
{{ end }}
</aside>
{{ end }}
{{ end }}
{{ end }}

View File

@ -1,25 +1,10 @@
{{ define "title" }}
<h1>{{ if (i18n .Title (dict "Count" 0))}}{{ i18n .Title (dict "Count" 0) }}{{ else }}{{ .Title }}{{ end }}</h1>
{{ end }}
{{ define "add_content" }}
{{ $partial_before := "" }}
{{ $partial := "layout/article" }}
{{ $pic := "true" }}
{{ if eq .Params.tool "generator" }}
{{ $partial = "layout/generator" }}
{{ else if eq .Params.tool "nottranslated" }}
{{ $partial = "layout/nottranslated" }}
{{ else if eq .Layout "contact_imprint" }}
{{ $partial_before = "snippets/contact" }}
{{ $partial = printf "layout/%s" .Layout }}
{{ else if eq .Layout "archive" }}
{{ $partial = printf "layout/%s" .Layout }}
{{ define "content" }}
{{ if .Layout }}
{{ $partial := printf "layout/%s" .Layout }}
<article>
{{ partial $partial (dict "context" . "content" .Content) }}
</article>
{{ end }}
<article>
{{ partial $partial (dict "context" . "pic" $pic "content" .Content "partial_before" $partial_before "type" "article") }}
</article>
{{ end }}
{{ define "sidebar" }}

View File

@ -0,0 +1,17 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{- $pages := where .Site.RegularPages "Permalink" "!=" .Permalink -}}
{{- $paginator := "" -}}
{{- $partial := "gen_list" -}}
{{- $paginate := true -}}
{{- $pages = (where $pages ".Params.about" "=" true) -}}
{{ $partial = string (printf "news/%s" $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}

View File

@ -0,0 +1,22 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .context.Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
<article>
<div>
{{ $pages := where site.RegularPages "Type" "in" site.Params.searchSections }}
{{ range $pages.GroupByDate "2006" }}
<h3 style="margin-top: 0; padding-top: 0; margin-bottom: 0; padding-bottom: 0;">{{ .Key }}</h3>
{{ range .Pages.GroupByDate "January" }}
<h4 style="margin-left: 1em; margin-top: 0; padding-top: 0; margin-bottom: 0; padding-bottom: 0;">{{ .Key }}:</h4>
{{ range .Pages }}
<div style="margin-left: 2em;">{{ .Date.Format "02.01.2006" }} <a href="{{ .Permalink }}" class="underline">{{ .Title }}</a></div>
{{ end }}
{{ end }}
{{ end }}
</div>
</article>
{{ end }}

View File

@ -0,0 +1,32 @@
{{ define "content" }}
{{ $text := "solo" }}
{{ $content := .Content }}
<article>
<section>
<div class="articleinner">
<div class="articletext {{ $text }}">
{{ partial "snippets/contact" (dict "context" .) }}
{{ $content }}
{{ if .Resources.ByType "image" }}
{{ range .Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname.Name ) (hasPrefix $picname.Name "banner") )}}
<div class="article-image">
<a href="{{- $picname.Permalink -}}" class="no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" />
</a>
</div>
{{ end }}
{{ end }}
{{ end }}
</div>
</div>
</section>
</article>
{{ end }}

View File

@ -0,0 +1,34 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{- $pages := where .Site.RegularPages "Permalink" "!=" .Permalink -}}
{{- $paginator := "" -}}
{{- $partial := "gen_list" -}}
{{- $paginate := true -}}
{{- $pages = where $pages ".Params.when" "ne" nil -}}
{{ $partial = string (printf "news/%s" $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}
{{ define "sidebar" }}
{{ if gt .Site.Taxonomies.events 0 }}
<aside class="sidebar">
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
<div class="align_menu"><a href="{{ "recurrent/" | relLangURL}}">{{ i18n "recurrent" }}</a></div>
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.events }}
{{ $orig := $taxonomyname }}
{{ if ne (i18n $taxonomyname) "" }}
{{ $taxonomyname = i18n $taxonomyname }}
{{ else }}
{{ $taxonomyname = $taxonomyname | humanize }}
{{ end }}
<div class="align_menu"><a href="{{ "events/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></div>
{{ end }}
</aside>
{{ end }}
{{ end }}

View File

@ -0,0 +1,17 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{- $pages := where .Site.RegularPages "Permalink" "!=" .Permalink -}}
{{- $paginator := "" -}}
{{- $partial := "gen_list" -}}
{{- $paginate := true -}}
{{- $pages = where $pages ".Params.featured" "=" true -}}
{{ $partial = string (printf "news/%s" $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}

View File

@ -0,0 +1,16 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
<div>
{{ range .Pages }}
<div>🗀 <a href="{{ .Permalink }}" class="underline">{{ .Title }}</a></div>
{{ end }}
{{ range .Resources }}
<div>🗀 <a href="{{ .Permalink }}">{{ . }}</a></div>
{{ end }}
</div>
{{ end }}

View File

@ -0,0 +1,33 @@
{{ define "content" }}
{{ $text := "solo" }}
{{ $content := .Content }}
<article>
<section>
<div class="articleinner">
<div class="articletext {{ $text }}">
{{ partial "snippets/contact" (dict "context" .) }}
{{ if i18n "executive" }}{{ i18n "executive" }}{{ else }}{{ "Executive" }}{{ end }}: {{ .Site.Params.imprintdata.executive }}
{{ $content }}
{{ if .Resources.ByType "image" }}
{{ range .Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname.Name ) (hasPrefix $picname.Name "banner") )}}
<div class="article-image">
<a href="{{- $picname.Permalink -}}" class="no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" />
</a>
</div>
{{ end }}
{{ end }}
{{ end }}
</div>
</div>
</section>
</article>
{{ end }}

View File

@ -1,4 +1,4 @@
{{ define "content" }}
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
@ -6,7 +6,7 @@
{{ end }}
{{ define "add_content" }}
{{ define "content" }}
{{- $all := where (where .Site.RegularPages "Permalink" "!=" .Permalink) "Type" "in" .Site.Params.searchSections }}
{{ $days := int (mul (mul (int .Site.Params.featured_expire) 7) -1) }}
@ -27,8 +27,8 @@
{{ $feat = i18n $feat }}
{{ end }}
<div class="two_lists">
{{ partial "layout/gen_list" (dict "context" . "pages" $featured "title" $feat "limit" "5" )}}
{{ partial "layout/gen_list" (dict "context" . "pages" $posts "title" $news "link" "news" "limit" "5" )}}
{{ partial "news/gen_list" (dict "context" . "pages" $featured "title" $feat "limit" "5" )}}
{{ partial "news/gen_list" (dict "context" . "pages" $posts "title" $news "link" "news" "limit" "5" )}}
</div>
{{ end }}

View File

@ -1,9 +1,3 @@
{{ define "title" }}
{{ if .Content }}
<h1>{{ .Title }}</h1>
{{ end }}
{{ end }}
{{ define "main" }}
{{- $all := where (where .Site.RegularPages "Permalink" "!=" .Permalink) "Type" "in" .Site.Params.searchSections }}
{{ $days := int (mul (mul (int .Site.Params.featured_expire) 7) -1) }}

View File

@ -0,0 +1,31 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{ $title := .Title }}
{{ $p := .Pages }}
{{ $paginator := $p }}
{{ if $p }}
<div class="links_wrapper">
{{ range $p }}
<div class="links" style="display: flex; flex-direction: column;">
<a href="{{ .Params.Link }}" class="t">
{{ .Title }}
</a>
<a href="{{ .Params.Link }}" class="p">
{{ .Params.Link }}
</a>
<a href="{{ .Params.Link }}" class="s">
{{ .Content }}
</a>
</div>
{{ end }}
</div>
{{ end }}
{{ end }}

View File

@ -0,0 +1,33 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{- $paginator := "" -}}
{{- $partial := "gen_list" -}}
{{- $paginate := true -}}
{{- $pages := .Data.Pages -}}
{{ $partial = string (printf "news/%s" $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}
{{ define "sidebar" }}
{{ if gt .Site.Taxonomies.categories 0 }}
<aside class="sidebar">
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.categories }}
{{ $orig := $taxonomyname }}
{{ if ne (i18n $taxonomyname) "" }}
{{ $taxonomyname = i18n $taxonomyname }}
{{ else }}
{{ $taxonomyname = $taxonomyname | humanize }}
{{ end }}
<div class="align_menu"><a href="{{ "categories/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></div>
{{ end }}
</aside>
{{ end }}
{{ end }}

View File

@ -0,0 +1,147 @@
{{ define "content" }}
<article>
{{ $metas := dict "when" .Params.when "price" .Params.price "contact_mail" .Params.contact_mail "covid" .Params.covid "insta" .Params.insta }}
{{ $banner := slice }}
{{ $image := slice }}
{{ $thumb := "" }}
{{ if .Resources.GetMatch "banner*" }}
{{ $banner = slice (.Resources.GetMatch "banner*") }}
{{ end }}
{{ if .Resources.ByType "image" }}
{{ $image = .Resources.ByType "image" }}
{{ end }}
{{ $image = (index (complement $banner $image) 0) }}
{{ if $banner }}
{{ $image = (index $banner 0) }}
{{ end }}
{{ $image = .Resources.GetMatch (string $image) }}
{{ if ne $image nil }}
{{ $thumb1 := $image.Fill "1280x480 smart"}}
{{ $thumb = $image}}
{{ end }}
{{ partial "snippets/article_metadata" $metas }}
{{- if .Description -}}
<p>{{ .Description }}</p>
{{ end }}
{{ $count_href := .TableOfContents | strings.Count "href" }}
{{ if ge $count_href 4 }}
<details open>
<summary class="toc-head">Inhaltsverzeichnis</summary>
<div class="toc">
{{ .TableOfContents }}
</div>
</details>
{{ end }}
{{ $content := .Content }}
{{ if or .Content (.Resources.ByType "image")}}
<div class="article_content">
{{- if .Content -}}
{{- $content -}}
{{ end }}
{{ if .Resources.ByType "image" }}
{{ range .Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname ) (hasPrefix $picname "banner") )}}
<a href="{{- $picname.Permalink -}}" class="article_image no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" /><br>
</a>
{{ end }}
{{ end }}
{{ end }}
</div>
{{ end }}
</article>
{{ end }}
{{ define "sidebar" }}
{{ if ne .Type "tools" }}
<aside class="sidebar">
{{ if or .Params.categories .Params.events }}
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
{{ end }}
{{ if .Params.categories }}
{{ range .Params.categories }}
<div class="align_menu"><a href="{{ "/categories/" | relLangURL }}{{ . | urlize }}">{{ . }}</a></div>
{{ end }}
{{ end }}
{{ if .Params.events }}
{{ range .Params.events }}
<div class="align_menu"><a href="{{ "/events/" | relLangURL }}{{ . | urlize }}">{{ . }}</a></div>
{{ end }}
{{ end }}
{{ if .Params.tags }}
<h3 class="align_menu"><a href="{{ "/tags/" | relLangURL }}">{{ if i18n "tags" }}{{ i18n "tags" }}{{ else }}{{ "Tags" }}{{ end }}</a></h3>
{{ range .Params.tags }}
<div class="align_menu"><a href="{{ "/tags/" | relLangURL }}{{ . | urlize }}">{{ . }}</a></div>
{{ end }}
{{ end }}
{{ $related := .Site.RegularPages.RelatedIndices . "tags" | first 5 }}
{{ if $related }}
<h3 class="align_menu">Related</h3>
{{ range $related }}
<div class="align_menu"><a href="{{ .Permalink }}">{{ .Title }}</a></div>
{{ end }}
{{ end }}
</aside>
{{ end }}
{{ end }}
{{ define "inner_footer" }}
{{ if and (eq .Kind "page") (or (eq .Section "news") (eq .Section "events") (eq .Section "about")) }}
<div class="article_footer">
{{ with .Params.foundations }}
<div class="bold">Träger der Veranstaltung:</div>
<div class="foundations_items">
{{ range . }}
{{ $l := . }}
{{ $url := "" }}
{{ if isset site.Params.foundations $l }}
{{ $url = index site.Params.foundations $l }}
{{ end }}
{{- $res_im := resources.GetMatch (printf "/images/foundations/%s*" $l ) -}}
{{ if $res_im }}
<div class="foundations_item">
{{ if $url }}<a href="{{ $url | safeHTML }}">{{ end }}<img src="{{- $res_im.Permalink -}}" class="borderrad4px article_footer_item1" /> {{ if $url }}</a>{{ end }}
</div>
{{ else }}
{{ if eq hugo.Environment "development" }}
<div class="foundations_item">
assets/images/foundations/{{- $l -}} .* missing
</div>
{{ else }}
picture missing.
{{ end }}
{{ end }}
{{ end }}
</div>
{{ end }}
<div class="mod_times">
<div class="mod_times_item">
<div class="bold">{{ if i18n "created" }}{{ i18n "created" }}{{ else }}{{ "Created" }}{{ end }}: </div>
<div>{{ .Date | time.Format ":date_full" }}</div>
</div>
{{ if ne .Date .Lastmod }}
<div class="mod_times_item">
<div class="bold">{{ if i18n "lastmod" }}{{ i18n "lastmod" }}{{ else }}{{ "Last modification" }}{{ end }}: </div>
<div>{{ .Lastmod | time.Format ":date_full" }}</div>
</div>
{{ end }}
</div>
</div>
{{ end }}
{{ end }}

View File

@ -0,0 +1,32 @@
{{ define "content" }}
<article>
{{- if .Description -}}
<p>{{ .Description }}</p>
{{ end }}
{{ $content := .Content }}
{{ if or .Content (.Resources.ByType "image")}}
<div class="article_content">
{{- if .Content -}}
{{- $content -}}
{{ end }}
{{ if .Resources.ByType "image" }}
{{ range .Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname ) (hasPrefix $picname "banner") )}}
<a href="{{- $picname.Permalink -}}" class="article_image no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" /><br>
</a>
{{ end }}
{{ end }}
{{ end }}
</div>
{{ end }}
</article>
{{ end }}

View File

@ -1,15 +0,0 @@
{{ if ne .context.Content "" }}
{{ partial "snippets/content" (dict "content" .context.Content) }}
{{ end }}
<div>
{{ $pages := where site.RegularPages "Type" "in" site.Params.searchSections }}
{{ range $pages.GroupByDate "2006" }}
<h3 style="margin-top: 0; padding-top: 0; margin-bottom: 0; padding-bottom: 0;">{{ .Key }}</h3>
{{ range .Pages.GroupByDate "January" }}
<h4 style="margin-left: 1em; margin-top: 0; padding-top: 0; margin-bottom: 0; padding-bottom: 0;">{{ .Key }}:</h4>
{{ range .Pages }}
<div style="margin-left: 2em;">{{ .Date.Format "02.01.2006" }} <a href="{{ .Permalink }}" class="underline">{{ .Title }}</a></div>
{{ end }}
{{ end }}
{{ end }}
</div>

View File

@ -1,68 +0,0 @@
{{ $metas := dict "when" .context.Params.when "price" .context.Params.price "contact_mail" .context.Params.contact_mail "covid" .context.Params.covid "insta" .context.Params.insta }}
{{ $banner := slice }}
{{ $image := slice }}
{{ $thumb := "" }}
{{ if .context.Resources.GetMatch "banner*" }}
{{ $banner = slice (.context.Resources.GetMatch "banner*") }}
{{ end }}
{{ if .context.Resources.ByType "image" }}
{{ $image = .context.Resources.ByType "image" }}
{{ end }}
{{ $image = (index (complement $banner $image) 0) }}
{{ if $banner }}
{{ $image = (index $banner 0) }}
{{ end }}
{{ $image = .context.Resources.GetMatch (string $image) }}
{{ if ne $image nil }}
{{ $thumb1 := $image.Fill "1280x480 smart"}}
{{ $thumb = $image}}
{{ end }}
{{ partial "snippets/article_metadata" $metas }}
{{- if .context.Description -}}
<p>{{ .context.Description }}</p>
{{ end }}
{{ $count_href := .context.TableOfContents | strings.Count "href" }}
{{ if ge $count_href 4 }}
<details open>
<summary class="toc-head">Inhaltsverzeichnis</summary>
<div class="toc">
{{ .context.TableOfContents }}
</div>
</details>
{{ end }}
{{ $content := .context.Content }}
{{ if or .context.Content (.context.Resources.ByType "image")}}
<div class="article_content">
{{- if .context.Content -}}
{{- $content -}}
{{ end }}
{{ if .context.Resources.ByType "image" }}
{{ range .context.Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname ) (hasPrefix $picname "banner") )}}
<a href="{{- $picname.Permalink -}}" class="article_image no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" /><br>
</a>
{{ end }}
{{ end }}
{{ end }}
</div>
{{ end }}
{{ if and (.comtext.Resources.GetMatch $banner) (ne .context.Params.banner false) }}
{{ else if and (.context.Resources.Match "banner*") (ne .context.Params.banner false) }}
{{ else if and (.context.Resources.ByType "image") (ne .context.Params.banner false) }}
{{ else }}
{{ end }}

View File

@ -1,32 +0,0 @@
{{ $text := "solo" }}
{{ $content := .context.Content }}
<section>
<div class="articleinner">
<div class="articletext {{ $text }}">
{{ if .partial_before }}
{{ partial .partial_before (dict "context" .context "pic" .pic) }}
{{ end }}
{{ if in .context.File "imprint" }}
{{ if i18n "executive" }}{{ i18n "executive" }}{{ else }}{{ "Executive" }}{{ end }}: {{ .context.Site.Params.imprintdata.executive }}
{{ end }}
{{ .content }}
{{ if .context.Resources.ByType "image" }}
{{ range .context.Resources.ByType "image" }}
{{ $picname := . }}
{{ if not (or (in $content $picname.Name ) (hasPrefix $picname.Name "banner") )}}
<div class="article-image">
<a href="{{- $picname.Permalink -}}" class="no_underline">
<img loading="lazy"
src="{{ .Permalink }}"
alt="{{ . }}"
{{ with .Title}} title="{{ . }}"{{ end }}
width={{ $picname.Width }}
height="{{ $picname.Height }}" />
</a>
</div>
{{ end }}
{{ end }}
{{ end }}
</div>
</div>
</section>

View File

@ -1,164 +0,0 @@
{{ $title := .title }}
{{ $link := .link }}
{{ $p := .pages }}
{{ if and (.limit) (not .paginate) }}
{{ $p = first .limit .pages }}
{{ end }}
{{ $act_section := .context.Section }}
{{ $paginator := .pages }}
{{ if .paginate }}
{{ $paginator = .context.Paginate $p }}
{{ $p = $paginator.Pages }}
{{ end }}
{{ if $p }}
<div class="gen_list">
{{ if $title }}
<h2 style="display: flex; align-items: baseline;">
{{ if $link }}
<a href="{{ $link | relLangURL }}">
{{ end }}
{{ $title }}
{{ if $link }}
</a>
<a href="{{ $link | relLangURL }}" style="text-decoration: underline; font-size: x-small; margin-left: 1em;">({{ if i18n "all" }}{{ i18n "all"}}{{ else }}{{ "all" }}{{ end }})</a>
{{ end }}
</h2>
{{ end }}
{{ range $p }}
{{ $slug := "" }}
{{ with .File }}
{{ $slug = anchorize .ContentBaseName }}
{{ end }}
<div class="list_item">
{{ $metas := dict "when" .Params.when "price" .Params.price }}
{{ $banner := slice }}
{{ $image := slice }}
{{ $images := slice }}
{{ $dir := ""}}
{{ with .File }}
{{ $dir = .Dir }}
{{ end }}
{{ if .Resources.GetMatch "banner*" }}
{{ $banner = slice (.Resources.GetMatch "banner*") }}
{{ end }}
{{ if .Resources.ByType "image" }}
{{ $image = .Resources.ByType "image" }}
{{ end }}
{{ $images = complement $banner $image }}
{{ $image = (index (complement $banner $image) 0) }}
{{ $banner = (index $banner 0) }}
<section>
<a href="{{ .Permalink }}">
{{ if $title }}<h3>{{ else }}<h2>{{ end }}
{{ if ne $act_section "about" }}
{{ if .Params.events }}
{{ index .Params.events 0 }}:
{{ else if .Params.recurrent }}
{{ if i18n "recurrent"}}
{{ i18n "recurrent"}}:
{{ else }}
{{ "Recurrent"}}:
{{ end }}
{{ else if .Params.categories }}
{{ if in .Params.categories "Buha" }}
In eigener Sache:
{{ end }}
{{ end }}
{{ end }}
{{ .Title }}
{{ if $title }}</h3>{{ else }}</h2>{{ end }}
{{ with .Resources.GetMatch $banner }}
{{ $img := . }}
{{ $good_w := "1920"}}
{{ $good_h := "550"}}
{{ $b := true }}
{{ if or (lt (int .Width) $good_w) (gt (int .Width) $good_w) (lt (int .Height) $good_h) (gt (int .Height) $good_h) }}
<div class="dev left">
{{ if lt (int .Width) $good_w }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Width: {{ .Width }}px: too small, must be {{ $good_w -}}px in width<br>
{{ end }}
{{ else if gt (int .Width) $good_w }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Width: {{ .Width }}px: too big, must be {{ $good_w -}}px in width<br>
{{ end }}
{{ end }}
{{ if lt (int .Height) $good_h }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Height: {{ .Height }}px: too small, must be {{ $good_h -}}px in height<br>
{{ end }}
{{ else if gt (int .Height) $good_h }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Height: {{ .Height }}px: too big, must be {{ $good_h -}}px in height<br>
{{ end }}
{{ end }}
{{ if eq hugo.Environment "development" }}
{{ if eq $b false }}
{{ printf "Please correct content/news/%s/%s" $slug .Name }}
{{ end }}
{{ end }}
</div>
{{ end }}
<!--<div class="img" style="background-image: url({{ .Permalink }})">
</div>-->
{{ if eq $b true }}
{{ $tiny := ($banner.Fill "768x280 q90") }}
{{ $small := ($banner.Fill "1024x280 q90") }}
{{ $medium := ($banner.Fill "1280x280 q90") }}
{{ $large := ($banner.Fill "1366x280 q90") }}
<img loading="lazy" srcset="{{- with $tiny.RelPermalink -}}{{.}} 480w{{- end -}}
{{- with $small.RelPermalink -}}, {{.}} 768w{{- end -}}
{{- with $medium.RelPermalink -}}, {{.}} 1024w{{- end -}}
{{- with $large.RelPermalink -}}, {{.}} 1366w{{- end -}}"
src="{{ $banner.RelPermalink }}" alt="Banner Image." />
{{ end }}
{{ else }}
{{ if eq hugo.Environment "development" }}
<div class="dev left">
{{ printf "content/%sbanner* missing.." $dir }}
</div>
{{ end }}
{{ end }}
{{ partial "snippets/article_metadata" $metas }}
<div class="text">
{{ if .Description }}
<p>{{ .Description }}</p>
{{ else if .Content }}
{{ $summary := "" }}
{{ if in .RawContent "<!--more-->" }}
{{ $tmp := split .RawContent "<!--more-->" }}
{{ index $tmp 0 | markdownify }}
{{ else }}
{{ if hasPrefix .Summary "<p>" }}
{{ .Summary }}
{{ else }}
<p>{{ .Summary }} </p>
{{ end }}
{{ end }}
{{ else if $image }}
{{ $i := (.Resources.GetMatch $image).Permalink }}
<img src="{{ $i }}" />
{{ end }}
</div>
{{ if .Truncated }}
<div class="readmore">
{{ if i18n "readmore" }}{{ i18n "readmore" }}{{ else }}{{ "read more" }}{{ end }}..
</div>
{{ end }}
</a>
</section>
</div>
{{ end }}
{{ if .paginate }}
{{ partial "snippets/paginator" (dict "paginator" $paginator) }}
{{ end }}
</div>
{{ end }}

View File

@ -1,32 +0,0 @@
{{ $title := .title }}
{{ $p := .pages }}
{{ if and (.limit) (not .paginate) }}
{{ $p = first .limit .pages }}
{{ end }}
{{ $paginator := .pages }}
{{ if .paginate }}
{{ $paginator = .context.Paginate $p }}
{{ $p = $paginator.Pages }}
{{ end }}
{{ if $p }}
<div class="links_wrapper">
{{ range $p }}
<div class="links" style="display: flex; flex-direction: column;">
<a href="{{ .Params.Link }}" class="t">
{{ .Title }}
</a>
<a href="{{ .Params.Link }}" class="p">
{{ .Params.Link }}
</a>
<a href="{{ .Params.Link }}" class="s">
{{ .Content }}
</a>
</div>
{{ end }}
</div>
{{ end }}

View File

@ -1,10 +0,0 @@
{{ if ne .context.Content "" }}
<section>
{{ partial "snippets/content" (dict "content" .context.Content) }}
</section>
{{ end }}
<section>
{{ range .context.Resources }}
<div>🗀 <a href="{{ .Permalink }}">{{ . }}</a></div>
{{ end }}
</section>

View File

@ -1,11 +0,0 @@
{{ if ne .context.Content "" }}
<div>
{{ partial "snippets/content" (dict "content" .context.Content) }}
</div>
{{ end }}
<div>
{{ range .context.Pages }}
<div>🗀 <a href="{{ .Permalink }}" class="underline">{{ .Title }}</a></div>
{{ end }}
</div>

View File

@ -0,0 +1,175 @@
{{ $title := .title }}
{{ $link := .link }}
{{ $pages := .pages }}
{{ if and (.limit) (not .paginate) }}
{{ $pages = first .limit .pages }}
{{ end }}
{{ $act_section := .context.Section }}
{{ $paginator := .pages }}
{{ if .paginate }}
{{ $paginator = .context.Paginate $pages }}
{{ $pages = $paginator.Pages }}
{{ end }}
{{ $bptiny := "40em" }}
{{ $bpsmall := "48em" }}
{{ $bpmedium := "64em" }}
{{ $bplarge := "85.375em" }}
{{ $bpxlarge := "120em" }}
{{ $bpxxlarge := "160em" }}
{{ if $pages }}
<div class="gen_list">
{{ if $title }}
<h2 style="display: flex; align-items: baseline;">
{{ if $link }}
<a href="{{ $link | relLangURL }}">
{{ end }}
{{ $title }}
{{ if $link }}
</a>
<a href="{{ $link | relLangURL }}" style="text-decoration: underline; font-size: x-small; margin-left: 1em;">({{ if i18n "all" }}{{ i18n "all"}}{{ else }}{{ "all" }}{{ end }})</a>
{{ end }}
</h2>
{{ end }}
{{ range $pages }}
{{ $slug := "" }}
{{ with .File }}
{{ $slug = anchorize .ContentBaseName }}
{{ end }}
<section>
{{ $metas := dict "when" .Params.when "price" .Params.price }}
{{ $banner := slice }}
{{ $image := slice }}
{{ $images := slice }}
{{ $dir := ""}}
{{ with .File }}
{{ $dir = .Dir }}
{{ end }}
{{ if .Resources.GetMatch "banner*" }}
{{ $banner = slice (.Resources.GetMatch "banner*") }}
{{ end }}
{{ if .Resources.ByType "image" }}
{{ $image = .Resources.ByType "image" }}
{{ end }}
{{ $images = complement $banner $image }}
{{ $image = (index (complement $banner $image) 0) }}
{{ $banner = (index $banner 0) }}
<a href="{{ .Permalink }}" class="list_item">
{{ if $title }}<h3>{{ else }}<h2>{{ end }}
{{ if ne $act_section "about" }}
{{ if .Params.events }}
{{ index .Params.events 0 }}:
{{ else if .Params.recurrent }}
{{ if i18n "recurrent"}}
{{ i18n "recurrent"}}:
{{ else }}
{{ "Recurrent"}}:
{{ end }}
{{ else if .Params.categories }}
{{ if in .Params.categories "Buha" }}
In eigener Sache:
{{ end }}
{{ end }}
{{ end }}
{{ .Title }}
{{ if $title }}</h3>{{ else }}</h2>{{ end }}
{{ with .Resources.GetMatch $banner }}
{{ $img := . }}
{{ $good_w := "1920"}}
{{ $good_h := "550"}}
{{ $b := true }}
{{ if or (lt (int .Width) $good_w) (gt (int .Width) $good_w) (lt (int .Height) $good_h) (gt (int .Height) $good_h) }}
<div class="dev left">
{{ if lt (int .Width) $good_w }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Width: {{ .Width }}px: too small, must be {{ $good_w -}}px in width<br>
{{ end }}
{{ else if gt (int .Width) $good_w }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Width: {{ .Width }}px: too big, must be {{ $good_w -}}px in width<br>
{{ end }}
{{ end }}
{{ if lt (int .Height) $good_h }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Height: {{ .Height }}px: too small, must be {{ $good_h -}}px in height<br>
{{ end }}
{{ else if gt (int .Height) $good_h }}
{{ $b = false }}
{{ if eq hugo.Environment "development" }}
Height: {{ .Height }}px: too big, must be {{ $good_h -}}px in height<br>
{{ end }}
{{ end }}
{{ if eq hugo.Environment "development" }}
{{ if eq $b false }}
{{ printf "Please correct content/news/%s/%s" $slug .Name }}
{{ end }}
{{ end }}
</div>
{{ end }}
{{ if eq $b true }}
{{ $tiny := ($banner.Resize "640x q90") }}
{{ $small := ($banner.Resize "768x q90") }}
{{ $medium := ($banner.Resize "1024x q90") }}
{{ $large := ($banner.Resize "1366x q90") }}
<img loading="lazy" srcset="{{- with $tiny.RelPermalink -}}{{.}} 640w{{- end -}}
{{- with $small.RelPermalink -}}, {{.}} 768w{{- end -}}
{{- with $medium.RelPermalink -}}, {{.}} 1024w{{- end -}}
{{- with $large.RelPermalink -}}, {{.}} 1366w{{- end -}}"
src="{{ $banner.RelPermalink }}" alt="Banner Image." />
{{ end }}
{{ else }}
{{ if eq hugo.Environment "development" }}
<div class="dev left">
{{ printf "content/%sbanner* missing.." $dir }}
</div>
{{ end }}
{{ end }}
{{ partial "snippets/article_metadata" $metas }}
<div class="text">
{{ if .Description }}
<p>{{ .Description }}</p>
{{ else if .Content }}
{{ $summary := "" }}
{{ if in .RawContent "<!--more-->" }}
{{ $tmp := split .RawContent "<!--more-->" }}
{{ index $tmp 0 | markdownify }}
{{ else }}
{{ if hasPrefix .Summary "<p>" }}
{{ .Summary }}
{{ else }}
<p>{{ .Summary }} </p>
{{ end }}
{{ end }}
{{ else if $image }}
{{ $i := (.Resources.GetMatch $image) }}
{{ $tiny := ($i.Resize "640x q90") }}
{{ $small := ($i.Resize "768x q90") }}
{{ $medium := ($i.Resize "10240x q90") }}
{{ $large := ($i.Resize "1366x q90") }}
<img loading="lazy" srcset="{{- with $tiny.RelPermalink -}}{{.}} 640w{{- end -}}
{{- with $small.RelPermalink -}}, {{.}} 768w{{- end -}}
{{- with $medium.RelPermalink -}}, {{.}} 1024w{{- end -}}
{{- with $large.RelPermalink -}}, {{.}} 1366w{{- end -}}"
src="{{ $i.RelPermalink }}" alt="Banner Image." />
{{ end }}
</div>
{{ if .Truncated }}
<div class="readmore">
{{ if i18n "readmore" }}{{ i18n "readmore" }}{{ else }}{{ "read more" }}{{ end }}..
</div>
{{ end }}
</a>
</section>
{{ end }}
{{ if .paginate }}
{{ partial "snippets/paginator" (dict "paginator" $paginator) }}
{{ end }}
</div>
{{ end }}

View File

@ -1,3 +1,6 @@
{{ define "debug" }}
{{ .Section }}<br>
{{ end }}
{{ $title := .Title }}
{{ $title = singularize $title }}
{{ $title = i18n $title }}
@ -38,7 +41,7 @@
{{ with .File }}
{{ $slug = anchorize .ContentBaseName }}
{{ end }}
{{ if or (and $img (ne .Params.banner false)) (.Resources.ByType "image") }}
{{ if and $img (ne .Params.banner false) }}
{{ if .Resources.Match "banner*" }}
{{ $img = .Resources.GetMatch "banner*" }}
{{ end }}
@ -46,7 +49,40 @@
{{ $img = index (.Resources.ByType "image") 0 }}
{{ end }}
{{ if $img }}
<div style="background-image: url({{- $img.Permalink -}})" class="banner {{ $css }}">
{{ $tiny := ($img.Resize "640x q90") }}
{{ $small := ($img.Resize "768x q90") }}
{{ $medium := ($img.Resize "10240x q90") }}
{{ $large := ($img.Resize "1366x q90") }}
<style>
@media (min-width: 40em) {
.ttestt {
background-image: url({{- $tiny.Permalink -}});
}
}
@media (min-width: 48em) {
.ttestt {
background-image: url({{- $small.Permalink -}});
}
}
@media (min-width: 64em) {
.ttestt {
background-image: url({{- $medium.Permalink -}});
}
}
@media (min-width: 85.375em) {
.ttestt {
background-image: url({{- $large.Permalink -}});
}
}
@media (min-width: 120em) {
.ttestt {
background-image: url({{- $img.Permalink -}});
}
}
</style>
<div class="ttestt banner {{ $css }}">
{{ if eq hugo.Environment "development" }}
<div class="dev right">
{{ $w := $img.Width }}

View File

@ -38,9 +38,10 @@
</div>
{{- end -}}
{{- if or (eq site.Params.rss true) (eq site.Params.misc true) (eq site.Params.sourcecode true) }}
{{- if or (eq site.Params.rss true) (eq site.Params.files true) (eq site.Params.sourcecode true) }}
<div class="infobox b">
{{ if eq site.Params.misc true }}<a href="{{- "misc" | absLangURL -}}">Misc</a>{{ end }}
{{ if eq site.Params.files true }}<a href="{{- "files" | absLangURL -}}">{{ if i18n "files" }}{{ i18n "files" }}{{ else }}{{ "Files" }}{{ end }}</a>{{ end }}
{{ if eq site.Params.tools true }}<a href="{{- "tools" | absLangURL -}}">{{ if i18n "tools" }}{{ i18n "tools" }}{{ else }}{{ "Tools" }}{{ end }}</a>{{ end }}
{{ if eq site.Params.rss true }}
{{- if or (in .Site.Params.mainMenu .Section) -}}
{{- with .OutputFormats.Get "rss" -}}

View File

@ -3,7 +3,7 @@
</div>
<noscript><p><b>Bitte aktiviere Javascript, sonst funktioniert der Generator nicht.</b></p></noscript>
{{ if (index .context.Params.forms 0) }}
{{ partial "layout/generator/form" (dict "context" .context "form" 0) }}
{{ partial "tools/generator/form" (dict "context" .context "form" 0) }}
{{ end }}
<script defer src="{{ "/js/visibleIf.js" | urlize | relURL }}"></script>

View File

@ -14,7 +14,7 @@
{{ if and .group (not (in $group .group))}}
<div class="margin_top_1rem">
{{ if i18n (singularize .group) }}{{ i18n (singularize .group) }}{{ else }}{{ humanize .group }}{{ end }}
{{ partial "layout/generator/expand" (dict "name" (printf "%sgroup" .group)) }}
{{ partial "tools/generator/expand" (dict "name" (printf "%sgroup" .group)) }}
</div>
{{ $group = $group | append .group }}
{{ end }}
@ -87,7 +87,7 @@
<div class="margin_top_1rem column {{ if .group }} visibleIf" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
<div class="w100 {{ if .group }}margin_left_1rem{{ end }}">
{{ .name }}
{{ if ne .expanded true }}{{ partial "layout/generator/expand" (dict "name" (printf "%scat" $in0)) }}{{ end }}{{- if .required -}}{{- " *" -}}{{- end -}}
{{ if ne .expanded true }}{{ partial "tools/generator/expand" (dict "name" (printf "%scat" $in0)) }}{{ end }}{{- if .required -}}{{- " *" -}}{{- end -}}
</div>
<div class="checkbox {{ if ne .expanded true }}visibleIf margin_left_1rem stretch" data-visibleif-rule="{{ $in0 }}cat == 'true'{{end}}">
<div class="column margin_left_1rem">
@ -130,7 +130,7 @@
<div class="margin_top_1rem column {{ if .group }} visibleIf" data-visibleif-rule="{{ .group }}group == 'true'{{ end }}">
<div class="w100 {{ if .group }}margin_left_1rem{{ end }}">
{{ .name }}
{{ if ne .expanded true }}{{ partial "layout/generator/expand" (dict "name" (printf "%scat" $in0)) }}{{ end }}{{- if .required -}}{{- " *" -}}{{- end -}}
{{ if ne .expanded true }}{{ partial "tools/generator/expand" (dict "name" (printf "%scat" $in0)) }}{{ end }}{{- if .required -}}{{- " *" -}}{{- end -}}
</div>
<div class="checkbox {{ if ne .expanded true }}visibleIf margin_left_1rem stretch" data-visibleif-rule="{{ $in0 }}cat == 'true'{{end}}">
<div class="column margin_left_1rem">

View File

@ -0,0 +1,34 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
{{- $pages := where .Site.RegularPages "Permalink" "!=" .Permalink -}}
{{- $paginator := "" -}}
{{- $partial := "gen_list" -}}
{{- $paginate := true -}}
{{- $pages = where $pages ".Params.recurrent" "=" true -}}
{{ $partial = string (printf "news/%s" $partial) }}
{{ partial $partial (dict "context" . "pages" $pages "content" .Content "type" .Type "paginate" $paginate) }}
{{ end }}
{{ define "sidebar" }}
{{ if gt .Site.Taxonomies.events 0 }}
<aside class="sidebar">
<h3 class="align_menu">{{ if i18n "categories" }}{{ i18n "categories" }}{{ else }}{{ "Categories" }}{{ end }}</h3>
<div class="align_menu"><a href="{{ "recurrent/" | relLangURL}}">{{ i18n "recurrent" }}</a></div>
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies.events }}
{{ $orig := $taxonomyname }}
{{ if ne (i18n $taxonomyname) "" }}
{{ $taxonomyname = i18n $taxonomyname }}
{{ else }}
{{ $taxonomyname = $taxonomyname | humanize }}
{{ end }}
<div class="align_menu"><a href="{{ "events/" | relLangURL}}{{ $orig | urlize }}">{{ $taxonomyname }}</a></div>
{{ end }}
</aside>
{{ end }}
{{ end }}

View File

@ -0,0 +1,5 @@
{{ define "content" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}

View File

@ -0,0 +1,19 @@
{{ define "intro" }}
{{ if ne .Content "" }}
{{ partial "snippets/content" (dict "content" .Content) }}
{{ end }}
{{ end }}
{{ define "content" }}
<div>
{{ range .Pages }}
<div>🗀 <a href="{{ .Permalink }}" class="underline">{{ .Title }}</a></div>
{{ end }}
</div>
<div>
{{ range .Resources }}
<div>🗀 <a href="{{ .Permalink }}">{{ . }}</a></div>
{{ end }}
</div>
{{ end }}

View File

@ -0,0 +1,11 @@
{{ define "content" }}
{{ $partial := "" }}
{{ if eq .Params.tool "generator" }}
{{ $partial = "tools/generator" }}
{{ else if eq .Params.tool "nottranslated" }}
{{ $partial = "tools/nottranslated" }}
{{ end }}
<article>
{{ partial $partial (dict "context" . "content" .Content) }}
</article>
{{ end }}