-
Notifications
You must be signed in to change notification settings - Fork 84
/
Copy pathcategory.pug
39 lines (37 loc) · 1 KB
/
category.pug
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
extends includes/layout.pug
block content
-
const categoriesList = list_categories({
order: 1
, show_count: theme.archives.categories_count
})
-
const tagsList = list_tags({
order: -1
, show_count: theme.archives.tags_count
})
-
const archivesList = list_archives({
type: 'yearly'
, order: -1
, show_count: false
})
#archive-flex
include includes/archive-aside.pug
#Archives
h1 #{__('menu.category.name')}: #{page.category}
#Archives-bg
- let year
- page.posts.each((article) => {
- let yearMonth = date(article.date, 'YYYY-MM')
if yearMonth !== year
- year = yearMonth
h2= year
.article-item
.control-archive
time= date(article.date, 'MM-DD')
a(href=url_for(article.path) target="_blank")
= article.title || __('post.noTitle')
- })
if config.per_page != 0
#paginator!= paginator()