From fcb48d9be078df0420ff98228fee4ac1b013f47b Mon Sep 17 00:00:00 2001 From: olOwOlo <26087907+olOwOlo@users.noreply.github.com> Date: Fri, 6 Jul 2018 22:50:37 +0800 Subject: [PATCH] refactor(param): camelcase for parameter names BREAKING CHANGE: Rename parameter names. | origin | now | | :------: |:--------:| | fancyboxJ**s** | fancyboxJ**S** | | fancyboxC**ss**| fancyboxC**SS**| | baidu_push | baidu**P**ush | | baidu_analytics | baidu**A**nalytics | | baidu_verification | baidu**V**erification | | google_verification | google**V**erification | --- CHANGELOG.md | 17 +++++++++++++++++ exampleSite/config.toml | 25 ++++++++++++++----------- layouts/partials/head.html | 6 +++--- layouts/partials/scripts.html | 10 +++++----- 4 files changed, 39 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e8eeaf8..38e1f8b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,20 @@ + +# 4.0.0 (WIP) + +### BREAKING CHANGES + +- Rename params + + | origin | now | + | :------: |:--------:| + | fancyboxJ**s** | fancyboxJ**S** | + | fancyboxC**ss**| fancyboxC**SS**| + | baidu_push | baidu**P**ush | + | baidu_analytics | baidu**A**nalytics | + | baidu_verification | baidu**V**erification | + | google_verification | google**V**erification | + + # [3.2.0](https://github.com/olOwOlo/hugo-theme-even/compare/v3.1.1...v3.2.0) (2018-07-06) diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 624cc0b..60da00d 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -2,11 +2,11 @@ baseURL = "http://localhost:1313/" languageCode = "en" defaultContentLanguage = "en" # en / zh-cn / ... (This field determines which i18n file to use) title = "Even - A super concise theme for Hugo" +preserveTaxonomyNames = true enableRobotsTXT = true enableEmoji = true theme = "even" -preserveTaxonomyNames = true hasCJKLanguage = true # has chinese/japanese/korean ? # 自动检测是否包含 中文\日文\韩文 paginate = 5 # 首页每页显示的文章数 disqusShortname = "" # disqus_shortname @@ -83,11 +83,13 @@ copyright = "" # default: author.name ↓ # 默认为下面配 changyanAppid = "" # Changyan app id # 畅言 changyanAppkey = "" # Changyan app key + livereUID = "" # LiveRe UID # 来必力 - baidu_push = false # baidu push # 百度 - baidu_analytics = "" # Baidu Analytics - baidu_verification = "" # Baidu Verification - google_verification = "" # Google_Verification # 谷歌 + + baiduPush = false # baidu push # 百度 + baiduAnalytics = "" # Baidu Analytics + baiduVerification = "" # Baidu Verification + googleVerification = "" # Google Verification # 谷歌 # Link custom CSS and JS assets # (relative to /static/css and /static/js respectively) @@ -98,17 +100,18 @@ copyright = "" # default: author.name ↓ # 默认为下面配 enable = false jquery = '' slideout = '' - fancyboxJs = '' - fancyboxCss = '' - gitmentJS = '' - gitmentCSS = '' - gitalkJS = '' - gitalkCSS = '' + fancyboxJS = '' + fancyboxCSS = '' timeagoJS = '' timeagoLocalesJS = '' flowchartDiagramsJS = ' ' sequenceDiagramsCSS = '' sequenceDiagramsJS = ' ' + # comment + gitmentJS = '' + gitmentCSS = '' + gitalkJS = '' + gitalkCSS = '' # Display a message at the beginning of an article to warn the readers that it's content may be outdated. # 在文章开头显示提示信息,提醒读者文章内容可能过时。 diff --git a/layouts/partials/head.html b/layouts/partials/head.html index 86ab6cf..19c000c 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -29,8 +29,8 @@ {{- end }} -{{ with .Site.Params.baidu_verification }}{{ end }} -{{ with .Site.Params.google_verification }}{{ end }} +{{ with .Site.Params.baiduVerification }}{{ end }} +{{ with .Site.Params.googleVerification }}{{ end }} @@ -63,7 +63,7 @@ {{ if .Site.Params.publicCDN.enable -}} - {{ if .Site.Params.fancybox }}{{ .Site.Params.publicCDN.fancyboxCss | safeHTML }}{{ end }} + {{ if .Site.Params.fancybox }}{{ .Site.Params.publicCDN.fancyboxCSS | safeHTML }}{{ end }} {{- else -}} {{ if .Site.Params.fancybox }}{{ end }} {{- end }} diff --git a/layouts/partials/scripts.html b/layouts/partials/scripts.html index b9c9a55..47df69b 100644 --- a/layouts/partials/scripts.html +++ b/layouts/partials/scripts.html @@ -3,7 +3,7 @@ {{- if .Site.Params.publicCDN.enable }} {{ .Site.Params.publicCDN.jquery | safeHTML }} {{ .Site.Params.publicCDN.slideout | safeHTML }} - {{ if .Site.Params.fancybox }}{{ .Site.Params.publicCDN.fancyboxJs | safeHTML }}{{ end }} + {{ if .Site.Params.fancybox }}{{ .Site.Params.publicCDN.fancyboxJS | safeHTML }}{{ end }} {{- else -}} @@ -90,7 +90,7 @@ {{ template "_internal/google_analytics_async.html" . }} {{- end -}} -{{- with .Site.Params.baidu_analytics -}} +{{- with .Site.Params.baiduAnalytics -}} {{- end }} - -{{- if .Site.Params.baidu_push -}} + +{{- if .Site.Params.baiduPush -}} {{ end }}