forked from fantaghiro/fantaghiro.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
categories.html
62 lines (55 loc) · 1.76 KB
/
categories.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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
---
layout: default
title: 文章分类
---
<div class="page-categories">
<ul class="list-group">
{% for cat in site.categories %}
{% case cat[0] %}
{% when 'writeups' %}
{% assign categoryTitle = '随便写写' %}
{% when 'publishing' %}
{% assign categoryTitle = '出版业态' %}
{% when 'edu' %}
{% assign categoryTitle = '数字教育' %}
{% when 'english' %}
{% assign categoryTitle = '英语好玩' %}
{% when 'study' %}
{% assign categoryTitle = '学习笔记' %}
{% else %}
{% assign categoryTitle = '教材研究' %}
{% endcase %}
<li class="list-group-item">
<a href="#{{ cat[0] }}-ref" class="category-heading" title="分类:{{ cat[0] }}" >{{ categoryTitle }}</a>
<span class="badge">{{ cat[1].size }}</span>
</li>
{% endfor %}
</ul>
</div>
<hr>
<div class="page-blank">
{% for cat in site.categories %}
{% case cat[0] %}
{% when 'writeups' %}
{% assign categoryTitle = '随便写写' %}
{% when 'publishing' %}
{% assign categoryTitle = '出版业态' %}
{% when 'edu' %}
{% assign categoryTitle = '数字教育' %}
{% when 'english' %}
{% assign categoryTitle = '英语好玩' %}
{% when 'study' %}
{% assign categoryTitle = '学习笔记' %}
{% else %}
{% assign categoryTitle = '教材研究' %}
{% endcase %}
<div class="page-list">
<h2 id="{{ cat[0] }}-ref">{{ categoryTitle }}</h3>
<ul id="blog-posts" class="posts">
{% for post in cat[1] %}
<li><span>{{ post.date | date_to_string }} »</span><a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</ul>
</div>
{% endfor %}
</div>