blog.lazkani.io/layouts/partials/share.html

34 lines
1.3 KiB
HTML

<ul>
{{ $icon_class_name := .Scratch.Get "icon_class_name"}}
{{ if .Description }}
{{ .Scratch.Set "description" .Description }}
{{ else }}
{{ .Scratch.Set "description" .Summary }}
{{ end }}
{{ $description := .Scratch.Get "description" }}
<li>
<a class="icon" href="https://getpocket.com/save?url={{ .Permalink }}&title={{ .Title }}" aria-label="Pocket">
<i class="fab fa-get-pocket {{ $icon_class_name }}" aria-hidden="true"></i>
</a>
</li>
<li>
<a class="icon" href="mailto:?subject={{ .Title }}&body=Check out this article: {{ .Permalink }}" aria-label="Email">
<i class="fas fa-envelope {{ $icon_class_name }}" aria-hidden="true"></i>
</a>
</li>
<li>
<a class="icon" href="https://twitter.com/share?url={{ .Permalink }}&text={{ .Title }}" aria-label="Twitter">
<i class="fab fa-twitter {{ $icon_class_name }}" aria-hidden="true"></i>
</a>
</li>
<li>
<a class="icon" href="http://reddit.com/submit?url={{ .Permalink }}&title={{ .Title }}" aria-label="reddit">
<i class="fab fa-reddit {{ $icon_class_name }}" aria-hidden="true"></i>
</a>
</li>
<li>
<a class="icon" href="http://www.linkedin.com/shareArticle?url={{ .Permalink }}&title={{ .Title }}" aria-label="Linkedin">
<i class="fab fa-linkedin {{ $icon_class_name }}" aria-hidden="true"></i>
</a>
</li>
</ul>