Hey @vireev
Thank you for the five star review.
We got you covered.
add_filter( 'ssb_buttons_output', 'add_pocket_button' );
/**
* Adding Custom Social Network.
*
* @param array $buttons Selected social networks.
* @return array
*/
function add_pocket_button( $buttons ) {
$pocket_icon = '<svg enable-background="new 0 0 0 0" height="40" viewBox="0 0 24 24" width="40" xmlns="http://www.w3.org/2000/svg"><circle cx="12" cy="12" fill="#039be5" r="12"/><path d="m5.491 11.74 11.57-4.461c.537-.194 1.006.131.832.943l.001-.001-1.97 9.281c-.146.658-.537.818-1.084.508l-3-2.211-1.447 1.394c-.16.16-.295.295-.605.295l.213-3.053 5.56-5.023c.242-.213-.054-.333-.373-.121l-6.871 4.326-2.962-.924c-.643-.204-.657-.643.136-.953z" fill="#fff"/></svg>';
$link = get_permalink();
$buttons[] = '<button class="ssb-telegram-icon" onclick="javascript:window.open(this.dataset.href, \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600\');return false;" data-href="https://t.me/share/url?url=' . esc_url( $link ) . '"> ' . $pocket_icon . '</button>';
return $buttons;
}
Kindly copy and paste the following piece of code at the end of functions.php file of your theme and it will add a telegram button as well.
Have a nice day!