From d43ab2e37e681e222da93226bcd5211e29e84438 Mon Sep 17 00:00:00 2001 From: anoduck <9925396+anoduck@users.noreply.github.com> Date: Sat, 15 Feb 2025 02:33:34 -0500 Subject: =?UTF-8?q?feat:=20=F0=9F=8E=B8=20Module=20additions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added created modules to the site along with more content. --- layouts/_default/baseof.html | 80 ++++++++++++++++++++++++++++++++++++++++++++ layouts/_default/single.html | 47 ++++++++++++++++++++++++++ layouts/partials/disqus.html | 24 +++++++++++++ 3 files changed, 151 insertions(+) create mode 100644 layouts/_default/baseof.html create mode 100644 layouts/_default/single.html create mode 100644 layouts/partials/disqus.html (limited to 'layouts') diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html new file mode 100644 index 0000000..ebf732c --- /dev/null +++ b/layouts/_default/baseof.html @@ -0,0 +1,80 @@ +{{- /* Set version-aware sidebar menu */ -}} +{{- $version := partial "utilities/GetVersion.html" (dict "page" . "base" true) -}} +{{- $.Scratch.Set "version" $version -}} +{{ with partial "utilities/GetMenu" (dict "page" . "version" $version) }}{{ $.Scratch.Set "sidebar" . }}{{ end }} + +{{- /* Validate if current version is latest */ -}} +{{- if and site.Params.docs.checkVersion $version -}} + {{- if ne $version "latest" -}} + {{- if partial "utilities/IsOlder" (dict "current" $version) -}} + {{- $.Scratch.Set "pageAlertMsg" (T "newerVersionAlert" site.Title) -}} + {{- $.Scratch.Set "pageAlertURL" (or site.Params.docs.latestURL site.baseURL) -}} + {{- end -}} + {{- end -}} +{{- end -}} + +{{- /* Initialize module configuration */ -}} +{{- $modules := partialCached "utilities/InitModules.html" . -}} +{{- $.Scratch.Set "modules" $modules -}} + +{{- $fullCover := or (or (and .IsHome .Site.Params.home.fullCover) .Page.Params.fullCover) .Site.Params.main.footerBelowFold }} +{{- $.Scratch.Set "fullCover" $fullCover -}} + +{{- /* Define section headings */ -}} +{{- $loading := "" -}} +{{- if $fullCover }}{{ $loading = .Site.Params.main.loading }}{{ end -}} +{{ $sections := partial "utilities/GetSections.html" (dict "page" . "loading" $loading) }} +{{- $.Scratch.Set "sections" $sections -}} + +{{- /* Define main breakpoint */ -}} +{{- $.Scratch.Set "breakpoint" (partialCached "utilities/GetBreakpoint.html" .) }} + +{{- /* Define base URL */ -}} +{{ $lang := site.LanguageCode | default site.Language.Lang }} +{{ $.Scratch.Set "baseURL" (strings.TrimSuffix (printf "%s/" $lang) site.Home.RelPermalink) }} + + + +
+ {{- partial "footer/scripts.html" (dict "page" . "type" "critical") -}} + {{ block "head" . }}{{ end -}} + + + +