feat(post): 支持文章页首行缩进

close #160
This commit is contained in:
LIlGG 2021-12-23 23:26:07 +08:00
parent 6564e20a17
commit 3f11c028da
3 changed files with 35 additions and 21 deletions

View File

@ -1,4 +1,4 @@
<!-- 全局公共样式 -->
<#-- 全局公共样式 -->
<@compress single_line=true>
<style type="text/css">
<#if settings.shownav!false>

View File

@ -1,15 +1,29 @@
<!-- 跟随 Pjax 进行页面变化的样式 -->
<#-- 跟随 Pjax 进行页面变化的样式 -->
<style>
/** Post start */
<#if is_post?? && settings.post_auto_collapse!true>
.yya:not(.sabit) {
top: -100px;
transition: all .4s ease;
}
<#if is_post??>
/** 文章页面导航栏自动收缩 */
<#if settings.post_auto_collapse!true>
.yya:not(.sabit) {
top: -100px;
transition: all .4s ease;
}
.sabit {
transition: all .4s ease;
}
.sabit {
transition: all .4s ease;
}
</#if>
/** 文章页首行缩进 */
<#if settings.post_line_indent!false>
.entry-content p {
text-indent: 2em; /*首行缩进*/
}
.toc-container {
right: calc((100% - 1000px - 250px)/2);
}
</#if>
</#if>
/** Post end */
</style>

View File

@ -470,6 +470,17 @@ post:
label: 开启
- value: false
label: 关闭
post_line_indent:
name: post_line_indent
label: 文章首行缩进
type: radio
data-type: bool
default: false
options:
- value: true
label: 开启
- value: false
label: 关闭
toc_depth:
name: toc_depth
label: 目录标题展开级别
@ -1518,17 +1529,6 @@ live2d:
label: 显示
- value: false
label: 隐藏
live2d_canTurnToAboutPage:
name: live2d_canTurnToAboutPage
label: 跳转关于页 按钮
type: radio
data-type: bool
default: true
options:
- value: true
label: 显示
- value: false
label: 隐藏
live2d_modelStorage:
name: live2d_modelStorage
label: 记录 ID (刷新后恢复)