import { View, Button } from "@tarojs/components";
import './index.scss'
import NamedIcon from "../NamedIcon";

export default function ShareBtn(props) {

  const handleClick = props.onClick || (() => {})

  return (
    <Button className="sharebtn" onClick={handleClick} openType={props.openType}>
      <View>
        {props.name=='share-friends'&&<Image style="width:56rpx;height:56rpx" src={require('../../assets/share-friends.png')}></Image>}
        {props.name=='sharing-circleoffriends'&&<Image style="width:56rpx;height:56rpx" src={require('../../assets/sharing-circleoffriends.png')}></Image>}
      </View>
      <View>
        <Text>{props.tips}</Text>
      </View>
    </Button>
  )
}