From 9e5401d0fac2215f74ee8a4c5d2533fbb6d84943 Mon Sep 17 00:00:00 2001
From: Bud Parr <budparr@gmail.com>
Date: Sat, 15 Apr 2017 02:23:18 +0000
Subject: [PATCH] change article to post
---
layouts/section/post.html | 0
layouts/post/summary-with-image.html | 0
layouts/post/summary.html | 0
layouts/post/single.html | 0
layouts/index.html | 19 ++++++++++---------
5 files changed, 10 insertions(+), 9 deletions(-)
diff --git a/layouts/index.html b/layouts/index.html
index d57e3d5..bdb6610 100755
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -2,17 +2,17 @@
<main class="cf ph3 ph5-l pv3 pv4-l f4 tc-l center measure-wide lh-copy mid-gray">
{{ .Content }}
</main>
+ {{/* Create a variable to use the same section twice. Note that we've included the date here. */}}
+ {{ $section := where .Data.Pages.ByDate.Reverse "Section" "post" }}
+ {{ if $section }}
+ <div class="pa3 pa4-ns w-100 w-70-ns center">
- <div class="pa3 pa4-ns w-100 w-70-ns center">
- <h1 class="flex-none">
- Recent Articles
- </h1>
+ <h1 class="flex-none">
+ Recent Articles
+ </h1>
-
- {{/* Create a variable to use the same section twice. Note that we've included the date here. */}}
- {{ $section := where .Data.Pages.ByDate.Reverse "Section" "article" }}
<section class="w-100 mw8">
- {{ range (first 3 $section) }}
+ {{ range (first 3 $section) }}
<div class="relative w-100 mb4">
{{ .Render "summary-with-image" }}
</div>
@@ -20,7 +20,7 @@
</section>
<section class="w-100">
- <h1 class="f3">More posts</h1>
+ <h1 class="f3">More Posts</h1>
{{/* Nest the requirements, "after" then "first" on the outside */}}
{{ range (first 4 (after 1 $section)) }}
<h2 class="f5 fw4 mb4 dib mr3">
@@ -33,4 +33,5 @@
</section>
</div>
+ {{ end }}
{{ end }}
diff --git a/layouts/article/single.html b/layouts/post/single.html
similarity index 100%
rename from layouts/article/single.html
rename to layouts/post/single.html
diff --git a/layouts/article/summary-with-image.html b/layouts/post/summary-with-image.html
similarity index 100%
rename from layouts/article/summary-with-image.html
rename to layouts/post/summary-with-image.html
diff --git a/layouts/article/summary.html b/layouts/post/summary.html
similarity index 100%
rename from layouts/article/summary.html
rename to layouts/post/summary.html
diff --git a/layouts/section/article.html b/layouts/section/post.html
similarity index 100%
rename from layouts/section/article.html
rename to layouts/section/post.html
--
Gitblit v1.10.0