<?php
if (!defined('ABSPATH')) {
    exit;
}
$current_url        = home_url(chama_get_current_request_uri());
$social_url = urlencode($current_url );
$social_title = urlencode(html_entity_decode(get_the_title(), ENT_COMPAT, 'UTF-8'));
$bluesky_url = 'https://bsky.app/intent/compose?text=' . $social_title . ' ' . $social_url;
$facebook_url = 'https://www.facebook.com/sharer?u=' . $social_url . '&amp;t=' . $social_title;
$linkedin_url = 'https://www.linkedin.com/sharing/share-offsite/?url=' . $social_url;
$reddit_url = 'https://www.reddit.com/submit?url=' . $social_url . '&amp;title=' . $social_title;
$threads_url = 'https://threads.net/intent/post?text=' . $social_title . ' ' . $social_url;
$whatsapp_url = 'https://api.whatsapp.com/send?text=' . $social_title . ' ' . $social_url;
$x_url = 'https://x.com/intent/tweet?text=' . $social_title . '&amp;url=' . $social_url;

?>
<a href="<?php echo esc_url($bluesky_url) ?>" title="Share on Bluesky" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-bluesky"></i></div></a>
<a href="<?php echo esc_url($facebook_url) ?>" title="Share on Facebook" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-facebook"></i></div></a>
<a href="<?php echo esc_url($reddit_url) ?>" title="Share on Reddit" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-reddit"></i></div></a>
<a href="<?php echo esc_url($threads_url) ?>" title="Share on Threads" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-threads"></i></div></a>
<a href="<?php echo esc_url($linkedin_url) ?>" title="Share on LinkedIn" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-linkedin"></i></div></a>
<a href="<?php echo esc_url($whatsapp_url) ?>" title="Share on WhatsApp" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-square-whatsapp"></i></div></a>
<a href="<?php echo esc_url($x_url) ?>" title="Share on X" target="_blank" class="chama-share-link"><div class="chama-icon-wrapper"><i class="fab fa-x-twitter"></i></div></a>
<a href="<?php echo esc_url($social_url); ?>" title="Copy Link"  class="chama-copy-link chama-share-link"><div class="chama-icon-wrapper"><i class="far fa-copy"></i></div></a>







