| Title: | Seamless Integration of Sharing and Connect Buttons in Markdown and Apps |
|---|---|
| Description: | Implementation of 'JQuery' <https://jquery.com> and 'CSS' styles to allow easy incorporation of various social media elements on a page. The elements include addition of share buttons or connect with us buttons or hyperlink buttons to 'Shiny' applications or dashboards and 'Rmarkdown' documents.Sharing capability on social media platforms including 'Facebook' <https://www.facebook.com>, 'Linkedin' <https://www.linkedin.com>, 'X/Twitter' <https://x.com>, 'Tumblr' <https://www.tumblr.com>, 'Pinterest' <https://www.pinterest.com>, 'Whatsapp' <https://www.whatsapp.com>, 'Reddit' <https://www.reddit.com>, 'Baidu' <https://www.baidu.com>, 'Blogger' <https://www.blogger.com>, 'Weibo' <https://www.weibo.com>, 'Instagram' <https://www.instagram.com>, 'Telegram' <https://www.telegram.me>, 'Youtube' <https://www.youtube.com>. |
| Authors: | Obinna Obianom [aut, cre] |
| Maintainer: | Obinna Obianom <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 1.2.1 |
| Built: | 2026-05-24 08:22:29 UTC |
| Source: | https://github.com/oobianom/r2social |
Buttons for others to connect socially to you
connectButton( link, image = NULL, text = NULL, position = c("left", "right", "inline"), display.inline = TRUE, link.out = TRUE, bg.col = NULL, plain = FALSE, visit.us = FALSE, facebook = FALSE, linkedin = FALSE, x = FALSE, tumblr = FALSE, pinterest = FALSE, whatsapp = FALSE, reddit = FALSE, instagram = FALSE, blogger = FALSE, weibo = FALSE, tiktok = FALSE, vk = FALSE, telegram = FALSE, youtube = FALSE )connectButton( link, image = NULL, text = NULL, position = c("left", "right", "inline"), display.inline = TRUE, link.out = TRUE, bg.col = NULL, plain = FALSE, visit.us = FALSE, facebook = FALSE, linkedin = FALSE, x = FALSE, tumblr = FALSE, pinterest = FALSE, whatsapp = FALSE, reddit = FALSE, instagram = FALSE, blogger = FALSE, weibo = FALSE, tiktok = FALSE, vk = FALSE, telegram = FALSE, youtube = FALSE )
link |
the direct link to connect to |
image |
image link only for pinterest |
text |
text link for X |
position |
position of buttons e.g "left","right","bottom","inline" |
display.inline |
TRUE or FALSE if the button should be inline |
link.out |
visit custom link |
bg.col |
background color for the icons. |
plain |
logical. with or without background |
visit.us |
visit custom link |
facebook |
link to an account on Facebook |
linkedin |
link to an account on Linkedin |
x |
link to an account on X |
tumblr |
link to an account on Tumblr |
pinterest |
link to an account on Pinterest |
whatsapp |
link to an account on Whatsapp |
reddit |
link to an account on Reddit |
instagram |
link to an account on Instagram |
blogger |
link to an account on blogger |
weibo |
link to an account on weibo |
tiktok |
link to an account on tiktok |
vk |
link to an account on VK or VKontakte |
telegram |
link to an account on Telegram |
youtube |
link to an account on Youtube |
Connect with me/us button via social links
More examples and demo pages are located at this link - https://r2social.obi.obianom.com.
'bg.col' argument is only functional if 'plain' argument is set to false
connectButton( link = "//rpkg.net", visit.us = TRUE, position = "left") connectButton( link = "//www.linkedin.com/in/oobianom", linkedin = TRUE, position = "right") connectButton( link = "//x.com/R2Rpkg", x = TRUE, position = "inline") # NOT styled connectButton( link = "//rpkg.net", visit.us = TRUE, position = "left") connectButton( link = "//www.linkedin.com/in/oobianom", linkedin = TRUE, plain = TRUE, position = "right") connectButton( link = "//x.com/R2Rpkg", x = TRUE, position = "inline")connectButton( link = "//rpkg.net", visit.us = TRUE, position = "left") connectButton( link = "//www.linkedin.com/in/oobianom", linkedin = TRUE, position = "right") connectButton( link = "//x.com/R2Rpkg", x = TRUE, position = "inline") # NOT styled connectButton( link = "//rpkg.net", visit.us = TRUE, position = "left") connectButton( link = "//www.linkedin.com/in/oobianom", linkedin = TRUE, plain = TRUE, position = "right") connectButton( link = "//x.com/R2Rpkg", x = TRUE, position = "inline")
Social profile card for a any profile
profileDisplay1(item)profileDisplay1(item)
item |
list of profiles along with their image and other items |
HTML of social links displayed on a card
profileDisplay1( list( a = list( name = "Obi Obianom", title = "Senior Scientist", image = "https://r2social.obi.obianom.com/misc/team3.jpg", social = list( list(name = "x", link = "https://x.com/R2Rpkg"), list(name = "linkedin", link = "https://linkedin.com/oobianom"), list(name = "website", link = "https://obianom.com"), list(name = "youtube", link = "https://youtube.com/R2Rpkg") ) ), b = list( name = "William Hane", title = "Core Developer", image = "https://r2social.obi.obianom.com/misc/team1.jpg", social = list(list(name = "youtube", link = "https://youtube.com/R2Rpkg")) ), c = list( name = "Maximillian Qian", title = "Code Cleaner", image = "https://r2social.obi.obianom.com/misc/team2.jpg", social = list(list(name = "facebook", link = "https://facebook.com/R2Rpkg")) ) ))profileDisplay1( list( a = list( name = "Obi Obianom", title = "Senior Scientist", image = "https://r2social.obi.obianom.com/misc/team3.jpg", social = list( list(name = "x", link = "https://x.com/R2Rpkg"), list(name = "linkedin", link = "https://linkedin.com/oobianom"), list(name = "website", link = "https://obianom.com"), list(name = "youtube", link = "https://youtube.com/R2Rpkg") ) ), b = list( name = "William Hane", title = "Core Developer", image = "https://r2social.obi.obianom.com/misc/team1.jpg", social = list(list(name = "youtube", link = "https://youtube.com/R2Rpkg")) ), c = list( name = "Maximillian Qian", title = "Code Cleaner", image = "https://r2social.obi.obianom.com/misc/team2.jpg", social = list(list(name = "facebook", link = "https://facebook.com/R2Rpkg")) ) ))
Social profile card for a any profile
profileDisplay2(item)profileDisplay2(item)
item |
list of profiles along with their image and other items |
HTML of social links displayed on a card
profileDisplay2( list( a = list( name = "Obi Obianom", image = "https://r2social.obi.obianom.com/misc/team3.jpg", social = list( list( name = "x", link = "https://x.com/R2Rpkg" ), list( name = "linkedin", link = "https://linkedin.com/oobianom" ), list( name = "website", link = "https://obianom.com" ), list( name = "youtube", link = "https://youtube.com/R2Rpkg" ) ) ), b = list( name = "William Hane", title = "Core Developer", image = "https://r2social.obi.obianom.com/misc/team1.jpg", social = list(list( name = "youtube", link = "https://youtube.com/R2Rpkg" )) ), c = list( name = "Maximillian Qian", title = "Code Cleaner", image = "https://r2social.obi.obianom.com/misc/team2.jpg", social = list(list( name = "facebook", link = "https://facebook.com/R2Rpkg" )) ) ) )profileDisplay2( list( a = list( name = "Obi Obianom", image = "https://r2social.obi.obianom.com/misc/team3.jpg", social = list( list( name = "x", link = "https://x.com/R2Rpkg" ), list( name = "linkedin", link = "https://linkedin.com/oobianom" ), list( name = "website", link = "https://obianom.com" ), list( name = "youtube", link = "https://youtube.com/R2Rpkg" ) ) ), b = list( name = "William Hane", title = "Core Developer", image = "https://r2social.obi.obianom.com/misc/team1.jpg", social = list(list( name = "youtube", link = "https://youtube.com/R2Rpkg" )) ), c = list( name = "Maximillian Qian", title = "Code Cleaner", image = "https://r2social.obi.obianom.com/misc/team2.jpg", social = list(list( name = "facebook", link = "https://facebook.com/R2Rpkg" )) ) ) )
Wrap functions needed for styling of the containers
r2social.scripts(name = "sharesocial")r2social.scripts(name = "sharesocial")
name |
script file name |
scripts needed for styling
if (interactive()) { r2social.scripts() }if (interactive()) { r2social.scripts() }
Customizable social icons
Description
For use in making buttons to share a page or connect to your social media
Usage
Arguments
linklink address to share
typetype of social button e.g. share or connect
imageimage link for pinterest only
texttext link for x only
plainlogical. with or without background
positionposition of buttons e.g "left","right","bottom","inline"
text.colortext color
bg.colbackground color for the icons.
facebookshare on Facebook
linkedinshare on Linkedin
xshare on Twitter
tumblrshare on Tumblr
pinterestshare on Pinterest
whatsappshare on Whatsapp
redditshare on Reddit
instagramshare on Instagram
bloggershare on Blogger
weiboshare on Weibo
tiktokshare on Tiktok
vkshare on VK or VKontakte
baidushare on Baidu
telegramshare on Telegram
youtubeshare on Youtube
visit.usvisit a direct link
link.outhyperlink to a page
Value
Social links button to be placed on pages
Examples for r2social
More examples and demo pages are located at this link - https://rpkg.net/package/r2social.
Note
'bg.col' argument is only functional if 'plain' argument is set to false
Examples