aboutsummaryrefslogtreecommitdiffstats
path: root/medio/templates/category.html
diff options
context:
space:
mode:
authorPachamaltese <mvargas@dcc.uchile.cl>2017-04-08 08:49:35 -0300
committerAlexis Metaireau <alexis@notmyidea.org>2017-04-08 13:49:35 +0200
commitb201e57315350340366ca8d2659e5429b85aab10 (patch)
tree2b6fe40e630e8916285d9293da8e057d50b30db9 /medio/templates/category.html
parentaad467728fc44d967a410cea977bf67a67355fb6 (diff)
downloadpelican-themes-b201e57315350340366ca8d2659e5429b85aab10.tar.gz
uploaded medio theme (#477)
* uploaded medio theme * cons example * Added example_pelicanconf.py
Diffstat (limited to 'medio/templates/category.html')
-rwxr-xr-xmedio/templates/category.html153
1 files changed, 153 insertions, 0 deletions
diff --git a/medio/templates/category.html b/medio/templates/category.html
new file mode 100755
index 0000000..96a2a4a
--- /dev/null
+++ b/medio/templates/category.html
@@ -0,0 +1,153 @@
+{% extends "base.html" %}
+{% block title %}{{ category|striptags }}{% endblock %}
+{% block content %}
+<div class="category-page-container">
+ <div class="category-logo">
+ {% if category|string in BLOG_CATEGORIES and BLOG_CATEGORIES.get(category|string).logo %}
+ <a href="{{ SITEURL }}/{{ category.url }}" rel="bookmark" title="Permalink to {{ category|striptags }}"><img src="{{ BLOG_CATEGORIES.get(category|string).logo }}" alt="{{ category|striptags }}"/></a>
+ {% else %}
+ <h1><a href="{{ SITEURL }}/{{ category.url }}" rel="bookmark" title="Permalink to {{ category|striptags }}">{{ category }}</a></h1>
+ {% endif %}
+ </div>
+
+ <div class="section-header">
+ Latest
+ </div>
+
+
+
+ {% set i = 0 %}
+ {% for article in articles_page.object_list %}
+ {% if i == 0 %}
+ <div class="pure-g article-row">
+ {% if article.cover or article.thumbnail %}
+ <div class="pure-u-1 pure-u-md-2-3">
+ <div class="col">
+ {% if article.cover %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-1" style="background-image:url({{ article.cover }})"><span class="header">{{ article.title }}</span></a>
+ {% elif article.thumbnail %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-1" style="background-image:url({{ article.thumbnail }})"><span class="header">{{ article.title }}</span></a>
+ {% endif %}
+ </div>
+ </div>
+ {% endif %}
+ <div class="pure-u-1{% if article.cover or article.thumbnail %} pure-u-md-1-3{% endif %} article-info">
+ <div class="col">
+
+ <h1><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></h1>
+
+ {{ article.summary }}
+
+ {% for author in article.authors %}
+ <div class="post-meta pure-g">
+ {% if author|string in BLOG_AUTHORS %}
+ <div class="pure-u">
+ <img src="{{ BLOG_AUTHORS.get(author|string).image }}" class="post-avatar" alt="Go to the profile of {{ author|striptags }}">
+ </div>
+ {% endif %}
+ <div class="pure-u-3-4 meta-data">
+ <a href="{{ SITEURL }}/{{ author.url }}" class="category">{{ author }}</a><br />
+ <abbr title="{{ article.date.isoformat() }}">{{ article.locale_date }}</abbr>
+ {% if article.readtime_minutes %}
+ &mdash; {{ article.readtime_minutes }} min read
+ {% endif %}
+ </div>
+ </div>
+ {% endfor %}
+
+ </div>
+
+ </div>
+
+ </div>
+ {% elif i < 3 %}
+ {% if i == 1 %}
+ <div class="pure-g article-row">
+ {% endif %}
+
+ <div class="pure-u-1 pure-u-sm-1-2 article-info">
+ <div class="col">
+ {% if article.cover %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-2" style="background-image:url({{ article.cover }})"><span class="header">{{ article.title }}</span></a>
+ {% elif article.thumbnail %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-2" style="background-image:url({{ article.thumbnail }})"><span class="header">{{ article.title }}</span></a>
+ {% endif %}
+
+ <h2><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></h2>
+ {{ article.summary }}
+
+ {% for author in article.authors %}
+ <div class="post-meta pure-g">
+ {% if author|string in BLOG_AUTHORS %}
+ <div class="pure-u">
+ <img src="{{ BLOG_AUTHORS.get(author|string).image }}" class="post-avatar" alt="Go to the profile of {{ author|striptags }}">
+ </div>
+ {% endif %}
+ <div class="pure-u-3-4 meta-data">
+ <a href="{{ SITEURL }}/{{ author.url }}" class="category">{{ author }}</a><br />
+ <abbr title="{{ article.date.isoformat() }}">{{ article.locale_date }}</abbr>
+ {% if article.readtime_minutes %}
+ &mdash; {{ article.readtime_minutes }} min read
+ {% endif %}
+ </div>
+ </div>
+ {% endfor %}
+
+ </div>
+ </div>
+
+ {% if i == 2 %}
+ </div>
+ {% endif %}
+ {% else %}
+ {% if i % 3 == 0 %}
+ <div class="pure-g article-row">
+ {% endif %}
+
+
+ <div class="pure-u-1 pure-u-lg-1-3 article-info">
+ <div class="col">
+ {% if article.cover %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-3" style="background-image:url({{ article.cover }})"><span class="header">{{ article.title }}</span></a>
+ {% elif article.thumbnail %}
+ <a href="{{ SITEURL }}/{{ article.url }}" class="article-thumbnail article-thumbnail-3" style="background-image:url({{ article.thumbnail }})"><span class="header">{{ article.title }}</span></a>
+ {% endif %}
+
+ <h2><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></h2>
+ {{ article.summary }}
+
+ {% for author in article.authors %}
+ <div class="post-meta pure-g">
+ {% if author|string in BLOG_AUTHORS %}
+ <div class="pure-u">
+ <img src="{{ BLOG_AUTHORS.get(author|string).image }}" class="post-avatar" alt="Go to the profile of {{ author|striptags }}">
+ </div>
+ {% endif %}
+ <div class="pure-u-3-4 meta-data">
+ <a href="{{ SITEURL }}/{{ author.url }}" class="category">{{ author }}</a><br />
+ <abbr title="{{ article.date.isoformat() }}">{{ article.locale_date }}</abbr>
+ {% if article.readtime_minutes %}
+ &mdash; {{ article.readtime_minutes }} min read
+ {% endif %}
+ </div>
+ </div>
+ {% endfor %}
+
+ </div>
+ </div>
+
+
+ {% if i % 3 == 2 %}
+ </div>
+ {% endif %}
+ {% endif %}
+ {% set i = i + 1 %}
+ {% endfor %}
+
+ {% if articles_page.object_list|length % 3 != 0 %}
+ </div>
+ {% endif %}
+
+ {% include "pagination.html" %}
+</div>
+{% endblock %}