Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/curttimson/hugo-theme-dopetrope.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCurtis Timson <curt@live.co.uk>2018-02-17 01:35:10 +0300
committerCurtis Timson <curt@live.co.uk>2018-02-17 01:35:10 +0300
commitabc6fe12d177ebf65f247b074eb56b37119b15d3 (patch)
tree0ae8f7ba5b6786d1623e72e18e6d4767b8e39de1
parent99d4fe2ec7164e60f3b737e0758d862feefdeb67 (diff)
:wrench: Configure portfolio folder name
-rw-r--r--exampleSite/config-prod.toml3
-rw-r--r--exampleSite/config.toml3
-rw-r--r--layouts/index.html2
-rw-r--r--layouts/partials/portfolio.html2
4 files changed, 8 insertions, 2 deletions
diff --git a/exampleSite/config-prod.toml b/exampleSite/config-prod.toml
index 3a922bf..7cb2739 100644
--- a/exampleSite/config-prod.toml
+++ b/exampleSite/config-prod.toml
@@ -39,6 +39,9 @@ theme = "../.."
title5 = "Vitae tempor lorem"
+[params.portfolio]
+ foldername = "portfolio"
+
[params.blog]
title = "The Blog"
viewalltext = "View All"
diff --git a/exampleSite/config.toml b/exampleSite/config.toml
index b54447a..aac2541 100644
--- a/exampleSite/config.toml
+++ b/exampleSite/config.toml
@@ -39,6 +39,9 @@ theme = "../.."
title5 = "Vitae tempor lorem"
+[params.portfolio]
+ foldername = "portfolio"
+
[params.blog]
title = "The Blog"
viewalltext = "View All"
diff --git a/layouts/index.html b/layouts/index.html
index 02931b3..82154f2 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -28,7 +28,7 @@
<!-- Main -->
<div id="main-wrapper">
<div class="container">
- {{ $portfolioItems := where .Site.Pages "Type" "portfolio" }}
+ {{ $portfolioItems := where .Site.Pages "Type" .Site.Params.Portfolio.foldername }}
{{ if $portfolioItems }}
<div class="row">
<div class="12u">
diff --git a/layouts/partials/portfolio.html b/layouts/partials/portfolio.html
index 5a2a605..8fc6c2c 100644
--- a/layouts/partials/portfolio.html
+++ b/layouts/partials/portfolio.html
@@ -4,7 +4,7 @@
<h2>My Portfolio</h2>
</header>
<div class="row">
- {{ range where .Data.Pages "Type" "portfolio" }}
+ {{ range where .Data.Pages "Type" .Site.Params.Portfolio.foldername }}
<div class="4u 12u(mobile)">
<section class="box">
<a href="{{ .Permalink }}" class="image featured"><img src="{{ .Params.thumbnail }}" alt="" /></a>