1.0.1 • Published 5 years ago

react-native-medium-clap v1.0.1

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

NPM VERSION LICENSE

Highly Customizable Medium Clap Component for react-native & react-native-web.

Installation

1) Make sure to first install & configure react-native-svg

2) Install react-native-medium-clap

npm install react-native-medium-clap

Usage

import MediumClap from 'react-native-medium-clap'


const ClapExample = () => {
  
  const onClapIncrease = (clap) => console.log(`Number of Claps: ${clap}`)

  return (
    <View>
      <MediumClap
        onClapIncrease={onClapIncrease}
        color="07AF6A"
        clapSize={50}
        translateY={30}
        countRadius={15}
        countTextStyle={{ fontSize:16 }}
        maxClapCount={45}
      />
    </View>

  )

}

Configuration

PropertyTypeDefaultDescription
onClapIncreasefunction() => {}callback function on clap increase
clapSizenumber45use this to change the size of clap icon
colorstring#07AF6Ause this to change primary color of component
translateYnumber20use this to change the translation in y direction
maxClapCountnumber50use this to limit the clap count increase
countRadiusnumber20use this to change the size of count component/circle
countTextStylestyle{}use this to apply styles to count text

Showcase

Demo for the component

Author

This library is brought to you by Piyush Gupta ( kida007 )

License

MIT