Enable partial sharing

It is currently not possible to disable the sharing on a specific
site, say google plus or facebook.

This allows a configuration item switch to tweak this behavior.
This commit is contained in:
Jean-Philippe Evrard
2018-04-06 20:30:26 +01:00
committed by Michael Noronha
parent 017543b2f8
commit c74cf85db5
2 changed files with 15 additions and 4 deletions

View File

@@ -25,6 +25,9 @@ faviconfile = "img/logo.png"
highlightjs = true
progressively = true
share = true
# Share to googleplus, twitter, fb, linkedin by default
# disable by setting share_on_<social network> = false
# example: share_on_googleplus = false
latestpostcount = 5
github = "example"
email = "you@example.com"

View File

@@ -52,10 +52,18 @@
</div>
{{ if .Site.Params.share }}
<div class="share">
<a href="" class="ssk ssk-facebook"></a>
<a href="" class="ssk ssk-twitter"></a>
<a href="" class="ssk ssk-google-plus"></a>
<a href="" class="ssk ssk-linkedin"></a>
{{ if .Site.Params.share_on_fb | default true }}
<a href="" class="ssk ssk-facebook"></a>
{{ end }}
{{ if .Site.Params.share_on_twitter | default true }}
<a href="" class="ssk ssk-twitter"></a>
{{ end }}
{{ if .Site.Params.share_on_googleplus | default true }}
<a href="" class="ssk ssk-google-plus"></a>
{{ end }}
{{ if .Site.Params.share_on_linkedin | default true }}
<a href="" class="ssk ssk-linkedin"></a>
{{ end }}
</div>
{{ end }}
{{ if .Site.Params.posts_navigation }}