Commit 120aaf65 authored by Sebastian Kotte's avatar Sebastian Kotte

Merge branch '338-beautify-related-news' into 'develop'

Resolve "Beautify related news"

Closes #338

See merge request !231
parents 7db03925 3f26e66c
Pipeline #5507 passed with stages
in 4 minutes and 59 seconds
......@@ -179,43 +179,45 @@
<f:if condition="{newsItem.allRelatedSorted}">
<!-- Related news records -->
<div class="card card-size-medium">
<section class="container">
<div class="frame frame-default frame-type-text frame-layout-0">
<header>
<h2>
<f:translate key="related-news"/>
</h2>
</header>
<ul class="list-unstyled d-block">
<f:for each="{newsItem.allRelatedSorted}" as="related">
<li>
<n:link class="news-related-item d-block mb-3" newsItem="{related}"
settings="{settings}" title="{related.title}">
<small>
<time datetime="{f:format.date(date:related.datetime, format:'%d %B %Y')}">
<f:format.date format="%d %B %Y">{related.datetime}</f:format.date>
<meta itemprop="datePublished"
content="{f:format.date(date:related.datetime, format:'Y-m-d')}"/>
</time>
<section class="container ">
<div class="col-md-12 mt-3 mb-3">
<div class="frame frame-default frame-type-text frame-layout-0">
<header>
<h2>
<f:translate key="related-news"/>
</h2>
</header>
<ul class="list-unstyled d-block">
<f:for each="{newsItem.allRelatedSorted}" as="related">
<li>
<n:link class="news-related-item d-block mb-3" newsItem="{related}"
settings="{settings}" title="{related.title}">
<small>
<time datetime="{f:format.date(date:related.datetime, format:'%d %B %Y')}">
<f:format.date format="%d %B %Y">{related.datetime}</f:format.date>
<meta itemprop="datePublished"
content="{f:format.date(date:related.datetime, format:'Y-m-d')}"/>
</time>
<f:if condition="{related.categories -> f:count()} > 0">
<div class="d-inline-block news-related-item__categories">
<span><f:translate key="categories"/>:</span>
<f:for each="{related.categories}" as="category"
iteration="iterator">
<f:if condition="{related.categories -> f:count()} > 0">
<div class="d-inline-block news-related-item__categories">
<span><f:translate key="categories"/>:</span>
<f:for each="{related.categories}" as="category"
iteration="iterator">
<span>{category.title}<f:if
condition="{iterator.isLast} == false">,</f:if></span>
</f:for>
</div>
</f:if>
</small>
</f:for>
</div>
</f:if>
</small>
<h5>{related.title}</h5>
</n:link>
</li>
</f:for>
</ul>
</div>
<h5>{related.title}</h5>
</n:link>
</li>
</f:for>
</ul>
</div>
</div>
</section>
</div>
</f:if>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment