diff --git a/archetypes/default.md b/archetypes/default.md deleted file mode 100644 index c6f3fce..0000000 --- a/archetypes/default.md +++ /dev/null @@ -1,5 +0,0 @@ -+++ -title = '{{ replace .File.ContentBaseName "-" " " | title }}' -date = {{ .Date }} -draft = true -+++ diff --git a/hugo.yaml b/hugo.yaml index 074aa06..f451d31 100644 --- a/hugo.yaml +++ b/hugo.yaml @@ -1,9 +1,7 @@ -baseurl: "https://torbjorn.no/" # please update this to your actual URL +baseurl: "https://torbjorn.no/" languageCode: "en-us" title: "Torbjørn Bakken Pedersen's home page" -theme: "xmin" -#disqusShortname: "" -ignoreFiles: ["\\.Rmd$", "\\.Rmarkdown$", "_cache$"] +ignoreFiles: ["_cache$"] footnotereturnlinkcontents: "↩" date-format: 2006-01-02 buildDrafts: false @@ -38,6 +36,7 @@ menu: weight: 3 - name: RSS url: "index.xml" + weight: 4 params: description: "Torbjørn Bakken Pedersen's personal web page" diff --git a/layouts/404.html b/layouts/404.html new file mode 100644 index 0000000..807d963 --- /dev/null +++ b/layouts/404.html @@ -0,0 +1,6 @@ +{{ partial "header.html" . }} + +
The page you requested does not exist.
+ +{{ partial "footer.html" . }} \ No newline at end of file diff --git a/layouts/_default/_markup/render-image.html b/layouts/_default/_markup/render-image.html index 91a8ee7..ab0bdbe 100644 --- a/layouts/_default/_markup/render-image.html +++ b/layouts/_default/_markup/render-image.html @@ -10,7 +10,7 @@ {{- $caption := .Title -}} {{- $src := .Destination -}} {{- $imgBd5 := md5 $src -}} -{{- $dataSzes := "800px" -}} +{{- $dataSzes := "(max-width: 320px) 320px, (max-width: 640px) 640px, 800px" -}} {{- $holder := "GIP" -}} {{- $hint := "photo" -}} {{- $filter := "box" -}} @@ -33,7 +33,7 @@ {{- if lt $imgRsc.Width 800 -}} {{- $imgRsc.RelPermalink }} {{ $imgRsc.Width }}w {{- else -}} - {{- (cond (gt $imgRsc.Width .) ($imgRsc.Process (print "resize " . "x webp " $hint " " $filter)) $imgRsc).RelPermalink }} {{ . }}w + {{- (cond (gt $imgRsc.Width .) ($imgRsc.Process (print "resize " . "x webp q85 " $hint " " $filter)) $imgRsc).RelPermalink }} {{ . }}w {{- end -}} {{- end -}} {{- end -}} @@ -55,34 +55,16 @@ alt="{{ $alt }}" title="{{ $alt }}" loading="lazy" - fetchpriority="high" + fetchpriority="auto" data-pagefind-ignore /> {{- end -}} {{- else -}} -Image unavailable.
+Image unavailable: "{{ $src }}" could not be found. Check the file path or name.
+{{ $caption | $.Page.RenderString }}
{{- end }} - \ No newline at end of file diff --git a/layouts/_default/list.html b/layouts/_default/list.html index e1b97bd..99d347a 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -11,13 +11,9 @@