From f749a48fd8885578a6a421d2e4ba27f58e2c4dca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6kmen=20G=C3=B6rgen?= Date: Sun, 2 Oct 2022 16:28:20 +0200 Subject: [PATCH] use internal templates in head. --- layouts/_default/baseof.html | 12 ++++----- layouts/partials/footer_extra.html | 8 +++--- layouts/partials/head.html | 40 +++--------------------------- layouts/partials/head_extra.html | 8 +++--- 4 files changed, 17 insertions(+), 51 deletions(-) diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index f72e3a7..79129d7 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -1,19 +1,19 @@ - {{- partial "head" . -}} + {{ partial "head" . }} - {{- partial "header" . -}} + {{ partial "header" . }}
- {{- block "main" . }}{{- end }} + {{ block "main" . }}{{ end }}
- {{- partial "footer" . -}} - {{- partial "footer_extra" . -}} + {{ partial "footer" . }} + {{ partial "footer_extra" . }} - {{- template "_internal/google_analytics_async.html" . -}} + {{ template "_internal/google_analytics_async.html" . }} diff --git a/layouts/partials/footer_extra.html b/layouts/partials/footer_extra.html index 0215932..838934b 100644 --- a/layouts/partials/footer_extra.html +++ b/layouts/partials/footer_extra.html @@ -1,13 +1,13 @@ -{{- partial "script_bootstrap" . -}} +{{ partial "script_bootstrap" . }} {{ if .Site.Params.highlightjs }} - {{- partial "script_highlight" . -}} + {{ partial "script_highlight" . }} {{ end }} {{ if .Site.Params.progressively }} - {{- partial "script_progressively" . -}} + {{ partial "script_progressively" . }} {{ end }} {{ if .Site.Params.uselatex }} - {{- partial "script_latex" . -}} + {{ partial "script_latex" . }} {{ end }} diff --git a/layouts/partials/head.html b/layouts/partials/head.html index a525495..838ebeb 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -14,42 +14,8 @@ content="{{ .Description | default .Site.Params.description }}" /> - - - - - - - - - {{ if .Site.Params.twitter }} - - {{ end }} - - - - - - + {{ template "_internal/opengraph.html" . }} + {{ template "_internal/twitter_cards.html" . }} {{ hugo.Generator }} @@ -74,5 +40,5 @@ title="{{ .Site.Title }}" /> - {{- partial "head_extra" . -}} + {{ partial "head_extra" . }} diff --git a/layouts/partials/head_extra.html b/layouts/partials/head_extra.html index fac508c..21ac0e1 100644 --- a/layouts/partials/head_extra.html +++ b/layouts/partials/head_extra.html @@ -1,11 +1,11 @@ -{{- partial "style_bootstrap" . -}} +{{ partial "style_bootstrap" . }} -{{- partial "style_main" . -}} +{{ partial "style_main" . }} {{ if .Site.Params.highlightjs }} - {{- partial "style_highlight" . -}} + {{ partial "style_highlight" . }} {{ end }} {{ if .Site.Params.progressively }} - {{- partial "style_progressively" . -}} + {{ partial "style_progressively" . }} {{ end }}