Skip to content

Commit

Permalink
Port article list page
Browse files Browse the repository at this point in the history
  • Loading branch information
chiwanpark committed May 1, 2018
1 parent 5a22c31 commit 44de3e1
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 3 deletions.
2 changes: 2 additions & 0 deletions _articles/index.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
= Articles
:page-layout: article-list
32 changes: 32 additions & 0 deletions _layouts/article-list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<!DOCTYPE html>
<html lang="{{ page.lang | default: site.lang | default: "en" }}">
<head>
{% assign page.title = "Articles" %}
{% include head.html %}
</head>
<body>
{% include navbar.html %}
<div class="content-container">
<main>
<h1>Articles</h1>
<ol class="articles">
{% assign articles = (site.articles | sort: 'date') | reverse %}
{% for article in articles %}
{% if article.title != "Articles" %}
<li class="article-overview">
<div class="date">{{ article.date | date: '%b %d, %Y' }}</div>
<div class="description">
<h2><a href="{{ article.url | relative_url }}">{{ article.title }}</a></h2>
<span class="summary">{{ article.summary }}</span>
</div>
</li>
{% endif %}
{% endfor %}
</ol>
</main>
</div>
{% include footer.html %}

{% include google-analytics.html %}
</body>
</html>
3 changes: 0 additions & 3 deletions pages/articles/index.md

This file was deleted.

0 comments on commit 44de3e1

Please sign in to comment.