You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
747 B
HTML

{% macro project_list() %}
{% for project in section.pages %}
<a href="{{ project.permalink }}">
{% set_global image = "/static/img/project_placeholder.png" %}
{% for asset in project.assets %}
{% if asset is matching("[img.](jpg|png)$") %}
{% set_global image = asset %}
{% break %}
{% endif %}
{% endfor %}
{% set image = resize_image(path=image, width=300, height=300, op="fill") %}
<div class="image" style="background-image: url('{{ image.url }}')"></div>
<div class="description">
<div class="title">{{ project.title }}</div>
<p>
{% if project.description %}
{{ project.description }}
{% else %}
&hellip;
{% endif %}
</p>
</div>
</a>
{% endfor %}
{% endmacro %}