1.0.3 • Published 4 years ago

social-sharing-component v1.0.3

Weekly downloads
5
License
MIT
Repository
-
Last release
4 years ago

social-sharing-component

Lightweight social sharing buttons for your site. Heavily inspired by sharingbuttons.io and react-sharingbuttons. SVG icons by flaticon.

Demo:

https://oleksii-ponomarov.github.io/social-sharing

Installation

npm install social-sharing-component

Usage

import SocialSharing from 'social-sharing-component'
<SocialSharing
	media={['facebook', 'twitter']}
	size="small"
/>

Available props

PropTypeValues
mediastring"all"
-//-"popular" // facebook, twitter, pinterest, linkedin, reddit
-//-"messenger" // whatsapp, telegram, fb-messenger, skype, wechat
arrayarray of media names, i.e.: 'facebook', 'twitter'
textstringcustom text to share
urlstringcustom url to share
sizestring"small", "medium", "large"
cornersstring"circle", "rounded", "square"

Default prop values

media = ''\ text = ""\ url = ""\ size = "small"\ corners = "circle"

Available social media names

facebook\ twitter\ tumblr\ e-mail\ pinterest\ linkedin\ reddit\ xing\ whatsapp\ hackernews\ vk\ telegram\ fb-messenger\ skype\ pocket\ wechat

Changing the size of the buttons

All of the sizes are in em units. So, to change the size of the buttons simply change the font-size property of .social-sharing-button class in your CSS.

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago