From c1f9a31f0c8d6a75e8ab902720f0c4c4830ba6fc Mon Sep 17 00:00:00 2001 From: Sébastien Dailly Date: Thu, 9 May 2013 14:40:47 +0200 Subject: Updated theme --- theme/templates/abstract.html | 7 ++++++- theme/templates/category.html | 12 +++--------- theme/templates/index.html | 15 +++------------ theme/templates/tag.html | 12 ++---------- 4 files changed, 14 insertions(+), 32 deletions(-) diff --git a/theme/templates/abstract.html b/theme/templates/abstract.html index 57ff2ab..5d10bfc 100644 --- a/theme/templates/abstract.html +++ b/theme/templates/abstract.html @@ -1,4 +1,5 @@ -{% macro abstract(article, title_level) %} +{% macro abstract(title_level) %} + {% for article in (articles_page.object_list if articles_page else articles) %}
<{{title_level}} class="title">{{article.title }} @@ -16,4 +17,8 @@
+ + {% endfor %} + + {% include 'navigator.html' %} {% endmacro %} diff --git a/theme/templates/category.html b/theme/templates/category.html index f3588eb..30284ca 100755 --- a/theme/templates/category.html +++ b/theme/templates/category.html @@ -1,18 +1,12 @@ {% extends "base.html" %} -{% block title %}{{ SITENAME }} - {{ category}}{% endblock %} +{% block title %}{{ SITENAME }} - {{ category }}{% endblock %} {% block content %}

Articles dans la catégorie « {{ category }} »

{% if articles %} - {% for article in (articles_page.object_list if articles_page else articles) %} - {% import 'abstract.html' as abstract with context %} - {{ abstract.abstract(article, "h2") }} - {% if not loop.last %} -
- {% endif %} - {% endfor %} + {% import 'abstract.html' as abstract with context %} + {{ abstract.abstract("h2") }} {% endif %} - {% include 'navigator.html' %} {% if CATEGORY_FEED_RSS %} diff --git a/theme/templates/index.html b/theme/templates/index.html index a54ae31..e35bb04 100755 --- a/theme/templates/index.html +++ b/theme/templates/index.html @@ -2,19 +2,11 @@ {% block title %}{{ SITENAME }} - Accueil{% endblock %} {% block content %} - {% if articles %} - {% for article in (articles_page.object_list if articles_page else articles) %} + {% if articles %} {% import 'abstract.html' as abstract with context %} - {{ abstract.abstract(article, "h1") }} - - {% if not loop.last %} -
- {% endif %} - - {% endfor %} - - {% include 'navigator.html' %} + {{ abstract.abstract("h1") }} + {% endif %} {% if FEED_RSS %} @@ -24,5 +16,4 @@ {% endif %} - {% endif %} {% endblock %} diff --git a/theme/templates/tag.html b/theme/templates/tag.html index 101a22d..533ca5c 100755 --- a/theme/templates/tag.html +++ b/theme/templates/tag.html @@ -1,20 +1,12 @@ {% extends "base.html" %} -{% block title %}{{ SITENAME }} - «{{ tag }}»{% endblock %} +{% block title %}{{ SITENAME }} - {{ tag }}{% endblock %} {% block content %}

Articles avec le mot-clef « {{ tag }} »

{% if articles %} - {% for article in (articles_page.object_list if articles_page else articles) %} {% import 'abstract.html' as abstract with context %} - {{ abstract.abstract(article, "h2") }} - - {% if not loop.last %} -
- {% endif %} - - {% endfor %} + {{ abstract.abstract("h2") }} {% endif %} - {% include 'navigator.html' %} {% if TAG_FEED_RSS %} -- cgit v1.2.3