Merge branch 'release_v4.0.1'

This commit is contained in:
凡梦星尘 2022-07-05 22:02:31 +08:00
commit ff9858975f
20 changed files with 30 additions and 202 deletions

View File

@ -10,7 +10,7 @@
> All page designs & configuration compatibility with Hexo NexT, it's very easy migrate your site from Hexo to Hugo and enjoy yourself.
[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.86.0-red?style=flat-square&logo=hugo&color=%23FF4088)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&label=gh-pg&logo=GitHub)](https://github.com/hugo-next/hugo-theme-next) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE)
[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&label=gh-pg&logo=GitHub)](https://github.com/hugo-next/hugo-theme-next) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE)
## 4 Scheme

View File

@ -10,7 +10,7 @@
> 本主题的所有页面设计和配置项都与原来 `Hexo` 引擎的 `NexT` 主题保持了良好的兼容性,可以非常平滑的从 `Hexo` 迁移至 `Hugo` 引擎,欢迎大家使用并反馈。
[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.86.0-red?style=flat-square&logo=hugo&color=%23FF4088)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&label=gh-pg&logo=GitHub)](https://github.com/hugo-next/hugo-theme-next) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE)
[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&label=gh-pg&logo=GitHub)](https://github.com/hugo-next/hugo-theme-next) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE)
## 4 种页面模式

View File

@ -114,7 +114,7 @@
height: 0;
}
@if $busuanzi_enable and $busuanzi_post_views {
@if $busuanzi_post_views {
#busuanzi_container_page_pv {
display: inline-block;
}

View File

@ -98,7 +98,6 @@
}
}
@if $busuanzi_enable {
.busuanzi-count {
@if $busuanzi_visitors {
#busuanzi_container_site_uv {
@ -111,4 +110,3 @@
}
}
}
}

View File

@ -1,96 +0,0 @@
// All variables from site's config content.
// In order not to conflict with the existing variables of SCSS and better identify,
// add a cfg_ prefix before the variable name
{{- $P := .Site.Params -}}
// Base variables
$scheme: {{ default $P.scheme "Gemini" }};
$cfg_darkmode: {{ $P.darkmode }};
$cfg_thm_cor_light: {{ $P.themeColor.light }};
$cfg_thm_cor_dark: {{ $P.themeColor.dark }};
$cfg_font_enable: {{ default $P.font.enable false }};
$cfg_font_global_size: {{ default $P.font.global.size 1 }};
$cfg_font_headings_size: {{ default $P.font.headings.size 1 }};
$cfg_font_title_size: {{ default $P.font.title.size 1 }};
$cfg_font_codes_size: {{ default $P.font.codes.size 1 }};
$cfg_font_posts_size: {{ default $P.font.posts.size 1 }};
// TODO
$cfg_hl_light_bg: #222;
$cfg_hl_light_fg: #000;
$cfg_hl_dark_bg: #000;
$cfg_hl_dark_fg: #222;
$cfg_sidebar_width: {{ $P.sidebar.width }};
$cfg_sidebar_position: {{ $P.sidebar.position }};
$cfg_sidebar_padding: {{ default $P.sidebar.padding 18 }};
$cfg_sidebar_offset: {{ default $P.sidebar.offset 12 }};
// TODO
$cfg_note_light_bg_offset: 0;
// Scaffolding Variables
$cfg_bd_scrollbar_overlay: {{ $P.bodyScrollbar.overlay }};
$cfg_bd_scrollbar_stable: {{ $P.bodyScrollbar.stable }};
$cfg_codeblock_copy_btn_style: {{ $P.codeblock.copyBtn.style }};
$cfg_mermaid_enable: {{ $P.mermaid.enable }};
$cfg_note_style: {{ $P.note.style }};
$cfg_note_icons: {{ $P.note.icons }};
$cfg_pdf_enable: {{ $P.pdf.enable }};
$cfg_pdf_height: {{ $P.pdf.height }};
$cfg_tabs_trans_tabs: {{ $P.tabs.transition.tabs }};
$cfg_tabs_trans_labels: {{ $P.tabs.transition.labels }};
// Outline Variables
$cfg_footer_icon_color: {{ $P.footer.icon.color }};
$cfg_footer_icon_animated: {{ $P.footer.icon.animated }};
$cfg_footer_beian_enable: {{ $P.footer.beian.enable }};
$cfg_busuanzi_enable: {{ $P.busuanzi.enable }};
$cfg_busuanzi_visitors: {{ $P.busuanzi.visitors }};
$cfg_busuanzi_views: {{ $P.busuanzi.views }};
$cfg_bookmark_enable: {{ $P.bookmark.enable }};
$cfg_bookmark_color: {{ $P.bookmark.color }};
$cfg_github_banner_enable: {{ $P.githubBanner.enable }};
$cfg_local_search_enable: {{ $P.localSearch.enable }};
$cfg_algolia_search_enable: {{ $P.algoliaSearch.enable }};
$cfg_mobile_layout_economy: {{ $P.mobileLayoutEconomy }};
$cfg_note_icons: {{ $P.note.icons }};
$cfg_social_icons_only: {{ $P.socialIcons.iconsOnly }};
$cfg_avatar_rounded: {{ $P.avatar.rounded }};
$cfg_avatar_rotated: {{ $P.avatar.rotated }};
$cfg_toc_enable: {{ $P.toc.enable }};
$cfg_toc_wrap: {{ $P.toc.wrap }};
$cfg_toc_expand_all: {{ $P.toc.expandAll }};
$cfg_site_state: {{ $P.siteState }};
//
$cfg_back2top_enable: {{ $P.backTop.enable }};
$cfg_back2top_scrollpercent: {{ $P.backTop.scrollPercent }};
$cfg_back2top_sidebar: {{ $P.backTop.sidebar }};
$cfg_reading_progress_enable: {{ $P.readingProgress.enable }};
$cfg_reading_progress_color: {{ $P.readingProgress.color }};
$cfg_reading_progress_height: {{ $P.readingProgress.height }};
$cfg_reading_progress_reversed: {{ $P.readingProgress.reversed }};
$cfg_reading_progress_start: {{ $P.readingProgress.start }};
$cfg_reading_progress_position: {{ $P.readingProgress.position }};

