diff options
author | amzrk2 | 2020-06-03 14:04:29 +0800 |
---|---|---|
committer | amzrk2 | 2020-06-03 14:04:29 +0800 |
commit | 63433dd64a35ef1a45301849ee9550b1f74fefd4 (patch) | |
tree | 65affcc7fd58e004486d8ab75acd145c6f1e5093 | |
parent | 3df71601ae866aff9c2ae060ed1ac7407807fcc4 (diff) | |
download | hugo-theme-fuji-63433dd64a35ef1a45301849ee9550b1f74fefd4.tar.gz hugo-theme-fuji-63433dd64a35ef1a45301849ee9550b1f74fefd4.tar.bz2 hugo-theme-fuji-63433dd64a35ef1a45301849ee9550b1f74fefd4.zip |
Update DisqusJS default settings
-rw-r--r-- | README.md | 4 | ||||
-rw-r--r-- | README_CN.md | 4 | ||||
-rw-r--r-- | layouts/partials/comment-disqusjs.html | 4 |
3 files changed, 5 insertions, 7 deletions
@@ -139,9 +139,9 @@ You can use `[SITEROOT]/layouts/_default/_markup/render-link.html` to decide whe 对于 Disqus 默认情况下使用 `{{ .Permalink }}` 作为 `url`,使用 `{{ .File.ContentBaseName }}` 作为 `identifier`。 -Use the `[SITEROOT]/layouts/partials/comment-*.html` to cover `themes/fuji/layouts/partials/comment-*.html`. Then you can customize the url and identifier, or set multiple api key for using DisqusJS. If you want to use DisqusJS, please remember to set `disqusJSApi` to anything in your `config.toml` to load CSS. +Use the `[SITEROOT]/layouts/partials/comment-*.html` to cover `themes/fuji/layouts/partials/comment-*.html`. Then you can customize the url and identifier, or set multiple api key, add more settings for using DisqusJS. If you want to use DisqusJS, please remember to set `disqusJSApi` to anything in your `config.toml` to load CSS. -You can check my blog for example of using DisqusJS, remember to set to your own key when deploing: +You can check my blog for example of using DisqusJS and add more settings and api keys, remember to set to your own key when deploing: - [`config.toml`]() - [`comment-disqusjs.html`]() diff --git a/README_CN.md b/README_CN.md index a3d006e..cfc650b 100644 --- a/README_CN.md +++ b/README_CN.md @@ -130,9 +130,9 @@ playerCover = "..." # 封面 对于 Disqus 默认情况下使用 `{{ .Permalink }}` 作为 `url`,使用 `{{ .File.ContentBaseName }}` 作为 `identifier`。 -使用 `[SITEROOT]/layouts/partials/comment-*.html` 来覆盖 `themes/fuji/layouts/partials/comment-*.html`。可在此文件内自定义指定的 url 和 identifier,或者为 DisqusJS 设置多个 api key。注意如果使用 DisqusJS,将 `config.toml` 内的 `disqusJSApi` 解除注释来加载 CSS。 +使用 `[SITEROOT]/layouts/partials/comment-*.html` 来覆盖 `themes/fuji/layouts/partials/comment-*.html`。可在此文件内自定义指定的 url 和 identifier,或者为 DisqusJS 设置多个 api key 抑或是添加更多设置。注意如果使用 DisqusJS,将 `config.toml` 内的 `disqusJSApi` 解除注释来加载 CSS。 -可以参考 Demo 的设置作为使用 DisqusJS 的例子,记得最后部署时候修改为自己的设置和 key 哦: +可以参考 Demo 的设置作为使用 DisqusJS、并且自定义设置和多个 api key 的例子,记得最后部署时候修改为自己的设置和 key 哦: - [`config.toml`]() - [`comment-disqusjs.html`]() diff --git a/layouts/partials/comment-disqusjs.html b/layouts/partials/comment-disqusjs.html index 5414aef..ebede31 100644 --- a/layouts/partials/comment-disqusjs.html +++ b/layouts/partials/comment-disqusjs.html @@ -14,9 +14,7 @@ url: '{{ .Permalink }}', title: '{{ .Title }}', api: '{{ .Site.Params.disqusJSApi }}', - apikey: '{{ .Site.Params.disqusJSApikey }}', - admin: '{{ .Site.Params.disqusJSAdmin }}', - adminLabel: '{{ .Site.Params.disqusJSAdminlabel }}' + apikey: '{{ .Site.Params.disqusJSApikey }}' }); document.querySelector('span.post-comment-notloaded').setAttribute('style', 'display: none;'); } |