From 1b61f09eea2a67ef791fbbabd6ed738ea2eb4c1f Mon Sep 17 00:00:00 2001
From: weru <fromweru@gmail.com>
Date: Mon, 31 Jan 2022 23:08:34 +0000
Subject: [PATCH] correct homepage regression #73
---
layouts/_default/baseof.html | 14 ++++++++++++--
exampleSite/content/tutorials/example/_index.md | 2 +-
2 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/exampleSite/content/tutorials/example/_index.md b/exampleSite/content/tutorials/example/_index.md
index 7d837d0..af9b5c7 100644
--- a/exampleSite/content/tutorials/example/_index.md
+++ b/exampleSite/content/tutorials/example/_index.md
@@ -5,4 +5,4 @@
Welcome to the Compose theme user guide! This guide shows you how to get started creating technical documentation sites using Compose, including site customization and how to use Compose's blocks and templates.
-{{< button "./install-theme/" "Get started now" >}}
+{{< button "../../docs/compose/install-theme/" "Get started now" >}}
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index 8567a43..7a01207 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -12,10 +12,20 @@
{{- with $docSections }}{{- else }}
{{- $docSections = "docs" }}
{{- end }}
- {{- if or (in $docSections .Section) (and (ne site.Params.uniqueHomepage true) .IsHome) }}
+ {{ $uniqueHomepage := .IsHome }}
+ {{ if site.Params.uniqueHomepage }}
+ {{ if .IsHome }}
+ {{ $uniqueHomepage = true }}
+ {{ end }}
+ {{ else }}
+ {{ $uniqueHomepage = false }}
+ {{ end }}
+ {{- if and (in $docSections .Section) (ne $uniqueHomepage true) }}
{{- partial "document" . }}
{{- else }}
- {{- block "main" . }}{{ end }}
+ <div class="content">
+ {{- block "main" . }}{{ end }}
+ </div>
{{- end -}}
</div>
{{- partialCached "footer" . -}}
--
Gitblit v1.10.0