]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Resources/views/Entry/entries.html.twig
add previewPicture on baggy theme
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Resources / views / Entry / entries.html.twig
index 3f5cf46090e7a3739b70d912df9fb737424252cc..0d295431ec2c2268a7436b9042cf6be51fbe4f1c 100644 (file)
                     <li><a title="{% trans %}delete{% endtrans %}" class="tool delete icon-trash icon" href="{{ path('delete_entry', { 'id': entry.id }) }}"><span>{% trans %}delete{% endtrans %}</span></a></li>
                     <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans %}original{% endtrans %} : {{ entry.title|e }}" class="tool link icon-link icon"><span>{{ entry.domainName }}</span></a></li>
                 </ul>
-                <p>{{ entry.content|striptags|slice(0, 300) }}&hellip;</p>
+                {% if entry.previewPicture is null %}
+                    <p>{{ entry.content|striptags|slice(0, 300) }}&hellip;</p>
+                {% else %}
+                    <img class="preview" src="{{ entry.previewPicture }}" alt="{{ entry.title|raw }}" />
+                {% endif %}
             </div>
         {% endfor %}
     {% endif %}