forked from hugoferreira/papyrus-theme
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathtags.html
28 lines (25 loc) · 759 Bytes
/
tags.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
---
layout: page
title: Tags
---
{% assign alldocs = site.documents %}
{% assign alltags = alldocs | map: 'tags' | join: ',' | split: ',' | group_by_exp: "tag","tag" %}
<p>
Click on any post to find all the pages 'tagged' with that tag.
</p>
<ul class="tag-box">
{% for tag in alltags %}
<li><a href="#{{ tag.name | slugify }}">{{ tag.name }} - <span>{{ tag.size }}</span></a></li>
{% endfor %}
{% assign tags_list = nil %}
</ul>
{% for tag in alltags %}
<h2 class="nice-title" id="{{ tag.name }}">{{ tag.name }}</h2>
<ul>
{%- for document in alldocs -%}
{% if document.tags contains tag.name %}
<li><a href="{{ document.url }}">{{ document.title }}</a></li>
{% endif %}
{% endfor %}
</ul>
{% endfor %}