2020-02-03 11:38:10 +01:00
{{- if .Params.share.enable | default .Site.Params.share.enable | eq true -}}
2020-02-17 14:02:27 +01:00
{{- /* 001: Twitter */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Twitter | default .Site.Params.Share.Twitter | eq true -}}
< a href = "//twitter.com/share?url={{ .Permalink }}&text={{ .Title }}&via={{ .Site.Params.Social.Twitter }}" target = "_blank" title = "{{ T " share " } } Twitter " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-twitter fa-fw") -}}
2019-03-14 11:16:11 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 002: Facebook */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Facebook | default .Site.Params.Share.Facebook | eq true -}}
< a href = "//www.facebook.com/sharer/sharer.php?u={{ .Permalink }}" target = "_blank" title = "{{ T " share " } } Facebook " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-facebook-square fa-fw") -}}
2019-03-14 11:16:11 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 003: Reddit */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Reddit | default .Site.Params.Share.Reddit | eq true -}}
< a href = "//reddit.com/submit?url={{ .Permalink }}&title={{ .Title }}" target = "_blank" title = "{{ T " share " } } Reddit " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-reddit fa-fw") -}}
2019-03-14 11:16:11 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 004: Linkedin */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Linkedin | default .Site.Params.Share.Linkedin | eq true -}}
< a href = "//www.linkedin.com/shareArticle?url={{ .Permalink }}&title={{ .Title }}" target = "_blank" title = "{{ T " share " } } LinkedIn " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-linkedin fa-fw") -}}
2019-03-14 11:16:11 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 005: Pinterest */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Pinterest | default .Site.Params.Share.Pinterest | eq true -}}
< a href = "//www.pinterest.com/pin/create/button/?url={{ .Permalink }}&description={{ .Title }}" target = "_blank" title = "{{ T " share " } } Pinterest " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-pinterest fa-fw") -}}
2019-03-14 11:16:11 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 006: Hacker News */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Hackernews | default .Site.Params.Share.Hackernews | eq true -}}
< a href = "//news.ycombinator.com/submitlink?u={{ .Permalink }}&description={{ .Title }}" target = "_blank" title = "{{ T " share " } } Hacker News " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-hacker-news fa-fw") -}}
2019-03-14 16:07:08 +01:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 007: Mix */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Mix | default .Site.Params.Share.Mix | eq true -}}
< a href = "//mix.com/add?url={{ .Permalink }}&description={{ .Title }}" target = "_blank" title = "{{ T " share " } } Mix " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-mix fa-fw") -}}
2019-08-05 15:15:01 +02:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 008: Tumblr */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Tumblr | default .Site.Params.Share.Tumblr | eq true -}}
< a href = "//www.tumblr.com/widgets/share/tool?canonicalUrl={{ .Permalink }}&title={{ .Title }}" target = "_blank" title = "{{ T " share " } } Tumblr " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-tumblr fa-fw") -}}
2019-08-05 15:15:01 +02:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 009: VKontakte */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.VKontakte | default .Site.Params.Share.VKontakte | eq true -}}
< a href = "//vk.com/share.php?url={{ .Permalink }}&title={{ .Title }}" target = "_blank" title = "{{ T " share " } } VKontakte " >
2020-02-17 14:02:27 +01:00
{{- partial "function/icon.html" (dict "class" "fab fa-vk fa-fw") -}}
2019-08-05 15:15:01 +02:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-03 11:38:10 +01:00
2020-02-17 14:02:27 +01:00
{{- /* 010: 微博 */ -}}
2020-02-03 11:38:10 +01:00
{{- if .Params.Share.Weibo | default .Site.Params.Share.Weibo | eq true -}}
2020-02-17 14:02:27 +01:00
< a href = "//service.weibo.com/share/share.php?url={{ .Permalink }}&appkey=&title={{ .Title }}{{ with $.Params.featuredImage }}&pic={{ . }}{{- end -}}" target = "_blank" title = "{{ T " share " } } 微博 " >
{{- partial "function/icon.html" (dict "class" "fab fa-weibo fa-fw") -}}
2019-08-05 15:15:01 +02:00
< / a >
2020-01-31 15:53:04 +01:00
{{- end -}}
2020-02-06 17:10:00 +01:00
{{- end -}}