mirror of
https://github.com/hazemKrimi/personal-website.git
synced 2026-05-01 18:00:26 +00:00
chore: new blog post and small patches (#3)
* wip: blog post on open source * wip: initial draft of the blog post * chore: remove sharing a blog post * fix: broken style from previous commit * chore: improve handling keywords
This commit is contained in:
@@ -14,15 +14,6 @@
|
||||
<div>
|
||||
<span>{{ readFile "assets/icons/calendar.svg" | safeHTML }} {{ .Date.Format .Site.Params.dateFormat }}</span>
|
||||
<span>{{ readFile "assets/icons/clock.svg" | safeHTML }} {{ printf "%d minute(s) read" .ReadingTime }}</span>
|
||||
<span
|
||||
id="share"
|
||||
data-title="{{ .Title }}"
|
||||
data-description="{{ .Params.description }}"
|
||||
data-url="{{ .Permalink }}"
|
||||
>
|
||||
{{ readFile "assets/icons/share.svg" | safeHTML }}
|
||||
Share
|
||||
</span>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@@ -35,15 +26,4 @@
|
||||
|
||||
{{ partial "table-of-contents.html" . }}
|
||||
</div>
|
||||
|
||||
|
||||
<script>
|
||||
document.querySelector('#share').addEventListener('click', async event => {
|
||||
await navigator.share({
|
||||
title: event.target.getAttribute('data-title'),
|
||||
description: event.target.getAttribute('data-description'),
|
||||
url: event.target.getAttribute('data-url'),
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{{ end }}
|
||||
|
||||
Reference in New Issue
Block a user