Skip to content

Commit

Permalink
site: Add share buttons on blog
Browse files Browse the repository at this point in the history
  • Loading branch information
eldainosor committed Jul 12, 2019
1 parent 11336a1 commit cea08ae
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ description: >- # this means to ignore newlines until "baseurl:"
Including various features from other projects and some interesting
system apps.
baseurl: "" # the subpath of your site, e.g. /blog
url: "" # the base hostname & protocol for your site, e.g. http://example.com
url: "http://bootleggersrom.github.io" # the base hostname & protocol for your site, e.g. http://example.com
twitter_username: jekyllrb
github_username: jekyll

Expand Down
1 change: 1 addition & 0 deletions _includes/jsincludes.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
$('.collapsible').collapsible();
$('.tooltipped').tooltip();
$('.parallax').parallax();
$('.dropdown-trigger').dropdown({'alignment':'right'});
});
$('a[href*="#"]').on('click', function (e) {
e.preventDefault();
Expand Down
13 changes: 11 additions & 2 deletions _layouts/blogpost.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
{% include head.html %}
<body class="shishu">
{% include navbar.html %}
<body>
<div class="container">
<div class="row">
<div class="card shishu-light-bg z-depth-3" id="article">
Expand All @@ -21,11 +20,21 @@
</div>
<div class="card-action">
<a href="http://t.me/keepthebootleg">Discuss it on our Telegram</a>
<div class="right">
<i class="dropdown-trigger waves-effect waves-light hide-on-med-and-up shishu-accent material-icons" data-target='share-drop'>share</i>
<a class="dropdown-trigger waves-effect waves-light hide-on-small-only" data-target='share-drop'>Share it on...</a>
<ul id='share-drop' class='dropdown-content'>
<li><a href="https://www.facebook.com/sharer/sharer.php?u={{ site.url }}{{ page.url }}" target="_blank">Facebook</a></li>
<li><a href="http://twitter.com/share?url={{ site.url }}{{ page.url }}&text={{ page.title }}">Twitter</a></li>
<li><a href="https://reddit.com/submit?url={{ site.url }}{{ page.url }}&title={{ page.title }}">Reddit</a></li>
<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>
<li><a href="tg://msg?url={{ site.url }}{{ page.url }}&text={{ page.title }}">Telegram</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</body>
{% include footerlinks.html %}
{% include jsincludes.html %}
</body>
Expand Down

0 comments on commit cea08ae

Please sign in to comment.