Info blocks action optional, layout fixed

This commit is contained in:
Oleg Lavrovsky 2017-05-10 16:57:35 +02:00
parent 8862eaab2e
commit 5a2196abfc
3 changed files with 18 additions and 9 deletions

View file

@ -43,12 +43,12 @@
{% for block in subcategories %} {% for block in subcategories %}
<article class="col-md-4"> <article class="col-md-4">
<a href="{% pageurl block %}"> <a href="{% pageurl block %}">
<header>
<h4>{{ block.trans_title }}</h4>
</header>
<div class="image"> <div class="image">
{% image block.feed_image fill-300x300 %} {% image block.feed_image fill-300x300 %}
</div> </div>
<header>
<h3>{{ block.trans_title }}</h3>
</header>
</a> </a>
</article> </article>
{% endfor %} {% endfor %}

View file

@ -5,16 +5,20 @@
<div class="row infoblocks"> <div class="row infoblocks">
{% for block in page.trans_infos %} {% for block in page.trans_infos %}
<article class="col-md-4"> <article class="col-md-4">
<div class="image"> <a href="{{ block.value.url }}">
{% image block.value.photo fill-300x300 %} <div class="image">
</div> {% image block.value.photo fill-300x300 %}
<header> </div>
<h3>{{ block.value.title }}</h3> <header>
</header> <h3>{{ block.value.title }}</h3>
</header>
</a>
{{ block.value.summary|richtext }} {{ block.value.summary|richtext }}
{% if block.value.action %}
<footer> <footer>
<a href="{{ block.value.url }}" class="btn btn-default">{{ block.value.action }}</a> <a href="{{ block.value.url }}" class="btn btn-default">{{ block.value.action }}</a>
</footer> </footer>
{% endif %}
</article> </article>
{% endfor %} {% endfor %}
</div> </div>

View file

@ -41,6 +41,11 @@ section {
} }
} }
// Article index blocks
.article-subcategories article {
margin-bottom: 1.5em;
}
// Special article layout // Special article layout
.article-page .lead { .article-page .lead {
h2,h3,h4,h5 { text-align: center; } h2,h3,h4,h5 { text-align: center; }