From d139da3a3277f73d7f01e4283d8dc01630a5317c Mon Sep 17 00:00:00 2001 From: Zhiming Wang Date: Mon, 20 Oct 2014 16:38:24 -0700 Subject: initial setup --- source/_includes/post/author.html | 8 ++++++++ source/_includes/post/categories.html | 10 ++++++++++ source/_includes/post/date.html | 5 +++++ source/_includes/post/disqus_thread.html | 1 + source/_includes/post/sharing.html | 11 +++++++++++ 5 files changed, 35 insertions(+) create mode 100644 source/_includes/post/author.html create mode 100644 source/_includes/post/categories.html create mode 100644 source/_includes/post/date.html create mode 100644 source/_includes/post/disqus_thread.html create mode 100644 source/_includes/post/sharing.html (limited to 'source/_includes/post') diff --git a/source/_includes/post/author.html b/source/_includes/post/author.html new file mode 100644 index 00000000..83dd6a89 --- /dev/null +++ b/source/_includes/post/author.html @@ -0,0 +1,8 @@ +{% if post.author %} + {% assign author = post.author %} +{% elsif page.author %} + {% assign author = page.author %} +{% else %} + {% assign author = site.author %} +{% endif %} +{% if author %}Posted by {{ author }}{% endif %} diff --git a/source/_includes/post/categories.html b/source/_includes/post/categories.html new file mode 100644 index 00000000..4a98b29d --- /dev/null +++ b/source/_includes/post/categories.html @@ -0,0 +1,10 @@ +{% capture category %}{% if post %}{{ post.categories | category_links | size }}{% else %}{{ page.categories | category_links | size }}{% endif %}{% endcapture %} +{% unless category == '0' %} + + {% if post %} + {{ post.categories | category_links }} + {% else %} + {{ page.categories | category_links }} + {% endif %} + +{% endunless %} diff --git a/source/_includes/post/date.html b/source/_includes/post/date.html new file mode 100644 index 00000000..a86953c2 --- /dev/null +++ b/source/_includes/post/date.html @@ -0,0 +1,5 @@ +{% if page.date %}{% capture time %}{{ page.date_time_html }}{% endcapture %}{% endif %} +{% if post.date %}{% capture time %}{{ post.date_time_html }}{% endcapture %}{% endif %} + +{% if page.updated %}{% capture updated %}{{ page.date_time_updated_html }}{% endcapture %}{% endif %} +{% if post.updated %}{% capture updated %}{{ post.date_time_updated_html }}{% endcapture %}{% endif %} diff --git a/source/_includes/post/disqus_thread.html b/source/_includes/post/disqus_thread.html new file mode 100644 index 00000000..b1acd8cc --- /dev/null +++ b/source/_includes/post/disqus_thread.html @@ -0,0 +1 @@ + diff --git a/source/_includes/post/sharing.html b/source/_includes/post/sharing.html new file mode 100644 index 00000000..d639faa1 --- /dev/null +++ b/source/_includes/post/sharing.html @@ -0,0 +1,11 @@ +
+ {% if site.twitter_tweet_button %} + + {% endif %} + {% if site.google_plus_one %} +
+ {% endif %} + {% if site.facebook_like %} +
+ {% endif %} +
-- cgit v1.2.1