diff --git a/assets/images/placeholder_autore.png b/assets/images/placeholder_autore.png new file mode 100644 index 0000000..8457e22 Binary files /dev/null and b/assets/images/placeholder_autore.png differ diff --git a/config.yml b/config.yml index dca67be..7815447 100644 --- a/config.yml +++ b/config.yml @@ -10,7 +10,7 @@ copyright: 2024 © Bergamo Linux Users Group paginate: 20 timeout: 1800s enableRobotsTXT: true -params: +params: description: Bergamo Linux Users Group social: - title: Mattermost @@ -52,6 +52,7 @@ params: taxonomies: tag: tags + author: author languages: it: @@ -117,6 +118,11 @@ languages: parent: about pageRef: /pages/segreteria weight: 54 + - identifer: authors + name: Autori + parent: about + pageRef: /author + weight: 55 - identifier: privacy name: Privacy pageRef: /pages/privacy-policy @@ -184,6 +190,11 @@ languages: name: Secretery pageRef: /pages/segreteria weight: 54 + - identifer: authors + name: Authors + parent: about + pageRef: /author + weight: 55 - identifier: privacy name: Privacy pageRef: /pages/privacy-policy diff --git a/content/author/_index.en.md b/content/author/_index.en.md new file mode 100644 index 0000000..0206e9a --- /dev/null +++ b/content/author/_index.en.md @@ -0,0 +1,3 @@ +--- +title: BgLUG's authors +--- diff --git a/content/author/_index.it.md b/content/author/_index.it.md new file mode 100644 index 0000000..f761fab --- /dev/null +++ b/content/author/_index.it.md @@ -0,0 +1,3 @@ +--- +title: Gli autori del BgLUG +--- diff --git a/content/author/paspo/_index.md b/content/author/paspo/_index.md new file mode 100644 index 0000000..b51cd6b --- /dev/null +++ b/content/author/paspo/_index.md @@ -0,0 +1,5 @@ +--- +title: paspo +image: paspo.png +description: paspo's [website](https://paspo.dev) +--- diff --git a/content/author/paspo/paspo.png b/content/author/paspo/paspo.png new file mode 100644 index 0000000..8ca1a5e Binary files /dev/null and b/content/author/paspo/paspo.png differ diff --git a/i18n/en.yaml b/i18n/en.yaml index c7304b9..ec2e9e8 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -1,3 +1,4 @@ --- license: License footer_license_note: Except where otherwise noted, content on this site is published under [CC-BY-SA](https://creativecommons.org/licenses/by-sa/4.0/) license. +all_posts_by: "All {{ . }}'s posts" diff --git a/i18n/it.yaml b/i18n/it.yaml index a4734e2..bff28de 100644 --- a/i18n/it.yaml +++ b/i18n/it.yaml @@ -1,3 +1,4 @@ --- license: Licenza footer_license_note: Eccetto dove diversamente indicato, ogni contenuto di questo sito è pubblicato con licenza [CC-BY-SA](https://creativecommons.org/licenses/by-sa/4.0/). +all_posts_by: "Tutti i post di {{ . }}" diff --git a/layouts/_default/author.html b/layouts/_default/author.html new file mode 100644 index 0000000..f4f52f3 --- /dev/null +++ b/layouts/_default/author.html @@ -0,0 +1,17 @@ +{{ define "main" }} +
+

{{ i18n "all_posts_by" .Title }}

+ {{ with .Description -}} +

{{ . | markdownify }}

+ {{- end }} +
+ + {{- if .Params.image }} + {{ .Params.image_alt }} + {{ end }} + + {{ range .RegularPages }} + {{ .Render "shortblock" }} + {{ end }} + +{{ end }} diff --git a/layouts/_default/shortblock.html b/layouts/_default/shortblock.html index c381a4f..8ef2bc1 100644 --- a/layouts/_default/shortblock.html +++ b/layouts/_default/shortblock.html @@ -39,9 +39,16 @@ {{ .Params.image_alt }}

{{ .Title }}

- {{- with .Params.author -}} - di {{ . | markdownify }}
- {{- end -}} + + {{- with .GetTerms "author" }} + {{- range . -}} +
+ di {{ .LinkTitle }} +
+ {{- end }} + {{- end }} + + {{ if .Site.Params.show_post_dates | default true }} {{- with .Date }}{{ end }} {{ end }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 89a81b3..d5a52cc 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -2,9 +2,15 @@

{{ .Title }}

{{ .Description }}

- {{- with .Params.author -}} -
di {{ . | markdownify }}
- {{- end -}} + + {{- with .GetTerms "author" }} + {{- range . -}} + + {{- end }} + {{- end }} + {{ if .Site.Params.show_post_dates | default true }} {{- with .Date }}{{ end }} {{ end }} diff --git a/layouts/_default/taxonomy.html b/layouts/_default/taxonomy.html new file mode 100644 index 0000000..6c04d22 --- /dev/null +++ b/layouts/_default/taxonomy.html @@ -0,0 +1,17 @@ +{{ define "main" }} +
+

{{ .Title }}

+ {{ with .Description -}} +

{{ . | markdownify }}

+ {{- end }} +
+ + {{- if .Params.image }} + {{ .Params.image_alt }} + {{ end }} + + {{ range .Pages }} + {{ .Render "taxonomyshortblock" }} + {{ end }} + +{{ end }} diff --git a/layouts/_default/taxonomyshortblock.html b/layouts/_default/taxonomyshortblock.html index 9b511a4..552f18c 100644 --- a/layouts/_default/taxonomyshortblock.html +++ b/layouts/_default/taxonomyshortblock.html @@ -4,8 +4,8 @@ {{ $rasters := slice "jpeg" "png" }} {{ $newres := "360x250 smart" }} - {{/* di default, niente immagine */}} - {{- $featimg := "#" -}} + {{/* immagine di default */}} + {{- $featimg := (resources.Get "/images/placeholder_autore.png").RelPermalink -}} {{- if .Params.image -}} {{/* se è stata definita un'immagine featured */}} @@ -44,9 +44,9 @@ {{ end }}

{{ with .Description }} - {{- . | truncate 400 }} + {{- . | markdownify | truncate 400 }} {{- else }} - {{- .Summary | truncate 400 }} + {{- .Summary | markdownify | truncate 400 }} {{- end }}

{{ partial "tags.html" . }}