new site
This commit is contained in:
27
category/index.html
Executable file
27
category/index.html
Executable file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
layout: base
|
||||
---
|
||||
<div class="row">
|
||||
<ul class="col-lg-2" id="filterList">
|
||||
{% assign idx = 0 %}
|
||||
{% for category in site.categories %}
|
||||
<li {% if idx == 0 %} class="current" {% endif %} data-show="{{ category | first }}">
|
||||
<a href="javascript:void(0)">
|
||||
{{ category | first }}
|
||||
<span class="cateCnt">{{ category | last | size }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% assign idx = idx | plus: 1 %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
|
||||
{% assign cateIdx = 0 %}
|
||||
{% for category in site.categories %}
|
||||
<section class="showcase col-lg-9 col-lg-offset-1 {% if cateIdx > 0 %} hide {% else %} current {% endif %}" data-show="{{ category | first }}">
|
||||
{% for posts in category %}
|
||||
{% include post_list.html posts=posts cateIdx=cateIdx %}
|
||||
{% assign cateIdx = cateIdx | plus: 1 %}
|
||||
{% endfor %}
|
||||
</section>
|
||||
{% endfor %}
|
||||
</div>
|
||||
Reference in New Issue
Block a user