]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - themes/default/home.twig
Better names for epub files and epub in all themes now
[github/wallabag/wallabag.git] / themes / default / home.twig
index bd5fc2d6ed1a8749f2a467dc60136f77ac3c359b..e6c781f58e53331c56826517f6cc4c689521d201 100755 (executable)
 {% include '_menu.twig' %}
 {% endblock %}
 {% block precontent %}
-            {% include '_sorting.twig' %}
+
+{% include '_sorting.twig' %}
 {% endblock %}
 {% block content %}
+
+                                               {% if includeImport %}
+                                                               {% include '_import.twig' %}
+                                               {% endif %}
+
             {% if tag %}
                 <h3>{% trans "Tag" %}: <b>{{ tag.value }}</b></h3>
             {% endif %}
                 {% block pager %}
                     {% if nb_results > 1 %}
                 <div class="results">
-                    <div class="nb-results">{{ nb_results }} {% trans "results" %}</div>
+                    <div class="nb-results">{{ nb_results }} {% trans "results" %}{% if search_term is defined %}{% trans " found for « " %} {{ search_term }} »{% endif %}</div>
                         {{ page_links | raw }}
                 </div>
+                    {% elseif nb_results == 1 %}
+                        {% if search_term is defined %}
+                     <div class="results">
+                        <div class="nb-results">{% trans "Only one result found for " %} « {{ search_term }} »</div>
+                     </div>
+                        {% endif %}
                     {% endif %}
                 {% endblock %}
                 {% for entry in entries %}
                 <p>{{ entry.content|striptags|slice(0, 300) }}...</p>
             </div>
                 {% endfor %}
-            {% endif %}
+
             {{ block('pager') }}
+            
             {% if view == 'home' %}{% if nb_results > 1 %}<a title="{% trans "mark all the entries as read" %}"  href="./?action=archive_all">{% trans "mark all the entries as read" %}</a>{% endif %}{% endif %}
+            
+            {% if tag %}<a title="{% trans "Download the articles from this tag in an epub" %}" href="./?epub&amp;method=tag&amp;tag={{ tag.value }}">{% trans "Download the articles from this tag in an epub" %}</a>
+            {% elseif search_term is defined %}<a title="{% trans "Download the articles from this search in an epub" %}" href="./?epub&amp;method=search&amp;search={{ search_term }}">{% trans "Download the articles from this search in an epub" %}</a>
+            {% else %}<a title="{% trans "Download the articles from this category in an epub" %}" href="./?epub&amp;method=category&amp;category={{ view }}">{% trans "Download the articles from this category in an epub" %}</a>{% endif %}
+            
+            {% endif %}
 {% endblock %}