Fix commonmark compatibility in tags+posts.
This commit is contained in:
parent
4ecba529e9
commit
79d8a3351f
2 changed files with 22 additions and 22 deletions
|
@ -10,22 +10,22 @@ permalink: /posts/
|
||||||
<div class="tags-header-line"></div>
|
<div class="tags-header-line"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tags-clouds">
|
<div class="tags-clouds">
|
||||||
{% for post in site.posts %}
|
{% for post in site.posts -%}
|
||||||
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %}
|
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture -%}
|
||||||
{% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture %}
|
{% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture -%}
|
||||||
{% if forloop.first %}<a href="#{{ this_year }}">{{ this_year }}</a>{% endif %}
|
{% if forloop.first %}<a href="#{{ this_year }}">{{ this_year }}</a>{% endif -%}
|
||||||
{% unless forloop.last %}
|
{% unless forloop.last -%}
|
||||||
{% if this_year != next_year %}<a href="#{{ next_year }}">{{ next_year }}</a>{% endif %}
|
{% if this_year != next_year %}<a href="#{{ next_year }}">{{ next_year }}</a>{% endif -%}
|
||||||
{% endunless %}
|
{% endunless -%}
|
||||||
{% endfor %}
|
{% endfor -%}
|
||||||
</div>
|
</div>
|
||||||
{% for post in site.posts %}
|
{% for post in site.posts -%}
|
||||||
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %}
|
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture -%}
|
||||||
{% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture %}
|
{% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture -%}
|
||||||
{% if forloop.first %}
|
{% if forloop.first -%}
|
||||||
<div class="tags-item" id="{{ this_year }}">
|
<div class="tags-item" id="{{ this_year }}">
|
||||||
<h2 class="tags-item-label">{{ this_year }}</h2>
|
<h2 class="tags-item-label">{{ this_year }}</h2>
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
<a class="tags-post" href="{{ post.url | prepend: site.baseurl }}">
|
<a class="tags-post" href="{{ post.url | prepend: site.baseurl }}">
|
||||||
<div>
|
<div>
|
||||||
<span class="tags-post-title">{{ post.title }}</span>
|
<span class="tags-post-title">{{ post.title }}</span>
|
||||||
|
@ -37,14 +37,14 @@ permalink: /posts/
|
||||||
</time>
|
</time>
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
{% if forloop.last %}
|
{% if forloop.last -%}
|
||||||
</div>
|
</div>
|
||||||
{% else %}
|
{% else -%}
|
||||||
{% if this_year != next_year %}
|
{% if this_year != next_year -%}
|
||||||
</div>
|
</div>
|
||||||
<div class="tags-item" id="{{ next_year }}">
|
<div class="tags-item" id="{{ next_year }}">
|
||||||
<h2 class="tags-item-label">{{ next_year }}</h2>
|
<h2 class="tags-item-label">{{ next_year }}</h2>
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
{% endif %}
|
{% endif -%}
|
||||||
{% endfor %}
|
{% endfor -%}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -10,11 +10,11 @@ permalink: /tags/
|
||||||
<div class="tags-header-line"></div>
|
<div class="tags-header-line"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tags-clouds">
|
<div class="tags-clouds">
|
||||||
{% for tag in site.tags %}
|
{% for tag in site.tags -%}
|
||||||
<a href="#{{ tag[0] }}">{{ tag[0] }}</a>
|
<a href="#{{ tag[0] }}">{{ tag[0] }}</a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
{% for tag in site.tags %}
|
{% for tag in site.tags -%}
|
||||||
<div class="tags-item" id="{{ tag[0] }}">
|
<div class="tags-item" id="{{ tag[0] }}">
|
||||||
<svg
|
<svg
|
||||||
class="tags-item-icon"
|
class="tags-item-icon"
|
||||||
|
@ -35,7 +35,7 @@ permalink: /tags/
|
||||||
<line x1="7" y1="7" x2="7.01" y2="7"></line>
|
<line x1="7" y1="7" x2="7.01" y2="7"></line>
|
||||||
</svg>
|
</svg>
|
||||||
<h2 class="tags-item-label">{{ tag[0] }}</h2>
|
<h2 class="tags-item-label">{{ tag[0] }}</h2>
|
||||||
{% for post in tag[1] %}
|
{% for post in tag[1] -%}
|
||||||
<a class="tags-post" href="{{ post.url | prepend: site.baseurl }}">
|
<a class="tags-post" href="{{ post.url | prepend: site.baseurl }}">
|
||||||
<div>
|
<div>
|
||||||
<span class="tags-post-title">{{ post.title }}</span>
|
<span class="tags-post-title">{{ post.title }}</span>
|
||||||
|
|
Loading…
Reference in a new issue