Fixing tags bullet joiner

This commit is contained in:
Lucas Cimon 2017-08-15 23:57:43 +02:00
parent e963d49d9b
commit 00defb07c0
3 changed files with 12 additions and 6 deletions

View File

@ -174,15 +174,16 @@ a {
color: #FF6600; }
.mg-tags {
font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
text-align: right; }
.mg-tag {
margin: 0 .5rem;
font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
color: #FF6600; }
.mg-tag:hover {
text-decoration: none;
color: #FF6600; }
.mg-tag > .uk-icon-tag {
display: inline; /* so that the icon stick with the tag label */
margin-right: .2rem; }
.mg-list-title {

View File

@ -1,5 +1,5 @@
<article class="uk-article mg-fadeable" itemtype="http://schema.org/BlogPosting" itemscope="itemscope" itemprop="blogPost"
data-tags='{{ article.tags|map(attribute='name')|list|tojson }}'>
data-tags='{{ article.tags|map(attribute="name")|list|tojson }}'>
<div class="mg-article-short">
{% if article.featured_image %}
<img class="mg-article-image image-process-thumb" src="{{ article.featured_image }}" alt="">
@ -19,4 +19,3 @@
</div>
<hr class="uk-article-divider">
</article>

View File

@ -1,3 +1,9 @@
{% set bullet = joiner(" &bullet; ") %}
<div class="mg-tags" title="Tags">{% for tag in article.tags %}{{bullet()}}<a class="mg-tag" href="{{tag.url}}"><i class="uk-icon-tag">&nbsp;{{tag.name}}</i></a>{% endfor %}</div>
{% set bullet = joiner(" • ") %}
<div class="mg-tags" title="Tags">
{% for tag in article.tags %}
{{bullet()}}
<a class="mg-tag" href="{{tag.url}}">
<i class="uk-icon-tag"></i>{{tag.name}}
</a>
{% endfor %}
</div>