aboutsummaryrefslogtreecommitdiffstats
path: root/pelican-bootstrap3/templates/includes
diff options
context:
space:
mode:
Diffstat (limited to 'pelican-bootstrap3/templates/includes')
-rw-r--r--pelican-bootstrap3/templates/includes/article_info.html9
-rw-r--r--pelican-bootstrap3/templates/includes/pagination.html7
-rw-r--r--pelican-bootstrap3/templates/includes/series.html22
-rw-r--r--pelican-bootstrap3/templates/includes/sidebar.html24
4 files changed, 59 insertions, 3 deletions
diff --git a/pelican-bootstrap3/templates/includes/article_info.html b/pelican-bootstrap3/templates/includes/article_info.html
index f13f4d1..787c360 100644
--- a/pelican-bootstrap3/templates/includes/article_info.html
+++ b/pelican-bootstrap3/templates/includes/article_info.html
@@ -3,6 +3,15 @@
<span class="published">
<i class="fa fa-calendar"></i><time datetime="{{ article.date.isoformat() }}"> {{ article.locale_date }}</time>
</span>
+
+ {% if SHOW_SERIES %}
+ {% if article.series %}
+ <span class="label label-default">Series</span>
+ Part {{ article.series.index}} of {{ article.series.name }}
+ {% endif %}
+ {% endif %}
+
+
{% if SHOW_ARTICLE_AUTHOR %}
{% if article.author %}
<span class="label label-default">By</span>
diff --git a/pelican-bootstrap3/templates/includes/pagination.html b/pelican-bootstrap3/templates/includes/pagination.html
index 9ae4285..2627bb1 100644
--- a/pelican-bootstrap3/templates/includes/pagination.html
+++ b/pelican-bootstrap3/templates/includes/pagination.html
@@ -23,9 +23,10 @@
<li class="prev disabled"><a href="#">&laquo;</a></li>
{% endif %}
{% for num in range( 1, 1 + articles_paginator.num_pages ) %}
+ {% set page = articles_paginator.page(num) %}
<li class="{{ 'active' if num == articles_page.number else '' }}"><a
- href="{{ SITEURL }}/{{ page_name }}{{ num if num > 1 else '' }}.html">{{ num }}</a></li>
- {% endfor %}
+ href="{{ SITEURL }}/{{ page.url }}">{{ num }}</a></li>
+ {% endfor %}
{% if articles_page.has_next() %}
<li class="next"><a
href="{{ SITEURL }}/{{ articles_next_page.url }}">&raquo;</a></li>
@@ -34,4 +35,4 @@
{% endif %}
</ul>
{% endif %}
-{% endif %} \ No newline at end of file
+{% endif %}
diff --git a/pelican-bootstrap3/templates/includes/series.html b/pelican-bootstrap3/templates/includes/series.html
new file mode 100644
index 0000000..24729a2
--- /dev/null
+++ b/pelican-bootstrap3/templates/includes/series.html
@@ -0,0 +1,22 @@
+{% if article.series %}
+<section class="well" id="related-posts">
+ {% set text = SERIES_TEXT|default('Part %(index)s of the %(name)s series') %}
+ <h4>{{ text|format(index=article.series.index, name=article.series.name) }}</h4>
+ {% if article.series.all_previous %}
+ <h5>Previous articles</h5>
+ <ul>
+ {% for article in article.series.all_previous %}
+ <li><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></li>
+ {% endfor %}
+ </ul>
+ {% endif %}
+ {% if article.series.all_next %}
+ <h5>Next articles</h5>
+ <ul>
+ {% for article in article.series.all_next %}
+ <li><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></li>
+ {% endfor %}
+ </ul>
+ {% endif %}
+</section>
+{% endif %}
diff --git a/pelican-bootstrap3/templates/includes/sidebar.html b/pelican-bootstrap3/templates/includes/sidebar.html
index ef6768b..35811f6 100644
--- a/pelican-bootstrap3/templates/includes/sidebar.html
+++ b/pelican-bootstrap3/templates/includes/sidebar.html
@@ -70,6 +70,30 @@
</ul>
</li>
{% endif %}
+
+ {% if DISPLAY_SERIES_ON_SIDEBAR %}
+ {% if article %}
+ {% if article.series %}
+ <li class="list-group-item"><h4><i class="fa fa-tags fa-list-ul"></i><span class="icon-label">Series</span></h4>
+ <ul class="list-group">
+ <li class="list-group-item">
+ {% if article.series.previous %}
+ <h5></i> Previous article</h5>
+ <a href="{{ SITEURL }}/{{ article.series.previous.url }}">{{ article.series.previous.title }}</a>
+ {% endif %}
+ </li>
+ <li class="list-group-item">
+ {% if article.series.next %}
+ <h5>Next article</h5>
+ <a href="{{ SITEURL }}/{{ article.series.next.url }}">{{ article.series.next.title }}</a>
+ {% endif %}
+ </li>
+ </ul>
+ </li>
+ {% endif%}
+ {% endif %}
+ {% endif %}
+
{% include 'includes/github.html' %}
{% include 'includes/twitter_timeline.html' %}
{% include 'includes/links.html' %}