diff --git a/README.md b/README.md
index 865e712..fab43f2 100755
--- a/README.md
+++ b/README.md
@@ -166,8 +166,31 @@ menu:
@primary-color: @xiaowenwen-green;
// 强调色
@accent-color: @material-orange;
+// ...
```
+## 文章配置项
+
+某一篇文章不想开启评论
+
+```
+---
+comments: false
+---
+```
+
+某一篇文章不想在底部显示推荐文章
+
+```
+---
+recommended_posts: false
+---
+```
+
+
+
+
+
其他的暂时不想写了,自己摸索吧~
diff --git a/layout/_partial/article.ejs b/layout/_partial/article.ejs
index 4a4c4bc..c13344b 100755
--- a/layout/_partial/article.ejs
+++ b/layout/_partial/article.ejs
@@ -1,134 +1,112 @@
-
-
- <% if(post.toc!==false){ %>
- <%- toc(post.content, {list_number: false}) %>
- <% } %>
-
-
-
-
- <%- post.content %>
-
-
- <% if (post.tags && post.tags.length) { %>
-
+
+
+ <% if(post.toc!==false){ %>
+ <%- toc(post.content, {list_number: false}) %>
<% } %>
+
+
+
+ <%- post.content %>
+
- <% if(post.prev || post.next){ %>
-
- <%} %>
+ <% if (post.tags && post.tags.length) { %>
+
+ <% } %>
-
+ <% if(post.prev || post.next){ %>
+
+ <%} %>
+
-
-
+
+<% if (post && ((theme.recommended_posts.enabled && post.recommended_posts != false) || post.comments )) { %>
+
+
- <% if (post.comments) { %>
- <% if (config.livere_shortname){ %>
-
+ <% if (post && theme.recommended_posts.enabled && post.recommended_posts != false) { %>
+ <%- partial('post/recommended_posts', {page: post, site: site}) %>
<% } %>
- <% if (config.disqus_shortname) { %>
-
- <% } %>
- <% if (config.valine){ %>
- <% if (config.valine.enable && config.valine.appId && config.valine.appKey){ %>
+ <% if (post.comments) { %>
+ <% if (config.livere_shortname || config.valine){ %>
+ 评论
+ <% } %>
+ <% if (config.livere_shortname){ %>
+
+ <% } %>
+
+ <% if (config.disqus_shortname) { %>
<% } %>
+
+ <% if (config.valine){ %>
+ <% if (config.valine.enable && config.valine.appId && config.valine.appKey){ %>
+
+ <% } %>
+ <% } %>
<% } %>
- <% } %>
- <% if (post && theme.recommended_posts.enabled) { %>
- <%- partial('post/recommended_posts', {page: post, site: site}) %>
- <% } %>
-
-
+
+
+<% } %>
-
diff --git a/layout/_partial/footer.ejs b/layout/_partial/footer.ejs
index fc1c836..593737b 100755
--- a/layout/_partial/footer.ejs
+++ b/layout/_partial/footer.ejs
@@ -15,13 +15,8 @@
- 本站使用
@xaoxuu 发布的
Material-X 主题
-
-
- 总访客为 人次,
- 累计访问 次。
-
-
+
diff --git a/layout/_partial/post.ejs b/layout/_partial/post.ejs
index 8fc6c2a..b804320 100755
--- a/layout/_partial/post.ejs
+++ b/layout/_partial/post.ejs
@@ -26,7 +26,7 @@
<% if (post.tags && post.tags.length) { %>
<% } %>
diff --git a/layout/_partial/post/recommended_posts.ejs b/layout/_partial/post/recommended_posts.ejs
index 1879f08..9561fbf 100644
--- a/layout/_partial/post/recommended_posts.ejs
+++ b/layout/_partial/post/recommended_posts.ejs
@@ -1,7 +1,7 @@
<% var post_list = recommended_posts(page, site) %>
<% if(post_list.length > 0) { %>
-
推荐文章
+
你可能感兴趣的文章
<% post_list.forEach(function(link) { %>
- <%= link.title %>
diff --git a/layout/_partial/scripts.ejs b/layout/_partial/scripts.ejs
index 2e3839c..300a278 100755
--- a/layout/_partial/scripts.ejs
+++ b/layout/_partial/scripts.ejs
@@ -1,38 +1,80 @@
-<% if (config.disqus_shortname){ %>
-
-<% } %>
-
+
-
+
+
+
<%- js('js/jquery.fitvids.js') %>
<%- js('js/search.js') %>
<%- js('js/app.js') %>
+
+<% if (page.comments) { %>
+ <% if (config.disqus_shortname){ %>
+
+ <% } %>
+ <% if (config.livere_shortname){ %>
+
+ <% } %>
+ <% if (config.valine){ %>
+ <% if (config.valine.enable && config.valine.appId && config.valine.appKey){ %>
+
+ <% } %>
+ <% } %>
+<% } %>
diff --git a/source/less/_article.less b/source/less/_article.less
index 57e8080..e0b2324 100755
--- a/source/less/_article.less
+++ b/source/less/_article.less
@@ -95,6 +95,10 @@
font-weight: normal;
margin-top: 1.5em;
margin-bottom: 1em;
+ &:first-child{
+ margin-top: 0;
+ padding-top: 0;
+ }
&.title {
left: 0;
&:before {
@@ -102,10 +106,13 @@
}
}
}
-
h1, h2 {
- margin-top: 2em;
color: @text-color-theme;
+ margin-top: 2em;
+ &:first-child{
+ margin-top: 0;
+ padding-top: 0;
+ }
}
h1, h2, h3 {