diff --git a/archetypes/default.md b/archetypes/default.md index ac36e06..64df988 100644 --- a/archetypes/default.md +++ b/archetypes/default.md @@ -1,2 +1,7 @@ -+++ -+++ +--- +title: "{{ replace .Name "-" " " | title }}" +description: "Descripe {{ title }}" +date: {{ .Date }} +draft: true +--- + diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 2e60d14..c1a52f9 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -11,7 +11,7 @@
{{- block "main" . -}}{{- end }}
- diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 01dbe93..0cd7f85 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,70 +1,22 @@ {{ define "main" }} -

{{ .Title }}

-{{ range .Pages.ByPublishDate.Reverse }} -

-

{{ .Title }}

- {{ partial "metadata.html" . }} - -

{{ .Summary }}

-
-

+ {{ range .Pages.ByTitle }} +
+

+ {{ .Title }} +

+

{{ .Description }}

+
+ {{ end }} {{ end }} -{{ end }} - {{ define "sidebar" }} -
-
-

About Me

- {{ with .Site.Params.Avatar }} -
- Ansprechendes Bild -
- {{ end }} - - {{ with .Site.Params.Description }} -
- {{ . }} -
- {{ end }} +
+ {{- partial "widget/header.html" (dict "title" "About Me") -}} + {{- partial "widget/aboutme.html" (dict "avatar" .Site.Params.Avatar "description" .Site.Params.Description) -}} -

Contact Me

- - -
+ {{ with .Site.Params.Social }} + {{- partial "widget/header.html" (dict "title" "Contact Me") -}} + {{- partial "widget/socials.html" . -}} + {{ end }}
{{ end }} \ No newline at end of file diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 7d38f89..0319b0f 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -1,6 +1,16 @@ {{ define "main" }} -

{{ .Title }}

-{{ partial "metadata.html" . }} -

-{{ .Content }} +

{{ .Title }}

+ {{ .Content }} +{{ end }} + +{{ define "sidebar" }} +
+ {{- partial "widget/header.html" (dict "title" "About Me") -}} + {{- partial "widget/aboutme.html" (dict "avatar" .Site.Params.Avatar "description" .Site.Params.Description) -}} + + {{ with .Site.Params.Social }} + {{- partial "widget/header.html" (dict "title" "Contact Me") -}} + {{- partial "widget/socials.html" . -}} + {{ end }} +
{{ end }} \ No newline at end of file diff --git a/layouts/blog/list.html b/layouts/blog/list.html index f9ebf22..7c25294 100644 --- a/layouts/blog/list.html +++ b/layouts/blog/list.html @@ -23,10 +23,9 @@ {{/* Der Paginator wurde in den If-Blöcken zwar erstellt, aber die Variable ist auserhalb nicht sichtbar, daher hier explizit holen. Dieser kann nach dem ersten erstellen auch nicht mehr verändert werden */}} {{ $pag := .Paginator }} -

{{ .Title }}

{{ range $pag.Pages }}
-

{{ .Title }}

+

{{ .Title }}

{{ .Summary }}

@@ -36,52 +35,27 @@ {{ end }} {{ define "sidebar" }} -
-
- {{ $catIdent := .Site.Params.Blog.Categories | default "categories" }} - {{ $cats := (index $.Site.Taxonomies $catIdent)}} - {{ if $cats }} -

Kategorien

-
- {{ $parentLink := ($.Site.GetPage (printf "/categories")).Permalink }} - {{ range $key, $sites := $cats }} -
- {{ $key }} -
{{ $sites.Count }}
-
- {{ end }} -
- {{ end }} +
+ {{ $catIdent := .Site.Params.Blog.Categories | default "categories" }} + {{ $cats := (index $.Site.Taxonomies $catIdent)}} + {{ if $cats }} + {{- partial "widget/header.html" (dict "title" "Kategorien") -}} + {{- partial "widget/taglist.html" (dict "ident" $catIdent "tax" $cats) -}} + {{ end }} - {{/* https://mertbakir.gitlab.io/hugo/tag-cloud-in-hugo/ */}} - {{ $tagsIdent := .Site.Params.Blog.Tags | default "tags" }} - {{ $tags := (index $.Site.Taxonomies $tagsIdent)}} - {{ if $tags }} -

Schlagwortwolke

-
- {{ $parentLink := ($.Site.GetPage (printf "/%s" $tagsIdent)).Permalink }} - {{ $maxCnt := mul 1.0 (index $tags.ByCount 0).Count }} - {{ $minCnt := mul 1.0 (index $tags.ByCount.Reverse 0).Count }} - {{ $div := math.Max 1 (sub $maxCnt $minCnt) }} - {{ range $key, $sites := $tags }} - - {{- (printf `%s%d` - (add (mul (math.Pow (div (sub $sites.Count $minCnt) $div) 2.0) 0.6) 0.8) - ($key | relURL) $key $sites.Count $key $sites.Count - ) | safeHTML -}} - - - {{ end }} -
- {{ end }} + {{ $tagsIdent := .Site.Params.Blog.Tags | default "tags" }} + {{ $tags := (index $.Site.Taxonomies $tagsIdent)}} + {{ if $tags }} + {{- partial "widget/header.html" (dict "title" "Schlagwortwolke") -}} + {{- partial "widget/cloud.html" (dict "ident" $tagsIdent "tax" $tags) -}} + {{ end }} -

Archive

-
- {{/* Hier explizit auf Type achten!! */}} - {{ range (where .Site.RegularPages "Type" "blog").GroupByDate "2006" }} - Jahr {{ .Key }} - {{ end }} -
+ {{- partial "widget/header.html" (dict "title" "Archive") -}} +
+ {{/* Hier explizit auf Type achten!! */}} + {{ range (where .Site.RegularPages "Type" "blog").GroupByDate "2006" }} + Jahr {{ .Key }} + {{ end }}
{{ end }} \ No newline at end of file diff --git a/layouts/blog/single.html b/layouts/blog/single.html index 02f560e..d6a192a 100644 --- a/layouts/blog/single.html +++ b/layouts/blog/single.html @@ -17,8 +17,9 @@ {{ define "sidebar" }} -