diff options
author | Francesco <tomaselli.fr@gmail.com> | 2024-05-11 22:14:41 +0200 |
---|---|---|
committer | Francesco <tomaselli.fr@gmail.com> | 2024-05-11 22:14:41 +0200 |
commit | 43de5d69b894aec43f993743b2d03f4157952e15 (patch) | |
tree | 930c50df484789e4a60a2a565dccc37cebc1000a /layouts | |
parent | 1ee175c6bea9bdc15188ad475565149487cb27f2 (diff) | |
parent | edd49a893c5f581a2f622f2b29a289760bbc2edc (diff) |
Merge branch 'main' into tmp
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/404.html | 1 | ||||
-rw-r--r-- | layouts/_default/baseof.html | 44 | ||||
-rw-r--r-- | layouts/_default/home.html | 3 | ||||
-rw-r--r-- | layouts/partials/comments.html | 2 | ||||
-rw-r--r-- | layouts/partials/head.html | 10 | ||||
-rw-r--r-- | layouts/partials/head/js.html | 3 | ||||
-rw-r--r-- | layouts/partials/math.html | 9 | ||||
-rw-r--r-- | layouts/partials/post-entry.html | 7 |
8 files changed, 46 insertions, 33 deletions
diff --git a/layouts/404.html b/layouts/404.html index 72ef81e..15c8a62 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -9,5 +9,4 @@ </div> - {{ end }}
\ No newline at end of file diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index a116c36..9b63b69 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -2,36 +2,35 @@ <html lang="{{ or site.Language.LanguageCode site.Language.Lang }}" dir="{{ or site.Language.LanguageDirection `ltr` }}"> -<head> - {{ partial "head.html" . }} -</head> + <head> + {{ partial "head.html" . }} + </head> -{{ $theme := "auto"}} + {{ $theme := "auto"}} -{{ with .Param "theme" }} -{{ $theme = .}} -{{ end }} + {{ with .Param "theme" }} + {{ $theme = .}} + {{ end }} -<body class="{{ $theme }}"> + <body class="{{ $theme }}"> - <div class="content"> - <header> - {{ partial "header.html" . }} - </header> + <div class="content"> + <header> + {{ partial "header.html" . }} + </header> - <main class="main"> - {{ block "main" . }}{{ end }} - </main> - </div> + <main class="main"> + {{ block "main" . }}{{ end }} + </main> + </div> - <footer> - {{ partial "footer.html" . }} - </footer> + <footer> + {{ partial "footer.html" . }} + </footer> -</body> + </body> - -<script> + <script> function isAuto() { return document.body.classList.contains("auto"); @@ -70,5 +69,4 @@ </script> - </html>
\ No newline at end of file diff --git a/layouts/_default/home.html b/layouts/_default/home.html index e251ce3..5273fa0 100644 --- a/layouts/_default/home.html +++ b/layouts/_default/home.html @@ -21,7 +21,8 @@ {{ with site.Params.social }} <div class="social-icons"> {{- range . }} - <a href="{{ trim .url " " | safeURL }}" target="_blank" rel="noopener noreferrer me" + <a href="{{ trim .url " " | safeURL }}" target="_blank" + rel="noopener noreferrer me" title="{{ (.title | default .name) | title }}"> {{ partial "svg.html" . }} </a> diff --git a/layouts/partials/comments.html b/layouts/partials/comments.html index 979b59e..cbc7d6c 100644 --- a/layouts/partials/comments.html +++ b/layouts/partials/comments.html @@ -14,5 +14,5 @@ data-loading="lazy" crossorigin="anonymous" async> -</script> + </script> {{ end }}
\ No newline at end of file diff --git a/layouts/partials/head.html b/layouts/partials/head.html index fef47c4..9350ee6 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -1,6 +1,14 @@ <meta charset="utf-8"> <meta name="viewport" content="width=device-width"> -<title>{{ if .IsHome }}{{ site.Title }}{{ else }}{{ printf "%s | %s" .Title site.Title }}{{ end }}</title> + +<title> + {{ if .IsHome }} + {{ site.Title }} + {{ else }} + {{ printf "%s | %s" .Title site.Title }} + {{ end }} +</title> + {{ partialCached "head/css.html" . }} {{ partialCached "head/js.html" . }} diff --git a/layouts/partials/head/js.html b/layouts/partials/head/js.html index 8bae509..aa471f4 100644 --- a/layouts/partials/head/js.html +++ b/layouts/partials/head/js.html @@ -1,6 +1,7 @@ {{- with resources.Get "js/main.js" }} {{- $opts := dict "minify" true }} {{- with . | js.Build $opts | fingerprint }} -<script src="{{ .RelPermalink }}" integrity="{{- .Data.Integrity }}" crossorigin="anonymous"></script> +<script src="{{ .RelPermalink }}" integrity="{{- .Data.Integrity }}" + crossorigin="anonymous"></script> {{- end }} {{- end }}
\ No newline at end of file diff --git a/layouts/partials/math.html b/layouts/partials/math.html index c54c8d5..62b330f 100644 --- a/layouts/partials/math.html +++ b/layouts/partials/math.html @@ -1,7 +1,10 @@ -<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.css"> -<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.js"></script> +<link rel="stylesheet" + href="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.css"> +<script defer + src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.js"></script> -<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/contrib/auto-render.min.js" +<script defer + src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/contrib/auto-render.min.js" onload="renderMathInElement(document.body);"></script> <script> diff --git a/layouts/partials/post-entry.html b/layouts/partials/post-entry.html index 5c89bca..2439632 100644 --- a/layouts/partials/post-entry.html +++ b/layouts/partials/post-entry.html @@ -5,11 +5,14 @@ {{ $dateFormat = .}} {{ end }} - <p class="line-date">{{ .Date.Format $dateFormat }} </p> <div> - <p class="line-title"> <a href="{{ .RelPermalink }}">{{ .Title }}</a></p> + <p class="line-title"> + <a href="{{ .RelPermalink }}"> + {{ .Title }} + </a> + </p> {{ if .Site.Params.listSummaries }} <p class="line-summary"> {{ .Summary }} </p> |