Skip to content

Commit 41ef125

Browse files
committed
site: Add share buttons on blog
1 parent 11336a1 commit 41ef125

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

_config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ description: >- # this means to ignore newlines until "baseurl:"
2020
Including various features from other projects and some interesting
2121
system apps.
2222
baseurl: "" # the subpath of your site, e.g. /blog
23-
url: "" # the base hostname & protocol for your site, e.g. http://example.com
23+
url: "http://bootleggersrom.github.io" # the base hostname & protocol for your site, e.g. http://example.com
2424
twitter_username: jekyllrb
2525
github_username: jekyll
2626

_layouts/blogpost.html

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
{% include head.html %}
44
<body class="shishu">
55
{% include navbar.html %}
6-
<body>
76
<div class="container">
87
<div class="row">
98
<div class="card shishu-light-bg z-depth-3" id="article">
@@ -21,12 +20,26 @@
2120
</div>
2221
<div class="card-action">
2322
<a href="http://t.me/keepthebootleg">Discuss it on our Telegram</a>
23+
<div class="right">
24+
<i class="dropdown-trigger waves-effect waves-light hide-on-med-and-up shishu-accent material-icons" data-target='share-drop'>share</i>
25+
<a class="dropdown-trigger waves-effect waves-light hide-on-small-only" data-target='share-drop'>Share it on...</a>
26+
<ul id='share-drop' class='dropdown-content'>
27+
<li><a href="https://www.facebook.com/sharer/sharer.php?u={{ site.url }}{{ page.url }}" target="_blank">Facebook</a></li>
28+
<li><a href="http://twitter.com/share?url={{ site.url }}{{ page.url }}&text={{ page.title }}">Twitter</a></li>
29+
<li><a href="https://reddit.com/submit?url={{ site.url }}{{ page.url }}&title={{ page.title }}">Reddit</a></li>
30+
<li class="hide-on-med-and-up"><a href="whatsapp://send?text={{ page.title }}: {{ site.url }}{{ page.url }}" data-action="share/whatsapp/share">WhatsApp</a></li>
31+
<li><a href="tg://msg?url={{ site.url }}{{ page.url }}&text={{ page.title }}">Telegram</a></li>
32+
</ul>
33+
</div>
2434
</div>
2535
</div>
2636
</div>
2737
</div>
28-
</body>
2938
{% include footerlinks.html %}
39+
40+
<script type="text/javascript">
41+
$('.dropdown-trigger').dropdown({'alignment':'right'});
42+
</script>
3043
{% include jsincludes.html %}
3144
</body>
3245
</html>

0 commit comments

Comments
 (0)