forked from barryclark/jekyll-now
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcategories.html
More file actions
31 lines (28 loc) · 1.07 KB
/
categories.html
File metadata and controls
31 lines (28 loc) · 1.07 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
---
layout: page
title: Categories
---
<div class="col-sm-3 col-xs-6">
<ul class="nav nav-tabs-vertical">
{% assign categories_list = site.categories %}
{% if categories_list.first[0] == null %}
{% for category in categories_list %}
<li>
<a href="{{ site.BASE_PATH }}/{{ site.categories_path }}#{{ category | replace:' ','-' }}-ref" data-toggle="tab">
{{ category | capitalize }} <span class="badge pull-right">({{ site.categories[category].size }} post)</span>
</a>
</li>
{% endfor %}
{% else %}
{% for category in categories_list %}
<li>
<a href="{{ site.BASE_PATH }}/{{ site.categories_path }}#{{ category[0] | replace:' ','-' }}-ref" data-toggle="tab">
{{ category[0] | capitalize }} <span class="badge pull-right">({{ category[1].size }} post)</span>
</a>
</li>
{% endfor %}
{% endif %}
{% assign categories_list = nil %}
</ul>
</div>
<div class="clearfix"></div>