Repository navigation
Expand file tree
/
Copy pathtags.html
More file actions
33 lines (30 loc) · 1.37 KB
/
Copy pathtags.html
File metadata and controls
33 lines (30 loc) · 1.37 KB
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
29
30
31
32
33
---
layout: page
title: Tags in Projects
image: 10.jpg
permalink: /tags/
---
{% capture site_tags %}{% for tag in site.tags %}{{ tag | first }}{% unless forloop.last %},{% endunless %}{% endfor %}{% endcapture %}
{% assign tag_words = site_tags | split:',' | sort %}
<div class="tags">
<ul class="tags-list">
{% for item in (0..site.tags.size) %}{% unless forloop.last %}
{% capture this_word %}{{ tag_words[item] | strip_newlines }}{% endcapture %}
<li class="tags-item"><a href="#{{ this_word | cgi_escape }}" class="tags-link">{{ this_word }} <span>{{ site.tags[this_word].size }}</span></a></li>
{% endunless %}{% endfor %}
</ul>
<hr>
{% for item in (0..site.tags.size) %}{% unless forloop.last %}
{% capture this_word %}{{ tag_words[item] | strip_newlines }}{% endcapture %}
<h2 class="tags-title" id="{{ this_word | cgi_escape }}">{{ this_word }}</h2>
<div class="tags-group">
{% for post in site.tags[this_word] %}{% if post.title != null %}
<div class="tag-item">
<div class="tag-text">
<a class="tag-link" href="{{ root_url }}{{ post.url | prepend: site.baseurl }}">{{ post.title }}</a> | <small><span class="tag-time"><i class="ion ion-md-time"></i>{% include read-time.html %}</span></small>
</div>
</div>
{% endif %}{% endfor %}
</div>
{% endunless %}{% endfor %}
</div> <!-- /.tags -->