
import { View } from '@tarojs/components'
import './index.scss'
import ShareBtn from './ShareBtn'

export default function ShareButtons(props) {

  const tips = !props.circleBtn ? '后台暂未配置海报图，请选择分享给好友或群' : ''

  return (
    <View className="sharebuttons">
      <View className="btns">
        <View className="btn">
          <ShareBtn name="share-friends" tips="发送朋友或群" openType="share" onClick={props.onShareFrineds} />
        </View>
        {props.circleBtn &&
        (
          <View className="btn">
            <ShareBtn name="sharing-circleoffriends" tips="分享至朋友圈" onClick={props.onSharingCircleOfFriends} />
          </View>
        )
        }
      </View>
      <View className="tips">{tips}</View>
    </View>
  )
}
