Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,18 @@ title_primary: "活版印字" # the bigger text
title_secondary: "Typography" # the smaller text
keywords:

tag:
min_font: 18 # Minimum font size
max_font: 25 # Maximum font size
start_color: '#0073e6'
end_color: '#003366'
show_count: true # Display the number of posts for each tag
amount: # Total amount of tags. Default: unlimited

toc:
enable: true
list_number: false # Displays list number

twitter: #username
rss: atom.xml
weibo: #username/id
Expand Down
1 change: 1 addition & 0 deletions languages/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Tags: Tags
About: About
Links: Links
Comments: Comments
ToC: Table of Contents
posted_at: Posted at
TagCount: '%d tags'
ArchiveCount: '%d post'
Expand Down
1 change: 1 addition & 0 deletions languages/zh-cn.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Tags: 标签
About: 关于
Links: 链接
Comments: 评论
ToC: 目录
posted_at: 发布于
TagCount: '%d 篇'
ArchiveCount: '%d 篇'
Expand Down
21 changes: 9 additions & 12 deletions layout/mixins.pug
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ mixin make_post(item, is_detail)
a(href= url_for(item.path))= item.title
p.post-meta
span.date.meta-item!=__("posted_at")+" " + date(item.date, 'YYYY-MM-DD')
if theme.duoshuo || theme.disqus
if theme.livere || theme.disqus
span.meta-item
i.fa.fa-comment-o
span  
Expand All @@ -32,6 +32,9 @@ mixin make_post(item, is_detail)
a.a-tag(href=config.root + item.path, title= item.name)= item.name
span  
- });
if theme.toc.enable
span= _p('ToC')
.toc!= toc(page.content, {list_number: theme.toc.list_number})
if is_detail
p.post-abstract!= item.content
else
Expand Down Expand Up @@ -103,20 +106,14 @@ mixin postList()
| </ul></li>

mixin tagList()
ul.listing
- site.tags.each(function (item) {
| <li class="listing-item">
.listing-post
p.post-title
a(href= url_for(item.path), title= item.name)= item.name
span.date.meta-item
!= __('TagCount', item.posts.length)
| </li>
- })
.tag-cloud__title= page.title
| -
span.tag-cloud__amount= site.tags.length
.tag-cloud-tags!= tagcloud({min_font: theme.tag.min_font, max_font: theme.tag.max_font, amout: theme.tag.amount, color: true, start_color: theme.tag.start_color, end_color: theme.tag.end_color, show_count: theme.tag.show_count})

mixin categoryList()
ul.listing
- site.categories.each(function (item) {
- site.categories.each(function (item) {
| <li class="listing-item">
.listing-post
p.post-title
Expand Down
4 changes: 2 additions & 2 deletions layout/partial/comments.pug
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ if theme.disqus
script(id='dsq-count-scr' src='//#{theme.disqus}.disqus.com/count.js' async)

if theme.livere
#lv-container(data-id='city', data-uid='#{theme.livere}')
#lv-container(data-id='city', data-uid=theme.livere)
script(type='text/javascript').
(function (d, s) {
var j, e = d.getElementsByTagName(s)[0];
Expand Down Expand Up @@ -59,4 +59,4 @@ if theme.dove
| 3. 我们在收到您的评论后将立即审核并更新至网站
br
i
small 评论一经采用,信函恕不退还,信鸽也不退还,请知悉。
small 评论一经采用,信函恕不退还,信鸽也不退还,请知悉。
1 change: 1 addition & 0 deletions layout/partial/head.pug
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ meta(content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-sca
meta(content="yes",name="apple-mobile-web-app-capable")
meta(content="black",name="apple-mobile-web-app-status-bar-style")
meta(content="telephone=no",name="format-detection")
meta(name="referrer",content="no-referrer")

meta(name="renderer",content="webkit")
link(rel="short icon", href="images/favicon.png",type="image/x-icon")
Expand Down
Loading