❤独立页面的一支持

This commit is contained in:
DefectingCat
2020-02-28 13:49:48 +08:00
parent 9c342f48e3
commit 976007ade4
6 changed files with 29 additions and 8 deletions

2
p.sh
View File

@ -24,7 +24,7 @@ case $git in
4) echo -n 'Heart'
read input
git add -A
git commit -m "💖$input"
git commit -m "$input"
git push
;;
*) echo 'Maybe not today.'

View File

@ -138,6 +138,7 @@ index:
#Custom page
page:
page_style: true #新增的独立页面是否使用post页面的样式
banner_img: /defect/images/img/post.jpg
banner_img_height: 100 # available: 0 - 100

View File

@ -138,6 +138,7 @@ index:
# 通过 hexo new page 命令创建的页面
# Custom Page
page:
page_style: true #新增的独立页面是否使用post页面的样式
banner_img: /img/default.png
banner_img_height: 70 # available: 0 - 100

View File

@ -3,4 +3,28 @@ page.banner_img = page.banner_img || theme.page.banner_img
page.banner_img_height = page.banner_img_height || theme.page.banner_img_height
%>
<%- page.content %>
<% if (theme.page.page_style) { %>
<div class="post-content mx-auto" id="post">
<div class="markdown-body">
<%- page.content %>
<hr>
</div>
<br>
<div>
<% if(theme.post.copyright.enable && theme.post.copyright.content) { %>
<p class="note note-warning"><%- theme.post.copyright.content %></p>
<% } %>
</div>
</div>
<!-- custom -->
<% if(theme.post.custom.enable) { %>
<div class="col-lg-7 mx-auto nopadding-md">
<div class="container custom post-content mx-auto">
<%- theme.post.custom.content %>
</div>
</div>
<% } %>
<% }else{ %>
<%- page.content %>
<% } %>

View File

@ -1,4 +0,0 @@
img
max-width: 90%
margin: 1.5rem auto
display: block

View File

@ -4,5 +4,4 @@
@import "_archive/archive"
@import "_about/about"
@import "_category/*"
@import "_tag/*"
@import "_custom/*"
@import "_tag/*"