Merge branch 'release_v4.4.0' into develop
This commit is contained in:
commit
d6de03a2d0
@ -112,10 +112,12 @@ tags:
|
|||||||
#expand: true
|
#expand: true
|
||||||
# It's means that will redirecting to external links
|
# It's means that will redirecting to external links
|
||||||
#extlink:
|
#extlink:
|
||||||
# Switch to enabled or disabled comment plugins in this post
|
# Disabled comment plugins in this post
|
||||||
#comment:
|
#comment:
|
||||||
# enable: false
|
# enable: false
|
||||||
# Enable table of content
|
# Disable table of content int this post
|
||||||
|
# Notice: By default will automatic build table of content
|
||||||
|
# with h2-h4 title in post and without other settings
|
||||||
#toc: false
|
#toc: false
|
||||||
# Absolute link for visit
|
# Absolute link for visit
|
||||||
#url: "{{ lower .Name }}.html"
|
#url: "{{ lower .Name }}.html"
|
||||||
|
@ -120,10 +120,11 @@ tags:
|
|||||||
#expand: true
|
#expand: true
|
||||||
# 外部链接地址,访问时直接跳转
|
# 外部链接地址,访问时直接跳转
|
||||||
#extlink:
|
#extlink:
|
||||||
# 在当前页面开启或关闭评论功能
|
# 在当前页面关闭评论功能
|
||||||
#comment:
|
#comment:
|
||||||
# enable: false
|
# enable: false
|
||||||
# 开启文章目录功能
|
# 关闭当前页面目录功能
|
||||||
|
# 注意:正常情况下文章中有H2-H4标题会自动生成目录,无需额外配置
|
||||||
#toc: false
|
#toc: false
|
||||||
# 绝对访问路径
|
# 绝对访问路径
|
||||||
#url: "{{ lower .Name }}.html"
|
#url: "{{ lower .Name }}.html"
|
||||||
|
@ -27,12 +27,12 @@ tags:
|
|||||||
# 外部链接地址,访问时直接跳转
|
# 外部链接地址,访问时直接跳转
|
||||||
# It's means that will redirecting to external links
|
# It's means that will redirecting to external links
|
||||||
#extlink:
|
#extlink:
|
||||||
# 在当前页面开启或关闭评论功能
|
# 在当前页面关闭评论功能
|
||||||
# Switch to enabled or disabled comment plugins in this post
|
# Disabled comment plugins in this post
|
||||||
#comment:
|
#comment:
|
||||||
# enable: false
|
# enable: false
|
||||||
# 开启文章目录功能
|
# 关闭文章目录功能
|
||||||
# Enable table of content
|
# Disable table of content
|
||||||
#toc: false
|
#toc: false
|
||||||
# 绝对访问路径
|
# 绝对访问路径
|
||||||
# Absolute link for visit
|
# Absolute link for visit
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
---
|
---
|
||||||
title: "没有H1-6标题头的文章"
|
title: "没有H1-6标题头和评论的文章"
|
||||||
description: "用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭。"
|
description: "用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭,并关闭评论功能。"
|
||||||
keywords: "toc,header"
|
keywords: "toc,header"
|
||||||
|
|
||||||
date: 2022-10-06T09:02:26+08:00
|
date: 2022-10-06T09:02:26+08:00
|
||||||
lastmod: 2022-10-06T09:02:26+08:00
|
lastmod: 2022-10-30T21:03:16+08:00
|
||||||
|
|
||||||
categories:
|
categories:
|
||||||
- 示例
|
- 示例
|
||||||
@ -12,12 +12,14 @@ tags:
|
|||||||
- toc
|
- toc
|
||||||
- 标题
|
- 标题
|
||||||
|
|
||||||
|
comment:
|
||||||
|
enable: false
|
||||||
url: "post/no-header-title.html"
|
url: "post/no-header-title.html"
|
||||||
---
|
---
|
||||||
|
|
||||||
刘慈欣2018克拉克奖获奖感言(部分内容节选)。
|
刘慈欣2018克拉克奖获奖感言(部分内容节选)。
|
||||||
|
|
||||||
> 用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭。
|
> 用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭,并关闭评论功能。
|
||||||
|
|
||||||
<!--more-->
|
<!--more-->
|
||||||
|
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
{{- range $k, $v := (partialCached "init.html" .) -}}
|
{{- range $k, $v := (partialCached "init.html" .) -}}
|
||||||
{{- $.Scratch.Set $k $v -}}
|
{{- $.Scratch.Set $k $v -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
{{ $commentEnable := .Params.comment.enable | default .Site.Params.comments.enable }}
|
||||||
|
{{ .Scratch.Set "isComment" $commentEnable }}
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="{{ .Site.LanguageCode }}" data-theme="{{ .Scratch.Get "theme" }}">
|
<html lang="{{ .Site.LanguageCode }}" data-theme="{{ .Scratch.Get "theme" }}">
|
||||||
|
|
||||||
@ -29,7 +31,7 @@
|
|||||||
<div class="main-inner {{ block "main_inner_class" . }}{{ end }}">
|
<div class="main-inner {{ block "main_inner_class" . }}{{ end }}">
|
||||||
<!-- Submenu,Content,Comment -->
|
<!-- Submenu,Content,Comment -->
|
||||||
{{- block "main" . }}{{- end }}
|
{{- block "main" . }}{{- end }}
|
||||||
{{- if .IsPage }}
|
{{- if and .IsPage $commentEnable }}
|
||||||
{{- partialCached "comments.html" . }}
|
{{- partialCached "comments.html" . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{{- $pageCfg := dict
|
{{- $pageCfg := dict
|
||||||
"isHome" .IsHome
|
"isHome" .IsHome
|
||||||
"isPage" .IsPage
|
"isPage" .IsPage
|
||||||
"comments" (.Params.comments | default .Site.Params.comments.enable)
|
"comments" (.Scratch.Get "isComment")
|
||||||
"permalink" (.Page.Permalink | absURL)
|
"permalink" (.Page.Permalink | absURL)
|
||||||
"path" (.Page.Permalink | path.Base)
|
"path" (.Page.Permalink | path.Base)
|
||||||
"title" .Page.Title
|
"title" .Page.Title
|
||||||
|
@ -29,10 +29,10 @@
|
|||||||
{{ partial "post/header_meta/categories.html" . }}
|
{{ partial "post/header_meta/categories.html" . }}
|
||||||
{{ if and $.IsHome (not (isset .Params "extlink")) }}
|
{{ if and $.IsHome (not (isset .Params "extlink")) }}
|
||||||
<div class="post-meta-items">
|
<div class="post-meta-items">
|
||||||
{{ if .Site.Params.waline.pageView }}
|
{{ if and (eq .Site.Params.analytis.busuanzi.enable false) .Site.Params.waline.pageView }}
|
||||||
{{ partial "post/header_meta/views.html" . }}
|
{{ partial "post/header_meta/views.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ if .Site.Params.waline.comment }}
|
{{ if and (.Scratch.Get "isComment") .Site.Params.waline.comment }}
|
||||||
{{ partial "post/header_meta/comments.html" . }}
|
{{ partial "post/header_meta/comments.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</div>
|
</div>
|
||||||
@ -43,7 +43,7 @@
|
|||||||
{{ partial "post/header_meta/words.html" . }}
|
{{ partial "post/header_meta/words.html" . }}
|
||||||
{{ partial "post/header_meta/readtime.html" . }}
|
{{ partial "post/header_meta/readtime.html" . }}
|
||||||
{{ partial "post/header_meta/views.html" . }}
|
{{ partial "post/header_meta/views.html" . }}
|
||||||
{{ if .Site.Params.waline.comment }}
|
{{ if and (.Scratch.Get "isComment") .Site.Params.waline.comment }}
|
||||||
{{ partial "post/header_meta/comments.html" . }}
|
{{ partial "post/header_meta/comments.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,7 +1,9 @@
|
|||||||
<div class="tool-buttons" >
|
<div class="tool-buttons" >
|
||||||
|
{{ if .Scratch.Get "isComment" }}
|
||||||
<div id="goto-comments" class="button goto-comments" title="{{ T "ToolBtns.comment" }}">
|
<div id="goto-comments" class="button goto-comments" title="{{ T "ToolBtns.comment" }}">
|
||||||
<i class="fas fa-comments"></i>
|
<i class="fas fa-comments"></i>
|
||||||
</div>
|
</div>
|
||||||
|
{{ end }}
|
||||||
{{ if .Site.Params.footer.translate }}
|
{{ if .Site.Params.footer.translate }}
|
||||||
<div id="goto-gtranslate" class="button" title="{{ T "ToolBtns.lang" }}">
|
<div id="goto-gtranslate" class="button" title="{{ T "ToolBtns.lang" }}">
|
||||||
<i class="fas fa-globe"></i>
|
<i class="fas fa-globe"></i>
|
||||||
|
Loading…
Reference in New Issue
Block a user