View File

@ -34,7 +34,6 @@ $footer_vendors_enable : {{ isset $P.footer "vendors" }};
{{ end }}
// Counter
$busuanzi_enable : {{ $P.busuanzi.enable }};
$busuanzi_visitors : {{ $P.busuanzi.visitors }};
$busuanzi_views : {{ $P.busuanzi.views }};
$busuanzi_post_views : {{ $P.busuanzi.postViews }};

View File

@ -753,6 +753,7 @@ params:
# Waline comments system
# More info seee: https://waline.js.org/
waline:
pageView: true
placeholder: "请文明发言"
emoji: false
imgUploader: false
@ -859,12 +860,11 @@ params:
# Show Views / Visitors of the website / page with busuanzi.
# For more information: http://ibruce.info/2015/04/04/busuanzi/
busuanzi:
enable: true
visitors: true
visitors: false
visitorsIcon: fa fa-user
views: true
views: false
viewsIcon: fa fa-eye
postViews: true
postViews: false
postViewsIcon: far fa-eye
@ -968,7 +968,7 @@ params:
# Use Animate.css to animate everything.
# For more information: https://animate.style
motion:
enable: false
enable: true
async: true
transition:
# All available transition variants: https://theme-next.js.org/animate/

Binary file not shown.

Before

Width:  |  Height:  |  Size: 118 KiB

After

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 36 KiB

View File

@ -1,9 +1,9 @@
{{- with .Params.tags }}
{{- if gt (len .) 0 }}
<div class="post-tags">
{{ range . }}
<a href="{{ . }}">{{ . }}</a>
<a href="{{ "/tags/" | relLangURL }}{{ . | urlize | lower }}">
{{ . }}
</a>
{{- end }}
</div>
{{- end }}
{{- end }}

View File

@ -1,11 +1,11 @@
{{- if .Site.Params.postMeta.categories }}
{{- if and .Params.categories (gt (len .Params.categories) 0) }}
{{- with .Params.categories }}
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="far fa-folder-open"></i>
</span>
<span class="post-meta-item-text">{{- print (T "PostCategory") (T "SymbolColon") -}}</span>
{{- range (first 1 .Params.categories) }}
{{- range (first 1 .) }}
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="{{ "/categories/" | relLangURL }}{{ . | urlize }}" itemprop="url" rel="index">
<span itemprop="name">{{- . -}}</span>

View File

