mirror of
https://github.com/WatchOutNewsAgency/wona.github.com.git
synced 2026-01-01 01:16:26 +00:00
1. Added Category support
2. Designed blog archives pages 3. Restructured Sass 4. Added Categories to rake post metadata 5. Some general style improvements
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
{% unless page.no_header %}
|
||||
<header>
|
||||
{% if index %}
|
||||
<h1 class="entry-title"><a href="{{ page.url }}">{{ page.title | titlecase }}</a></h1>
|
||||
<h1 class="entry-title"><a href="{{ post.url }}">{{ post.title | titlecase }}</a></h1>
|
||||
{% else %}
|
||||
<h1 class="entry-title">{{ page.title | titlecase }}</h1>
|
||||
{% endif %}
|
||||
@ -10,12 +10,13 @@
|
||||
{% endunless %}
|
||||
{% if index %}
|
||||
<div class="entry-content">{{ content | exerpt | smart_quotes }}</div>
|
||||
<p><a rel="full-article" href="{{ page.url }}">Read on →</a></p>
|
||||
<p><a rel="full-article" href="{{ post.url }}">Read on →</a></p>
|
||||
<footer>
|
||||
<p class="meta">
|
||||
{% include post_author.html %}
|
||||
{% include post_date.html %}
|
||||
<span class="comments"><a rel="comments" href="{{ page.url }}#disqus_thread">Add a comment</a></span>
|
||||
{% include post_categories.html %}
|
||||
<span class="comments"><a rel="comments" href="{{ post.url }}#disqus_thread">Comments</a></span>
|
||||
{% include sharing.html %}
|
||||
</p>
|
||||
</footer>
|
||||
|
||||
@ -11,6 +11,6 @@
|
||||
</fieldset>
|
||||
</form>
|
||||
<ul role="main-nav">
|
||||
<li><a href="/">Home</a></li>
|
||||
<li><a href="/archive.html">Archive</a></li>
|
||||
<li><a href="/">Blog</a></li>
|
||||
<li><a href="/archives.html">Archives</a></li>
|
||||
</ul>
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
{% if page.author %}
|
||||
{% assign author = page.author %}
|
||||
{% if post.author %}
|
||||
{% assign author = post.author %}
|
||||
{% else %}
|
||||
{% assign author = site.author %}
|
||||
{% endif %}
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{% if page.date %}
|
||||
<time datetime="{{ page.date | datetime }}" pubdate {% if page.updated %} updated {% endif %}>{{ page.date | ordinalize }}</time>
|
||||
{% capture date %}{{ page.date }}{{ post.date }}{% endcapture %}
|
||||
{% capture has_date %}{{ date | size }}{% endcapture %}
|
||||
{% capture updated %}{{ page.updated }}{{ post.updated }}{% endcapture %}
|
||||
{% capture was_updated %}{{ updated | size }}{% endcapture %}
|
||||
{% if has_date != '0' %}
|
||||
<time datetime="{{ date | datetime }}" pubdate {% if updated %} updated {% endif %}>{{ date | ordinalize }}</time>
|
||||
{% endif %}
|
||||
{% if page.updated %}
|
||||
<time class="updated" datetime="{{ page.updated | datetime }}"></time>
|
||||
{% if was_updated != '0' %}
|
||||
<time class="updated" datetime="{{ updated | datetime }}"></time>
|
||||
{% endif %}
|
||||
|
||||
@ -5,13 +5,16 @@ single: true
|
||||
|
||||
<article class="hentry">
|
||||
{% include article.html %}
|
||||
{% unless page.no_meta %}
|
||||
<footer>
|
||||
<p class="meta">
|
||||
{% include post_author.html %}
|
||||
{% include post_date.html %}
|
||||
{% include post_categories.html %}
|
||||
{% include sharing.html %}
|
||||
</p>
|
||||
</footer>
|
||||
{% endunless %}
|
||||
{% if site.disqus_short_name %}
|
||||
<section>
|
||||
<h1>Comments</h1>
|
||||
|
||||
@ -1,24 +0,0 @@
|
||||
---
|
||||
layout: post
|
||||
title: Blog Archive
|
||||
no_meta: true
|
||||
---
|
||||
{% for post in site.posts reverse %}
|
||||
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %}
|
||||
{% capture this_month %}{{ post.date | date: "%B" }}{% endcapture %}
|
||||
{% unless year == this_year %}
|
||||
{% unless forloop.first %}</ul>{% endunless %}
|
||||
{% assign year = this_year %}
|
||||
<h2>{{ year }}</h2>
|
||||
<ul class="blog_archives">
|
||||
{% endunless %}
|
||||
{% unless month == this_month %}
|
||||
{% assign month = this_month %}
|
||||
<li><h4>{{ month }}</h4></li>
|
||||
{% endunless %}
|
||||
<li>
|
||||
<time datetime="{{ post.date | datetime }}" pubdate>{{ post.date | date: "%d"}}</time>
|
||||
<a href="{{ post.url }}">{{post.title}}</a>
|
||||
</li>
|
||||
{% if forloop.last %}</ul>{% endif %}
|
||||
{% endfor %}
|
||||
@ -3,8 +3,8 @@ layout: default
|
||||
blog_index: true
|
||||
---
|
||||
{% assign index = true %}
|
||||
{% for page in paginator.posts %}
|
||||
{% assign content = page.content %}
|
||||
{% for post in paginator.posts %}
|
||||
{% assign content = post.content %}
|
||||
<article>
|
||||
{% include article.html %}
|
||||
</article>
|
||||
|
||||
Reference in New Issue
Block a user