Skip to content
Snippets Groups Projects
Commit cd608a5d authored by OndraPetrzilka's avatar OndraPetrzilka
Browse files

if there is no image, do not display it

parent 3729e7f9
No related branches found
No related tags found
2 merge requests!632Release,!630if there is no image, do not display it
Pipeline #9848 passed
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
{% if page.author_page %} {% if page.author_page %}
<a href="{{ page.author_page.url }}" itemprop="name">{{ page.author }}</a> <a href="{{ page.author_page.url }}" itemprop="name">{{ page.author }}</a>
{% else %} {% else %}
<span itemprop="name">{{ page.author }}</span> <span itemprop="name">{{ page.author|default_if_none:'' }}</span>
{% endif %} {% endif %}
</span> </span>
</div> </div>
...@@ -31,11 +31,12 @@ ...@@ -31,11 +31,12 @@
{% endfor %} {% endfor %}
</div> </div>
</div> </div>
{% if page.image %}
<figure class="figure"> <figure class="figure">
{% image page.image width-2000 as img %} {% image page.image width-2000 as img %}
<img src="{{ img.url }}" alt="{{ page.title }}"/> <img src="{{ img.url }}" alt="{{ page.title }}"/>
</figure> </figure>
{% endif %}
<div class="lg:flex mt-8 lg:space-x-16"> <div class="lg:flex mt-8 lg:space-x-16">
<div class="lg:w-2/3"> <div class="lg:w-2/3">
<div itemprop="description" class="w-full space-y-8"> <div itemprop="description" class="w-full space-y-8">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment