summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--_includes/post-card.liquid30
-rw-r--r--_includes/post-list.liquid41
-rw-r--r--_includes/recent-posts.liquid10
-rw-r--r--_layouts/index.liquid26
-rw-r--r--_layouts/journal.liquid10
-rw-r--r--index.md10
6 files changed, 72 insertions, 55 deletions
diff --git a/_includes/post-card.liquid b/_includes/post-card.liquid
new file mode 100644
index 0000000..558b227
--- /dev/null
+++ b/_includes/post-card.liquid
@@ -0,0 +1,30 @@
+<div class="card">
+ <header class="card-header">
+ <p class="card-header-title">
+ {% if post.published_date %}
+ {{ post.published_date | date: "%A, %b %e, %Y" }}
+ {% endif %}
+ </p>
+ </header>
+ <div class="card-content">
+ <p class="subtitle">
+ {{ post.title }}
+ </p>
+ <div class="content">
+ {{ post.content | truncatewords: 50 }}
+ </div>
+ </div>
+ <footer class="card-footer">
+ <a class="card-footer-item"
+ href="{{ post.permalink }}"
+ >
+ Read more...
+ </a>
+ <a class="card-footer-item"
+ href="{{ post.permalink }}"
+ target="_blank"
+ >
+ Open in new tab...
+ </a>
+ </footer>
+</div>
diff --git a/_includes/post-list.liquid b/_includes/post-list.liquid
deleted file mode 100644
index 2edc142..0000000
--- a/_includes/post-list.liquid
+++ /dev/null
@@ -1,41 +0,0 @@
-<div class="columns is-centered is-multiline">
- <p class="menu-label has-text-centered">
- Recent Posts
- </p>
-
- {% assign posts = collections.posts.pages %}
- {% for post in posts %}
- <div class="column is-full">
- <div class="card">
- <header class="card-header">
- <p class="card-header-title">
- {% if post.published_date %}
- {{ post.published_date | date: "%A, %b %e, %Y" }}
- {% endif %}
- </p>
- </header>
- <div class="card-content">
- <p class="subtitle">
- {{ post.title }}
- </p>
- <div class="content">
- {{ post.content | truncatewords: 50 }}
- </div>
- </div>
- <footer class="card-footer">
- <a class="card-footer-item"
- href="{{ post.permalink }}"
- >
- Read more...
- </a>
- <a class="card-footer-item"
- href="{{ post.permalink }}"
- target="_blank"
- >
- Open in new tab...
- </a>
- </footer>
- </div>
- </div>
- {% endfor %}
-</div>
diff --git a/_includes/recent-posts.liquid b/_includes/recent-posts.liquid
new file mode 100644
index 0000000..c93ce63
--- /dev/null
+++ b/_includes/recent-posts.liquid
@@ -0,0 +1,10 @@
+<div class="columns is-centered is-multiline">
+ <p class="menu-label has-text-centered">
+ Recent Posts
+ </p>
+
+ {% assign posts = collections.posts.pages %}
+ {% for post in posts %}
+ {% include post-card.liquid %}
+ {% endfor %}
+</div>
diff --git a/_layouts/index.liquid b/_layouts/index.liquid
index 39c0084..0c5e8db 100644
--- a/_layouts/index.liquid
+++ b/_layouts/index.liquid
@@ -8,10 +8,10 @@
<body>
<!-- begin hero -->
<section class="hero
- is-primary
- is-fullheight
- is-fullheight-with-navbar
- ">
+ is-primary
+ is-fullheight
+ is-fullheight-with-navbar
+ ">
<!-- begin hero head -->
<div class="hero-head">
{% include "nav.liquid" %}
@@ -77,6 +77,24 @@
</section>
<!-- end hero -->
+ <!-- begin latest post -->
+ <section class="section">
+ <div class="container">
+ <p class="title">
+ Latest Post
+ </p>
+ <p class="subtitle">
+ <a href="/journal">
+ See the whole journal here.
+ </a>
+ </p>
+
+ {% assign post = collections.posts.pages.first %}
+ {% include post-card.liquid %}
+ </div>
+ </section>
+ <!-- end latest post -->
+
<!-- begin main content -->
<section class="section">
<div class="container">
diff --git a/_layouts/journal.liquid b/_layouts/journal.liquid
index 8d8798c..81f6428 100644
--- a/_layouts/journal.liquid
+++ b/_layouts/journal.liquid
@@ -37,17 +37,17 @@
<div class="container">
<div class="columns">
- <!-- begin long post list -->
+ <!-- begin short post list -->
<div class="column">
- {% include post-list.liquid %}
+ {% include recent-posts.liquid %}
</div>
- <!-- end long post list -->
+ <!-- end short post list -->
- <!-- begin short post list -->
+ <!-- begin long post list -->
<div class="column is-narrow">
{% include all-posts.liquid %}
</div>
- <!-- end short post list -->
+ <!-- end long post list -->
</div>
</div>
diff --git a/index.md b/index.md
index 0966de8..dd2d9f0 100644
--- a/index.md
+++ b/index.md
@@ -3,12 +3,12 @@ layout: index.liquid
title: Welcome!
categories: ["index"]
---
-# Welcome!
+# Site Index
-You've reached the personal and professional pages of Adam Carpenter
-(53hornet). Below's a summary of what you'll find on my site. If you want to
-search my site or get alerts when new content is added, [subscribe to my RSS
-feed](/rss.xml).
+Welcome! You've reached the personal and professional pages of Adam
+Carpenter (53hornet). Below's a summary of what you'll find on my site.
+If you want to search my site or get alerts when new content is added,
+[subscribe to my RSS feed](/rss.xml).
## Journal