diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html deleted file mode 100644 index 3b06b31d..00000000 --- a/layouts/_default/baseof.html +++ /dev/null @@ -1,134 +0,0 @@ - - - - - {{ block "title" . }}{{ .Site.Title }}{{ end }} - {{ partial "head.html" . }} - - -{{ $csClass := "colorscheme-light" }} -{{ if eq .Site.Params.colorScheme "dark" }} -{{ $csClass = "colorscheme-dark" }} -{{ else if eq .Site.Params.colorScheme "auto" }} -{{ $csClass = "colorscheme-auto" }} -{{ end }} - - - {{ partial "float" . }} -
- {{ partial "header.html" . }} - -
- {{ block "content" . }}{{ end }} -
- - {{ partial "footer.html" . }} -
- - {{ if .HasShortcode "mermaid" }} - - - {{ end }} - - {{ if .Site.Params.disableDefaultJsScripts }} - {{ if not .Site.Params.hideColorSchemeToggle }} - {{ errorf "Invalid configuration. Default JS scripts are disabled, but 'hideColorSchemeToggle' is false." }} - {{end}} - {{ else if hugo.IsServer }} - {{ $script := resources.Get "js/coder.js" }} - - {{ else }} - {{ $script := resources.Get "js/coder.js" | minify | fingerprint }} - - {{ end }} - - {{ range .Site.Params.customJS }} - {{ if hugo.IsServer }} - {{ $script := resources.Get . }} - - {{ else }} - {{ $script := resources.Get . | minify | fingerprint }} - - {{ end }} - {{ end }} - - {{ range .Site.Params.customRemoteJS }} - {{ if hugo.IsServer }} - {{ $script := resources.GetRemote . }} - - {{ else }} - {{ $script := resources.GetRemote . | minify | fingerprint }} - - {{ end }} - {{ end }} - - - {{ template "_internal/google_analytics.html" . }} - - {{ if and .Site.Params.fathomAnalytics .Site.Params.fathomAnalytics.siteID }} - {{- partial "analytics/fathom" . -}} - {{ end }} - - {{ if and .Site.Params.plausibleAnalytics .Site.Params.plausibleAnalytics.domain }} - {{- partial "analytics/plausible" . -}} - {{ end }} - - {{ if and .Site.Params.goatCounter .Site.Params.goatCounter.code }} - {{- partial "analytics/goatcounter" . -}} - {{ end }} - - {{ if and .Site.Params.cloudflare .Site.Params.cloudflare.token }} - {{- partial "analytics/cloudflare" . -}} - {{ end }} - - {{ if and .Site.Params.baidu .Site.Params.baidu.token }} - {{- partial "analytics/baidu" . -}} - {{ end }} - - {{ if and .Site.Params.wideAngleAnalytics .Site.Params.wideAngleAnalytics.siteID }} - {{- partial "analytics/wideangle" . -}} - {{ end }} - - {{ if and .Site.Params.matomo .Site.Params.matomo.serverURL }} - {{- partial "analytics/matomo" . -}} - {{ end }} - - {{ if and .Site.Params.googleTagManager .Site.Params.googleTagManager.id }} - {{- partial "analytics/googletagmanager" . -}} - {{ end }} - - {{ if and .Site.Params.applicationInsights .Site.Params.applicationInsights.connectionString }} - {{- partial "analytics/applicationinsights" . -}} - {{ end }} - - {{ if and .Site.Params.microAnalytics .Site.Params.microAnalytics.id }} - {{- partial "analytics/microanalyticsio" . -}} - {{ end }} - - {{ if .Site.Params.vercelAnalytics}} - {{- partial "analytics/vercel" . -}} - {{ end }} - - {{ if and .Site.Params.yandexMetrika .Site.Params.yandexMetrika.id }} - {{- partial "analytics/yandex-metrika" . -}} - {{ end }} - - {{ if and .Site.Params.umami .Site.Params.umami.siteID }} - {{- partial "analytics/umami" . -}} - {{ end }} - - {{ if and .Site.Params.pirsch .Site.Params.pirsch.code }} - {{- partial "analytics/pirsch" . -}} - {{ end }} - - {{ if and .Site.Params.clicky .Site.Params.clicky.id }} - {{- partial "analytics/clicky" . -}} - {{ end }} - - {{- partial "body/extensions" . -}} - - - diff --git a/layouts/partials/head/color-scheme.html b/layouts/partials/head/color-scheme.html deleted file mode 100644 index 18e2d799..00000000 --- a/layouts/partials/head/color-scheme.html +++ /dev/null @@ -1,11 +0,0 @@ -{{ if or (eq .Site.Params.colorScheme "auto") (eq .Site.Params.colorScheme "dark") }} - {{ if hugo.IsServer }} - {{ $cssOpts := (dict "targetPath" "css/coder-dark.css" "enableSourceMap" true ) }} - {{ $styles := resources.Get "scss/coder-dark.scss" | resources.ExecuteAsTemplate "style.coder-dark.css" . | toCSS $cssOpts }} - - {{ else }} - {{ $cssOpts := (dict "targetPath" "css/coder-dark.css" ) }} - {{ $styles := resources.Get "scss/coder-dark.scss" | resources.ExecuteAsTemplate "style.coder-dark.css" . | toCSS $cssOpts | minify | fingerprint }} - - {{ end }} -{{ end }} diff --git a/layouts/partials/head/custom-styles.html b/layouts/partials/head/custom-styles.html deleted file mode 100644 index 89070261..00000000 --- a/layouts/partials/head/custom-styles.html +++ /dev/null @@ -1,21 +0,0 @@ - {{ range .Site.Params.customCSS }} - {{ if hugo.IsServer }} - {{ $styles := resources.Get . }} - - {{ else }} - {{ $styles := resources.Get . | minify | fingerprint }} - - {{ end }} -{{ end }} - -{{ range .Site.Params.customSCSS }} - {{/* We don't change the targetPath to because it's transparent to users */}} - {{ if hugo.IsServer }} - {{ $cssOpts := (dict "enableSourceMap" true ) }} - {{ $styles := resources.Get . | toCSS $cssOpts }} - - {{ else }} - {{ $styles := resources.Get . | toCSS | minify | fingerprint }} - - {{ end }} -{{ end }} diff --git a/layouts/partials/head/theme-styles.html b/layouts/partials/head/theme-styles.html deleted file mode 100644 index 2bb8f880..00000000 --- a/layouts/partials/head/theme-styles.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - -{{ if hugo.IsServer }} - {{ $cssOpts := (dict "targetPath" "css/coder.css" "enableSourceMap" true ) }} - {{ $styles := resources.Get "scss/coder.scss" | resources.ExecuteAsTemplate "style.coder.css" . | toCSS $cssOpts }} - -{{ else }} - {{ $cssOpts := (dict "targetPath" "css/coder.css" ) }} - {{ $styles := resources.Get "scss/coder.scss" | resources.ExecuteAsTemplate "style.coder.css" . | toCSS $cssOpts | minify | fingerprint }} - -{{ end }} - -{{ if .Site.Params.rtl }} - {{ if hugo.IsServer }} - {{ $cssOpts := (dict "targetPath" "css/coder-rtl.css" "enableSourceMap" true ) }} - {{ $styles := resources.Get "scss/coder-rtl.scss" | resources.ExecuteAsTemplate "style.coder-rtl.css" . | toCSS $cssOpts }} - - {{ else }} - {{ $cssOpts := (dict "targetPath" "css/coder-rtl.css" ) }} - {{ $styles := resources.Get "scss/coder-rtl.scss" | resources.ExecuteAsTemplate "style.coder-rtl.css" . | toCSS $cssOpts | minify | fingerprint }} - - {{ end }} -{{ end }} diff --git a/layouts/partials/header.html b/layouts/partials/header.html deleted file mode 100644 index 0e8ca703..00000000 --- a/layouts/partials/header.html +++ /dev/null @@ -1,41 +0,0 @@ - diff --git a/themes/hugo-coder b/themes/hugo-coder index f850eb85..e9dfb36b 160000 --- a/themes/hugo-coder +++ b/themes/hugo-coder @@ -1 +1 @@ -Subproject commit f850eb85badf5542c0b38e0fe6c8817454498c2c +Subproject commit e9dfb36b97f123ae2ef84f6d8082b89eca1d9da4