@ -2,10 +2,10 @@
{{- if .Site.Params.leancloudVisitors.enable }}
{{- $pageViewCls = "leancloud-visitors-count" }}
{{- end }}
{{- if and .Site.Params.waline.enable .Site.Params.waline.pageView }}
{{- if .Site.Params.waline.pageView }}
{{- $pageViewCls = "waline-pageview-count" }}
{{- end }}
{{- if and .Site.Params.busuanzi.enable .Site.Params.busuanzi.postViews }}
{{- if .Site.Params.busuanzi.postViews }}
{{- $pageViewCls = "busuanzi_value_page_pv" }}
{{- end }}
<span class="post-meta-item" title="{{ T "PostViews" }}">

View File

@ -1,17 +0,0 @@
{{- if isset .Params "categories" }}
{{- if not (eq (len .Params.categories) 0) }}
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="fa fa-folder-open"></i>
</span>
<span class="post-meta-item-text">{{- T "PostCatg" }}{{- T "ColoneFlag"}}</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
{{- range (first 3 .Params.categories) }}
<span class="post-meta-catg" itemprop="name">
<a href="{{ . | urlize }}" itemprop="url" rel="index">{{ . }}</a>
</span>
{{- end }}
</span>
</span>
{{- end }}
{{- end }}

View File

@ -1,16 +0,0 @@
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="far fa-calendar"></i>
</span>
<span class="post-meta-item-text">{{- T "PostPublishDate" }}{{- T "ColoneFlag" }}</span>
<time title="{{ T "PostPublishTime" }}{{ T "ColoneFlag" }}{{ .PublishDate }}" itemprop="dateCreated datePublished" datetime="{{ .PublishDate }}">{{- .PublishDate.Format .Site.Params.DateFormat -}}</time>
</span>
{{- if gt .Lastmod .PublishDate }}
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="far fa-calendar-check"></i>
</span>
<span class="post-meta-item-text">{{- T "PostLastModDate" }}{{- T "ColoneFlag" }}</span>
<time title="{{ T "PostLastModTime" }}{{ T "ColoneFlag" }}{{ .Lastmod }}" itemprop="dateModified" datetime="{{ .Lastmod }}">{{- .Lastmod.Format .Site.Params.DateFormat -}}</time>
</span>
{{- end }}

View File

@ -1,7 +0,0 @@
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="fa fa-hourglass"></i>
</span>
<span class="post-meta-item-text">{{- T "PostReading" }}{{- T "ColoneFlag" -}}</span>
<span>{{- T "PostReadTime" . -}}</span>
</span>

View File

@ -1,17 +0,0 @@
{{- if isset .Params "tags" }}
{{- if not (eq (len .Params.tags) 0) }}
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="fa fa-tags"></i>
</span>
<span class="post-meta-item-text">{{- T "PostTag" }}{{- T "ColoneFlag"}}</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
{{- range (first 3 .Params.tags) }}
<span class="post-meta-catg" itemprop="name">
<a href="{{ . | urlize }}" itemprop="url" rel="index">{{ . }}</a>
</span>
{{- end }}
</span>
</span>
{{- end }}
{{- end }}

View File

@ -1,9 +0,0 @@
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="fa fa-eye"></i>
</span>
<span class="post-meta-item-text">{{- T "PostVisitor" -}}{{ T "ColoneFlag" -}}</span>
<span id="busuanzi_value_site_pv">
<i class="fa fa-sync fa-spin"></i>
</span>
</span>

View File

@ -1,7 +0,0 @@
<span class="post-meta-item">
<span class="post-meta-item-icon">
<i class="fa fa-file-word"></i>
</span>
<span class="post-meta-item-text">{{- T "PostWords" }}{{- T "ColoneFlag" -}}</span>
<span>{{- T "PostWordCount" . -}}</span>
</span>

View File

@ -1,11 +1,11 @@
name = "Hugo Theme Next"
name = "Hugo Next"
license = "MIT"
licenselink = "https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE"
description = "Easily & powerful theme for Hugo engine."
homepage = "https://github.com/hugo-next/hugo-theme-next"
tags = ["blog", "simple", "dark", "personal", "fast", "theme"]
features = ["some", "awesome", "features"]
min_version = "0.86.0"
tags = ["Blog", "Simple", "Personal", "Responsive", "Documentation", "Light", "Dark"]
features = ["Blog", "Responsive", "Documentation", "Light", "Dark"]
min_version = "0.89.0"
demosite = "https://preview.hugo-next.eu.org"
[author]