From 878271a7be8cc8df6c95143861df42ad2a751ff0 Mon Sep 17 00:00:00 2001 From: kshcherban Date: Mon, 28 May 2018 12:07:44 +0200 Subject: Switched disqus engine to internal template (https://gohugo.io/templates/internal/#configure-disqus) --- README.md | 2 +- exampleSite/config.toml | 2 +- layouts/partials/comments.html | 17 ++--------------- theme.toml | 4 ++-- 4 files changed, 6 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 1094323..790f8cf 100644 --- a/README.md +++ b/README.md @@ -25,6 +25,7 @@ canonifyurls = true title = "Pixyll" author = "admin" theme = "pixyll" +disqusShortname = "sitename" [indexes] category = "categories" @@ -34,7 +35,6 @@ theme = "pixyll" search_engine = true google_analytics_id = "XX-XXXXXXXX-X" twitter_username = "username" - disqus_shortname = "sitename" paginate = true ``` diff --git a/exampleSite/config.toml b/exampleSite/config.toml index f6a6b2c..32a6e98 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -13,6 +13,7 @@ themesDir = "../.." title = "Pixyll" enableEmoji = true DefaultContentLanguage = "en" +#disqusShortname = "" [Languages] [Languages.en] @@ -33,5 +34,4 @@ hrefTargetBlank = true search_engine = true #google_analytics_id = "" twitter_username = "username" - #disqus_shortname = "" paginate = 5 diff --git a/layouts/partials/comments.html b/layouts/partials/comments.html index e050343..b4e3c17 100644 --- a/layouts/partials/comments.html +++ b/layouts/partials/comments.html @@ -1,16 +1,3 @@ -{{ if isset .Site.Params "disqus_shortname" }} -
- +{{ if (.Site.DisqusShortname) }} +{{ template "_internal/disqus.html" . }} {{ end }} diff --git a/theme.toml b/theme.toml index 7a7bfce..2a109f6 100644 --- a/theme.toml +++ b/theme.toml @@ -3,5 +3,5 @@ description = "A simple, beautiful theme for Hugo." author = "Dmitriy Slupytskyi" license = "MIT" source_repo = "https://github.com/azmelanar/hugo-theme-pixyll" -tags = ["blog", "personal"] -min_version = 0.14 +tags = ["blog", "personal", "search", "responsive", "minimal"] +min_version = 0.25 -- cgit v1.2.3