From 15aec575271a335bbdef4efe1260744aad94323d Mon Sep 17 00:00:00 2001 From: Yihui Xie Date: Thu, 13 Jul 2017 11:18:04 -0500 Subject: factor out banner to make it more customizable --- exampleSite/content/about.md | 2 +- layouts/partials/banner.html | 7 +++++++ layouts/partials/header.html | 6 +----- 3 files changed, 9 insertions(+), 6 deletions(-) create mode 100644 layouts/partials/banner.html diff --git a/exampleSite/content/about.md b/exampleSite/content/about.md index aaa898b..d8e7583 100644 --- a/exampleSite/content/about.md +++ b/exampleSite/content/about.md @@ -109,7 +109,7 @@ To add a table of contents to an article, you can add `toc: true` to the YAML me # Custom layouts -Besides the custom layout^[If this is the first time you have heard about "customizing layouts", please read the Hugo documentation first: https://gohugo.io/themes/customizing/.] files `head_custom.html` and `foot_custom.html` supported in **XMin** (see [documentation](https://xmin.yihui.name/about/)), this theme added two more layout files `comments.html` and `info.html` under `layouts/partials/`. The former can be used to add a comment section, e.g., if you want to use Hugo's default Disqus template, just add this to `comments.html`: +Besides the custom layout^[If this is the first time you have heard about "customizing layouts", please read the Hugo documentation first: https://gohugo.io/themes/customizing/.] files `head_custom.html` and `foot_custom.html` supported in **XMin** (see [documentation](https://xmin.yihui.name/about/)), this theme added a few more layout files `banner.html`, `comments.html` and `info.html` under `layouts/partials/`. The first can be used to customize the banner. The second can be used to add a comment section, e.g., if you want to use Hugo's default Disqus template, just add this to `comments.html`: ``` {{ template "_internal/disqus.html" . }} diff --git a/layouts/partials/banner.html b/layouts/partials/banner.html new file mode 100644 index 0000000..cc4181c --- /dev/null +++ b/layouts/partials/banner.html @@ -0,0 +1,7 @@ + diff --git a/layouts/partials/header.html b/layouts/partials/header.html index ebab038..bff1bd1 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -11,11 +11,7 @@